Query editor
-- EURC-- BRZ-- cNGN-- CADCwith fx as (select*from query_5519263),main as (selectblockchain,block_month,date_trunc('week', block_date) as block_week,block_date,token_pair,token_bought_symbol,token_sold_symbol,project,token_bought_amount,token_sold_amount,amount_usdfrom dex.trades tjoin fx as fb on lower(t.token_bought_symbol) = lower(fb.token)join fx as fs on lower(t.token_sold_symbol) = lower(fs.token)where--blockchain = 'base' andblock_date >=timestamp '2025-01-01' andfb.ccy != fs.ccy),agg_blockchain as (selectblock_week,blockchain,sum(amount_usd) as volume_usdfrom maingroup by 1,2)select*,(volume_usd - lag(volume_usd, 1) over (partition by blockchain order by block_week)) / lag(volume_usd, 1) over (partition by blockchain order by block_week) as growth_simplefrom agg_blockchain