mattkstewGovernance Grind 3
    Updated 2023-01-25
    with tab1 as (
    select
    voter,
    count(distinct proposal_id) as votes

    from terra.core.fact_governance_votes
    where proposal_id in (3796,3795,3794,3665,3619)
    group by 1 )

    select
    case
    when votes = 1 then '1 Vote'
    when votes = 2 then '2 Vote'
    when votes = 3 then '3 Vote'
    when votes = 4 then '4 Vote'
    when votes = 5 then '5 Vote'
    End as voter_votes_distribution,
    count(*)
    from tab1
    group by 1
    Run a query to Download Data