select distinct PROGRAM_NAME, address_name, count (distinct realms_id) as DAOs_Count
from solana.core.fact_proposal_votes v
inner join solana.core.dim_labels l on l.address = v.PROGRAM_NAME
group by PROGRAM_NAME, address_name
order by DAOs_Count DESC