Query editor
-- 0x2f2a2543B76A4166549F7aaB2e75Bef0aefC5B0f wbtc-- 0xaf88d065e77c8cC2239327C5EDb3A432268e5831 usdc-- 0x82aF49447D8a07e3bd95BD0d56f35241523fBab1 weth-- 0x0000000000000000000000000000000000000000 ethwith swap as (selectblock_date as ds,date_trunc('day',block_time) ts,blockchain,project,tx_hash,amount_usdfrom dex.tradeswhereblockchain in ('arbitrum') andproject in ('uniswap') and(token_bought_address in (0x0000000000000000000000000000000000000000, 0x82aF49447D8a07e3bd95BD0d56f35241523fBab1,0x2f2a2543B76A4166549F7aaB2e75Bef0aefC5B0f, 0xaf88d065e77c8cC2239327C5EDb3A432268e5831) ortoken_sold_address in (0x0000000000000000000000000000000000000000, 0x82aF49447D8a07e3bd95BD0d56f35241523fBab1,0x2f2a2543B76A4166549F7aaB2e75Bef0aefC5B0f, 0xaf88d065e77c8cC2239327C5EDb3A432268e5831)) and-- block_time > timestamp '2025-10-10 17:30' and block_time < timestamp '2025-10-11 04:00'block_time >= timestamp '2025-09-10' --and block_time <= timestamp '2025-10-12'), price as (SELECT"timestamp" AS ts,priceFROM prices.minuteWHERE"timestamp" >= current_date - interval '1' month andblockchain = 'ethereum' andcontract_address = 0x0000000000000000000000000000000000000000), fee as (selectdistincts.project,tx.hash as tx_hash,date_trunc('day', tx.block_time) as ts,tx.block_number,effective_gas_price/1e9 as gas_price_gwei,(gas_used*effective_gas_price)/1e18 as tx_fee_native,p.price*(gas_used*effective_gas_price/1e18) as tx_fee_usdfrom arbitrum.transactions txjoin swap s on tx.hash = s.tx_hashjoin price p on date_trunc('minute', tx.block_time) = p.tswhere-- block_time > timestamp '2025-10-10 17:30' and block_time < timestamp '2025-10-11 04:00'block_time >= timestamp '2025-09-10' --and block_time <= timestamp '2025-10-12')selectts,avg(gas_price_gwei) as gas_price_gwei_mean,sum(tx_fee_usd) as tx_feefrom fee