with maintable as (
select 'Hyperspace' as platform,
purchaser,
count (distinct tx_id) as Sales_Count,
count (distinct mint) as NFTS_Count,
sum (sales_amount) as Total_SOL_Volume
from solana.core.fact_nft_sales
where marketplace = 'hyperspace'
and succeeded = 'TRUE'
group by 1,2
union ALL
select 'Coral Cube' as platform,
purchaser,
count (distinct tx_id) as Sales_Count,
count (distinct mint) as NFTS_Count,
sum (sales_amount) as Total_SOL_Volume
from solana.core.fact_nft_sales
where marketplace = 'coral cube'
and succeeded = 'TRUE'
group by 1,2)
select purchaser,
sales_count,
total_sol_volume
from maintable
where platform = 'Hyperspace'
order by 3 desc
limit 10