Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- select
- CASE
- WHEN (deviceType = 2 AND appVersion % 2 = 0) THEN 'iOS_Parent'
- WHEN (deviceType = 1 AND appVersion % 2 = 1) THEN 'Android_Parent'
- WHEN (deviceType = 2 AND appVersion % 2 = 1) THEN 'iOS_Child'
- WHEN (deviceType = 1 AND appVersion % 2 = 0) THEN 'Android_Child'
- ELSE 'Unknown'
- END AS platform,
- action,
- count(*) as n,
- count(distinct uid) as n_u
- from stat.funnelTrack
- where dt >= today() - interval '14' day
- AND action in ('pmr_content_cards', 'pmr_content_cards_newuser')
- group by 1, 2 order by 2, 1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement