chat_prompt
stringlengths 438
1.53k
|
|---|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"season_5_1992\" (\n \"number_in_series\" real,\n \"number_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"original_air_date\" text,\n \"production_code\" text\n);\n\nQuestion: What is the series number that has a production code of 50021\u201350025?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"number_in_series\") FROM \"season_5_1992\" WHERE \"production_code\"='50021\u201350025';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"references\" (\n \"position\" text,\n \"player\" text,\n \"county_team\" text,\n \"club_team_s\" text,\n \"team_number\" real\n);\n\nQuestion: Which county team has jimmy finn as the player?"
},
{
"role": "assistant",
"content": "SELECT \"county_team\" FROM \"references\" WHERE \"player\"='jimmy finn';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"references\" (\n \"position\" text,\n \"player\" text,\n \"county_team\" text,\n \"club_team_s\" text,\n \"team_number\" real\n);\n\nQuestion: How many team numbers have john keane as the player?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"team_number\") FROM \"references\" WHERE \"player\"='john keane';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"references\" (\n \"position\" text,\n \"player\" text,\n \"county_team\" text,\n \"club_team_s\" text,\n \"team_number\" real\n);\n\nQuestion: Which position has john keane as the player?"
},
{
"role": "assistant",
"content": "SELECT \"position\" FROM \"references\" WHERE \"player\"='john keane';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What was the loss of the game when the record was 27-17?"
},
{
"role": "assistant",
"content": "SELECT \"loss\" FROM \"game_log\" WHERE \"record\"='27-17';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"winners\" (\n \"year\" text,\n \"champion\" text,\n \"country\" text,\n \"score\" text,\n \"purse\" real,\n \"winner_s_share\" real\n);\n\nQuestion: Which average purse was earned by Erika Wicoff and has a winner's share greater than $9,750?"
},
{
"role": "assistant",
"content": "SELECT AVG(\"purse\") FROM \"winners\" WHERE \"champion\"='erika wicoff' AND \"winner_s_share\">'9,750';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"group_b_relegation\" (\n \"position\" real,\n \"club\" text,\n \"played\" real,\n \"points\" text,\n \"wins\" real,\n \"draws\" real,\n \"losses\" real,\n \"goals_for\" real,\n \"goals_against\" real,\n \"goal_difference\" real\n);\n\nQuestion: What are the smallest goals with wins smaller than 16, and a Draws larger than 14?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"goals_against\") FROM \"group_b_relegation\" WHERE \"wins\"<16 AND \"draws\">14;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"group_b_relegation\" (\n \"position\" real,\n \"club\" text,\n \"played\" real,\n \"points\" text,\n \"wins\" real,\n \"draws\" real,\n \"losses\" real,\n \"goals_for\" real,\n \"goals_against\" real,\n \"goal_difference\" real\n);\n\nQuestion: What are the average wins with a Points of 42-2, and Goals against of 67, and Played smaller than 44?"
},
{
"role": "assistant",
"content": "SELECT AVG(\"wins\") FROM \"group_b_relegation\" WHERE \"points\"='42-2' AND \"goals_against\"=67 AND \"played\"<44;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"group_b_relegation\" (\n \"position\" real,\n \"club\" text,\n \"played\" real,\n \"points\" text,\n \"wins\" real,\n \"draws\" real,\n \"losses\" real,\n \"goals_for\" real,\n \"goals_against\" real,\n \"goal_difference\" real\n);\n\nQuestion: Which average wins have a Club of barcelona atl\u00e8tic, and Goals for larger than 56?"
},
{
"role": "assistant",
"content": "SELECT AVG(\"wins\") FROM \"group_b_relegation\" WHERE \"club\"='barcelona atl\u00e8tic' AND \"goals_for\">56;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"group_b_relegation\" (\n \"position\" real,\n \"club\" text,\n \"played\" real,\n \"points\" text,\n \"wins\" real,\n \"draws\" real,\n \"losses\" real,\n \"goals_for\" real,\n \"goals_against\" real,\n \"goal_difference\" real\n);\n\nQuestion: Which lowest position has goals against smaller than 78, Points of 42-2, and Wins larger than 15?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"position\") FROM \"group_b_relegation\" WHERE \"goals_against\"<78 AND \"points\"='42-2' AND \"wins\">15;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"group_b_relegation\" (\n \"position\" real,\n \"club\" text,\n \"played\" real,\n \"points\" text,\n \"wins\" real,\n \"draws\" real,\n \"losses\" real,\n \"goals_for\" real,\n \"goals_against\" real,\n \"goal_difference\" real\n);\n\nQuestion: Which lowest played has a Position of 2, and Goals against larger than 53?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"played\") FROM \"group_b_relegation\" WHERE \"position\"=2 AND \"goals_against\">53;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"group_b_relegation\" (\n \"position\" real,\n \"club\" text,\n \"played\" real,\n \"points\" text,\n \"wins\" real,\n \"draws\" real,\n \"losses\" real,\n \"goals_for\" real,\n \"goals_against\" real,\n \"goal_difference\" real\n);\n\nQuestion: How many goal differences have Played larger than 44?"
},
{
"role": "assistant",
"content": "SELECT SUM(\"goal_difference\") FROM \"group_b_relegation\" WHERE \"played\">44;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"achievements\" (\n \"year\" real,\n \"tournament\" text,\n \"venue\" text,\n \"result\" text,\n \"extra\" text\n);\n\nQuestion: What year was the race in Vienna, Austria?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"year\") FROM \"achievements\" WHERE \"venue\"='vienna, austria';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"achievements\" (\n \"year\" real,\n \"tournament\" text,\n \"venue\" text,\n \"result\" text,\n \"extra\" text\n);\n\nQuestion: What event (Extra) in 2002 did the competitor compete in and place 8th?"
},
{
"role": "assistant",
"content": "SELECT \"extra\" FROM \"achievements\" WHERE \"year\"=2002 AND \"result\"='8th';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"achievements\" (\n \"year\" real,\n \"tournament\" text,\n \"venue\" text,\n \"result\" text,\n \"extra\" text\n);\n\nQuestion: Where was the Olympic Games held?"
},
{
"role": "assistant",
"content": "SELECT \"venue\" FROM \"achievements\" WHERE \"tournament\"='olympic games';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: That is the value for Try bonus when the value for Points is 418?"
},
{
"role": "assistant",
"content": "SELECT \"try_bonus\" FROM \"2009_2010_table\" WHERE \"points_for\"='418';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: What is the Club, when the value for Played is 22, and when the value for Tries is 41?"
},
{
"role": "assistant",
"content": "SELECT \"club\" FROM \"2009_2010_table\" WHERE \"played\"='22' AND \"tries_for\"='41';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: What is the value for Drawn, when the value for Losing bonus is 6?"
},
{
"role": "assistant",
"content": "SELECT \"drawn\" FROM \"2009_2010_table\" WHERE \"losing_bonus\"='6';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: What is the value for Lost, when the value for Try bonus is 2, and when the value for Losing bonus is 4?"
},
{
"role": "assistant",
"content": "SELECT \"lost\" FROM \"2009_2010_table\" WHERE \"try_bonus\"='2' AND \"losing_bonus\"='4';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: What is the Losing bonus, when the value for Points is 43?"
},
{
"role": "assistant",
"content": "SELECT \"losing_bonus\" FROM \"2009_2010_table\" WHERE \"points\"='43';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: What is the Club, when the value for Lost is 9, and when the value for Tries is 55?"
},
{
"role": "assistant",
"content": "SELECT \"club\" FROM \"2009_2010_table\" WHERE \"lost\"='9' AND \"tries_for\"='55';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"managers_since_1970\" (\n \"nationality\" text,\n \"cambridge_united_career\" text,\n \"games\" real,\n \"drawn\" real,\n \"lost\" real,\n \"pct_won\" text,\n \"pts_game\" text\n);\n\nQuestion: What is the largest draw with 37 games from England?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"drawn\") FROM \"managers_since_1970\" WHERE \"nationality\"='england' AND \"games\"=37;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"managers_since_1970\" (\n \"nationality\" text,\n \"cambridge_united_career\" text,\n \"games\" real,\n \"drawn\" real,\n \"lost\" real,\n \"pct_won\" text,\n \"pts_game\" text\n);\n\nQuestion: How many draws have a Cambridge United career of 2008\u20132009 and less than 13 losses?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"drawn\") FROM \"managers_since_1970\" WHERE \"cambridge_united_career\"='2008\u20132009' AND \"lost\"<13;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"record\" text\n);\n\nQuestion: What was the record at the game when the score was 1\u20130?"
},
{
"role": "assistant",
"content": "SELECT \"record\" FROM \"game_log\" WHERE \"score\"='1\u20130';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"record\" text\n);\n\nQuestion: What was the score of the game when the record was 19\u201313\u20133?"
},
{
"role": "assistant",
"content": "SELECT \"score\" FROM \"game_log\" WHERE \"record\"='19\u201313\u20133';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"record\" text\n);\n\nQuestion: Who was the visiting team when the score was 1\u20133?"
},
{
"role": "assistant",
"content": "SELECT \"visitor\" FROM \"game_log\" WHERE \"score\"='1\u20133';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"record\" text\n);\n\nQuestion: Who was the home team when there was a record of 20\u201313\u20133?"
},
{
"role": "assistant",
"content": "SELECT \"home\" FROM \"game_log\" WHERE \"record\"='20\u201313\u20133';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"record\" text\n);\n\nQuestion: What was the date of the game with the record of 18\u201310\u20132?"
},
{
"role": "assistant",
"content": "SELECT \"date\" FROM \"game_log\" WHERE \"record\"='18\u201310\u20132';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"december\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"decision\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: Visitor of minnesota has what average attendance?"
},
{
"role": "assistant",
"content": "SELECT AVG(\"attendance\") FROM \"december\" WHERE \"visitor\"='minnesota';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"december\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"decision\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: Date of december 29 has what visitor?"
},
{
"role": "assistant",
"content": "SELECT \"visitor\" FROM \"december\" WHERE \"date\"='december 29';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"december\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"decision\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: Score of 2 \u2013 3 has what attendance?"
},
{
"role": "assistant",
"content": "SELECT \"attendance\" FROM \"december\" WHERE \"score\"='2 \u2013 3';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: With a record of 48-51 for the team, the lowest 2005 attendance was listed as how many?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"attendance\") FROM \"game_log\" WHERE \"record\"='48-51';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What would be the lowest Attendance that also showed a loss of Obermueller (1-2)?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"attendance\") FROM \"game_log\" WHERE \"loss\"='obermueller (1-2)';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2013_season\" (\n \"week\" real,\n \"date\" text,\n \"visiting_team\" text,\n \"host_team\" text,\n \"stadium\" text\n);\n\nQuestion: What was the stadium for the game held on October 31?"
},
{
"role": "assistant",
"content": "SELECT \"stadium\" FROM \"2013_season\" WHERE \"date\"='october 31';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2013_season\" (\n \"week\" real,\n \"date\" text,\n \"visiting_team\" text,\n \"host_team\" text,\n \"stadium\" text\n);\n\nQuestion: How many weeks in total were games played at Cleveland Browns Stadium?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"week\") FROM \"2013_season\" WHERE \"stadium\"='cleveland browns stadium';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"singles_5_1_4\" (\n \"outcome\" text,\n \"date\" text,\n \"surface\" text,\n \"opponent_in_the_final\" text,\n \"score_in_the_final\" text\n);\n\nQuestion: What was the surface on 23 October 2011?"
},
{
"role": "assistant",
"content": "SELECT \"surface\" FROM \"singles_5_1_4\" WHERE \"date\"='23 october 2011';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"coaching_records\" (\n \"years\" text,\n \"coach\" text,\n \"seasons\" real,\n \"wins\" real,\n \"losses\" real,\n \"ties\" text,\n \"pct\" text\n);\n\nQuestion: Which Notre Dame coach lost 15 games?"
},
{
"role": "assistant",
"content": "SELECT \"coach\" FROM \"coaching_records\" WHERE \"losses\"=15;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"coaching_records\" (\n \"years\" text,\n \"coach\" text,\n \"seasons\" real,\n \"wins\" real,\n \"losses\" real,\n \"ties\" text,\n \"pct\" text\n);\n\nQuestion: How many losses did Notre Dame have in 1904?"
},
{
"role": "assistant",
"content": "SELECT AVG(\"losses\") FROM \"coaching_records\" WHERE \"years\"='1904';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"coaching_records\" (\n \"years\" text,\n \"coach\" text,\n \"seasons\" real,\n \"wins\" real,\n \"losses\" real,\n \"ties\" text,\n \"pct\" text\n);\n\nQuestion: What was the winning percent of Notre Dame in 1905?"
},
{
"role": "assistant",
"content": "SELECT \"pct\" FROM \"coaching_records\" WHERE \"years\"='1905';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"australia_in_england\" (\n \"date\" text,\n \"home_captain\" text,\n \"away_captain\" text,\n \"venue\" text,\n \"result\" text\n);\n\nQuestion: Who is the home captain that played at Edgbaston?"
},
{
"role": "assistant",
"content": "SELECT \"home_captain\" FROM \"australia_in_england\" WHERE \"venue\"='edgbaston';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"australia_in_england\" (\n \"date\" text,\n \"home_captain\" text,\n \"away_captain\" text,\n \"venue\" text,\n \"result\" text\n);\n\nQuestion: Who is the home captain that played at Edgbaston?"
},
{
"role": "assistant",
"content": "SELECT \"home_captain\" FROM \"australia_in_england\" WHERE \"venue\"='edgbaston';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"australia_in_england\" (\n \"date\" text,\n \"home_captain\" text,\n \"away_captain\" text,\n \"venue\" text,\n \"result\" text\n);\n\nQuestion: For the matches with home captain Graham Gooch played on the dates 3,4,5,6,7 June 1993, what was the result?"
},
{
"role": "assistant",
"content": "SELECT \"result\" FROM \"australia_in_england\" WHERE \"home_captain\"='graham gooch' AND \"date\"='3,4,5,6,7 june 1993';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"australia_in_england\" (\n \"date\" text,\n \"home_captain\" text,\n \"away_captain\" text,\n \"venue\" text,\n \"result\" text\n);\n\nQuestion: What was the venue for the matches played on the dates 3,4,5,6,7 June 1993?"
},
{
"role": "assistant",
"content": "SELECT \"venue\" FROM \"australia_in_england\" WHERE \"date\"='3,4,5,6,7 june 1993';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"australia_in_england\" (\n \"date\" text,\n \"home_captain\" text,\n \"away_captain\" text,\n \"venue\" text,\n \"result\" text\n);\n\nQuestion: Who was the away captain for matches played at Trent Bridge?"
},
{
"role": "assistant",
"content": "SELECT \"away_captain\" FROM \"australia_in_england\" WHERE \"venue\"='trent bridge';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"most_career_games\" (\n \"rank\" real,\n \"games\" real,\n \"player\" text,\n \"club_clubs\" text,\n \"career_span\" text\n);\n\nQuestion: Which rank is Hawthorn?"
},
{
"role": "assistant",
"content": "SELECT \"rank\" FROM \"most_career_games\" WHERE \"club_clubs\"='hawthorn';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"billy_elliot\" (\n \"status\" text,\n \"name\" text,\n \"first_performance\" text,\n \"last_performance\" text,\n \"style\" text\n);\n\nQuestion: What is the First Performance when the status is past and the style was ballet, tap?"
},
{
"role": "assistant",
"content": "SELECT \"first_performance\" FROM \"billy_elliot\" WHERE \"status\"='past' AND \"style\"='ballet, tap';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"billy_elliot\" (\n \"status\" text,\n \"name\" text,\n \"first_performance\" text,\n \"last_performance\" text,\n \"style\" text\n);\n\nQuestion: What was the Last Performance when the status is current cast, and a Name of noah parets?"
},
{
"role": "assistant",
"content": "SELECT \"last_performance\" FROM \"billy_elliot\" WHERE \"status\"='current cast' AND \"name\"='noah parets';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"billy_elliot\" (\n \"status\" text,\n \"name\" text,\n \"first_performance\" text,\n \"last_performance\" text,\n \"style\" text\n);\n\nQuestion: What is the style for Giuseppe Bausilio?"
},
{
"role": "assistant",
"content": "SELECT \"style\" FROM \"billy_elliot\" WHERE \"name\"='giuseppe bausilio';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"mixed_martial_arts_record\" (\n \"res\" text,\n \"record\" text,\n \"opponent\" text,\n \"method\" text,\n \"event\" text,\n \"round\" text,\n \"location\" text\n);\n\nQuestion: Which opponent has the event Jungle Fight 6?"
},
{
"role": "assistant",
"content": "SELECT \"opponent\" FROM \"mixed_martial_arts_record\" WHERE \"event\"='jungle fight 6';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"mixed_martial_arts_record\" (\n \"res\" text,\n \"record\" text,\n \"opponent\" text,\n \"method\" text,\n \"event\" text,\n \"round\" text,\n \"location\" text\n);\n\nQuestion: Which is the method under the event Jungle Fight 2?"
},
{
"role": "assistant",
"content": "SELECT \"method\" FROM \"mixed_martial_arts_record\" WHERE \"event\"='jungle fight 2';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"apertura_2004_standings\" (\n \"place\" real,\n \"team\" text,\n \"played\" real,\n \"draw\" real,\n \"lost\" real,\n \"goals_scored\" real,\n \"goals_conceded\" real,\n \"points\" real\n);\n\nQuestion: What is the total number of points when draw is 4?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"points\") FROM \"apertura_2004_standings\" WHERE \"draw\"=4;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"apertura_2004_standings\" (\n \"place\" real,\n \"team\" text,\n \"played\" real,\n \"draw\" real,\n \"lost\" real,\n \"goals_scored\" real,\n \"goals_conceded\" real,\n \"points\" real\n);\n\nQuestion: what is the goals scored when draw is less than 8, points is 19 and goals conceded is more than 26?"
},
{
"role": "assistant",
"content": "SELECT SUM(\"goals_scored\") FROM \"apertura_2004_standings\" WHERE \"draw\"<8 AND \"points\"=19 AND \"goals_conceded\">26;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"apertura_2004_standings\" (\n \"place\" real,\n \"team\" text,\n \"played\" real,\n \"draw\" real,\n \"lost\" real,\n \"goals_scored\" real,\n \"goals_conceded\" real,\n \"points\" real\n);\n\nQuestion: what is the points when the goals conceded is less than 24, place is less than 6 and goals scored is less than 26?"
},
{
"role": "assistant",
"content": "SELECT SUM(\"points\") FROM \"apertura_2004_standings\" WHERE \"goals_conceded\"<24 AND \"place\"<6 AND \"goals_scored\"<26;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"apertura_2004_standings\" (\n \"place\" real,\n \"team\" text,\n \"played\" real,\n \"draw\" real,\n \"lost\" real,\n \"goals_scored\" real,\n \"goals_conceded\" real,\n \"points\" real\n);\n\nQuestion: what is the place when losses is less than 12 and points is less than 19?"
},
{
"role": "assistant",
"content": "SELECT SUM(\"place\") FROM \"apertura_2004_standings\" WHERE \"lost\"<12 AND \"points\"<19;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"apertura_2004_standings\" (\n \"place\" real,\n \"team\" text,\n \"played\" real,\n \"draw\" real,\n \"lost\" real,\n \"goals_scored\" real,\n \"goals_conceded\" real,\n \"points\" real\n);\n\nQuestion: what is the average place when lost is more than 12?"
},
{
"role": "assistant",
"content": "SELECT AVG(\"place\") FROM \"apertura_2004_standings\" WHERE \"lost\">12;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"chamber_of_deputies_election\" (\n \"year\" real,\n \"designation\" text,\n \"pct_votes\" real,\n \"seats\" text,\n \"pct_seats\" real\n);\n\nQuestion: In what Year were there 48 of 120 Seats and a % votes larger than 34.18?"
},
{
"role": "assistant",
"content": "SELECT SUM(\"year\") FROM \"chamber_of_deputies_election\" WHERE \"seats\"='48 of 120' AND \"pct_votes\">34.18;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"chamber_of_deputies_election\" (\n \"year\" real,\n \"designation\" text,\n \"pct_votes\" real,\n \"seats\" text,\n \"pct_seats\" real\n);\n\nQuestion: After 1993, what is the Seats with a % votes of 38.72?"
},
{
"role": "assistant",
"content": "SELECT \"seats\" FROM \"chamber_of_deputies_election\" WHERE \"year\">1993 AND \"pct_votes\"=38.72;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"see_also\" (\n \"peak\" text,\n \"elevation_m\" real,\n \"prominence_m\" real,\n \"isolation_km\" real,\n \"municipality\" text,\n \"county\" text\n);\n\nQuestion: What is the highest Isolation (km) when the elevation was smaller than 1320, and a Municipality of hinn\u00f8ya?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"isolation_km\") FROM \"see_also\" WHERE \"elevation_m\"<1320 AND \"municipality\"='hinn\u00f8ya';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"see_also\" (\n \"peak\" text,\n \"elevation_m\" real,\n \"prominence_m\" real,\n \"isolation_km\" real,\n \"municipality\" text,\n \"county\" text\n);\n\nQuestion: What is the average Isolation in the municipality of Sunndal at an elevation of more than 1850?"
},
{
"role": "assistant",
"content": "SELECT AVG(\"isolation_km\") FROM \"see_also\" WHERE \"municipality\"='sunndal' AND \"elevation_m\">1850;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"see_also\" (\n \"peak\" text,\n \"elevation_m\" real,\n \"prominence_m\" real,\n \"isolation_km\" real,\n \"municipality\" text,\n \"county\" text\n);\n\nQuestion: What is the highest elevation for the peak daurm\u00e5l, and an Isolation (km) larger than 4?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"elevation_m\") FROM \"see_also\" WHERE \"peak\"='daurm\u00e5l' AND \"isolation_km\">4;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"see_also\" (\n \"peak\" text,\n \"elevation_m\" real,\n \"prominence_m\" real,\n \"isolation_km\" real,\n \"municipality\" text,\n \"county\" text\n);\n\nQuestion: What country has an Elevation less than 1833 and an Isolation (km) larger than 18, and a Peak of store lenangstind?"
},
{
"role": "assistant",
"content": "SELECT \"county\" FROM \"see_also\" WHERE \"elevation_m\"<1833 AND \"isolation_km\">18 AND \"peak\"='store lenangstind';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"see_also\" (\n \"peak\" text,\n \"elevation_m\" real,\n \"prominence_m\" real,\n \"isolation_km\" real,\n \"municipality\" text,\n \"county\" text\n);\n\nQuestion: What country has a prominence less than 1292 and an Isolation (km) of 14?"
},
{
"role": "assistant",
"content": "SELECT \"county\" FROM \"see_also\" WHERE \"prominence_m\"<1292 AND \"isolation_km\"=14;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"heats\" (\n \"heat\" real,\n \"lane\" real,\n \"name\" text,\n \"nationality\" text,\n \"time\" text\n);\n\nQuestion: Which lane did George Bovell swim in?"
},
{
"role": "assistant",
"content": "SELECT SUM(\"lane\") FROM \"heats\" WHERE \"name\"='george bovell';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"summary\" (\n \"tournament\" text,\n \"wins\" real,\n \"top_5\" real,\n \"top_10\" real,\n \"top_25\" real,\n \"events\" real,\n \"cuts_made\" real\n);\n\nQuestion: What is the average of the top-25 with 16 cuts and less than 23 events?"
},
{
"role": "assistant",
"content": "SELECT AVG(\"top_25\") FROM \"summary\" WHERE \"cuts_made\"=16 AND \"events\"<23;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"summary\" (\n \"tournament\" text,\n \"wins\" real,\n \"top_5\" real,\n \"top_10\" real,\n \"top_25\" real,\n \"events\" real,\n \"cuts_made\" real\n);\n\nQuestion: What is the highest top-25 with more than 9 top-10 but less than 29 events?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"top_25\") FROM \"summary\" WHERE \"top_10\">9 AND \"events\"<29;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"indianapolis_colts_draft_history\" (\n \"round\" real,\n \"pick_num\" real,\n \"overall\" real,\n \"name\" text,\n \"position\" text,\n \"college\" text\n);\n\nQuestion: What's the Overall average that has brad scioli, and a Pick # larger than 5?"
},
{
"role": "assistant",
"content": "SELECT AVG(\"overall\") FROM \"indianapolis_colts_draft_history\" WHERE \"name\"='brad scioli' AND \"pick_num\">5;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"indianapolis_colts_draft_history\" (\n \"round\" real,\n \"pick_num\" real,\n \"overall\" real,\n \"name\" text,\n \"position\" text,\n \"college\" text\n);\n\nQuestion: What's the lowest Overall average that has a College of Arkansas, and a Round larger than 3?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"overall\") FROM \"indianapolis_colts_draft_history\" WHERE \"college\"='arkansas' AND \"round\">3;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"indianapolis_colts_draft_history\" (\n \"round\" real,\n \"pick_num\" real,\n \"overall\" real,\n \"name\" text,\n \"position\" text,\n \"college\" text\n);\n\nQuestion: Which highest Overall has a Pick # of 4, and a Round larger than 7?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"overall\") FROM \"indianapolis_colts_draft_history\" WHERE \"pick_num\"=4 AND \"round\">7;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"indianapolis_colts_draft_history\" (\n \"round\" real,\n \"pick_num\" real,\n \"overall\" real,\n \"name\" text,\n \"position\" text,\n \"college\" text\n);\n\nQuestion: What's the overall average that has a round less than 7, and a Pick # of 4?"
},
{
"role": "assistant",
"content": "SELECT AVG(\"overall\") FROM \"indianapolis_colts_draft_history\" WHERE \"round\"<7 AND \"pick_num\"=4;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"nominations\" (\n \"no_1\" text,\n \"no_2\" text,\n \"no_3\" text,\n \"no_4\" text,\n \"no_5\" text,\n \"intruder\" text,\n \"no_6\" text,\n \"no_7\" text,\n \"no_8\" text,\n \"no_9\" text,\n \"final\" text\n);\n\nQuestion: Who is the no. 4 team that has the no. 5 player Susana Telmo?"
},
{
"role": "assistant",
"content": "SELECT \"no_4\" FROM \"nominations\" WHERE \"no_5\"='susana telmo';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"nominations\" (\n \"no_1\" text,\n \"no_2\" text,\n \"no_3\" text,\n \"no_4\" text,\n \"no_5\" text,\n \"intruder\" text,\n \"no_6\" text,\n \"no_7\" text,\n \"no_8\" text,\n \"no_9\" text,\n \"final\" text\n);\n\nQuestion: Who is the no. 9 team that has a no. 6 player of paulo?"
},
{
"role": "assistant",
"content": "SELECT \"no_9\" FROM \"nominations\" WHERE \"no_6\"='paulo';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"nominations\" (\n \"no_1\" text,\n \"no_2\" text,\n \"no_3\" text,\n \"no_4\" text,\n \"no_5\" text,\n \"intruder\" text,\n \"no_6\" text,\n \"no_7\" text,\n \"no_8\" text,\n \"no_9\" text,\n \"final\" text\n);\n\nQuestion: Who this the no. 8 team that has a no. 9 player, Telmo?"
},
{
"role": "assistant",
"content": "SELECT \"no_8\" FROM \"nominations\" WHERE \"no_9\"='telmo';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"geography_and_environment\" (\n \"island\" text,\n \"nickname\" text,\n \"area\" text,\n \"population_as_of_2010\" real,\n \"highest_point\" text,\n \"elevation\" text,\n \"age_ma\" text\n);\n\nQuestion: Name the nickname with age of 4.9"
},
{
"role": "assistant",
"content": "SELECT \"nickname\" FROM \"geography_and_environment\" WHERE \"age_ma\"='4.9';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"geography_and_environment\" (\n \"island\" text,\n \"nickname\" text,\n \"area\" text,\n \"population_as_of_2010\" real,\n \"highest_point\" text,\n \"elevation\" text,\n \"age_ma\" text\n);\n\nQuestion: Name the island with age ma of 1.0"
},
{
"role": "assistant",
"content": "SELECT \"island\" FROM \"geography_and_environment\" WHERE \"age_ma\"='1.0';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"geography_and_environment\" (\n \"island\" text,\n \"nickname\" text,\n \"area\" text,\n \"population_as_of_2010\" real,\n \"highest_point\" text,\n \"elevation\" text,\n \"age_ma\" text\n);\n\nQuestion: Name the elevation of the gathering place"
},
{
"role": "assistant",
"content": "SELECT \"elevation\" FROM \"geography_and_environment\" WHERE \"nickname\"='the gathering place';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"geography_and_environment\" (\n \"island\" text,\n \"nickname\" text,\n \"area\" text,\n \"population_as_of_2010\" real,\n \"highest_point\" text,\n \"elevation\" text,\n \"age_ma\" text\n);\n\nQuestion: Name the most point with population less than 144,444 and age of 1.0"
},
{
"role": "assistant",
"content": "SELECT \"highest_point\" FROM \"geography_and_environment\" WHERE \"population_as_of_2010\"<'144,444' AND \"age_ma\"='1.0';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"series_winners\" (\n \"season\" real,\n \"season_premiere_date\" text,\n \"season_finale_date\" text,\n \"winner\" text,\n \"1st_runner_up\" text,\n \"2nd_runner_up\" text\n);\n\nQuestion: Who won when mahesh manjrekar was the 2nd runner-up?"
},
{
"role": "assistant",
"content": "SELECT \"winner\" FROM \"series_winners\" WHERE \"2nd_runner_up\"='mahesh manjrekar';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"series_winners\" (\n \"season\" real,\n \"season_premiere_date\" text,\n \"season_finale_date\" text,\n \"winner\" text,\n \"1st_runner_up\" text,\n \"2nd_runner_up\" text\n);\n\nQuestion: When was the season finale of a show with season premiere on 12 December 2010?"
},
{
"role": "assistant",
"content": "SELECT \"season_finale_date\" FROM \"series_winners\" WHERE \"season_premiere_date\"='12 december 2010';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"schedule\" (\n \"week\" real,\n \"date\" text,\n \"opponent\" text,\n \"result\" text,\n \"game_site\" text,\n \"record\" text,\n \"attendance\" real\n);\n\nQuestion: Game site of kingdome, and a Result of w 24-6 has what record?"
},
{
"role": "assistant",
"content": "SELECT \"record\" FROM \"schedule\" WHERE \"game_site\"='kingdome' AND \"result\"='w 24-6';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"schedule\" (\n \"week\" real,\n \"date\" text,\n \"opponent\" text,\n \"result\" text,\n \"game_site\" text,\n \"record\" text,\n \"attendance\" real\n);\n\nQuestion: Attendance larger than 60,967, and a Opponent of at cleveland browns has what record?"
},
{
"role": "assistant",
"content": "SELECT \"record\" FROM \"schedule\" WHERE \"attendance\">'60,967' AND \"opponent\"='at cleveland browns';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"schedule\" (\n \"week\" real,\n \"date\" text,\n \"opponent\" text,\n \"result\" text,\n \"game_site\" text,\n \"record\" text,\n \"attendance\" real\n);\n\nQuestion: Date of september 25, 1983 is what game site?"
},
{
"role": "assistant",
"content": "SELECT \"game_site\" FROM \"schedule\" WHERE \"date\"='september 25, 1983';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text,\n \"stadium\" text\n);\n\nQuestion: What stadium held the game that had a score of 6\u20133?"
},
{
"role": "assistant",
"content": "SELECT \"stadium\" FROM \"game_log\" WHERE \"score\"='6\u20133';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text,\n \"stadium\" text\n);\n\nQuestion: What was the date of the game that had a loss of Reed (0\u20132)?"
},
{
"role": "assistant",
"content": "SELECT \"date\" FROM \"game_log\" WHERE \"loss\"='reed (0\u20132)';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text,\n \"stadium\" text\n);\n\nQuestion: What was the date of the game attended by more than 44,835 with a record of 0\u20131?"
},
{
"role": "assistant",
"content": "SELECT \"date\" FROM \"game_log\" WHERE \"attendance\">'44,835' AND \"record\"='0\u20131';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" text,\n \"record\" text\n);\n\nQuestion: On which Date was there a record of 11-8?"
},
{
"role": "assistant",
"content": "SELECT \"date\" FROM \"game_log\" WHERE \"record\"='11-8';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"most_grand_tour_podiums\" (\n \"name\" text,\n \"tour\" real,\n \"giro\" real,\n \"vuelta\" real,\n \"total\" real\n);\n\nQuestion: How many podiums associated with 1 vuelta and over 7 tours?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"total\") FROM \"most_grand_tour_podiums\" WHERE \"vuelta\"=1 AND \"tour\">7;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"most_grand_tour_podiums\" (\n \"name\" text,\n \"tour\" real,\n \"giro\" real,\n \"vuelta\" real,\n \"total\" real\n);\n\nQuestion: What is the total for miguel indur\u00e1in with a Vuelta larger than 1?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"total\") FROM \"most_grand_tour_podiums\" WHERE \"name\"='miguel indur\u00e1in' AND \"vuelta\">1;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"race\" (\n \"name\" text,\n \"team\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real,\n \"points\" real\n);\n\nQuestion: What is the grid associated with a Time/Retired of + 1 lap, and under 7 points?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"grid\") FROM \"race\" WHERE \"time_retired\"='+ 1 lap' AND \"points\"<7;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"race\" (\n \"name\" text,\n \"team\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real,\n \"points\" real\n);\n\nQuestion: What grid is associated with 67 laps?"
},
{
"role": "assistant",
"content": "SELECT \"grid\" FROM \"race\" WHERE \"laps\"=67;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"all_time_top_25_women\" (\n \"rank\" real,\n \"time\" text,\n \"wind_m_s\" text,\n \"athlete\" text,\n \"nation\" text,\n \"date\" text,\n \"location\" text\n);\n\nQuestion: Name the nation for 8 june 1983 for marlies gohr"
},
{
"role": "assistant",
"content": "SELECT \"nation\" FROM \"all_time_top_25_women\" WHERE \"date\"='8 june 1983' AND \"athlete\"='marlies gohr';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"all_time_top_25_women\" (\n \"rank\" real,\n \"time\" text,\n \"wind_m_s\" text,\n \"athlete\" text,\n \"nation\" text,\n \"date\" text,\n \"location\" text\n);\n\nQuestion: Name the athlete for bulgaria with rank less than 22"
},
{
"role": "assistant",
"content": "SELECT \"athlete\" FROM \"all_time_top_25_women\" WHERE \"rank\"<22 AND \"nation\"='bulgaria';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"complete_formula_one_world_championship_\" (\n \"year\" real,\n \"entrant\" text,\n \"chassis\" text,\n \"engine\" text,\n \"pts\" real\n);\n\nQuestion: What engine was used by Ram Penthouse Rizla Racing in 1978?"
},
{
"role": "assistant",
"content": "SELECT \"engine\" FROM \"complete_formula_one_world_championship_\" WHERE \"year\">1978 AND \"entrant\"='ram penthouse rizla racing';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"players_selected\" (\n \"year\" real,\n \"pick\" text,\n \"player_name\" text,\n \"college\" text,\n \"position\" text\n);\n\nQuestion: Which College has a Year smaller than 1962, and a Position of rb?"
},
{
"role": "assistant",
"content": "SELECT \"college\" FROM \"players_selected\" WHERE \"year\"<1962 AND \"position\"='rb';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"players_selected\" (\n \"year\" real,\n \"pick\" text,\n \"player_name\" text,\n \"college\" text,\n \"position\" text\n);\n\nQuestion: Which Year has a College of nebraska, and a Pick of 2?"
},
{
"role": "assistant",
"content": "SELECT \"year\" FROM \"players_selected\" WHERE \"college\"='nebraska' AND \"pick\"='2';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"players_selected\" (\n \"year\" real,\n \"pick\" text,\n \"player_name\" text,\n \"college\" text,\n \"position\" text\n);\n\nQuestion: Which Pick has a Year larger than 1983, and a Player name of brian jozwiak?"
},
{
"role": "assistant",
"content": "SELECT \"pick\" FROM \"players_selected\" WHERE \"year\">1983 AND \"player_name\"='brian jozwiak';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"players_selected\" (\n \"year\" real,\n \"pick\" text,\n \"player_name\" text,\n \"college\" text,\n \"position\" text\n);\n\nQuestion: Which lowest year has a Position of rb, and a College of louisiana state?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"year\") FROM \"players_selected\" WHERE \"position\"='rb' AND \"college\"='louisiana state';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"players_selected\" (\n \"year\" real,\n \"pick\" text,\n \"player_name\" text,\n \"college\" text,\n \"position\" text\n);\n\nQuestion: How many years have a Player name of ronnie bull?"
},
{
"role": "assistant",
"content": "SELECT SUM(\"year\") FROM \"players_selected\" WHERE \"player_name\"='ronnie bull';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2005\" (\n \"film\" text,\n \"director_s\" text,\n \"producer_s\" text,\n \"recipient\" text,\n \"date\" text,\n \"award\" text\n);\n\nQuestion: Who was the recipient of an award of \u00a34,203?"
},
{
"role": "assistant",
"content": "SELECT \"recipient\" FROM \"2005\" WHERE \"award\"='\u00a34,203';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2005\" (\n \"film\" text,\n \"director_s\" text,\n \"producer_s\" text,\n \"recipient\" text,\n \"date\" text,\n \"award\" text\n);\n\nQuestion: Who directed the film that received an award of \u00a36,245?"
},
{
"role": "assistant",
"content": "SELECT \"director_s\" FROM \"2005\" WHERE \"award\"='\u00a36,245';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2005\" (\n \"film\" text,\n \"director_s\" text,\n \"producer_s\" text,\n \"recipient\" text,\n \"date\" text,\n \"award\" text\n);\n\nQuestion: Who directed the film that Avie Luthra received an award for?"
},
{
"role": "assistant",
"content": "SELECT \"director_s\" FROM \"2005\" WHERE \"recipient\"='avie luthra';"
}
]
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.