SpiltadavidTotal Weekly Number of Mint and Sales Transactions
    Updated 2023-01-05
    select 'Secondary' as type,trunc(block_timestamp,'week') as date, count(DISTINCT(tx_hash)) as total_tx, count(DISTINCT(nft_address)) as total_collection, count(DISTINCT(tokenid)) as total_nft,
    sum(price_usd) as volume
    from ethereum.core.ez_nft_sales
    where block_timestamp::date >= '2022-01-01' and block_timestamp::date < '2023-01-01'
    group by 1,2
    UNION
    select 'Mint' as type,trunc(block_timestamp,'week') as date, count(DISTINCT(tx_hash)) as total_tx, count(DISTINCT(NFT_ADDRESS)) as total_collection, count(DISTINCT(tokenid)) as total_nft,
    sum(mint_price_usd) as volume
    from ethereum.core.ez_nft_mints
    where block_timestamp::date >= '2022-01-01' and block_timestamp::date < '2023-01-01'
    and nft_address not in (select address from ethereum.core.dim_labels
    where label not in ('uniswap','curve finance'))
    group by 1,2
    Run a query to Download Data