Query editor
withsub as (selecttopic1,count(*) as num_fills,max(tx_hash) as examplefromethereum.logswherecontract_address = 0x881d40237659c251811cec9c364ef91dc08d300c -- swap event address is 881and block_time > now() - interval '7' daygroup by1)selectcasewhen topic1 = 0xf35f348d53012d52a5d39f9390d246956ac932d5778d2bb49e359dba4fa0896d then '1inch'when topic1 = 0x62db2e87ad4360c521a990935f97f7c44833c4f99a8f1c09129331715b07f525 then 'MEV Bot: a69babe'when topic1 = 0x015123c6e2552626efe611b6c48de60d080a6650860a38f237bc2b6f651f79d1 then 'Airswap'when topic1 = 0x9e4182a38ef65fd4828a1563124c6ada8e2cd461a1a638cbc46803f0cd3e7f48 then 'Paraswap'when topic1 = 0xcbf46790f422d91c0bc3f78784cac5d123211479f745ef4d632dfd71fd4d53f3 then 'Open Ocean'when topic1 = 0xa8dc30b66c6d4a8aac3d15925bfca09e42cac4a00c50f9949154b045088e2ac2 then '0x'when topic1 = 0x3ef3c00071253ec2c927305151c4ef63c615047982b99857a44557bf0c1e3c45 then 'Hashflow'when topic1 = 0xbd5c436f8c83379009c1962310b8347e561d1900906d3fe4075b1596f8955f88 then '1inch'else cast(topic1 as varchar)end as project_name,casewhen topic1 = 0xf35f348d53012d52a5d39f9390d246956ac932d5778d2bb49e359dba4fa0896d then 'oneInchV5FeeDynamic'when topic1 = 0x62db2e87ad4360c521a990935f97f7c44833c4f99a8f1c09129331715b07f525 then 'pmmFeeDynamicv4'when topic1 = 0x015123c6e2552626efe611b6c48de60d080a6650860a38f237bc2b6f651f79d1 then 'airswapLight4FeeDynamicFixed'when topic1 = 0x9e4182a38ef65fd4828a1563124c6ada8e2cd461a1a638cbc46803f0cd3e7f48 then 'paraswapV5FeeDynamic'when topic1 = 0xcbf46790f422d91c0bc3f78784cac5d123211479f745ef4d632dfd71fd4d53f3 then 'openOceanFeeDynamic'when topic1 = 0xa8dc30b66c6d4a8aac3d15925bfca09e42cac4a00c50f9949154b045088e2ac2 then '0xFeeDynamic'when topic1 = 0x3ef3c00071253ec2c927305151c4ef63c615047982b99857a44557bf0c1e3c45 then 'hashFlowFeeDynamic'when topic1 = 0xbd5c436f8c83379009c1962310b8347e561d1900906d3fe4075b1596f8955f88 then 'oneInchV4FeeDynamic'else cast(topic1 as varchar)end as decoded_aggregator_id,*fromsuborder by4 desc