Advertisement
beowulf1416

Untitled

Jul 7th, 2015
200
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.43 KB | None | 0 0
  1. INSERT into reachout_tab_listener_minutes_by_gateway (listener_ani_id,listener_id, ani_e164, gateway_id, did_e164, minutes, created_at)
  2. SELECT listener_ani_id,listener_id, ani_e164, gateway_id, did_e164, sum(seconds/60) as minutes,'2015-07-07' as created_at from log_call force index(date_start)
  3. WHERE date_start > '2015-01-07' and length(ani_e164)=11 group by gateway_id,listener_id having minutes > 35
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement