Skip to content

Instantly share code, notes, and snippets.

@jaymay
Created July 30, 2015 18:31
Show Gist options
  • Save jaymay/5c50e7989c4860bd7f66 to your computer and use it in GitHub Desktop.
Save jaymay/5c50e7989c4860bd7f66 to your computer and use it in GitHub Desktop.
Talkdesk app installs
select a.plan_type, sum(api.num_installs) installs
from accounts a
left outer join app_installs api on a.account_id = api.account_id and a.run_at = api.run_at and a.timespan = api.timespan
inner join apps ap on api.app_id = ap.id
where a.run_at = 20150601
and ap.name like ('talkdesk')
and a.account_type = 'customer'
group by a.plan_type
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment