MLDZMNaal8
Updated 2022-11-08
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
36
›
⌄
with tb1 as(SELECT
*
from solana.core.dim_labels
where label ilike '%alameda%'
or label ilike 'ftx%'
),
tb2 as (select
mint
from solana.core.fact_transfers
where mint in ('EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v',
'Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB',
'6nuaX3ogrr2CaoAPjtaKHAoBNWok32BMcRozuf32s2QF',
'FYpdBuyAHSbdaAyD1sKkxyLWbAP8uUW9h6uvdhK74ij1')
),
tb3 as (select
BLOCK_TIMESTAMP::date as day,
count(distinct TX_ID) as no_transfer,
count(distinct TX_FROM) as no_sender,
sum(AMOUNT) as total_volume,
avg(AMOUNT) as avg_volume,
sum(total_volume) over (order by day) as cum_volume
from solana.core.fact_transfers s left join solana.core.dim_labels b on s.mint=b.address
where MINT in (select mint from tb2)
and TX_TO in (select ADDRESS from tb1)
and TX_FROM not in (select ADDRESS from tb1)
and BLOCK_TIMESTAMP>='2022-10-01'
group by 1),
tb4 as (select
BLOCK_TIMESTAMP::date as day,
count(distinct TX_ID) as no_transfer1,
count(distinct TX_TO) as no_sender1,
sum(AMOUNT) as total_volume1,
avg(AMOUNT) as avg_volume1,
Run a query to Download Data