Query editor
with tips as (selectblock_time,tx_hash,bytearray_ltrim(topic1) as donors,bytearray_ltrim(topic2) as streamers,casewhen contract_address = 0x84a71ccd554cc1b02749b35d22f684cc8ec987e1 then varbinary_to_decimal(varbinary_ltrim(data))/1e6else varbinary_to_decimal(varbinary_ltrim(data))/1e18end as value--,data,casewhen contract_address = 0x84a71ccd554cc1b02749b35d22f684cc8ec987e1 then 'usdc'when contract_address = 0x9ebe3a824ca958e4b3da772d2065518f009cba62 then 'pengu'when contract_address = 0x000000000000000000000000000000000000800a then 'eth'end as token,contract_address,index,topic3from abstract.logswhere tx_hash in (0x51ecab7b272755cd3b9a189ea284b231200c84040a89494f2be2c7cc211ad7db, -- eth0xbdfd4b325392ef268176bcf66a59562733cec460730e5acc13bdf14c5a818d8b, -- pengu0x63c4f17976a12dd0a3f27101dcd11628c26b2ee3995d37e3ea78f3d66df3984c -- usdc)and topic0 = 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efand contract_address in (0x84a71ccd554cc1b02749b35d22f684cc8ec987e1,0x9ebe3a824ca958e4b3da772d2065518f009cba62,0x000000000000000000000000000000000000800a)and topic1 != 0x0000000000000000000000000000000000000000000000000000000000008001and topic2 != 0x0000000000000000000000000000000000000000000000000000000000008001and topic1 is not nulland topic2 is not null)select * from tips-- select-- --date_trunc('day',block_time) as day-- streamers-- ,token-- ,sum(value) as value-- from tips-- where token = 'eth'-- group by 1,2-- order by 1,3 desc