maybeyonaslido_top5_act_bal
    Updated 2022-06-01
    with top_hodl as (
    select
    user_address,
    balance
    from ethereum.erc20_balances
    where contract_address = '0x5a98fcbea516cf06857215779fd812ca3bef1b32'
    and user_address != '0x3e40d73eb977dc6a537af587d48316fee66e9c8c' -- lido treasury
    and balance_date = current_date
    order by balance desc
    limit 5
    )

    select
    balance_date,
    user_address,
    balance
    from ethereum.erc20_balances
    where contract_address = '0x5a98fcbea516cf06857215779fd812ca3bef1b32'
    and user_address != '0x3e40d73eb977dc6a537af587d48316fee66e9c8c'
    and user_address in (select user_address from top_hodl)