HosseinUntitled Query
Updated 2022-08-01Copy Reference Fork
99
1
2
3
4
5
6
7
8
9
10
11
›
⌄
select day, address, tx_num,n from (
select date_trunc('day', block_timestamp) as day, a.inner_instructions[0]:instructions[0]:parsed:info:owner as address, count(distinct(tx_id)) as tx_num, ROW_NUMBER() OVER (PARTITION BY day ORDER BY tx_num DESC) as n
from solana.core.fact_transactions a
where a.succeeded = 1
and a.inner_instructions[0]:instructions[1]:programId = 'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA'
and a.inner_instructions[0]:instructions[1]:parsed:type = 'mintTo'
and a.inner_instructions[0]:instructions[1]:program = 'spl-token'
and a.inner_instructions[0]:instructions[0]:parsed:info:owner != ''
group by day, address
) where n = 1
order by day
Run a query to Download Data