0xHaM-dNew Users
Updated 2024-06-26
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
›
⌄
with new as (
select
block_timestamp,
FROM_ADDRESS as user
from blast.core.fact_transactions a
left outer join blast.core.dim_labels b on a.TO_ADDRESS = b.address
where FROM_ADDRESS not in (
select address from blast.core.dim_labels
)
and STATUS = 'SUCCESS'
UNION all
select
block_timestamp,
TO_ADDRESS as user
from blast.core.fact_transactions a
left outer join blast.core.dim_labels b on a.TO_ADDRESS = b.address
where TO_ADDRESS not in (select address from blast.core.dim_labels)
and STATUS = 'SUCCESS'
)
,
new_user as (
select min(block_timestamp) as min_date,
user
from new
group by 2
)
select trunc(min_date,'d') as weekly,
count(DISTINCT user) as "New Users",
sum("New Users") over (order by weekly asc) as "Cumulative New Users"
from new_user
where min_date::date >= '2024-02-29'
group by 1
QueryRunArchived: QueryRun has been archived