Sbhn_NPextensive-coffee
    Updated 2025-03-08
    select date_trunc('day',block_timestamp) as date,
    sum(amount_usd) as usd_volume,
    sum(usd_volume) over (order by date) as cumulative,
    count(distinct concat('0x', right(topics[2],40))) as traders,
    count(distinct tx_hash) as swaps
    from ink.core.fact_event_logs
    join ink.core.ez_token_transfers a using(tx_hash)
    where topic_0 = '0xd78ad95fa46c994b6551d0da85fc275fe613ce37657fb8d5e3d130840159d822'
    and concat('0x', right(topics[1],40)) = '0xa8c1c38ff57428e5c3a34e0899be5cb385476507'
    and a.contract_address = '0x4200000000000000000000000000000000000006'
    and concat('0x', right(topics[2],40)) != '0xa8c1c38ff57428e5c3a34e0899be5cb385476507'
    group by 1
    QueryRunArchived: QueryRun has been archived