Query editor
-- struct Fees {-- uint128 transmissionFees;-- uint128 executionFee;-- uint128 switchboardFees;-- }with all_data as (SELECT'ethereum' AS chain,logs.tx_hash,logs.topic1 as request_hash,txns.block_time AS date_time,logs.contract_address,txns.to as tx_solver,txns."from" as tx_from,logs.topic0,0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2 as native_token,varbinary_to_uint256(varbinary_ltrim(varbinary_substring(logs.data, 289, 32))) as transmissionFees,varbinary_to_uint256(varbinary_ltrim(varbinary_substring(logs.data, 321, 32))) as executionFee,varbinary_to_uint256(varbinary_ltrim(varbinary_substring(logs.data, 353, 32))) as switchboardFeesFROM ethereum.logs logsJOIN ethereum.transactions txns ON logs.tx_hash = txns.hashWHERE logs.contract_address IN (0x943AC2775928318653e91d350574436A1b9b16f9)AND logs.topic0 IN (0x45d70e73f9a26cea18d4009d1ad25ffbdc4114ce9d8ceb15959ae9eadb0a3a2c)and txns.success = trueand txns.block_time >= CAST('2022-10-12 16:00:00' AS TIMESTAMP)union ALLSELECT'optimism' AS chain,logs.tx_hash,logs.topic1 as request_hash,txns.block_time AS date_time,logs.contract_address,txns.to as tx_solver,txns."from" as tx_from,logs.topic0,0x4200000000000000000000000000000000000006 as native_token,varbinary_to_uint256(varbinary_ltrim(varbinary_substring(logs.data, 289, 32))) as transmissionFees,varbinary_to_uint256(varbinary_ltrim(varbinary_substring(logs.data, 321, 32))) as executionFee,varbinary_to_uint256(varbinary_ltrim(varbinary_substring(logs.data, 353, 32))) as switchboardFeesFROM Optimism.logs logsJOIN Optimism.transactions txns ON logs.tx_hash = txns.hashWHERE logs.contract_address IN (0x301bD265F0b3C16A58CbDb886Ad87842E3A1c0a4)AND logs.topic0 IN (0x45d70e73f9a26cea18d4009d1ad25ffbdc4114ce9d8ceb15959ae9eadb0a3a2c)and txns.success = trueand txns.block_time >= CAST('2022-10-12 16:00:00' AS TIMESTAMP)union ALLSELECT'bnb' AS chain,