Query editor
WITHzyfi_receive as (SELECTl.evt_block_time as time,l.evt_tx_hash as tx_hash,(value) / (1e18) as valueFROMerc20_zksync.evt_Transfer as lWHEREl.to IN (0x418F8EA78D856bEcf95e08C4A5773F5E85147866,0xA2Aac7bC9725c36ad9B12D2407dF8de6B2B68359,0xa2D1AE31C2236fBE054c6C9fBDEF27e78ac78D71,0x9702beC6668A94619a9c3cfef0e220512FbEEfbd)),zyfi_send as (SELECTl.evt_block_time as time,l.evt_tx_hash as tx_hash,(- l.value) / (1e18) as valueFROMerc20_zksync.evt_Transfer as lWHEREl.value < 50e18AND l."from" IN (0xA2Aac7bC9725c36ad9B12D2407dF8de6B2B68359,0xa2D1AE31C2236fBE054c6C9fBDEF27e78ac78D71,0x9702beC6668A94619a9c3cfef0e220512FbEEfbd)),all_tx_zyfi as (SELECT*FROMzyfi_receiveUNION ALLSELECT*FROMzyfi_send),group_tx_zyfi as (SELECTtx_hash,time,sum(value) as fees_paidFROMall_tx_zyfiGROUP BY1,2),group_tx_zksync_zyfi as (SELECTg.tx_hash,g.time,g.fees_paid,