
02.03 18:41:15.740 Started

 INI

     

  

02.03 18:41:21.479 
Stopped

02.13 09:10:10.151 Started

 INI

     

  
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data

02.13 09:21:06.475 
Stopped

02.13 09:22:13.661 Started

 INI

     

  
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data

02.13 09:27:34.633 
Stopped

02.13 10:15:04.220 Started

 INI

     

  
drop table if exists abonents
drop table if exists duration
drop table if exists abonents
drop table if exists duration
select zone,   concat(comment,' (',zone,')') as 'comment' from ccsx.zone where country=64 order by 'comment' 
select ind,   concat(comment,' (',ind,')') as 'comment' from ccsx.ind where country=64 and zone=111
select zone,   concat(comment,' (',zone,')') as 'comment' from ccsx.zone where country=64 order by 'comment' 
select ind,   concat(comment,' (',ind,')') as 'comment' from ccsx.ind where country=64 and zone=141
select in_country as '. ', in_zone as '. ', in_ind as '. ', in_channel as '. ', incomingcalltime as ' . ', callednumber as ' ', out_country as '. ', out_zone as '. ', out_ind as '. ', out_channel as '. ', establishconnectiontime as '  ', disconnecttime as ' ', duration as '', t2.description as ' ' from ccsx.connection t1 left join ccsx.con_close_reason t2 on t1.closereason = t2.id_reas where id>0  and in_country=64 and in_zone=111 and out_country=64 and out_zone=141 and incomingcalltime >= '2012-02-01 00:00:00' and incomingcalltime <='2012-02-12 23:29:59' 

02.13 10:22:33.997 
Stopped

02.14 03:53:27.323 Started

 INI

     

  
drop table if exists abonents
drop table if exists duration

02.14 03:53:42.595 
Stopped

02.14 04:14:08.879 Started

 INI

     

  
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data
drop table if exists abonents
drop table if exists duration
drop table if exists abonents
drop table if exists duration

02.14 05:10:36.450 
Stopped

02.14 05:10:47.255 Started

 INI

     

  
drop table if exists tempDirs
drop table if exists inDir
drop table if exists outDir
create table tempDirs as select concat(i.country,'-',i.zone,i.ind) as direct from ccsx.ind as i left join ccsx.channel as c on c.country=i.country and c.zone=i.zone and c.ind=i.ind left join ccsx.point as p on p.ac=c.ac and p.point=c.point where p.state=4 or i.ispipe=1 group by concat(i.country,'-',i.zone,i.ind)
create table inDir as select concat(in_country,'-', in_zone, in_ind) as 'in_direct',  count(*) as 'in_count',  sum(if(duration>0,1,0)) as 'in_succsessful',  sum(if(duration=0,1,0)) as 'in_unsuccsessful',  sum(if(closereason=4,1,0)) as 'in_occ',  sum(if(closereason=5,1,0)) as 'in_der',  if(count(*)>1,((sum(if(duration=0,1,0))/count(*))*100),0) as 'in_percent'  from ccsx.connection  where incomingCallTime >= '2012-02-01 00:00:00' and incomingCallTime <= '2012-02-13 23:59:59'  group by concat(in_country,'-' ,in_zone, in_ind) 
create table outDir as select concat(out_country,'-', out_zone, out_ind) as 'out_direct',  count(*) as 'out_count',  sum(if(duration>0,1,0)) as 'out_succsessful',  sum(if(duration=0,1,0)) as 'out_unsuccsessful',  sum(if(closereason=4,1,0)) as 'out_occ',  sum(if(closereason=5,1,0)) as 'out_der',  if(count(*)>1,((sum(if(duration=0,1,0))/count(*))*100),0) as 'out_percent'  from ccsx.connection  where incomingCallTime >= '2012-02-01 00:00:00' and incomingCallTime <= '2012-02-13 23:59:59'  group by concat(out_country,'-' ,out_zone, out_ind) 
select   t.direct,  if(i.in_count is null,0,i.in_count) as 'in_count',   if(i.in_unsuccsessful is null,0,i.in_unsuccsessful) as 'in_unsuccsessful',  if(i.in_percent is null,0,i.in_percent) as 'in_percent',   if(o.out_count is null,0,o.out_count) as 'out_count',  if(o.out_unsuccsessful is null,0,o.out_unsuccsessful) as 'out_unsuccsessful',  if(i.in_occ is null,0,i.in_occ) as 'in_occ',  if(i.in_der is null,0,i.in_der) as 'in_der',  if(o.out_percent is null,0,o.out_percent) as 'out_percent'  from  ccsx_tarif.tempDirs as t  left join ccsx_tarif.inDir as i on i.in_direct=t.direct  left join ccsx_tarif.outDir as o on o.out_direct=t.direct
drop table if exists tempDirs
drop table if exists inDir
drop table if exists outDir

02.14 05:12:59.816 
Stopped

02.15 02:36:56.379 Started

 INI

     

  
drop table if exists abonents
drop table if exists duration
drop table if exists abonents
drop table if exists duration
drop table if exists abonents
drop table if exists duration
drop table if exists abonents
drop table if exists duration

02.15 02:47:55.086 
Stopped

02.17 02:10:35.310 Started

 INI

     

  
select zone,   concat(comment,' (',zone,')') as 'comment' from ccsx.zone where country=64 order by 'comment' 
select zone,   concat(comment,' (',zone,')') as 'comment' from ccsx.zone where country=64 order by 'comment' 
select ind,   concat(comment,' (',ind,')') as 'comment' from ccsx.ind where country=64 and zone=339
select in_country as '. ', in_zone as '. ', in_ind as '. ', in_channel as '. ', incomingcalltime as ' . ', callednumber as ' ', out_country as '. ', out_zone as '. ', out_ind as '. ', out_channel as '. ', establishconnectiontime as '  ', disconnecttime as ' ', duration as '', t2.description as ' ' from ccsx.connection t1 left join ccsx.con_close_reason t2 on t1.closereason = t2.id_reas where id>0  and in_country=64 and out_country=64 and out_zone=339 and incomingcalltime >= '2012-02-10 00:00:00' and incomingcalltime <='2012-02-16 23:29:59' 

02.17 02:14:26.642 
Stopped

02.27 02:21:00.298 Started

 INI

     

  

02.27 02:30:54.322 
Stopped

02.27 02:43:22.017 Started

 INI

     

  
select zone,   concat(comment,' (',zone,')') as 'comment' from ccsx.zone where country=64 order by 'comment' 
select ind,   concat(comment,' (',ind,')') as 'comment' from ccsx.ind where country=64 and zone=141
select zone,   concat(comment,' (',zone,')') as 'comment' from ccsx.zone where country=64 order by 'comment' 
select in_country as '. ', in_zone as '. ', in_ind as '. ', in_channel as '. ', incomingcalltime as ' . ', callednumber as ' ', out_country as '. ', out_zone as '. ', out_ind as '. ', out_channel as '. ', establishconnectiontime as '  ', disconnecttime as ' ', duration as '', t2.description as ' ' from ccsx.connection t1 left join ccsx.con_close_reason t2 on t1.closereason = t2.id_reas where id>0  and in_country=64 and in_zone=141 and in_ind=687 and out_country=64 and incomingcalltime >= '2012-02-01 00:00:00' and incomingcalltime <='2012-02-26 23:29:59' 
drop table if exists abonents
drop table if exists duration
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-02-01 00:00:00' and '2012-02-26 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-02-01 00:00:00' and '2012-02-26 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data
drop table if exists abonents
drop table if exists duration
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data
drop table if exists abonents
drop table if exists duration
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-02-01 00:00:00' and '2012-02-26 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-02-01 00:00:00' and '2012-02-26 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data
drop table if exists abonents
drop table if exists duration

02.27 02:52:39.048 
Stopped

02.27 03:09:44.813 Started

 INI

     

  
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-01-01 00:00:00' and '2012-01-31 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data
drop table if exists abonents
drop table if exists duration
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-02-01 00:00:00' and '2012-02-26 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-02-01 00:00:00' and '2012-02-26 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data
drop table if exists abonents
drop table if exists duration
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-02-01 00:00:00' and '2012-02-26 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-02-01 00:00:00' and '2012-02-26 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data
drop table if exists abonents
drop table if exists duration

02.27 03:32:56.434 
Stopped

02.27 03:38:33.198 Started

 INI

     

  
select zone,   concat(comment,' (',zone,')') as 'comment' from ccsx.zone where country=64 order by 'comment' 
select ind,   concat(comment,' (',ind,')') as 'comment' from ccsx.ind where country=64 and zone=295
select zone,   concat(comment,' (',zone,')') as 'comment' from ccsx.zone where country=64 order by 'comment' 
select in_country as '. ', in_zone as '. ', in_ind as '. ', in_channel as '. ', incomingcalltime as ' . ', callednumber as ' ', out_country as '. ', out_zone as '. ', out_ind as '. ', out_channel as '. ', establishconnectiontime as '  ', disconnecttime as ' ', duration as '', t2.description as ' ' from ccsx.connection t1 left join ccsx.con_close_reason t2 on t1.closereason = t2.id_reas where id>0  and in_country=64 and in_zone=295 and in_ind=162 and out_country=64 and incomingcalltime >= '2012-02-01 00:00:00' and incomingcalltime <='2012-02-26 23:29:59' 

02.27 03:39:51.281 
Stopped

03.01 02:38:31.921 Started

 INI

     

  
drop table if exists abonents
drop table if exists duration

03.01 02:45:10.765 
Stopped

03.06 02:21:21.285 Started

 INI

     

  
drop table if exists abonents
drop table if exists duration
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-03-01 00:00:00' and '2012-03-05 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-03-01 00:00:00' and '2012-03-05 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-03-01 00:00:00' and '2012-03-05 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-03-01 00:00:00' and '2012-03-05 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data
drop table if exists abonents
drop table if exists duration

03.06 02:33:58.814 
Stopped

04.02 01:12:58.317 Started

 INI

     

  

04.02 01:13:25.115 
Stopped

04.02 01:38:04.773 Started

 INI

     

  
drop table if exists abonents
drop table if exists duration
drop table if exists abonents
drop table if exists duration

04.02 01:45:43.352 
Stopped

04.02 01:45:58.063 Started

 INI

     

  
drop table if exists abonents
drop table if exists duration

04.02 02:10:11.583 
Stopped

05.01 12:50:55.668 Started

 INI

     

  

05.01 12:51:06.493 
Stopped

05.01 12:54:13.422 Started

 INI

     

  

  

  
select in_country as '. ', in_zone as '. ', in_ind as '. ', in_channel as '. ', incomingcalltime as ' . ', callednumber as ' ', out_country as '. ', out_zone as '. ', out_ind as '. ', out_channel as '. ', establishconnectiontime as '  ', disconnecttime as ' ', duration as '', t2.description as ' ' from ccsx.connection t1 left join ccsx.con_close_reason t2 on t1.closereason = t2.id_reas where id>0 

05.01 12:57:00.612 
Stopped

05.01 12:59:46.748 Started

 INI
mySQL Error Code: (2003)
Can't connect to MySQL server on '172.30.4.180' (0)
    .      

05.01 13:00:37.561 
Stopped

05.01 13:02:39.556 Started

 INI
mySQL Error Code: (2003)
Can't connect to MySQL server on '172.30.4.180' (0)
    .      

05.01 13:57:08.321 
Stopped

05.01 14:05:48.443 Started

 INI

     

  
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-04-01 00:00:00' and '2012-04-30 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-04-01 00:00:00' and '2012-04-30 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2011-12-01 00:00:00' and '2012-04-30 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2011-12-01 00:00:00' and '2012-04-30 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data
drop table if exists abonents
drop table if exists duration
create table abonents as select concat(c.zone, c.ind) as abonent from ccsx.channel as c where c.country=64 group by c.zone, c.ind
create table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-04-01 00:00:00' and '2012-04-30 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_datacreate table duration as select CONCAT(in_zone,in_ind) as abonent, sum(truncate((connection.duration+59)/60,0)) as sum, coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) as id_group_tariff, group_tariff_data.id as id_group_tariff_data from ccsx.connection left join ccsx_tarif.zone as t1 on t1.country = connection.out_country and  t1.zone=left(connection.calledNumber,3) and t1.ind=right(connection.calledNumber,3) left join ccsx_tarif.zone as t2 on t2.country = connection.out_country and  t2.zone=left(connection.calledNumber,3) and t2.ind is null left join ccsx_tarif.zone as t3 on t3.country = connection.out_country and  t3.zone=connection.out_zone and t3.ind=connection.out_ind left join ccsx_tarif.zone as t4 on t4.country = connection.out_country and  t4.zone=connection.out_zone and t4.ind is null left join ccsx_tarif.group_tariff_data on  incomingCallTime between group_tariff_data.period_start and group_tariff_data.period_end  and group_tariff_data.id_tariff=coalesce(t1.id_tariff, t3.id_tariff,t2.id_tariff, t4.id_tariff) where connection.incomingCallTime between '2012-04-01 00:00:00' and '2012-04-30 23:59:59'  and connection.duration > 5  group by in_zone, in_ind, id_group_tariff, id_group_tariff_data

05.01 14:11:24.553 
Stopped

11.01 12:27:46.680 Started

 INI

     

  

11.01 12:28:11.676 
Stopped

03.01 10:01:53.381 Started

 INI

     

  

03.01 10:02:45.215 
Stopped

04.01 11:02:53.396 Started

 INI
mySQL Error Code: (2003)
Can't connect to MySQL server on '172.30.4.180' (0)
     .      

04.01 11:07:57.854 
Stopped

10.26 03:39:33.753 Started

 INI

     

  

10.26 03:39:37.919 
Stopped

10.04 05:02:51.343 Started

 INI

     

  

  

  

10.04 05:04:55.846 
Stopped

11.14 06:48:29.993 Started

 INI

     

  

11.14 06:48:35.040 
Stopped

04.18 04:44:31.204 Started

 INI

     

  

04.18 04:44:56.333 
Stopped

05.12 04:38:00.286 Started

 INI

     

  

  

  
drop table if exists tempDirs
drop table if exists inDir
drop table if exists outDir
create table tempDirs as select concat(i.country,'-',i.zone,i.ind) as direct from ccsx.ind as i left join ccsx.channel as c on c.country=i.country and c.zone=i.zone and c.ind=i.ind left join ccsx.point as p on p.ac=c.ac and p.point=c.point where p.state<>4 and i.ispipe<>1 group by concat(i.country,'-',i.zone,i.ind)
create table inDir as select concat(in_country,'-', in_zone, in_ind) as 'in_direct',  count(*) as 'in_count',  sum(if(duration>0,1,0)) as 'in_succsessful',  sum(if(duration=0,1,0)) as 'in_unsuccsessful',  sum(if(closereason=4,1,0)) as 'in_occ',  sum(if(closereason=5,1,0)) as 'in_der',  if(count(*)>1,((sum(if(duration=0,1,0))/count(*))*100),0) as 'in_percent'  from ccsx.connection  where incomingCallTime >= '2022-04-01 00:00:00' and incomingCallTime <= '2022-04-30 23:59:59'  group by concat(in_country,'-' ,in_zone, in_ind) 
create table outDir as select concat(out_country,'-', out_zone, out_ind) as 'out_direct',  count(*) as 'out_count',  sum(if(duration>0,1,0)) as 'out_succsessful',  sum(if(duration=0,1,0)) as 'out_unsuccsessful',  sum(if(closereason=4,1,0)) as 'out_occ',  sum(if(closereason=5,1,0)) as 'out_der',  if(count(*)>1,((sum(if(duration=0,1,0))/count(*))*100),0) as 'out_percent'  from ccsx.connection  where incomingCallTime >= '2022-04-01 00:00:00' and incomingCallTime <= '2022-04-30 23:59:59'  group by concat(out_country,'-' ,out_zone, out_ind) 
select   t.direct,  if(i.in_count is null,0,i.in_count) as 'in_count',   if(i.in_unsuccsessful is null,0,i.in_unsuccsessful) as 'in_unsuccsessful',  if(i.in_percent is null,0,i.in_percent) as 'in_percent',   if(o.out_count is null,0,o.out_count) as 'out_count',  if(o.out_unsuccsessful is null,0,o.out_unsuccsessful) as 'out_unsuccsessful',  if(i.in_occ is null,0,i.in_occ) as 'in_occ',  if(i.in_der is null,0,i.in_der) as 'in_der',   if(o.out_percent is null,0,o.out_percent) as 'out_percent'  from  ccsx_tarif.tempDirs as t  left join ccsx_tarif.inDir as i on i.in_direct=t.direct  left join ccsx_tarif.outDir as o on o.out_direct=t.direct
drop table if exists tempDirs
drop table if exists inDir
drop table if exists outDir

05.12 04:44:49.805 
Stopped

05.12 05:15:31.944 Started

 INI

     

  

05.12 05:15:37.392 
Stopped

05.12 05:28:03.855 Started

 INI

     

  

05.12 05:28:09.002 
Stopped
