hessSellers Breakdown Based on total Sell
    Updated 2022-10-11
    with price as ( select date(block_timestamp) as p_date, (sum(SWAP_TO_AMOUNT)/sum(SWAP_FROM_AMOUNT)) as price
    from solana.core.fact_swaps
    where SWAP_FROM_MINT = 'So11111111111111111111111111111111111111112'
    and SWAP_TO_MINT = 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v'
    and p_date >= CURRENT_DATE - 90
    group by 1)
    ,
    nfts as ( select address, label
    from solana.core.dim_labels
    where address_name in ('The Suites','sol nfl players','collectorz club gen1','Collectorz Club: The Collectorz'
    ,'Sports Rewind','Blockasset Legends','Smesh Bros','Hockey Heroes'))

    ,
    final as ( select trunc(block_timestamp,'day') as date,
    purchaser,
    seller,
    tx_id,
    label,
    sales_amount*price as volume
    from price a left outer join solana.core.fact_nft_sales b on a.p_date = b.block_timestamp::date
    join nfts c on b.mint = c.address
    )
    ,
    finalII as( select date,
    seller,
    label,
    sum(volume) as volumes,
    sum(volumes) over (partition by label order by date asc )as cum_volume,
    avg(volume) as avg_volume,
    avg(avg_volume) over (partition by label order by date rows between 7 preceding and 0 following) as ma_7_volume,
    count(DISTINCT(purchaser)) as total_buyer,
    count(DISTINCT(seller)) as total_seller,
    count(DISTINCT(tx_id)) as total_sales

    from final
    where date >= CURRENT_DATE - 90
    Run a query to Download Data