ArioDEX Season - Top 10 token - number of swap - Ethereum's DEXs
    Updated 2022-12-06
    with before as (
    SELECT
    'Before FTX Collapse' as status,
    concat(SYMBOL_IN, '→', SYMBOL_OUT) as Swap_pair,
    count(distinct TX_Hash) as N_TXS
    from ethereum.core.ez_dex_swaps
    where AMOUNT_IN_USD is not NULL
    and AMOUNT_IN_USD > 0
    and SYMBOL_IN is not NULL
    and SYMBOL_OUT is not NULL
    and BLOCK_TIMESTAMP between '2022-11-01' and '2022-11-07'
    and EVENT_NAME = 'Swap'
    group by 1,2
    order by 3 desc
    limit 10
    ),
    After as (
    SELECT
    'After FTX Collapse' as status,
    concat(SYMBOL_IN, '→', SYMBOL_OUT) as Swap_pair,
    count(distinct TX_Hash) as N_TXS
    from ethereum.core.ez_dex_swaps
    where AMOUNT_IN_USD is not NULL
    and AMOUNT_IN_USD > 0
    and SYMBOL_IN is not NULL
    and SYMBOL_OUT is not NULL
    and BLOCK_TIMESTAMP between '2022-11-08' and '2022-11-17'
    and EVENT_NAME = 'Swap'
    group by 1,2
    order by 3 desc
    limit 10
    )
    select * from before
    union ALL
    select * from after
    Run a query to Download Data