shadilTotal fee of OP transactions in over time
    Updated 2022-08-03
    select time_d, sum(total_fee)
    from (select prices.price_in_usd * sum(optimism.core.fact_token_transfers.raw_amount/pow(10, 18)) as total_fee,
    date_trunc('day', optimism.core.ez_nft_sales.block_timestamp) as time_d
    from optimism.core.ez_nft_sales join (select Avg(price) as price_in_usd,
    symbol,
    date_trunc('day', hour) as date_time
    from optimism.core.fact_hourly_token_prices
    where symbol in ('OP')
    group by date_time, symbol) as prices
    on symbol in ('OP')
    and prices.date_time = date_trunc('day', optimism.core.ez_nft_sales.block_timestamp)
    join optimism.core.fact_token_transfers on optimism.core.ez_nft_sales.tx_hash = optimism.core.fact_token_transfers.tx_hash
    where optimism.core.fact_token_transfers.to_address ilike '%0XEC1557A67D4980C948CD473075293204F4D280FD%'
    and currency_symbol in ('OP')
    and event_type in ('sale')
    and platform_name ilike '%quixotic%'
    and optimism.core.fact_token_transfers.origin_from_address not in ('0x0a0805082ea0fc8bfdcc6218a986efda6704efe5')
    group by time_d, prices.price_in_usd)
    group by time_d
    Run a query to Download Data