saeide-ahmadi-7Classification of transactions by value
Updated 2022-08-10
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
›
⌄
with grouped_transactions as(
select
TX_HASH,
case
when ETH_VALUE < 0.01 then 'A: Under 0.01 ETH'
when ETH_VALUE>=0.01 and ETH_VALUE<0.1 then 'B: 0.01-0.1 ETH'
when ETH_VALUE>=0.1 and ETH_VALUE<1 then 'C: 0.1-1 ETH'
when ETH_VALUE>=1 and ETH_VALUE<10 then 'D: 1-10 ETH'
when ETH_VALUE>=10 and ETH_VALUE<100 then 'E: 10-100 ETH'
when ETH_VALUE>=100 then 'F: Above 100 ETH'
end as bucket
from
ethereum.core.fact_transactions join flipside_prod_db.crosschain.address_labels
on TO_ADDRESS = ADDRESS
where
lower(PROJECT_NAME) like '%tornado%' AND STATUS = 'SUCCESS'
)
select
bucket,
count(distinct TX_HASH) as number_of_transactions
FROM
grouped_transactions
GROUP by
bucket
ORDER by
bucket
-- number_of_transactions desc
Run a query to Download Data