gokcintop 5
Updated 2022-10-20Copy Reference Fork
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
›
⌄
with daus as (
SELECT
distinct tx_from as users,trunc(block_timestamp,'week') as date,
count(distinct trunc(block_timestamp,'day')) as active_days
from osmosis.core.fact_transactions where tx_status = 'SUCCEEDED'
group by 1,2
having active_days>=4
),
active_users as (
SELECT
trunc(block_timestamp,'week') as date,
tx_from as users,
tx_id as txs
from osmosis.core.fact_transactions where tx_from in (select users from daus)
group by 1,2,3
),
transfers as (
select distinct receiver,
count(distinct receiver) as unique_wallet,
count(distinct tx_id) as txs
from osmosis.core.fact_transfers where receiver in (select users from active_users)
group by 1,receiver
)
select receiver,TXS from transfers
order by txs desc
limit 5
Run a query to Download Data