How to calculate the number of new users in BigQuery

399 views
Skip to first unread message

furdeletenier guargia

unread,
Sep 21, 2022, 11:09:21 AM9/21/22
to Firebase Google Group
Hi team,
I would like to know, in the data exported from Firebase to BigQuery, how to count the number of new users,  which of the following SQL queries is accurate for the number of new users.
1、select event_date as first_date,
count(distinct user_pseudo_id) as new_user
  from `xxxx.analytics.events_*`
  where event_name = 'first_open'
  group by 1
2、
select
format_timestamp('%Y%m%d',timestamp_micros(user_first_touch_timestamp)) as first_date,
count(distinct user_pseudo_id) as new_user,
from `xxxx.analytics.events_*`
where event_name = 'user_engagement'
group by 1
Reply all
Reply to author
Forward
0 new messages