You are on page 1of 7

Huawei 2G

select group_name,tanggal,week=datepart(week,tanggal),total_traffic=tch_traffictot
from hw_dtch_2wneday
where group_id = 'area'
and tanggal between '1/3/2011' and '1/9/2011'
order by group_name,tanggal asc
ALU 2G
select group_name,tanggal,week=datepart(week,tanggal),
total_traffic=tch_total_traffic
from al_ne_day
where group_id = 'area'

and tanggal between '1/3/2012' and '1/9/2012'


order by group_name,tanggal asc

Huawei 3G
select rnc,time,week=datepart(week,time),
speech_traffic=sp_traff_tot,video_traffic=vp_traff_tot,
packet_traffic=ps_traff_tot
from hw_3g_rnc_day
where (rnc like 'medan%' or rnc like 'pekanbaru%')
and time between '7/1/2009' and '7/5/2009'
order by rnc,time asc

select distinct
RNC,week=datepart(week,time),
Speech_Traffic_Tot=sum(sp_traff_tot)
from hw_3G_RNC_DAY
where datepart(week,time) = 21 and RNC in
('RNBTM01','RNPKB02','RNMDN02','RNMDN03')
group by RNC,datepart(week,time)
ALU DEPO
select distinct
cell_name,cell_id,week=datepart(week,tanggal),
tch=max(tch_avail_max),trafficvol=sum(tch_total_traffic),trafficmax=avg(tch_traffic_bs
yhr),
cong=avg(tch_cong_ratio),tdrop=avg(tch_drop_ratio),pdrop=avg(perceive_drop_rate)
from al_cell_day
where datepart(week,tanggal) = 19
group by cell_name,cell_id,datepart(week,tanggal)
SLA drop = IF(H3990<1.5,"<1.5",IF(H3990>4,">4","1.5-4"))

HW DEPO
select distinct
ne_name,cell,week=datepart(week,tanggal), year=datepart(year,tanggal),
tch=max(tch_avail),trafficvol=sum(tch_traffictot),trafficmax=avg(tch_trafficmax),cong=
avg(tchcong_rate),tdrop=avg(TCHDROP_RATE),pdrop=avg(PERCEIV_RATE),tch_dro
p=sum(TCH_DROP),TCH_AVAIL=avg(TCH_AVAIL),tch_usability=avg(TCH_USBLT
Y)
from hw_dtch_2wday
where cluster = 'west hw'
and datepart(week,tanggal) = 19
group by ne_name,cell,datepart(week,tanggal),datepart(year,tanggal)
new script HW Depo
select distinct
ne_name,cell,week=datepart(week,tanggal), year=datepart(year,tanggal),
tch=max(tch_avail),trafficvol=sum(tch_traffictot),trafficmax=avg(tch_trafficmax),con
g=avg(tchcong_rate),tdrop=avg(TCHDROP_RATE),pdrop=avg(PERCEIV_RATE),tch_usb
lty=avg(TCH_USBLTY)
from hw_dtch_2wday
where cluster = 'west hw'
and datepart(week,tanggal) = 37
group by ne_name,cell,datepart(week,tanggal),datepart(year,tanggal)

select distinct
ne_name,cell,week=datepart(week,tanggal),
year=datepart(year,tanggal),cluster,
tch=max(tch_avail),trafficvol=sum(tch_traffictot),trafficmax=avg(tch_trafficm
ax),cong=avg(tchcong_rate),tdrop=avg(TCHDROP_RATE),pdrop=avg(PERCEIV
_RATE),tch_usblty=avg(TCH_USBLTY)
from hw_dtch_2wday
where cluster like 'west%'
and datepart(week,tanggal) = 52
group by ne_name,cell,datepart(week,tanggal),datepart(year,tanggal),cluster
Final script

select distinct
ne_name,cell,week=datepart(week,tanggal),
year=datepart(year,tanggal),cluster,
tch=max(tch_avail),trafficvol=sum(tch_traffictot),trafficmax=avg(tch_trafficm
ax),cong=avg(tchcong_rate),tdrop=avg(TCHDROP_RATE),pdrop=avg(PERCEIV
_RATE),tch_usblty=avg(TCH_USBLTY),tch_drop=sum(TCH_DROP),TCH_AVAIL=av

g(TCH_AVAIL)
from hw_dtch_2wday
where cluster = 'west'
and datepart(week,tanggal) = 52
group by ne_name,cell,datepart(week,tanggal),datepart(year,tanggal),cluster

select group_name,tanggal,week=datepart(week,tanggal),
seiz_call,tch_drop,perceiv_rate,tch_overflow,tchdrop_rate,tchcong_rate,Ineffectif
=100-suc_call_rate,calmnbedrp,tch_avail,

tch_traffictot,site_total,TCH_USBLTY
from HW_DTCH_2WNEDAY
where datepart(week,tanggal) > 0
and (group_id like 'area' or group_name like 'west_hw')
Formula nentuin cluster hourly trend traffic
=IF(OR(B2="Banda Aceh",B2=Deli
Serdang,B2=KARO,B2="Lhokseumawe",B2=Tebing
Tinggi,B2="Medan",B2="Pematang Siantar",B2="Rantau Prapat",B2="Padang
Sidempuan"),"SUMBAGUT",IF(OR(B2="muba",B2="bandar
lampung",B2="bangka",B2="baturaja",B2="belitung",B2="bengkulu",B2="jambi",B2="
kota bumi",B2="lubuk linggau",B2="muara bungo",B2="palembang",B2="KAYU
AGUNG"),"SUMBAGSEL",IF(OR(B2="Batam",B2="Bintan",B2="DUMAI",B2=Kari
mun,B2="Padang 1",B2="Padang 1",B2=Tanjung Batu,B2="Padang
2",B2="Pekanbaru"),"SUMBAGTENG","""")))
Subs=(D2/0.025)/7 / (traffic vol/0.025)/7
ALU
select distinct
ne_name,cell_name,cell_id,week=datepart(week,tanggal),
tch=max(tch_avail_max),trafficvol=sum(tch_total_traffic),trafficmax=avg(tch_traffic_bs
yhr),occup_hr_rate=avg(occup_hr_rate),
cong=avg(tch_cong_ratio),tdrop=avg(tch_drop_ratio),pdrop=avg(perceive_drop_rate)
from al_cell_day
where datepart(week,tanggal) = 10 and year =2011
group by ne_name, cell_name,cell_id,datepart(week,tanggal)
new script ALU Depo
select distinct
ne_name,cell_name,cell_id,week=datepart(week,tanggal),year=datepart(year,tanggal),
tch=max(tch_avail_max),trafficvol=sum(tch_total_traffic),trafficmax=avg(tch_traffic_bs
yhr),occup_hr_rate=avg(occup_hr_rate),
cong=avg(tch_cong_ratio),tdrop=avg(tch_drop_ratio),pdrop=avg(perceive_drop_rate),tch
_avail=avg(tch_avail)
from al_cell_day
where datepart(week,tanggal) = 37
group by ne_name, cell_name,cell_id,datepart(week,tanggal),datepart(year,tanggal)
Utk mencari tch_avail_rate = 100*tch_avail_max/tch_avail
select distinct
ne_name,cell_name,cell_id,week=datepart(week,tanggal),year=datepart(year,tanggal),

tch=max(tch_avail_max),trafficvol=sum(tch_total_traffic),trafficmax=avg(tch_traffic_bs
yhr),occup_hr_rate=avg(occup_hr_rate),
cong=avg(tch_cong_ratio),tdrop=avg(tch_drop_ratio),pdrop=avg(perceive_drop_rate)
from al_cell_day
where datepart(week,tanggal) = 26
group by ne_name, cell_name,cell_id,datepart(week,tanggal),datepart(year,tanggal)
Formula nentuin subregion
=IF(OR(M2="Banda Aceh",M2=Deli Serdang,M2=Tanah
KARO,M2="Lhokseumawe",M2=Tebing Tinggi,M2="Depo 1 Medan",M2=Depo 2
Medan,M2=Depo 3 Medan,M2=Depo 4 Medan,M2=Asahan,M2=Binjai
Langkat,M2=Meulaboh,M2=Sibolga,M2="Pematang Siantar",M2="Rantau
Prapat",M2=Simalungun,M2=Subulussalam,M2="Padang
Sidempuan"),"SUMBAGUT",IF(OR(M2="Batam",M2="Bintan",M2="DUMAI",M2=B
angkinang,M2="Bukittinggi",M2="Padang",M2=Pekanbaru
ESA,M2="Solok2",M2=Rengat,M2=Rokan
Hulu,M2=Tembilahan,M2="Pekanbaru SUN"),"SUMBAGTENG",""")))
Speech traffic
select * from hw_3G_RNC_DAY where time between '20110501' and '20110523' and
(Group_Name in ('RNBTM01','RNMDN02','RNMDN03','RNPKB02',RNPDP01))
Speech traffic weekly
Select distinct
RNC,week= datepart(week,time),
Speech_Traffic_Tot=sum(sp_traff_tot)
From hw_3G_RNC_DAY
Where datepart(week,time)=21 and datepart(year,time)=2012
And RNC in (RNBTM01,RNPKB02,RNMDN02,RNMDN03,RNPDP01)
Group by RNC,datepart(week,time)
Speech traffic weekly Level Cell
Select
RNC, week= datepart(week,time),
Speech_Traffic_Tot = sum(sp_traff_tot)
From HW_3G_CELL_DAY
Where datepart(week,time)>=1 and datepart(week,time)<5
and datepart(year,time)=2012
And RNC in (RNBTM01,RNPKB02,RNMDN02,RNMDN03,RNPDP01)
Group by RNC,datepart(week,time)
select distinct
RNC,week=21,
Speech_Traffic_Tot=sum(sp_traff_tot)
from hw_3G_RNC_DAY
where -- datepart(week,time) = 21

time >='2011-05-22' and time <='2011-05-28'


and RNC in ('RNBTM01','RNPKB02','RNMDN02','RNMDN03')
group by RNC
--,datepart(week,time)

Speech per cell level


select rnc,cell,cell_name,site_name,time,
SPEECH_TRAFIC
from HW_3G_CELL_DAY
where datepart(week,time) = 4 ganti week yg di inginkan
And RNC in (RNBTM01,RNPKB02,RNMDN02,RNMDN03,RNPDP01)
ganti rnc yg ada di medan
Order by rnc,cell,cell_name,site_name,time
----- Speech traffic daily level cell
select rnc,cell,cell_name,site_name,time,
sp_traff
from hw_3G_cell_day
where time between '20120128' and '20120130' and rnc in
('RNMDN02','RNMDN03',RNMDN04,'RNBTM01','RNPDP01','RNPKB02')
order by rnc,cell,cell_name,site_name,time
select * from HW_3G_CELL_DAY
where time between '20110501' and '20110523' and
(RNC in ('RNBTM01','RNMDN02','RNMDN03','RNPKB02',RNPDP01))
Data per BSC
select group_name,time,week=datepart(week,time),
seiz_call,tch_drop,perceiv_rate,tch_overflow,tchdrop_rate,tchcong_rate,Ineffectif=100suc_call_rate,calmnbedrp,tch_avail,
tch_traffictot,site_total,TCH_USBLTY
from HW_DTCH_2WNEDAY
where datepart(week,time) = 38
and (group_id like 'ne_name' or group_name like 'west_hw')
and group_name not like 'bamb%' and group_name not like 'bbkl2'
and group_name not like 'bsmp%' and group_name not like 'bsam%'
and group_name not like 'blmp%' and group_name not like 'bbjm%'
and group_name not like 'BSOR%'
and group_name not like 'bblp%' and group_name not like 'Bjmb%'
and group_name not like 'bbbl%' and group_name not like 'bkdr%'
and group_name not like 'bkup%' and group_name not like 'bjyp%'
and group_name not like 'bpal%' and group_name not like 'bmks%'
and group_name not like 'bmnd%' and group_name not like 'bplm%'
and group_name not like 'bptk%' and group_name not like 'west hw%'

order by group_name,time desc

select distinct
cell,ne_name,tanggal,
tch_avail,tch_traffictot,tch_trafficmax,tchcong_rate,TCHDROP_RATE,PERCEIV_RATE
,TCH_USBLTY
from hw_dtch_2wday where tanggal between '2012-01-15' and '2012-01-14'
and cluster like 'west%
ALU BSC daily
select * from AL_CELL_DAY where tanggal between '20121127' and '20121203' and
(ne_name like 'BACH3_1' or ne_name like 'BACH3_2' or ne_name like 'BACH4_1' or
ne_name like 'BACH4_2' or ne_name like 'BACH5_' or ne_name like 'BACH5_2' or
ne_name like 'BACH6_1' or ne_name like 'BACH7_1' or ne_name like 'BACH7_2 ' or
ne_name like 'BMD13_1' or ne_name like 'BMD13_2' or ne_name like 'BMD14_1' or
ne_name like 'BMD14_2' or ne_name like 'BPDG2_1' or ne_name like 'BPDG2_2' or
ne_name like 'BPDG4_1' or ne_name like 'BPDG4_2')
HW BSC daily
select * from hw_dtch_2wneday where tanggal between '20071119' and '20071120' and
(group_name in ('bbtm4','bbtm5','bbtm6','bpkb6','bnat1','bbtm8','bbtm7'))
POC daily
select * from POC_DAY_2G
where
(POC_ID like 'AC0' or
POC_ID like 'AC1' or
POC_ID like 'AC2' or
POC_ID like 'AC3' or
POC_ID like 'AC4' or
POC_ID like 'MD0' or
POC_ID like 'MD1' or
POC_ID like 'MD2' or
POC_ID like 'MD3' or
POC_ID like 'MD4' or
POC_ID like 'MD5' or
POC_ID like 'BM0' or
POC_ID like 'BM1' or
POC_ID like 'BM2' or
POC_ID like 'PD0' or
POC_ID like 'PD1' or

POC_ID like 'PK0' or


POC_ID like 'PK1')
And time >=20110807 and time <=20110813

select distinct
ne_name,cell,week=datepart(week,tanggal),
year=datepart(year,tanggal),cluster,
FAIL_CALL=sum(FAIL_CALL),PERCEIVE_CONG_RATE=avg(PERCEIVE_CONG_RAT
)
from HW_PERCONG_DAY
where cluster = 'west'
and datepart(week,tanggal) = 52
group by ne_name,cell,datepart(week,tanggal),datepart(year,tanggal),cluster

You might also like