Eman-RazDistribution of Transaction Based on the TXs Count
Updated 2024-01-16
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
›
⌄
with tab1 as (select PROPOSER as "User", count(distinct tx_id), case
when count(distinct tx_id)=1 then 'n=1'
when count(distinct tx_id)>1 and count(distinct tx_id)<=5 then '1<n<=5'
when count(distinct tx_id)>5 and count(distinct tx_id)<=10 then '5<n<=10'
when count(distinct tx_id)>10 and count(distinct tx_id)<=50 then '10<n<=50'
when count(distinct tx_id)>50 and count(distinct tx_id)<=100 then '50<n<=100'
when count(distinct tx_id)>100 and count(distinct tx_id)<=500 then '100<n<=500'
when count(distinct tx_id)>500 and count(distinct tx_id)<=1000 then '500<n<=1000'
else 'n>1000'
end as "Class"
from flow.core.fact_transactions
where block_timestamp::date>='2023-01-01' and block_timestamp::date<='{{End_Date}}'
group by 1)
select "Class", count(distinct "User") as "User Count"
from tab1
group by 1
QueryRunArchived: QueryRun has been archived