sagharkariClassification of Users Based on the Volume of FLOW
    Updated 2022-11-11
    with tab1 as
    (select DELEGATOR as staker, sum(amount) as total_flow, case
    when total_flow<=0.01 then 'FLOW<=0.01'
    when total_flow>0.01 and total_flow<=0.1 then '0.01<FLOW<=0.1'
    when total_flow>0.1 and total_flow<=1 then '0.1<FLOW<=1'
    when total_flow>1 and total_flow<=10 then '1<FLOW<=10'
    when total_flow>10 and total_flow<=100 then '10<FLOW<=100'
    when total_flow>100 and total_flow<=1000 then '100<FLOW<=1000'
    when total_flow>1000 then 'FLOW>1000'
    end as Group_
    from flow.core.ez_staking_actions
    where action in ('DelegatorTokensCommitted','TokensCommitted')
    group by 1)
    select group_, count(staker) as staker_count
    from tab1
    group by 1
    Run a query to Download Data