with top10_addresses as (
select
from_address,
sum(amount_e8) / 1e8 as inflow,
100 * ratio_to_report(inflow) over () as perc
from flipside_prod_db.thorchain.transfer_events
where asset = 'THOR.RUNE'
and to_address = 'thor1ty6h2ll07fqfzumphp6kq3hm4ps28xlm2l6kd6'
group by 1
order by 2 desc
limit 10
)
select
from_address,
count(*) as number_of_transfers
from flipside_prod_db.thorchain.transfer_events
where from_address in (select from_address from top10_addresses)
group by 1