0-MIDDepositors new copy
    Updated 2023-08-24
    with tab1 as (
    select date_trunc('minute',BLOCK_TIMESTAMP) as time
    ,TO_ADDRESS
    ,ETH_VALUE
    from base.core.fact_transactions
    where FROM_ADDRESS in('0x80c67432656d59144ceff962e8faf8926599bcf8','0xe4edb277e41dc89ab076a1f049f4a3efa700bce8','0xd9d74a29307cc6fc8bf424ee4217f1a587fbc8dc')
    ),
    tab2 as (
    select date_trunc('day',time) as day
    ,TO_ADDRESS
    ,ETH_VALUE
    ,row_number()over(partition by TO_ADDRESS order by day) as times_row
    from tab1)
    select
    day
    ,count(TO_ADDRESS) as "NEW DEPOSITORS"
    ,sum(ETH_VALUE) as volume
    ,sum("NEW DEPOSITORS")over(order by day) as "TOTAL NEW DEPOSITORS"
    from tab2
    where times_row=1
    group by 1






    Run a query to Download Data