SniperNFT daily transactions and fees
    Updated 2022-10-18
    with eth_price as (
    select hour::date as day,
    avg (price) as avg_price
    from ethereum.core.fact_hourly_token_prices
    where symbol = 'WETH'
    group by 1),

    matic_price as (
    select hour::date as day,
    avg (price) as avg_Price
    from ethereum.core.fact_hourly_token_prices
    where symbol = 'MATIC'
    group by 1),


    eth_nft as (
    select t1.block_timestamp,
    t1.tx_hash,
    t1.event_inputs:from as seller,
    t1.event_inputs:to as buyer,
    t2.tx_fee as fee
    from ethereum.core.fact_event_logs t1 join ethereum.core.fact_transactions t2 on t1.tx_hash = t2.tx_hash
    where t1.block_timestamp::date >= '2022-01-01'
    and t1.event_name = 'Transfer'
    and t1.tx_status = 'SUCCESS'
    and t1.event_inputs:tokenId is not null
    and t1.event_inputs:from != '0x0000000000000000000000000000000000000000'
    and t1.event_inputs:to != '0x0000000000000000000000000000000000000000'),
    polygon_nft as (
    select t1.block_timestamp,
    t1.tx_hash,
    t1.event_inputs:from as seller,
    t1.event_inputs:to as buyer,
    t2.tx_fee as fee
    Run a query to Download Data