DevJacobidistribution-joined
    Updated 2022-07-28
    with usdc as (
    with usdc_cleared as (
    select * from flipside_prod_db.algorand.account_asset
    where asset_id = 31566704
    and asset_closed = 'FALSE'
    and frozen = 'FALSE'
    )

    select amount_group_usdc, count(*) as anzahl_usdc from (
    select case
    when amount / 1000000 = 0 then '0'
    when amount / 1000000 < 1 then '< 1'
    when amount / 1000000 < 10 then '1 < x < 10'
    when amount / 1000000 < 100 then '10 < x < 100'
    when amount / 1000000 < 1000 then '100 < x < 1T'
    when amount / 1000000 < 10000 then '1T < x < 10T'
    when amount / 1000000 < 100000 then '10T < x < 100T'
    when amount / 1000000 < 1000000 then '100T < x < 1M'
    when amount / 1000000 < 10000000 then '1M < x < 10M'
    when amount / 1000000 < 100000000 then '10M < x < 100M'
    when amount / 1000000 < 1000000000 then '100M < x < 1Mrd'
    else '1Mrd+'
    end as amount_group_usdc
    from usdc_cleared
    ) group by amount_group_usdc
    order by amount_group_usdc
    ),

    usdt as(
    with usdt_cleared as (
    select * from flipside_prod_db.algorand.account_asset
    where asset_id = 312769
    and asset_closed = 'FALSE'
    and frozen = 'FALSE'
    )

    Run a query to Download Data