Soheil_MKUntitled Query
Updated 2022-12-07Copy 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
33
34
35
36
›
⌄
with main1 as (
select
TX_HASH,
origin_function_signature ,
(RAW_AMOUNT/pow(10,DECIMALS)) as amounts
from ethereum.core.ez_token_transfers
where ORIGIN_TO_ADDRESS ='0x5954ab967bc958940b7eb73ee84797dc8a2afbb9'
)
select
case
when amounts <100 then '0-100 $APE'
when amounts >=100 and amounts<500 then '100-500 $APE'
when amounts >=500 and amounts<1000 then '500-1000 $APE'
when amounts >=1000 and amounts<5000 then '1000-5000 $APE'
when amounts >=5000 and amounts<10000 then '5000-10000 $APE'
when amounts >=10000 then '+10000 $APE'
End as Tokens,
count(distinct TX_HASH) as txs,
'$APECOIN ($APE) Pool' as type
from main1
where origin_function_signature = '0x9dcaafb4'
group by 1
union all
select
case
when amounts <100 then '0-100 $APE'
when amounts >=100 and amounts<500 then '100-500 $APE'
when amounts >=500 and amounts<1000 then '500-1000 $APE'
when amounts >=1000 and amounts<5000 then '1000-5000 $APE'
when amounts >=5000 and amounts<10000 then '5000-10000 $APE'
when amounts >=10000 then '+10000 $APE'
End as Tokens,
count(distinct TX_HASH) as txs,
Run a query to Download Data