conversations
listlengths 2
2
|
---|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Record\n###Question: With a record of 43-26, what was the score that game?"
},
{
"from": "gpt",
"value": "SELECT Score FROM table WHERE Record = 43-26"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Record\n###Question: On June 8, what's the loss when the Blue Jays played the Tigers?"
},
{
"from": "gpt",
"value": "SELECT Loss FROM table WHERE Opponent = tigers AND Date = june 8"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Record\n###Question: What date was the record 38-22?"
},
{
"from": "gpt",
"value": "SELECT Date FROM table WHERE Record = 38-22"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Record\n###Question: The game that had a record of 39-25, what was the score?"
},
{
"from": "gpt",
"value": "SELECT Score FROM table WHERE Record = 39-25"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Tournament, Winning score, Margin of victory, Runner-up\n###Question: Which runner-up has a 10 strokes margin of victory?"
},
{
"from": "gpt",
"value": "SELECT Runner-up FROM table WHERE Margin of victory = 10 strokes"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Res., Record, Opponent, Method, Event, Round, Time, Location\n###Question: Which of the events only lasted no more than 0:55?"
},
{
"from": "gpt",
"value": "SELECT Event FROM table WHERE Time = 0:55"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Res., Record, Opponent, Method, Event, Round, Time, Location\n###Question: Which event only lasted for 3 rounds against Fernando Terere?"
},
{
"from": "gpt",
"value": "SELECT Event FROM table WHERE Round = 3 AND Opponent = fernando terere"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Team, Car(s), Driver(s), Primary Sponsor(s), Owner(s), Crew Chief, Rounds\n###Question: What is the Primary Sponsor for the team owned by Randy Humphrey?"
},
{
"from": "gpt",
"value": "SELECT Primary Sponsor(s) FROM table WHERE Owner(s) = randy humphrey"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Team, Car(s), Driver(s), Primary Sponsor(s), Owner(s), Crew Chief, Rounds\n###Question: Who is the Driver on Bob Keselowski's team?"
},
{
"from": "gpt",
"value": "SELECT Driver(s) FROM table WHERE Owner(s) = bob keselowski"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Team, Car(s), Driver(s), Primary Sponsor(s), Owner(s), Crew Chief, Rounds\n###Question: Walter Giles is Crew Chief of what team?"
},
{
"from": "gpt",
"value": "SELECT Team FROM table WHERE Crew Chief = walter giles"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Rank, Stadium, Capacity, Club, Region\n###Question: What club does the stadium stc krymteplitsia belong to?"
},
{
"from": "gpt",
"value": "SELECT Club FROM table WHERE Stadium = stc krymteplitsia"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Year, Start, Qual, Rank, Finish, Laps\n###Question: What was Tony Bettenhausen's qualifying time in 1947?"
},
{
"from": "gpt",
"value": "SELECT Qual FROM table WHERE Year = 1947"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Year, Start, Qual, Rank, Finish, Laps\n###Question: Which year did Tony Bettenhausen complete more than 200 laps?"
},
{
"from": "gpt",
"value": "SELECT Year FROM table WHERE Laps > 200"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Tournament, 2001, 2002, 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012\n###Question: What was the value in 2006 when 2003 was not held and 2012 was A?"
},
{
"from": "gpt",
"value": "SELECT 2006 FROM table WHERE 2003 = not held AND 2012 = a"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Tournament, 2001, 2002, 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012\n###Question: What was the 2008 value when 2012 was Grand Slam Tournaments?"
},
{
"from": "gpt",
"value": "SELECT 2008 FROM table WHERE 2012 = grand slam tournaments"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Tournament, 2001, 2002, 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012\n###Question: What was the value in 2008 when 2012 was 1R, 2010 was A, and 2005 was A?"
},
{
"from": "gpt",
"value": "SELECT 2008 FROM table WHERE 2012 = 1r AND 2010 = a AND 2005 = a"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Tournament, 2001, 2002, 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012\n###Question: What was the value in 2003 when 2006 was WTA Premier Mandatory Tournaments?"
},
{
"from": "gpt",
"value": "SELECT 2003 FROM table WHERE 2006 = wta premier mandatory tournaments"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Tournament, 2001, 2002, 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012\n###Question: What was the value in 2009 when 2005 was A for the Australian Open?"
},
{
"from": "gpt",
"value": "SELECT 2009 FROM table WHERE 2005 = a AND Tournament = australian open"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Tournament, 2001, 2002, 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012\n###Question: What was the value in 2012 when 2002 was Q1 and 2010 was 1R?"
},
{
"from": "gpt",
"value": "SELECT 2012 FROM table WHERE 2002 = q1 AND 2010 = 1r"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: name, type, elevation, USGS Map, GNIS ID\n###Question: What type has a GNIS ID of 1139805"
},
{
"from": "gpt",
"value": "SELECT type FROM table WHERE GNIS ID = 1139805"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: name, type, elevation, USGS Map, GNIS ID\n###Question: Which name has a USGS Map of clear lake?"
},
{
"from": "gpt",
"value": "SELECT name FROM table WHERE USGS Map = clear lake"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Name, Country, Status, Transfer window, Transfer fee, Source\n###Question: What is the status of Norris?"
},
{
"from": "gpt",
"value": "SELECT Status FROM table WHERE Name = norris"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Name, Country, Status, Transfer window, Transfer fee, Source\n###Question: What is the source for Laird?"
},
{
"from": "gpt",
"value": "SELECT Source FROM table WHERE Name = laird"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Class, Type, Fleet numbers, Quantity made, Date made, 1958 CIÉ, 1958 UTA, Date withdrawn\n###Question: What 1958 CIE is class s?"
},
{
"from": "gpt",
"value": "SELECT 1958 CIÉ FROM table WHERE Class = s"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Class, Type, Fleet numbers, Quantity made, Date made, 1958 CIÉ, 1958 UTA, Date withdrawn\n###Question: What day withdrawn is associated with fleet numbers of 12, 25, 42–46, 50, 70–71, 74–77, 106–107, 129?"
},
{
"from": "gpt",
"value": "SELECT Date withdrawn FROM table WHERE Fleet numbers = 12, 25, 42–46, 50, 70–71, 74–77, 106–107, 129"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Place, Player, Country, Score, To par, Earnings ( $ )\n###Question: Which player has a score of 74-74-73-70=291?"
},
{
"from": "gpt",
"value": "SELECT Player FROM table WHERE Score = 74-74-73-70=291"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Place, Player, Country, Score, To par, Earnings ( $ )\n###Question: What is the average earnings of a United States player who had a score of 72-68-74-72=286?"
},
{
"from": "gpt",
"value": "SELECT AVG Earnings ( $ ) FROM table WHERE Country = united states AND Score = 72-68-74-72=286"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Attendance\n###Question: What was the attendance at the game that had a loss of Mercker (3-1)?"
},
{
"from": "gpt",
"value": "SELECT Attendance FROM table WHERE Loss = mercker (3-1)"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Attendance\n###Question: What was the attendance at the game that had a loss of Ayala (6-12)?"
},
{
"from": "gpt",
"value": "SELECT Attendance FROM table WHERE Loss = ayala (6-12)"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Attendance\n###Question: What was the loss of the game that had a score of 9-7?"
},
{
"from": "gpt",
"value": "SELECT Loss FROM table WHERE Score = 9-7"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Attendance\n###Question: What was the loss of the game attended by 14,691?"
},
{
"from": "gpt",
"value": "SELECT Loss FROM table WHERE Attendance = 14,691"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Attendance\n###Question: What was the loss of the game attended by 29,704?"
},
{
"from": "gpt",
"value": "SELECT Loss FROM table WHERE Attendance = 29,704"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Winner, Score, Location, Series\n###Question: What is the Winner, when the Location is Clemson, SC, and when the Date is November 17, 2012?"
},
{
"from": "gpt",
"value": "SELECT Winner FROM table WHERE Location = clemson, sc AND Date = november 17, 2012"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Winner, Score, Location, Series\n###Question: What is the Location, when the Score is 38-29?"
},
{
"from": "gpt",
"value": "SELECT Location FROM table WHERE Score = 38-29"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Winner, Score, Location, Series\n###Question: What is the Location, when the Score is 35-31?"
},
{
"from": "gpt",
"value": "SELECT Location FROM table WHERE Score = 35-31"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Winner, Score, Location, Series\n###Question: What is the Score, when the Location is Clemson, SC, when the Winner is Clemson, and when the Date is November 11, 2006?"
},
{
"from": "gpt",
"value": "SELECT Score FROM table WHERE Location = clemson, sc AND Winner = clemson AND Date = november 11, 2006"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Year, Team, Co-Drivers, Class, Laps, Pos., Class Pos.\n###Question: What year did finish 1st in LMP1 class?"
},
{
"from": "gpt",
"value": "SELECT AVG Year FROM table WHERE Class = lmp1 AND Class Pos. = 1st"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Week, Date, Opponent, Result, Attendance\n###Question: What was the game result on November 16, 1969?"
},
{
"from": "gpt",
"value": "SELECT Result FROM table WHERE Date = november 16, 1969"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Stage, Winner, General classification, Points classification, Mountains classification, Young rider classification, Trofeo Fast Team\n###Question: What is the general classification of stage 3"
},
{
"from": "gpt",
"value": "SELECT General classification FROM table WHERE Stage = 3"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Stage, Winner, General classification, Points classification, Mountains classification, Young rider classification, Trofeo Fast Team\n###Question: How many points did lech piasecki, stephen roche, and carrera jeans-vagabond have?"
},
{
"from": "gpt",
"value": "SELECT Points classification FROM table WHERE Young rider classification = lech piasecki AND General classification = stephen roche AND Winner = carrera jeans-vagabond"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Venue, Score, Result, Competition\n###Question: What venue was the 11 September 2012 game?"
},
{
"from": "gpt",
"value": "SELECT Venue FROM table WHERE Date = 11 september 2012"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Name, Years, Gender, Area, Authority, Decile, Roll\n###Question: What is the lowest Decile for a school with a roll smaller than 3?"
},
{
"from": "gpt",
"value": "SELECT MIN Decile FROM table WHERE Roll < 3"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Name, Years, Gender, Area, Authority, Decile, Roll\n###Question: What is the Gender of students at a school with a Decile of 5 and a Roll of 90?"
},
{
"from": "gpt",
"value": "SELECT Gender FROM table WHERE Decile = 5 AND Roll = 90"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Name, Years, Gender, Area, Authority, Decile, Roll\n###Question: Name the Years of schools with a Roll Larger than 23 and a Decile greater than 5."
},
{
"from": "gpt",
"value": "SELECT Years FROM table WHERE Roll > 23 AND Decile > 5"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Name, Years, Gender, Area, Authority, Decile, Roll\n###Question: What is the total number of Rolls of State schools in Hapuku with a Decile greater than 4?"
},
{
"from": "gpt",
"value": "SELECT COUNT Roll FROM table WHERE Authority = state AND Area = hapuku AND Decile > 4"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: D 48, D 47, D 46, D 45, D 44, D 43, D 42, D 41\n###Question: What is the D45 associated with a D42 of r 22?"
},
{
"from": "gpt",
"value": "SELECT D 45 FROM table WHERE D 42 = r 22"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: D 48, D 47, D 46, D 45, D 44, D 43, D 42, D 41\n###Question: What is the D43 associated with a D41 of r 21?"
},
{
"from": "gpt",
"value": "SELECT D 43 FROM table WHERE D 41 = r 21"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: D 48, D 47, D 46, D 45, D 44, D 43, D 42, D 41\n###Question: What is the D42 associated with a D47 of d 27?"
},
{
"from": "gpt",
"value": "SELECT D 42 FROM table WHERE D 47 = d 27"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: D 48, D 47, D 46, D 45, D 44, D 43, D 42, D 41\n###Question: What is the D43 associated with a D41 of r 16?"
},
{
"from": "gpt",
"value": "SELECT D 43 FROM table WHERE D 41 = r 16"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Record\n###Question: What is the record for the game when the loss was hargan (14–13)?"
},
{
"from": "gpt",
"value": "SELECT Record FROM table WHERE Loss = hargan (14–13)"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Record\n###Question: What is the record for the game with a score of 7–5?"
},
{
"from": "gpt",
"value": "SELECT Record FROM table WHERE Score = 7–5"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Record\n###Question: What date was the game with loss of Aker (3–8)?"
},
{
"from": "gpt",
"value": "SELECT Date FROM table WHERE Loss = aker (3–8)"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Record\n###Question: What team was the opponent when the score was 7–1?"
},
{
"from": "gpt",
"value": "SELECT Opponent FROM table WHERE Score = 7–1"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Record\n###Question: What was the score when the opponent was the Orioles and the loss shows morehead (5–4)?"
},
{
"from": "gpt",
"value": "SELECT Score FROM table WHERE Opponent = orioles AND Loss = morehead (5–4)"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Attendance, Record\n###Question: Name the opponent with a record of 60-61"
},
{
"from": "gpt",
"value": "SELECT Opponent FROM table WHERE Record = 60-61"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Rank, Name, Nationality, Score, Perfection\n###Question: Who had a perfection percentage of 77.96%?"
},
{
"from": "gpt",
"value": "SELECT Name FROM table WHERE Perfection = 77.96%"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Rank, Name, Nationality, Score, Perfection\n###Question: What was the rank of Svetlana Fedorenko?"
},
{
"from": "gpt",
"value": "SELECT Rank FROM table WHERE Name = svetlana fedorenko"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Rank, Name, Nationality, Score, Perfection\n###Question: Who had a perfection percentage of 73.24%?"
},
{
"from": "gpt",
"value": "SELECT Name FROM table WHERE Perfection = 73.24%"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Opponent, Score, Loss, Record\n###Question: What was the score of the game on June 1?"
},
{
"from": "gpt",
"value": "SELECT Score FROM table WHERE Date = june 1"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Tournament, Surface, Opponent, Score\n###Question: What was the score against andrei pavel?"
},
{
"from": "gpt",
"value": "SELECT Score FROM table WHERE Opponent = andrei pavel"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Tournament, Surface, Opponent, Score\n###Question: When was the tournament of bologna?"
},
{
"from": "gpt",
"value": "SELECT Date FROM table WHERE Tournament = bologna"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Tournament, Surface, Opponent, Score\n###Question: Who played on clay and had a score of 6–1, 7–6?"
},
{
"from": "gpt",
"value": "SELECT Opponent FROM table WHERE Surface = clay AND Score = 6–1, 7–6"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Tournament, Surface, Opponent, Score\n###Question: Who played on clay on 3 march 2012?"
},
{
"from": "gpt",
"value": "SELECT Opponent FROM table WHERE Surface = clay AND Date = 3 march 2012"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Tournament, Surface, Opponent, Score\n###Question: What was the score against fabrice martin?"
},
{
"from": "gpt",
"value": "SELECT Score FROM table WHERE Opponent = fabrice martin"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Tournament, Surface, Opponent, Score\n###Question: What was the surface of the score of 7–5, 3–6, 7–6?"
},
{
"from": "gpt",
"value": "SELECT Surface FROM table WHERE Score = 7–5, 3–6, 7–6"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Elector, Order, Title, Elevated, Elevator\n###Question: What's the Order with an Elector of Marino Bulcani?"
},
{
"from": "gpt",
"value": "SELECT Order FROM table WHERE Elector = marino bulcani"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Elector, Order, Title, Elevated, Elevator\n###Question: What's the Elevator that has Elevated: 1378, September 18, an Order of Cardinal-Priest, and an Elector of Poncello Orsini?"
},
{
"from": "gpt",
"value": "SELECT Elevator FROM table WHERE Elevated = 1378, september 18 AND Order = cardinal-priest AND Elector = poncello orsini"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Elector, Order, Title, Elevated, Elevator\n###Question: What is listed as the Elector with the Title of Deacon of S. Maria in Domnica?"
},
{
"from": "gpt",
"value": "SELECT Elector FROM table WHERE Title = deacon of s. maria in domnica"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Elector, Order, Title, Elevated, Elevator\n###Question: What's listed for the Elevated category that has an Order of Cardinal-Bishop?"
},
{
"from": "gpt",
"value": "SELECT Elevated FROM table WHERE Order = cardinal-bishop"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: School, Team, Division Record, Overall Record, Season Outcome\n###Question: The Milford School has what Division Record?"
},
{
"from": "gpt",
"value": "SELECT Division Record FROM table WHERE School = milford"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: School, Team, Division Record, Overall Record, Season Outcome\n###Question: What is the name of the School of the Sussex Tech's Team?"
},
{
"from": "gpt",
"value": "SELECT Team FROM table WHERE School = sussex tech"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Place, Player, Country, Score, To par, Money (US$)\n###Question: What was Arnold Palmer's score in the tournamnet?"
},
{
"from": "gpt",
"value": "SELECT Score FROM table WHERE Player = arnold palmer"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Member, Party, Electorate, State, Term in office\n###Question: What the name of Peter White's party?"
},
{
"from": "gpt",
"value": "SELECT Party FROM table WHERE Member = peter white"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Member, Party, Electorate, State, Term in office\n###Question: What term did an Electorate of indi have in office?"
},
{
"from": "gpt",
"value": "SELECT Term in office FROM table WHERE Electorate = indi"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Member, Party, Electorate, State, Term in office\n###Question: What term did hon ralph hunt serve in office?"
},
{
"from": "gpt",
"value": "SELECT Term in office FROM table WHERE Member = hon ralph hunt"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Member, Party, Electorate, State, Term in office\n###Question: What party is Peter Fisher from Vic serve in office?"
},
{
"from": "gpt",
"value": "SELECT Party FROM table WHERE State = vic AND Member = peter fisher"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Year, Team, Co-Drivers, Class, Laps, Pos., Class Pos.\n###Question: How many laps were done in 2012?"
},
{
"from": "gpt",
"value": "SELECT SUM Laps FROM table WHERE Year = 2012"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Outcome, Date, Tournament, Surface, Opponent, Score\n###Question: On what day was the score of 1–6 6–1 3–6 achieved?"
},
{
"from": "gpt",
"value": "SELECT Date FROM table WHERE Score = 1–6 6–1 3–6"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Rank, Nation, Gold, Silver, Bronze, Total\n###Question: Name the average gold for czech republic and bronze less than 1 when total is less than 14"
},
{
"from": "gpt",
"value": "SELECT AVG Gold FROM table WHERE Total < 14 AND Bronze < 1 AND Nation = czech republic"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Rank, Nation, Gold, Silver, Bronze, Total\n###Question: Name the highest rank when silver is 4 and bronze is less than 3"
},
{
"from": "gpt",
"value": "SELECT MAX Rank FROM table WHERE Silver = 4 AND Bronze < 3"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Rank, Nation, Gold, Silver, Bronze, Total\n###Question: Name the total number of total for bronze of 4 and silver more than 6"
},
{
"from": "gpt",
"value": "SELECT COUNT Total FROM table WHERE Bronze = 4 AND Silver > 6"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Outcome, Date, Tournament, Surface, Partner, Opponents in the final, Score in the final\n###Question: When the Surface was Carpet (i), what was the Outcome?"
},
{
"from": "gpt",
"value": "SELECT Outcome FROM table WHERE Surface = carpet (i)"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Draw, Artist, Song, Votes, Place\n###Question: What is the draw number of the song with a place lower than 6 and more than 38 votes?"
},
{
"from": "gpt",
"value": "SELECT SUM Draw FROM table WHERE Place > 6 AND Votes > 38"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Draw, Artist, Song, Votes, Place\n###Question: What is the total number of votes Sahlene with a place below 1 has?"
},
{
"from": "gpt",
"value": "SELECT COUNT Votes FROM table WHERE Artist = sahlene AND Place > 1"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Draw, Artist, Song, Votes, Place\n###Question: What is the highest place of the song with 38 votes and a draw great than 3?"
},
{
"from": "gpt",
"value": "SELECT MAX Place FROM table WHERE Votes = 38 AND Draw > 3"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Draw, Artist, Song, Votes, Place\n###Question: How many votes did Yvetta Kadakas & Ivo Linna, who had less than 4 draws, have?"
},
{
"from": "gpt",
"value": "SELECT SUM Votes FROM table WHERE Draw < 4 AND Artist = yvetta kadakas & ivo linna"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Year, Chassis, Engine, Start, Finish, Team\n###Question: What year was there a finish of 3?"
},
{
"from": "gpt",
"value": "SELECT Year FROM table WHERE Finish = 3"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Year, Chassis, Engine, Start, Finish, Team\n###Question: What year was the start 33?"
},
{
"from": "gpt",
"value": "SELECT SUM Year FROM table WHERE Start = 33"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Year, Chassis, Engine, Start, Finish, Team\n###Question: When was there a team of Simon and the start was 3?"
},
{
"from": "gpt",
"value": "SELECT Year FROM table WHERE Team = simon AND Start = 3"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Rank, City, Roof ( m ), Spire (m), Floors, Built\n###Question: What's the name of the 1985 city with a Spire (m) of 105, and a Roof (m) smaller than 96?"
},
{
"from": "gpt",
"value": "SELECT City FROM table WHERE Spire (m) = 105 AND Roof ( m ) < 96 AND Built = 1985"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Rank, City, Roof ( m ), Spire (m), Floors, Built\n###Question: What's the average number of floors that were built in 2004, and have a roof (m) of 106?"
},
{
"from": "gpt",
"value": "SELECT AVG Floors FROM table WHERE Built = 2004 AND Roof ( m ) = 106"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Rank, City, Roof ( m ), Spire (m), Floors, Built\n###Question: What's the total number of floors built after 2006, and have a rank of 12?"
},
{
"from": "gpt",
"value": "SELECT SUM Floors FROM table WHERE Built > 2006 AND Rank = 12"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Round, Opponents, H / A, Result F–A, Attendance\n###Question: What is the sum of attendance for H/A values of \"n\"?"
},
{
"from": "gpt",
"value": "SELECT SUM Attendance FROM table WHERE H / A = n"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Outcome, Tournament, Surface, Opponent, Score\n###Question: Name the score which has opponent of stefano galvani"
},
{
"from": "gpt",
"value": "SELECT Score FROM table WHERE Opponent = stefano galvani"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Outcome, Tournament, Surface, Opponent, Score\n###Question: Name the score with opponent of javier genaro-martinez"
},
{
"from": "gpt",
"value": "SELECT Score FROM table WHERE Opponent = javier genaro-martinez"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Outcome, Tournament, Surface, Opponent, Score\n###Question: Name the outcome for dunlop world challenge"
},
{
"from": "gpt",
"value": "SELECT Outcome FROM table WHERE Tournament = dunlop world challenge"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Visiting Team, Final Score, Host Team, Stadium\n###Question: Who was the visiting team on December 6?"
},
{
"from": "gpt",
"value": "SELECT Visiting Team FROM table WHERE Date = december 6"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Visiting Team, Final Score, Host Team, Stadium\n###Question: Who was the host team on October 4?"
},
{
"from": "gpt",
"value": "SELECT Host Team FROM table WHERE Date = october 4"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Company, Business, Country, Value ( USD )\n###Question: In New Zealand, what's the value that has an unknown date and is an energy business?"
},
{
"from": "gpt",
"value": "SELECT Value ( USD ) FROM table WHERE Date = unknown AND Business = energy AND Country = new zealand"
}
]
|
[
{
"from": "human",
"value": "Considering the provided database schema and associated query, produce SQL code to retrieve the answer to the query. \n###Database Schema: Date, Company, Business, Country, Value ( USD )\n###Question: What company has an unknown date and is an energy business?"
},
{
"from": "gpt",
"value": "SELECT Company FROM table WHERE Business = energy AND Date = unknown"
}
]
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.