Query editor
withtimeline as (select timestamp as dayfrom utils.dayswhere timestamp >= timestamp '2024-10-29'), volume_excl as (select *from "query_5254724"), coingecko_tokens as (select address as contract_address, blockchainfrom dune.pancakeswap.result_coingecko_coin_listwhere blockchain = 'ethereum'unionselect 0x0000000000000000000000000000000000000000 as contract_address, 'ethereum' as blockchain), fluid_dex_lite_swaps as (select *-- from "query_5572407" -- fullfrom "query_6639013" -- simplewhere block_time >=casewhen '{{timeframe}}' = 'last 3 months' then greatest(current_date - interval '3' month, timestamp '2025-08-01')when '{{timeframe}}' = 'last 6 months' then greatest(current_date - interval '6' month, timestamp '2025-08-01')else timestamp '2025-08-01'endand blockchain = 'ethereum'), fluid_dex_swaps as (select s.*from "query_4727837(blockchain='ethereum')" as swhere s.block_time >=casewhen '{{timeframe}}' = 'last 3 months' then greatest(current_date - interval '3' month, timestamp '2024-10-29')when '{{timeframe}}' = 'last 6 months' then greatest(current_date - interval '6' month, timestamp '2024-10-29')else timestamp '2024-10-29'endand s.blockchain = 'ethereum'), trading_volume as (selectt.block_date as day, t.blockchain, t.project as dex, sum(t.amount_usd) as volume_usdfrom dex.trades as tleft join volume_excl as eton t.blockchain = et.blockchainand et.address_type = 'taker'and t.taker = et.addressleft join volume_excl as ef