Table:
0
A
B
C
D
E
F
G
1
Year
Winner
Jockey
Trainer
Owner
Time
Purse
2
2013
London Bridge
Mike Smith
Jo Hughes
Eastwind Racing & Martha Trussell
2:58.32
$500,000
3
2012
Calidoscopio (ARG)
Aaron Gryder
Guillermo Frenkel Santillán
Stud Dona Pancha
2:57.25
$500,000
4
2011
Afleet Again
Cornelio Velasquez
Robert E. Reid, Jr.
Kasey K Racing Stable
3:00.39
$500,000
5
2010
Eldaafer
John Velazquez
Diane Alvardo
IEAH Stables and Mansour Albaroudy
2:59.62
$500,000
6
2009
Man of Iron
Johnny Murtagh
Aidan O'Brien
Derrick Smith/ Susan Magnier / Michael Tabor
2:54.11
$500,000
7
2008
Muhannak
Pat Smullen
Ralph Beckett
Richard Pegum
2:28.24†
$500,000

Questions and formulas:
Question: What was the purse when the trainer was Aidan O'Brien?
Formula: UNIQUE(CHOOSECOLS(FILTER(A1:G1,D1="aidan o'brien"),7))
Formula2: UNIQUE(CHOOSECOLS(FILTER(A2:G7,D2:D7="aidan o'brien"),7))
Level: medium
Question: What is the time for when cornelio velasquez was the jockey?
Formula: UNIQUE(CHOOSECOLS(FILTER(A1:G1,C1="cornelio velasquez"),6))
Formula2: UNIQUE(CHOOSECOLS(FILTER(A2:G7,C2:C7="cornelio velasquez"),6))
Level: medium
Question: Who was the jockey when the owner was Richard Pegum?
Formula: UNIQUE(CHOOSECOLS(FILTER(A1:G1,E1="richard pegum"),3))
Formula2: UNIQUE(CHOOSECOLS(FILTER(A2:G7,E2:E7="richard pegum"),3))
Level: medium
Question: What is the purse when Aidan O'brien was the trainer?
Formula: UNIQUE(CHOOSECOLS(FILTER(A1:G1,D1="aidan o'brien"),7))
Formula2: UNIQUE(CHOOSECOLS(FILTER(A2:G7,D2:D7="aidan o'brien"),7))
Level: medium
Question: What is the purse for the year earlier than 2013 and muhannak was the winner?
Formula: UNIQUE(CHOOSECOLS(FILTER(A1:G1,(A1<2013)*(B1="muhannak")),7))
Formula2: UNIQUE(CHOOSECOLS(FILTER(A2:G7,(A2:A7<2013)*(B2:B7="muhannak")),7))
Level: medium
Question: Who was the trainer in 2013?
Formula: UNIQUE(CHOOSECOLS(FILTER(A1:G1,A1=2013),4))
Formula2: UNIQUE(CHOOSECOLS(FILTER(A2:G7,A2:A7=2013),4))
Level: medium