mmdrezaFLOW - 6 - Monthly distribution of NFT sales
    Updated 2022-10-26
    select
    date_trunc('month',block_timestamp) as date,
    case
    when price < 10 then 'Less than 10 $USD'
    when price >= 10 and price < 30 then 'Between [10 - 30) $USD'
    when price >= 30 and price < 60 then 'Between [30 - 60) $USD'
    when price >= 60 and price < 90 then 'Between [60 - 90) $USD'
    when price >= 90 and price < 120 then 'Between [90 - 120) $USD'
    when price >= 120 then 'More than 120 $USD'
    else 'nothing'
    end as distribution,
    count(DISTINCT tx_id) as sales,
    nft_collection
    from flow.core.ez_nft_sales
    where nft_collection like '%{{project}}'
    and tx_succeeded = 'TRUE'
    group by date,distribution,nft_collection
    order by date desc

    Run a query to Download Data