thea[Blur Mega] DoD of Trader
    Updated 2023-04-13
    with trader as (
    select block_week,
    count(distinct wallet) as wallets
    from (
    select to_date(date_trunc('week', block_timestamp)) as block_week,
    buyer_address as wallet
    from ethereum.core.ez_nft_sales
    where platform_name = 'blur'
    and price_usd is not null
    union all
    select to_date(date_trunc('week', block_timestamp)) as block_week,
    seller_address as wallet
    from ethereum.core.ez_nft_sales
    where platform_name = 'blur'
    and price_usd is not null
    )
    group by 1
    )
    select block_week,
    (wallets - last_wallets) / last_wallets as trader_dod
    from (
    select *,
    lag(wallets) over (order by block_week) as last_wallets
    from trader
    )
    Run a query to Download Data