elsina2024-08-20: daily activity per user
Updated 2024-10-19
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
›
⌄
with users as (
SELECT
date_trunc('day', block_timestamp) as date,
origin_from_address,
count(DISTINCT tx_hash) as tx_count,
count(DISTINCT pool_name) as pool_count,
sum(amount_in_usd) as total_vol,
FROM
avalanche.defi.ez_dex_swaps
WHERE
date >= current_date - interval '30 days'
GROUP BY
date, origin_from_address
)
select
date,
avg(tx_count) as avg_tx_count_per_user,
avg(total_vol) as avg_tot_vol_per_user,
avg(pool_count) as avg_pairs_per_user
from
users
group by
date
order by
date asc
QueryRunArchived: QueryRun has been archived