Yousefi_1994Sushi vs Uni - Uniswap Top Pool By Number of Swaps on Arbitrum
    Updated 2022-10-16
    with arbitrum_uniswap as (
    select
    contract_address as "Pool Address",
    'Uniswap' as "Platform",
    count (distinct tx_hash) as "Number of Swaps"
    from arbitrum.core.fact_event_logs
    where origin_to_address in ('0xe592427a0aece92de3edee1f18e0157c05861564','0x68b3465833fb72a70ecdf485e0e4c7bd8665fc45')
    and event_name = 'Swap'
    and tx_status = 'SUCCESS'
    group by "Pool Address"
    order by "Number of Swaps" desc
    limit 11
    )

    select
    case
    when "Pool Address" = '0xc31e54c7a869b9fcbecc14363cf510d1c41fa443' or "Pool Address" = '0x17c14d2c404d167802b16c450d3c99f88f2c4f4d' then 'ETH-USDC'
    when "Pool Address" = '0x1aeedd3727a6431b8f070c0afaa81cc74f273882' then 'ETH-GMX'
    when "Pool Address" = '0x641c00a822e8b671738d32a431a4fb6074e5c79d' then 'ETH-USDT'
    when "Pool Address" = '0x4fd47e5102dfbf95541f64ed6fe13d4ed26d2546' then 'LPT-ETH'
    when "Pool Address" = '0x13398e27a21be1218b6900cbedf677571df42a48' then 'USDT-USDC'
    when "Pool Address" = '0x2b734ec7555cb49c755a9495a8d17cd2383926e0' then 'UMAMI-ETH'
    when "Pool Address" = '0x112e05d5b51cd21006872f469cda427cd0e36e5d' then 'SPA-ETH'
    when "Pool Address" = '0xd37af656abf91c7f548fffc0133175b5e4d3d5e6' then 'DAI-USDC'
    when "Pool Address" = '0x50450351517117cb58189edba6bbad6284d45902' then 'USDs-USDC'
    when "Pool Address" = '0x08687dd94b1e084808b549fb5594d6e3d3b7b948' then 'ETH-DBL'
    else "Pool Address"
    end as "Pool",
    sum("Number of Swaps") as "Number of Swaps"
    from arbitrum_uniswap
    group by "Pool"
    order by "Number of Swaps" desc
    Run a query to Download Data