BlockTrackerunique Traders
    Updated 2024-09-10
    with data as (
    select
    traders,
    min(block_timestamp) as first_tx
    from
    (
    select
    block_timestamp,
    seller_address as traders
    from aptos.nft.ez_nft_sales
    union all
    select
    block_timestamp,
    buyer_address as traders
    from aptos.nft.ez_nft_sales
    )
    group by 1
    )

    select
    date_trunc('day', first_tx) as date,
    count(DISTINCT traders) as new_trader,
    sum(new_trader) over (order by date) as cum_trader
    from data
    where date >= current_date - 30
    group by 1
    order by 1 desc





    QueryRunArchived: QueryRun has been archived