0xHaM-dDex & Cex
    Updated 2022-11-28
    SELECT
    BLOCK_TIMESTAMP::date as date,
    'Pre_Merge Sell ETH in Dex' as status,
    count(DISTINCT tx_hash) as swap_tx_cnt,
    count(DISTINCT SENDER) as uniq_swapper,
    sum(amount_in) as swap_eth_amt
    FROM ethereum.core.ez_dex_swaps
    WHERE SYMBOL_IN = 'WETH'
    AND BLOCK_TIMESTAMP::date >= '2022-08-15'
    AND BLOCK_TIMESTAMP::date < '2022-09-15'
    group by 1,2

    UNION
    SELECT
    BLOCK_TIMESTAMP::date as date,
    'Pre_Merge Buy ETH in Dex' as status,
    count(DISTINCT tx_hash) as swap_tx_cnt,
    count(DISTINCT SENDER) as uniq_swapper,
    sum(amount_out) as swap_eth_amt
    FROM ethereum.core.ez_dex_swaps
    WHERE SYMBOL_OUT = 'WETH'
    AND BLOCK_TIMESTAMP::date >= '2022-08-15'
    AND BLOCK_TIMESTAMP::date < '2022-09-15'
    group by 1,2

    UNION

    SELECT
    BLOCK_TIMESTAMP::date as date,
    'Pre_Merge Send ETH to Cex' as status,
    count(DISTINCT tx_hash) as swap_tx_cnt,
    count(DISTINCT ORIGIN_FROM_ADDRESS) as uniq_sender,
    sum(amount) as swap_eth_amt
    FROM ethereum.core.ez_eth_transfers
    WHERE ORIGIN_TO_ADDRESS in (SELECT address FROM ethereum.core.dim_labels WHERE LABEL_TYPE = 'cex')
    Run a query to Download Data