maybeyonasalgo_dex_dist_swap_from
    Updated 2022-03-23
    with
    swaps as (
    select
    tx_group_id as tx_id,
    swapper as user,
    swap_from_asset_id as from_asset,
    swap_to_asset_id as to_asset
    from algorand.swaps
    where block_timestamp >= '2022-01-01'
    and swap_from_amount > 0
    ),
    user_swaps as (
    select
    user,
    count(distinct from_asset) as from_asset
    from swaps
    group by 1
    )

    select
    from_asset,
    count(distinct user) as users
    from user_swaps
    group by 1


    Run a query to Download Data