KingTigerMafia-7mwRZbPopular Swap Program
    Updated 2022-06-14
    -- with all_tx as (
    -- select swap_program, count(tx_id) as all_tx
    -- from solana.core.fact_swaps
    -- group by 1
    -- ), success_tx as (
    -- select swap_program, count(tx_id) as success_tx
    -- from solana.core.fact_swaps
    -- where succeeded='TRUE'
    -- group by 1
    -- )
    -- select s.swap_program, success_tx/all_tx*100 as success_rate
    -- from success_tx s join all_tx a on s.swap_program = a.swap_program
    -- order by 2 asc
    -- limit 10


    select swap_program, count(tx_id) as all_tx
    from solana.core.fact_swaps
    group by 1
    order by 2 desc
    Run a query to Download Data