Query editor
with token_transfer_detail as (select 'arbitrum' as blockchain,t.contract_address,t.evt_block_time,t."to" as pool,cast(t.value as double) as amount_originalfrom erc20_arbitrum.evt_Transfer tinner join uniswap_v3_arbitrum.UniswapV3Factory_evt_PoolCreated p on t."to" = p.poolwhere t.evt_block_time >= date('2021-06-01') -- first pool created dateunion allselect 'arbitrum' as blockchain,t.contract_address,t.evt_block_time,t."from" as pool,-1 * cast(t.value as double) as amount_originalfrom erc20_arbitrum.evt_Transfer tinner join uniswap_v3_arbitrum.UniswapV3Factory_evt_PoolCreated p on t."from" = p.poolwhere t.evt_block_time >= date('2021-06-01') -- first pool created dateunion allselect 'ethereum' as blockchain,t.contract_address,t.evt_block_time,t."to" as pool,cast(t.value as double) as amount_originalfrom erc20_ethereum.evt_Transfer tinner join uniswap_v3_ethereum.Factory_evt_PoolCreated p on t."to" = p.poolwhere t.evt_block_time >= date('2021-05-04') -- first pool created dateunion allselect 'ethereum' as blockchain,t.contract_address,t.evt_block_time,t."from" as pool,-1 * cast(t.value as double) as amount_originalfrom erc20_ethereum.evt_Transfer tinner join uniswap_v3_ethereum.Factory_evt_PoolCreated p on t."from" = p.poolwhere t.evt_block_time >= date('2021-05-04') -- first pool created dateunion allselect 'optimism' as blockchain,t.contract_address,t.evt_block_time,t."to" as pool,cast(t.value as double) as amount_originalfrom erc20_optimism.evt_Transfer tinner join uniswap_v3_optimism.Factory_evt_PoolCreated p on t."to" = p.poolwhere t.evt_block_time >= date('2021-11-11') -- first pool created dateunion allselect 'optimism' as blockchain,t.contract_address,t.evt_block_time,t."from" as pool,