feyikemiVertex_totals Over time
    Updated 2025-01-21
    with trades as (
    select
    'perp' as type,
    *
    from arbitrum.vertex.ez_perp_trades
    union all
    select
    'spot' as type,
    *
    from arbitrum.vertex.ez_spot_trades

    )

    select
    date_trunc('day', block_timestamp) AS Date,
    type,
    sum(amount_usd) as Total_volume,
    count(DISTINCT tx_hash) as Total_Trades,
    count(DISTINCT trader) as Total_traders
    from trades
    where is_taker = 'TRUE'
    GROUP BY 1, 2
    QueryRunArchived: QueryRun has been archived