Query editor
with pools as (select distinctpool,token0,token1from uniswap_ethereum.pools t0where token0 in (select distinct pToken from rumpel_ethereum.pointtokenvault_evt_ptokendeployed)or token1 in (select distinct pToken from rumpel_ethereum.pointtokenvault_evt_ptokendeployed)),wallets as (select distinct safe from rumpel_ethereum.rumpelwalletfactory_evt_safecreated),cl_pool_events as (selectevt_block_time,evt_tx_hash,evt_tx_from as user,'Add Liquidity' as event,contract_address as address,amount0,amount1from uniswap_v3_ethereum.uniswapv3pool_evt_mintwhere evt_block_time >= timestamp '2024-09-01 00:00:00'and contract_address in (select pool from pools)union allselectevt_block_time,evt_tx_hash,evt_tx_from as user,'Remove Liquidity' as event,contract_address as address,amount0,amount1from uniswap_v3_ethereum.uniswapv3pool_evt_burnwhere evt_block_time >= timestamp '2024-09-01 00:00:00'and contract_address in (select pool from pools)union allselectevt_block_time,evt_tx_hash,evt_tx_from as user,'Swap' as event,contract_address as address,amount0,amount1from uniswap_v3_ethereum.uniswapv3pool_evt_swapwhere evt_block_time >= timestamp '2024-09-01 00:00:00'and contract_address in (select pool from pools)),tf as (selectevt_block_time,evt_tx_hash,"to" as user,case when "from" in (select distinct target from rumpel_ethereum.rumpelguard_evt_setcallallowed) then 'Withdraw/Unstake from Strategy Vault' else 'Deposit to Safe' end as event,"from" as address,contract_address,cast(value as decimal(38)) as amountfrom erc20_ethereum.evt_transferwhere "to" in (select safe from wallets)and evt_block_time >= timestamp '2024-09-07 00:00:00'union allselectevt_block_time,