Query editor
WITH create_strategy_logs AS (SELECTtx_hash,topic1 AS strategy_idFROM base.logsWHEREblock_time > TRY_CAST('2024-05-01 01:34' /* CLTBase creation */ AS TIMESTAMP)AND contract_address IN (0xdfb179526ae303eea49ac99dd360159c39105828)AND topic0 = 0xb2c0a7e473453e1af27b29d3a11452171e4ca8c48c8519c913ad68cdd17b2908 /* strategyCreated */),strategies_with_pool AS (SELECTlog.tx_hash,log.strategy_id,CASEWHEN BYTEARRAY_LTRIM(BYTEARRAY_SUBSTRING(txn.data, 5, 32)) IN (0xdfb179526ae303eea49ac99dd360159c39105828) --txn it done through multisignTHEN BYTEARRAY_LTRIM(BYTEARRAY_SUBSTRING(txn.data, 373, 20))ELSE BYTEARRAY_LTRIM(BYTEARRAY_SUBSTRING(txn.data, 5, 32))END AS poolFROM create_strategy_logs AS logLEFT JOIN base.transactions AS txn ON log.tx_hash = txn.hash)SELECTstrategy_id,st.pool,token0,token1,feeFROM strategies_with_pool AS stLEFT JOIN dex.raw_pools AS rpON rp.blockchain = 'base'AND rp.contract_address IN (0x38015d05f4fec8afe15d7cc0386a126574e8077b) --uniswapV3 FactoryAND st.pool = rp.pool