hbd1994#3: Is Uniswap Attracting New Users? | Overall
    Updated 2023-05-16
    with uniswap_new_users as (
    select
    ORIGIN_FROM_ADDRESS as new_users,
    min(BLOCK_TIMESTAMP) as first_swap_date
    from ethereum.core.ez_dex_swaps
    where PLATFORM ilike '%uniswap%'
    group by 1
    order by 2
    )

    select
    case
    when date_trunc('day', first_swap_date::date) >= Current_date - {{Days_From_Now}} then 'Desired Interval'
    else 'Before Desired Interval' end as interval_type,
    count (distinct new_users) as new_users_count
    from uniswap_new_users
    group by 1
    order by 1



    Run a query to Download Data