primo_dataflow_top_shots_conference_final_teams
    Updated 2022-07-12
    -- Q19. Analyze the NBA Conference Finals (May 17th- May 29th) and determine whether it had an impact on NBA Top Shot's volume.
    -- Did the Warriors, Celtics, Mavericks, or Heat see higher sales volume?

    select date(s.block_timestamp) dt
    , case when s.nft_collection = 'A.0b2a3299cc857e29.TopShot' then 'NBA Top Shot' else 'Other' end top_shot
    , d.player
    , d.team
    , case when d.team in ('Golden State Warriors', 'Boston Celtics', 'Dallas Mavericks', 'Miami Heat') then d.team else 'Other' end playoff_teams
    , case when d.nft_id is null then 'NFT not dim table' else 'NFT in dim table' end dim_table
    , case when d.team in ('Golden State Warriors', 'Boston Celtics', 'Dallas Mavericks', 'Miami Heat') then 'Conference Finals Team' else 'Other' end team_type
    , count(distinct s.tx_id) sales_ct
    from flow.core.fact_nft_sales s
    inner join flow.core.dim_topshot_metadata d
    on s.nft_id = d.nft_id
    where s.tx_succeeded = TRUE
    and s.nft_collection = 'A.0b2a3299cc857e29.TopShot'
    --and d.nft_id is not null
    group by 1,2,3,4,5,6,7

    Run a query to Download Data