Hadisehpercentage of crossover of whales and small Users
    Updated 2022-06-15
    with top_shot as (select buyer , count(NFT_COLLECTION)as total
    from flow.core.fact_nft_sales
    WHERE MARKETPLACE = 'A.c1e4f4f4c4257510.TopShotMarketV3'
    group by 1),
    top_shot_user as ( select buyer as topshot, case when total >= 50 then 'whale'
    when total < 50 then 'small users' end as type
    from top_shot),
    other_collections as ( select DISTINCT buyer , contract_name
    from flow.core.fact_nft_sales x join flow.core.dim_contract_labels y on x.nft_collection =y.EVENT_CONTRACT
    where nft_collection <> 'A.0b2a3299cc857e29.TopShot'),
    final as ( select topshot , buyer , type
    from top_shot_user x join other_collections y on x.topshot = y.buyer)

    select count(buyer) as total_user , type
    from final
    group by 2

    Run a query to Download Data