0-MIDdaily average
    Updated 2023-04-14
    with act1 as (
    with tab1 as (
    select BLOCK_TIMESTAMP::date as date
    ,ORIGIN_FROM_ADDRESS
    ,SYMBOL
    ,AMOUNT
    ,AMOUNT_USD
    ,ORIGIN_TO_ADDRESS
    from arbitrum.core.ez_token_transfers
    where CONTRACT_ADDRESS=lower('0x912ce59144191c1204e64559fe8253a0e49e6548')
    and date>='2023-03-23'
    and SYMBOL='ARB'),
    tab2 as (
    select ADDRESS
    ,PROJECT_NAME
    ,LABEL_TYPE
    from crosschain.core.address_labels
    where LABEL_TYPE='dex')
    select
    date
    ,SYMBOL
    ,PROJECT_NAME
    ,sum(AMOUNT)as volume
    ,sum(AMOUNT_USD) as usd_volume
    ,count(distinct ORIGIN_FROM_ADDRESS) as users
    from tab1
    left join tab2
    on tab1.ORIGIN_TO_ADDRESS=tab2.ADDRESS
    where PROJECT_NAME is not null
    group by 1,2,3),
    act2 as (
    with tab3 as (
    select BLOCK_TIMESTAMP::date as date
    ,ORIGIN_FROM_ADDRESS
    ,SYMBOL
    ,AMOUNT
    Run a query to Download Data