Query editor
with all_txns as (select distinct tx_id, trader_id as user, amount_usdfrom dex_solana.tradeswhere project = 'pumpswap' and amount_usd is not null),txn_count as (select user, count(tx_id) as swaps, sum(amount_usd) as volumnfrom all_txnsgroup by 1)SELECTCOUNT(DISTINCT CASE WHEN swaps >= 5 THEN user END) AS users_with_5_or_more_swaps,cast(COUNT(DISTINCT CASE WHEN swaps >= 5 THEN user END) as double)/cast(33782532 as double)*100 as percent_users_with_5_or_more_swaps,COUNT(DISTINCT CASE WHEN volumn >= 500 THEN user END) AS users_with_500_or_more_volume,cast(COUNT(DISTINCT CASE WHEN volumn >= 500 THEN user END) as double)/cast(33782532 as double)*100 as percent_users_with_500_or_more_volumeFROM txn_count