Query editor
with-- select the list of etherscan mevbotsmev_bots as (select*from(selectaddressfromlabels.addresseswhereblockchain = 'ethereum'and model_name = 'mev'unionselectfrom_hex('{{mev_bot_address}}') as address)where'0x123456789abcde' = '{{mev_bot_address}}'or address = from_hex('{{mev_bot_address}}')),-- select all the txn made by etherscan mevbotsmev_bot_transactions as (select distinct"from",to,tx_hashfromethereum.traceswhereblock_time > cast('{{start_date}}' as timestamp)and "from" in (selectaddressfrommev_bots)),-- -- get all the traces executed by mevbotsmev_bot_traces as (selectmevbot,x."from",x.to,x.tx_hash,x.block_timefrom(select"from",to,tx_hash,block_timefromethereum.traceswhereblock_time > cast('{{start_date}}' as timestamp)) xinner join (