PierandreaPrimary Sales - Rarity Stats
    Updated 2023-04-13
    with minted as (SELECT
    NFT_ASSET_ID as x,
    BLOCK_TIMESTAMP::date as Date
    from algorand.nft.ez_nft_sales_fifa
    WHERE SALE_TYPE = 'mint'
    ),

    rarity as (SELECT
    NFT_ASSET_ID as y,
    RARITY
    from algorand.nft.ez_nft_metadata_fifa ),
    merge as (select *
    from minted
    inner join rarity on minted.x = rarity.y)


    select
    RARITY,
    count(Y) as NFT_Minted
    from merge
    group by RARITY
    order by 2 ASC