Query editor
withmerged as (selectcoalesce(frontend, 'unknown') as frontend,bet_id,bettor,usd_amount,usd_payoutamount as usd_payout,usd_ggr,bet_type,is_freebet,status != 'Accepted' as is_settledfrom dune.azuro.result_ordinars_combos_resolvedleft join dune.azuro.dataset_frontends using (affiliate)union allselectfrontend,bet_id,bettor,usd_amount,usd_payout,usd_ggr,bet_type,is_freebet,bet_status != 'accepted' as is_settledfrom query_5092706 -- live: matview frozen since 2026-10-08 (storage over plan limit)where bet_id not in (-- 2026-10-06 oracle key compromise bets, same exclusion as query 5258401'0xf9548be470a4e130c90cea8b179fcd66d2972ac7_442081','0x0e00e6ffcb5e207b800eec9e02999d1fd9e448f2_6661')),totals as (selectcount(distinct nullif(frontend, 'unknown')) as applications,count(distinct bet_id) as bets,count(distinct bettor) as unique_users,sum(usd_amount - usd_payout) filter (where is_settled) as prediction_amount,sum(usd_amount) filter (where not is_freebet) as bet_amount,sum(usd_ggr) as total_profit,sum(usd_ggr) / nullif(sum(usd_amount) filter (where is_settled and not is_freebet), 0) * 100 as betting_take_rate,sum(usd_amount) filter (where not is_freebet) / count(distinct bettor) as bet_amount_per_user,cast(count(distinct bet_id) as double) / count(distinct bettor) as bets_per_user,sum(usd_amount) filter (where not is_freebet)/ nullif(count(distinct case when not is_freebet then bet_id end), 0) as avg_bet,approx_percentile(case when not is_freebet then usd_amount end, 0.5) as median_betfrom merged),singles as (selectcount(distinct bet_id) as single_bets,sum(usd_amount - usd_payout) filter (where is_settled) as singles_prediction_amount,sum(usd_amount) filter (where not is_freebet) as singles_bet_amount,sum(usd_ggr) as singles_total_profit,sum(usd_ggr) / nullif(sum(usd_amount) filter (where is_settled and not is_freebet), 0) * 100 as singles_betting_take_ratefrom merged