rajsVELO Lock Period
    Updated 2022-08-17
    SELECT
    case when unlock_date::date - block_timestamp::date > 1000 then 'gr_than_1000'
    when unlock_date::date - block_timestamp::date > 100 then 'gr_than_100'
    when unlock_date::date - block_timestamp::date > 10 then 'gr_than_10'
    else 'less_than_10'
    end as lock_category,
    sum(velo_amount) as amount,
    sum(sum(velo_amount)) over () as cum_amount,
    sum(velo_amount) / sum(sum(velo_amount)) over () * 100 as pct_share
    from optimism.velodrome.ez_velo_locks
    where velo_action = 'deposit'
    group by 1
    order by 2 desc
    -- limit 10
    Run a query to Download Data