Query editor
WITH active_pools_from_swaps AS (SELECTid as pool_id,COUNT(DISTINCT evt_tx_hash) as trade_count,COUNT(DISTINCT sender) as unique_traders,MAX(evt_block_time) as last_trade_timeFROM uniswap_v4_ethereum.poolmanager_evt_swapWHERE evt_block_time >= CURRENT_DATE - INTERVAL '21' dayGROUP BY id),pool_info AS (SELECTid as pool_id,currency0,currency1,fee,hooks,evt_block_time as initialized_timeFROM uniswap_v4_ethereum.poolmanager_evt_initialize)SELECTp.pool_id,p.currency0,p.currency1,p.fee,p.hooks,p.initialized_time,a.trade_count,a.unique_traders,a.last_trade_timeFROM pool_info pINNER JOIN active_pools_from_swaps aON p.pool_id = a.pool_idWHERE a.trade_count >= 1ORDER BY a.trade_count DESCLIMIT 10000