Query editor
withfluid_dexes as (selecttx_hash, block_time, blockchain, bytearray_substring(topic1, 13, 20) as dex, cast(bytearray_to_uint256(bytearray_ltrim(bytearray_substring(data, 1, 32))) as integer) as dex_id, bytearray_substring(topic2, 13, 20) as token0, bytearray_substring(topic3, 13, 20) as token1from evms.logswhere block_time >= timestamp '2024-09-20'and contract_address = 0x91716C4EDA1Fb55e84Bf8b4c7085f84285c19085 -- Fluid DEX Factoryand topic0 = 0x3fecd5f7aca6136a20a999e7d11ff5dcea4bd675cb125f93ccd7d53f98ec57e4 -- DexT1Deployedand blockchain in('ethereum', 'arbitrum', 'base','plasma')), tokens as (selectcontract_address as token, blockchain, symbol, decimalsfrom tokens.erc20where contract_address <> 0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeand blockchain in ('ethereum', 'arbitrum', 'base')unionselect0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee as token, chain as blockchain, symbol, decimalsfrom tokens.nativewhere chain in ('ethereum', 'arbitrum', 'base')unionselect0x0a1a1a107e45b7ced86833863f482bc5f4ed82ef as token, 'plasma' as blockchain, 'USDai' as symbol, 18 as decimalsunionselect0x0B2b2B2076d95dda7817e785989fE353fe955ef9 as token, 'plasma' as blockchain, 'sUSDai' as symbol, 18 as decimalsunionselect0xb8ce59fc3717ada4c02eadf9682a9e934f625ebb as token