Yousefi_1994EUROC DEX Total Volume
    Updated 2023-08-19
    with
    euroc_price_usd as (
    select
    hour::date as days,
    avg(price) as price_usd
    from
    ethereum.core.fact_hourly_token_prices
    where
    token_address = '0x1abaea1f7c830bd89acc67ec4af516284b1bc33c'
    and hour::date >= '2023-05-25'
    group by
    days,
    token_address
    ),
    swaps_sell_euroc as (
    select
    block_timestamp,
    tx_hash,
    pool_name,
    amount_in as amount,
    'Sell (Swap From EUROC)' as
    type
    from
    avalanche.core.ez_dex_swaps
    where
    token_in = '0xc891eb4cbdeff6e073e859e987815ed1505c2acd'
    ),
    swaps_buy_euroc as (
    select
    block_timestamp,
    tx_hash,
    pool_name,
    amount_out as amount,
    'Buy (Swap To EUROC)' as
    type
    from
    Run a query to Download Data