Query editor
withget_liquidity as (select*fromdune.ether_fi.result_lrts_restaking_dex_pools_balances dbwhere db.day >= now() - interval '100' dayand lower(token_symbol) = 'weeth'and lower(token_type) = 'lrt'and pool_liquidity_usd >= 0.001 -- greater than 0.001 usd),liquidity as (selectgl.day,gl.blockchain,sum(case when lower(gl.pool_token_symbol) in (select lower(token_symbol) from query_5515764) then pool_liquidity_usd else 0 end) as liquidity_usd,sum(case when lower(gl.pool_token_symbol) in (select lower(token_symbol) from query_5515764) THEN pool_liquidity_eth ELSE 0 END) as liquidity_eth,sum(case when lower(gl.pool_token_symbol) = 'weeth' then pool_liquidity_usd ELSE 0 END) as weeth_liquidity_usd,sum(case when lower(gl.pool_token_symbol) = 'weeth' then pool_token_balance ELSE 0 END) as weeth_liquidityfromget_liquidity glwhere day <= date_trunc('day', now() - interval '4' hour) -- at least four hours before updating for current daygroup by 1, 2union allselectday,'Liquidity Pool' as blockchain,sum(token_balance_usd) as liqudity_usd,sum(token_balance_eth) as liqudity_eth,cast(null as double) as weeth_liquidity_usd,cast(null as double) as weeth_liquidityfromdune.ether_fi.result_etherfi_assets_under_managementwhere day >= now() - interval '100' dayand day <= date_trunc('day', now() - interval '4' hour)and address = 0x308861A430be4cce5502d0A12724771Fc6DaF216and token_address = 0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2group by 1, 2, 5, 6),dex_volume as (selectblock_day as day,blockchain,sum(amount_usd) as volumefromdune.ether_fi.result_lrts_restaking_tradeswhere block_day >= now() - interval '100' dayand lower(token_symbol) = 'weeth'group by 1, 2),dex_rates as (selectday,blockchain,