Updated 2022-10-27
    select
    balance_type,
    count(distinct address) as users,
    sum(balance)/pow(10,6) as osmo,
    avg(balance)/pow(10,6) as average_holdings
    from osmosis.core.fact_daily_balances
    where currency = 'uosmo'
    and balance_type != 'locked liquidity'
    and date = (select max(date) from osmosis.core.fact_daily_balances )
    GROUP BY 1
    Run a query to Download Data