Query editor
selectpr.block_month,pr.user_address,f.from_owner as funding_address,casewhen f.from_owner in ('5F1seMKUqSNhv45f6FhB2cFmgJbk8U1avJw7M6TexUq1', 'Ar4Yshdo4jDwfYuuva6rMpopoKR9meHfHd3W2fUKp5SS', 'Cc3bpPzUvgAzdW9Nv7dUQ8cpap8Xa7ujJgLdpqGrTCu6')then 'on-ramp'when cex_name is not nullthen 'exchange'else 'unknown'end as funding_provider,sum(f.amount_usd) as funding_amount_usdfrom dune.meso_team.result_phantom_solana_swap_revenue prjoin tokens_solana.transfers f on f.to_owner = pr.user_address and f.block_month = pr.block_monthleft join cex_solana.addresses cex on cex.address = f.from_ownerwhere f.amount_usd > 0and f.from_owner not in ('25mYnjJ2MXHZH6NvTTdA63JvjgRVcuiaj6MRiEQNs1Dq','9yj3zvLS3fDMqi1F8zhkaWfq8TZpZWHe6cz1Sgt7djXf','8psNvWTrdNTiVRNzAgsou9kETXNJm2SXZyaKuJraVRtf','CnmA6Zb8hLrG33AT4RTzKdGv1vKwRBKQQr8iNckvv8Yg','2rQZb9xqQGwoCMDkpabbzDB9wyPTjSPj9WNhJodTaRHm','9gnLg6NtVxaASvxtADLFKZ9s8yHft1jXb1Vu6gVKvh1J','wtpXRqKLdGc7vpReogsRugv6EFCw4HBHcxm8pFcR84a','D1NJy3Qq3RKBG29EDRj28ozbGwnhmM5yBUp8PonSYUnm')group by 1,2,3,4,5