FatemeTheLadyFLOW, SOLANA AND ETH NFT SALES
    Updated 2022-06-05
    with FLOW as(select
    date_trunc('MINUTE',BLOCK_TIMESTAMP ) as min,
    count(distinct TX_ID) as num_success
    from flow.core.fact_nft_sales
    where BLOCK_TIMESTAMP::date >='2022-05-01' and BLOCK_TIMESTAMP::date <='2022-06-03' and TX_SUCCEEDED='1'
    group by 1
    order by 1 asc),
    SOLANA as(select
    date_trunc('MINUTE',BLOCK_TIMESTAMP ) as min,
    count(distinct TX_ID) as num_success
    from flipside_prod_db.solana.fact_transactions
    where BLOCK_TIMESTAMP::date >='2022-05-01' and BLOCK_TIMESTAMP::date <='2022-06-03' and SUCCEEDED='1'
    group by 1
    order by 1 asc),

    ETH as(select
    date_trunc('MINUTE',S.BLOCK_TIMESTAMP ) as min,
    count(distinct S.TX_HASH) as num_success
    from flipside_prod_db.ethereum_core.ez_nft_sales S LEFT JOIN flipside_prod_db.ethereum_core.fact_transactions T ON S.TX_HASH=T.TX_HASH
    where S.BLOCK_TIMESTAMP::date >='2022-05-01' and S.BLOCK_TIMESTAMP::date <='2022-06-03' and T.STATUS='SUCCESS'
    group by 1
    order by 1 asc)
    select
    date_trunc('day',FLOW.min) as day,
    Avg(FLOW.num_success) as FLOW_success_Avg,
    Avg(SOLANA.num_success) as SOLANA_success_Avg,
    Avg(ETH.num_success) as ETH_success_Avg
    from FLOW left join SOLANA on FLOW.min=SOLANA.min
    left join ETH on FLOW.min=ETH.min
    group by 1 order by 1 asc
    Run a query to Download Data