Grand Slam — three-tier podium plus a WR in one event
PersonA (person, event) qualifies as a "Grand Slam" when four things hold at once: a final-round podium at a World Championship (WC), a final-round podium at the person's Continental Championship, a final-round podium at their National Championship, and at least one WR (single or average) at some point in their career in that event.
The bar stacks — sustained world-top form plus winning at home and on the continent, with a moment of literally being fastest on Earth. The onlyFirst=1 toggle further restricts to people whose three podiums were all gold (pos=1) — the "all-gold" slam.
By the numbers
Data source
CI reads results + championships + eligible_country_iso2s_for_championship from the WCA dump, then folds them into wca_grand_slam keyed by (wca_id, event_id). Championships split three ways: world, leading-underscore continent codes, and ISO2 country codes; multi-country championships (e.g. greater_china) resolve via the eligibility table. The server only reads PG.
SELECT gs.wca_id, gs.event_id, gs.best_value, gs.avg_value,
gs.has_wr, gs.is_only_first,
gs.world_champ_comp_id, gs.world_champ_pos,
gs.continental_champ_comp_id, gs.continental_champ_pos,
gs.national_champ_comp_id, gs.national_champ_pos,
p.name AS person_name
FROM wca_grand_slam gs
JOIN wca_persons p ON p.wca_id = gs.wca_id
WHERE gs.event_id = ?
ORDER BY gs.best_value NULLS LAST;Algorithm / pipeline
results rows where round_type_id ∈ {c, f} and pos BETWEEN 1 AND 3. Heats / semis don't count — must be finals.compId ∈ worldChampComps → WC tier; continentalChampComps.get(compId) === person's continent → continental tier; nationalChampComps.get(compId) === person's country (or the multi-country set contains it) → national tier. If the person podiums multiple times in the same tier, keep the row with the smallest pos.(person, event) with regional_single_record = "WR" or regional_average_record = "WR" flips has_wr = TRUE. No round or comp-type restriction — one WR is enough, forever.wca_grand_slam only if worldChampPos / contChampPos / natChampPos are all non-null and hasWrSingle || hasWrAvg. Then is_only_first = (worldChampPos = 1 AND contChampPos = 1 AND natChampPos = 1)./v1/wca/grand-slam?event=&onlyFirst= filters wca_grand_slam by event_id plus optional is_only_first / has_wr, joins wca_persons / wca_competitions / wca_countries for names + iso2, and returns up to 5000 rows sorted by best_value.Caveats & edges
- Continental tier is decided by the person's current nationality → continent (
persons.country_id→countries.continent_id), not by where the comp was held. People who changed citizenship may "re-qualify". - Podium uses raw
pos(WCA official placement); we don't recompute from values. A DNF'd average withpos = 3still counts. - Multi-country championships (e.g.
greater_china) resolve viaeligible_country_iso2s_for_championship; podiums by TW / HK / MO competitors at China Championship credit their national tier. onlyFirstdoes not require the three golds to be in the same year — across a career is fine.