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 \"grand_slam_tournament_performance_timeli\" (\n \"tournament\" text,\n \"2003\" text,\n \"2004\" text,\n \"2005\" text,\n \"2006\" text,\n \"2007\" text,\n \"2008\" text,\n \"2009\" text,\n \"2010\" text,\n \"2011\" text,\n \"2012\" text,\n \"2013\" text,\n \"win_pct\" real\n);\n\nQuestion: Which 2011 has a 2009 of 15\u20132?"
},
{
"role": "assistant",
"content": "SELECT \"2011\" FROM \"grand_slam_tournament_performance_timeli\" WHERE \"2009\"='15\u20132';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"grand_slam_tournament_performance_timeli\" (\n \"tournament\" text,\n \"2003\" text,\n \"2004\" text,\n \"2005\" text,\n \"2006\" text,\n \"2007\" text,\n \"2008\" text,\n \"2009\" text,\n \"2010\" text,\n \"2011\" text,\n \"2012\" text,\n \"2013\" text,\n \"win_pct\" real\n);\n\nQuestion: Which 2010 has a 2006 of w?"
},
{
"role": "assistant",
"content": "SELECT \"2010\" FROM \"grand_slam_tournament_performance_timeli\" WHERE \"2006\"='w';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"grand_slam_tournament_performance_timeli\" (\n \"tournament\" text,\n \"2003\" text,\n \"2004\" text,\n \"2005\" text,\n \"2006\" text,\n \"2007\" text,\n \"2008\" text,\n \"2009\" text,\n \"2010\" text,\n \"2011\" text,\n \"2012\" text,\n \"2013\" text,\n \"win_pct\" real\n);\n\nQuestion: Which 2008 has a 2005 of 13\u20133?"
},
{
"role": "assistant",
"content": "SELECT \"2008\" FROM \"grand_slam_tournament_performance_timeli\" WHERE \"2005\"='13\u20133';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"round_1\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"ground\" text,\n \"crowd\" text,\n \"date\" text,\n \"time\" text,\n \"report\" text\n);\n\nQuestion: What is the time of the Ghantoot Racing and Polo Club?"
},
{
"role": "assistant",
"content": "SELECT \"time\" FROM \"round_1\" WHERE \"ground\"='ghantoot racing and polo club';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"round_1\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"ground\" text,\n \"crowd\" text,\n \"date\" text,\n \"time\" text,\n \"report\" text\n);\n\nQuestion: What is the home team score of the game with Adelaide as the away team?"
},
{
"role": "assistant",
"content": "SELECT \"home_team_score\" FROM \"round_1\" WHERE \"away_team\"='adelaide';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"round_1\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"ground\" text,\n \"crowd\" text,\n \"date\" text,\n \"time\" text,\n \"report\" text\n);\n\nQuestion: What is the time of the Essendon home team game?"
},
{
"role": "assistant",
"content": "SELECT \"time\" FROM \"round_1\" WHERE \"home_team\"='essendon';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"round_1\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"ground\" text,\n \"crowd\" text,\n \"date\" text,\n \"time\" text,\n \"report\" text\n);\n\nQuestion: What is the home team score of the Ghantoot Racing and Polo Club Ground?"
},
{
"role": "assistant",
"content": "SELECT \"home_team_score\" FROM \"round_1\" WHERE \"ground\"='ghantoot racing and polo club';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"release_history\" (\n \"date\" text,\n \"label\" text,\n \"region\" text,\n \"format\" text,\n \"catalog\" text\n);\n\nQuestion: What shows for region when the date is february 2006?"
},
{
"role": "assistant",
"content": "SELECT \"region\" FROM \"release_history\" WHERE \"date\"='february 2006';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"release_history\" (\n \"date\" text,\n \"label\" text,\n \"region\" text,\n \"format\" text,\n \"catalog\" text\n);\n\nQuestion: What shows as the format for catalog 11 135?"
},
{
"role": "assistant",
"content": "SELECT \"format\" FROM \"release_history\" WHERE \"catalog\"='11 135';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"release_history\" (\n \"date\" text,\n \"label\" text,\n \"region\" text,\n \"format\" text,\n \"catalog\" text\n);\n\nQuestion: What is the release Date of the 7\" single in Catalog 87184?"
},
{
"role": "assistant",
"content": "SELECT \"date\" FROM \"release_history\" WHERE \"format\"='7\\\" single' AND \"catalog\"='87184';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"release_history\" (\n \"date\" text,\n \"label\" text,\n \"region\" text,\n \"format\" text,\n \"catalog\" text\n);\n\nQuestion: In what Region is Catalog number 885 380-1?"
},
{
"role": "assistant",
"content": "SELECT \"region\" FROM \"release_history\" WHERE \"catalog\"='885 380-1';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"release_history\" (\n \"date\" text,\n \"label\" text,\n \"region\" text,\n \"format\" text,\n \"catalog\" text\n);\n\nQuestion: What Label is dated April 1986 in 7\" single Format in France?"
},
{
"role": "assistant",
"content": "SELECT \"label\" FROM \"release_history\" WHERE \"region\"='france' AND \"format\"='7\\\" single' AND \"date\"='april 1986';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"comparison\" (\n \"model\" text,\n \"release_date\" real,\n \"price\" text,\n \"midi_inputs_outputs\" text,\n \"sampling_rate\" text,\n \"sampling_memory_upgrade_able\" text,\n \"sampling_time\" text,\n \"storage_method\" text,\n \"pad_banks\" real\n);\n\nQuestion: Which Sampling Memory/Upgrade-able has a rate of 16-bit 44.1khz?"
},
{
"role": "assistant",
"content": "SELECT \"sampling_memory_upgrade_able\" FROM \"comparison\" WHERE \"sampling_rate\"='16-bit 44.1khz';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"comparison\" (\n \"model\" text,\n \"release_date\" real,\n \"price\" text,\n \"midi_inputs_outputs\" text,\n \"sampling_rate\" text,\n \"sampling_memory_upgrade_able\" text,\n \"sampling_time\" text,\n \"storage_method\" text,\n \"pad_banks\" real\n);\n\nQuestion: Around what time frame release a Sampling Rate of 12-bit 40khz?"
},
{
"role": "assistant",
"content": "SELECT SUM(\"release_date\") FROM \"comparison\" WHERE \"sampling_rate\"='12-bit 40khz';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"comparison\" (\n \"model\" text,\n \"release_date\" real,\n \"price\" text,\n \"midi_inputs_outputs\" text,\n \"sampling_rate\" text,\n \"sampling_memory_upgrade_able\" text,\n \"sampling_time\" text,\n \"storage_method\" text,\n \"pad_banks\" real\n);\n\nQuestion: How much is a product with a Sampling Rate of 12-bit 40khz?"
},
{
"role": "assistant",
"content": "SELECT \"price\" FROM \"comparison\" WHERE \"sampling_rate\"='12-bit 40khz';"
}
] |
[
{
"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 team scored on december 19"
},
{
"role": "assistant",
"content": "SELECT \"record\" FROM \"game_log\" WHERE \"date\"='december 19';"
}
] |
[
{
"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 team scored 5\u20135\u20131\u20131?"
},
{
"role": "assistant",
"content": "SELECT \"home\" FROM \"game_log\" WHERE \"record\"='5\u20135\u20131\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 \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"record\" text\n);\n\nQuestion: what team scored on november 7"
},
{
"role": "assistant",
"content": "SELECT \"record\" FROM \"game_log\" WHERE \"date\"='november 7';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"leaders\" (\n \"rank\" real,\n \"player\" text,\n \"country\" text,\n \"earnings\" real,\n \"wins\" real\n);\n\nQuestion: Which player has rank 1?"
},
{
"role": "assistant",
"content": "SELECT \"player\" FROM \"leaders\" WHERE \"rank\"=1;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"leaders\" (\n \"rank\" real,\n \"player\" text,\n \"country\" text,\n \"earnings\" real,\n \"wins\" real\n);\n\nQuestion: What's the mean number of wins with a rank that's more than 5?"
},
{
"role": "assistant",
"content": "SELECT AVG(\"wins\") FROM \"leaders\" WHERE \"rank\">5;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"leaders\" (\n \"rank\" real,\n \"player\" text,\n \"country\" text,\n \"earnings\" real,\n \"wins\" real\n);\n\nQuestion: What amount of earnings does Tiger Woods have?"
},
{
"role": "assistant",
"content": "SELECT \"earnings\" FROM \"leaders\" WHERE \"player\"='tiger woods';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"position\" real,\n \"club_city_town\" text,\n \"games_played\" real,\n \"w_l_d\" text,\n \"goals_for_against\" text,\n \"points\" real\n);\n\nQuestion: What is the position number of the club with more than 24 points and a w-l-d of 8-5-3?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"position\") FROM \"regular_season\" WHERE \"points\">24 AND \"w_l_d\"='8-5-3';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"position\" real,\n \"club_city_town\" text,\n \"games_played\" real,\n \"w_l_d\" text,\n \"goals_for_against\" text,\n \"points\" real\n);\n\nQuestion: What is the goals for/against of the club with 17 points?"
},
{
"role": "assistant",
"content": "SELECT \"goals_for_against\" FROM \"regular_season\" WHERE \"points\"=17;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"position\" real,\n \"club_city_town\" text,\n \"games_played\" real,\n \"w_l_d\" text,\n \"goals_for_against\" text,\n \"points\" real\n);\n\nQuestion: What is the highest number of games played of the club with a position number less than 4 and a 29-24 goals for/against?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"games_played\") FROM \"regular_season\" WHERE \"position\"<4 AND \"goals_for_against\"='29-24';"
}
] |
[
{
"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 \"attendance\" real\n);\n\nQuestion: Which date's attendance was more than 35,540?"
},
{
"role": "assistant",
"content": "SELECT \"date\" FROM \"schedule\" WHERE \"attendance\">'35,540';"
}
] |
[
{
"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 \"attendance\" real\n);\n\nQuestion: What is the smallest attendance number for December 3, 1944?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"attendance\") FROM \"schedule\" WHERE \"date\"='december 3, 1944';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"inde_fran_aise\" (\n \"colony\" text,\n \"liberation\" text,\n \"de_facto_transfer\" text,\n \"treaty_of_cession\" text,\n \"de_jure_transfer\" text,\n \"merger\" text\n);\n\nQuestion: When was the Treaty of Cession for Karikal Colony?"
},
{
"role": "assistant",
"content": "SELECT \"treaty_of_cession\" FROM \"inde_fran_aise\" WHERE \"colony\"='karikal';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"1972\" (\n \"date\" text,\n \"city\" text,\n \"opponent\" text,\n \"results\" text,\n \"type_of_game\" text\n);\n\nQuestion: what day was the game in argentina"
},
{
"role": "assistant",
"content": "SELECT \"date\" FROM \"1972\" WHERE \"opponent\"='argentina';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"1972\" (\n \"date\" text,\n \"city\" text,\n \"opponent\" text,\n \"results\" text,\n \"type_of_game\" text\n);\n\nQuestion: what city scored 0:0"
},
{
"role": "assistant",
"content": "SELECT \"city\" FROM \"1972\" WHERE \"results\"='0:0';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"1972\" (\n \"date\" text,\n \"city\" text,\n \"opponent\" text,\n \"results\" text,\n \"type_of_game\" text\n);\n\nQuestion: what game was played on june 14"
},
{
"role": "assistant",
"content": "SELECT \"type_of_game\" FROM \"1972\" WHERE \"date\"='june 14';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"playoffs\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"series\" text\n);\n\nQuestion: What score has april 28 as the date?"
},
{
"role": "assistant",
"content": "SELECT \"score\" FROM \"playoffs\" WHERE \"date\"='april 28';"
}
] |
[
{
"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 \"leading_scorer\" text,\n \"record\" text\n);\n\nQuestion: What score has tim duncan (27) as the leading scorer?"
},
{
"role": "assistant",
"content": "SELECT \"score\" FROM \"december\" WHERE \"leading_scorer\"='tim duncan (27)';"
}
] |
[
{
"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 \"leading_scorer\" text,\n \"record\" text\n);\n\nQuestion: What visitor has tim duncan (16) as the leading scorer?"
},
{
"role": "assistant",
"content": "SELECT \"visitor\" FROM \"december\" WHERE \"leading_scorer\"='tim duncan (16)';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"jacksonville_jaguars_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 were Will Rackley's total rounds?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"round\") FROM \"jacksonville_jaguars_draft_history\" WHERE \"name\"='will rackley';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"jacksonville_jaguars_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 cornerback has the lowest overall and a pick number smaller than 16?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"overall\") FROM \"jacksonville_jaguars_draft_history\" WHERE \"position\"='cornerback' AND \"pick_num\"<16;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"jacksonville_jaguars_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 cornerback has the highest round?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"round\") FROM \"jacksonville_jaguars_draft_history\" WHERE \"position\"='cornerback';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"singles_14_9_5\" (\n \"outcome\" text,\n \"date\" text,\n \"championship\" text,\n \"surface\" text,\n \"opponent_in_the_final\" text,\n \"score_in_the_final\" text\n);\n\nQuestion: What was the outcome on 25 october 2004?"
},
{
"role": "assistant",
"content": "SELECT \"outcome\" FROM \"singles_14_9_5\" WHERE \"date\"='25 october 2004';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"singles_14_9_5\" (\n \"outcome\" text,\n \"date\" text,\n \"championship\" text,\n \"surface\" text,\n \"opponent_in_the_final\" text,\n \"score_in_the_final\" text\n);\n\nQuestion: Which opponent was a runner-up on 2 march 1998?"
},
{
"role": "assistant",
"content": "SELECT \"opponent_in_the_final\" FROM \"singles_14_9_5\" WHERE \"outcome\"='runner-up' AND \"date\"='2 march 1998';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"singles_14_9_5\" (\n \"outcome\" text,\n \"date\" text,\n \"championship\" text,\n \"surface\" text,\n \"opponent_in_the_final\" text,\n \"score_in_the_final\" text\n);\n\nQuestion: Which championship had an oppenent of mario an\u010di\u0107 in the final?"
},
{
"role": "assistant",
"content": "SELECT \"championship\" FROM \"singles_14_9_5\" WHERE \"opponent_in_the_final\"='mario an\u010di\u0107';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"top_up_additional_member_system_results\" (\n \"party\" text,\n \"votes\" real,\n \"share\" text,\n \"change\" text,\n \"seats\" text\n);\n\nQuestion: Name the change with share of 2.9%"
},
{
"role": "assistant",
"content": "SELECT \"change\" FROM \"top_up_additional_member_system_results\" WHERE \"share\"='2.9%';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"top_up_additional_member_system_results\" (\n \"party\" text,\n \"votes\" real,\n \"share\" text,\n \"change\" text,\n \"seats\" text\n);\n\nQuestion: Name the change for english democrats"
},
{
"role": "assistant",
"content": "SELECT \"change\" FROM \"top_up_additional_member_system_results\" WHERE \"party\"='english democrats';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"top_up_additional_member_system_results\" (\n \"party\" text,\n \"votes\" real,\n \"share\" text,\n \"change\" text,\n \"seats\" text\n);\n\nQuestion: Name the average votes for one london"
},
{
"role": "assistant",
"content": "SELECT AVG(\"votes\") FROM \"top_up_additional_member_system_results\" WHERE \"party\"='one london';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"leaders\" (\n \"rank\" real,\n \"player\" text,\n \"country\" text,\n \"earnings\" real,\n \"events\" real,\n \"wins\" real\n);\n\nQuestion: Which Country has a Rank of 5?"
},
{
"role": "assistant",
"content": "SELECT \"country\" FROM \"leaders\" WHERE \"rank\"=5;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"leaders\" (\n \"rank\" real,\n \"player\" text,\n \"country\" text,\n \"earnings\" real,\n \"events\" real,\n \"wins\" real\n);\n\nQuestion: Which Earnings ($) is the lowest one that has a Rank of 1, and Events smaller than 22?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"earnings\") FROM \"leaders\" WHERE \"rank\"=1 AND \"events\"<22;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"leaders\" (\n \"rank\" real,\n \"player\" text,\n \"country\" text,\n \"earnings\" real,\n \"events\" real,\n \"wins\" real\n);\n\nQuestion: How many earnings have Wins larger than 3?"
},
{
"role": "assistant",
"content": "SELECT SUM(\"earnings\") FROM \"leaders\" WHERE \"wins\">3;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"leaders\" (\n \"rank\" real,\n \"player\" text,\n \"country\" text,\n \"earnings\" real,\n \"events\" real,\n \"wins\" real\n);\n\nQuestion: Which Player has 4 Wins?"
},
{
"role": "assistant",
"content": "SELECT \"player\" FROM \"leaders\" WHERE \"wins\"=4;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"results\" (\n \"year\" real,\n \"class\" text,\n \"team_name\" text,\n \"bike\" text,\n \"riders\" text,\n \"races\" text,\n \"wins\" real,\n \"podiums\" real,\n \"poles\" real,\n \"f_laps\" real,\n \"points\" text,\n \"pos\" text\n);\n\nQuestion: How many Poles have a Bike of honda rc212v, and Podiums smaller than 0?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"poles\") FROM \"results\" WHERE \"bike\"='honda rc212v' AND \"podiums\"<0;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"results\" (\n \"year\" real,\n \"class\" text,\n \"team_name\" text,\n \"bike\" text,\n \"riders\" text,\n \"races\" text,\n \"wins\" real,\n \"podiums\" real,\n \"poles\" real,\n \"f_laps\" real,\n \"points\" text,\n \"pos\" text\n);\n\nQuestion: Which Wins is the highest one that has a Pos of 2nd, and Poles larger than 2?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"wins\") FROM \"results\" WHERE \"pos\"='2nd' AND \"poles\">2;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"melodifestivalen_1997\" (\n \"draw\" real,\n \"artist\" text,\n \"song\" text,\n \"points\" real,\n \"place\" text\n);\n\nQuestion: What is the average of points for 8th place with draw more than 8?"
},
{
"role": "assistant",
"content": "SELECT AVG(\"points\") FROM \"melodifestivalen_1997\" WHERE \"place\"='8th' AND \"draw\">8;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"game\" real,\n \"october\" real,\n \"opponent\" text,\n \"score\" text,\n \"record\" text,\n \"points\" real\n);\n\nQuestion: Which Points have a Game smaller than 8, and a Record of 1\u20130\u20130?"
},
{
"role": "assistant",
"content": "SELECT SUM(\"points\") FROM \"regular_season\" WHERE \"game\"<8 AND \"record\"='1\u20130\u20130';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"game\" real,\n \"october\" real,\n \"opponent\" text,\n \"score\" text,\n \"record\" text,\n \"points\" real\n);\n\nQuestion: Which Game has a Record of 5\u20133\u20131, and an October smaller than 29?"
},
{
"role": "assistant",
"content": "SELECT SUM(\"game\") FROM \"regular_season\" WHERE \"record\"='5\u20133\u20131' AND \"october\"<29;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"game\" real,\n \"october\" real,\n \"opponent\" text,\n \"score\" text,\n \"record\" text,\n \"points\" real\n);\n\nQuestion: Which Game has a Score of 3\u20134?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"game\") FROM \"regular_season\" WHERE \"score\"='3\u20134';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"game\" real,\n \"october\" real,\n \"opponent\" text,\n \"score\" text,\n \"record\" text,\n \"points\" real\n);\n\nQuestion: Which Game has a Record of 4\u20132\u20131, and Points larger than 9?"
},
{
"role": "assistant",
"content": "SELECT SUM(\"game\") FROM \"regular_season\" WHERE \"record\"='4\u20132\u20131' AND \"points\">9;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"draft_picks\" (\n \"round\" real,\n \"player\" text,\n \"position\" text,\n \"nationality\" text,\n \"college_junior_club_team_league\" text\n);\n\nQuestion: Which Nationality has a Position of defense, and a Player of nikita korovkin?"
},
{
"role": "assistant",
"content": "SELECT \"nationality\" FROM \"draft_picks\" WHERE \"position\"='defense' AND \"player\"='nikita korovkin';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"draft_picks\" (\n \"round\" real,\n \"player\" text,\n \"position\" text,\n \"nationality\" text,\n \"college_junior_club_team_league\" text\n);\n\nQuestion: Which Nationality has a Position of left wing?"
},
{
"role": "assistant",
"content": "SELECT \"nationality\" FROM \"draft_picks\" WHERE \"position\"='left wing';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"draft_picks\" (\n \"round\" real,\n \"player\" text,\n \"position\" text,\n \"nationality\" text,\n \"college_junior_club_team_league\" text\n);\n\nQuestion: Which Player has a Position of forward?"
},
{
"role": "assistant",
"content": "SELECT \"player\" FROM \"draft_picks\" WHERE \"position\"='forward';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"coaches_poll\" (\n \"week_1_sept_2\" text,\n \"week_2_sept_7\" text,\n \"week_3_sept_14\" text,\n \"week_5_sept_28\" text,\n \"week_6_oct_5\" text,\n \"week_7_oct_12\" text,\n \"week_10_nov_2\" text,\n \"week_13_nov_23\" text,\n \"week_14_nov_30\" text,\n \"week_15_dec_7\" text,\n \"week_16_final_jan_9\" text\n);\n\nQuestion: Which Week 3 Sept 14 has a Week 6 Oct 5 of kansas (4-1)?"
},
{
"role": "assistant",
"content": "SELECT \"week_3_sept_14\" FROM \"coaches_poll\" WHERE \"week_6_oct_5\"='kansas (4-1)';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"coaches_poll\" (\n \"week_1_sept_2\" text,\n \"week_2_sept_7\" text,\n \"week_3_sept_14\" text,\n \"week_5_sept_28\" text,\n \"week_6_oct_5\" text,\n \"week_7_oct_12\" text,\n \"week_10_nov_2\" text,\n \"week_13_nov_23\" text,\n \"week_14_nov_30\" text,\n \"week_15_dec_7\" text,\n \"week_16_final_jan_9\" text\n);\n\nQuestion: Which Week 2 Sept 7 has a Week 6 Oct 5 of wake forest (3-1)?"
},
{
"role": "assistant",
"content": "SELECT \"week_2_sept_7\" FROM \"coaches_poll\" WHERE \"week_6_oct_5\"='wake forest (3-1)';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"coaches_poll\" (\n \"week_1_sept_2\" text,\n \"week_2_sept_7\" text,\n \"week_3_sept_14\" text,\n \"week_5_sept_28\" text,\n \"week_6_oct_5\" text,\n \"week_7_oct_12\" text,\n \"week_10_nov_2\" text,\n \"week_13_nov_23\" text,\n \"week_14_nov_30\" text,\n \"week_15_dec_7\" text,\n \"week_16_final_jan_9\" text\n);\n\nQuestion: Which Week 1 Sept 2 has a Week 3 Sept 14 of south florida (3-0)?"
},
{
"role": "assistant",
"content": "SELECT \"week_1_sept_2\" FROM \"coaches_poll\" WHERE \"week_3_sept_14\"='south florida (3-0)';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"coaches_poll\" (\n \"week_1_sept_2\" text,\n \"week_2_sept_7\" text,\n \"week_3_sept_14\" text,\n \"week_5_sept_28\" text,\n \"week_6_oct_5\" text,\n \"week_7_oct_12\" text,\n \"week_10_nov_2\" text,\n \"week_13_nov_23\" text,\n \"week_14_nov_30\" text,\n \"week_15_dec_7\" text,\n \"week_16_final_jan_9\" text\n);\n\nQuestion: Which Week 7 Oct 12 has a Week 6 Oct 5 of boise state (4-0)?"
},
{
"role": "assistant",
"content": "SELECT \"week_7_oct_12\" FROM \"coaches_poll\" WHERE \"week_6_oct_5\"='boise state (4-0)';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"coaches_poll\" (\n \"week_1_sept_2\" text,\n \"week_2_sept_7\" text,\n \"week_3_sept_14\" text,\n \"week_5_sept_28\" text,\n \"week_6_oct_5\" text,\n \"week_7_oct_12\" text,\n \"week_10_nov_2\" text,\n \"week_13_nov_23\" text,\n \"week_14_nov_30\" text,\n \"week_15_dec_7\" text,\n \"week_16_final_jan_9\" text\n);\n\nQuestion: Which Week 2 Sept 7 has a Week 7 Oct 12 of ball state (7-0)?"
},
{
"role": "assistant",
"content": "SELECT \"week_2_sept_7\" FROM \"coaches_poll\" WHERE \"week_7_oct_12\"='ball state (7-0)';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"coaches_poll\" (\n \"week_1_sept_2\" text,\n \"week_2_sept_7\" text,\n \"week_3_sept_14\" text,\n \"week_5_sept_28\" text,\n \"week_6_oct_5\" text,\n \"week_7_oct_12\" text,\n \"week_10_nov_2\" text,\n \"week_13_nov_23\" text,\n \"week_14_nov_30\" text,\n \"week_15_dec_7\" text,\n \"week_16_final_jan_9\" text\n);\n\nQuestion: Which Week 6 Oct 5 has a Week 14 Nov 30 of texas (11-1)?"
},
{
"role": "assistant",
"content": "SELECT \"week_6_oct_5\" FROM \"coaches_poll\" WHERE \"week_14_nov_30\"='texas (11-1)';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"nfl_draft\" (\n \"round\" real,\n \"pick\" real,\n \"player\" text,\n \"position\" text,\n \"school_club_team\" text\n);\n\nQuestion: What is the highest round of Tommy Allman, who had a pick less than 40?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"round\") FROM \"nfl_draft\" WHERE \"player\"='tommy allman' AND \"pick\"<40;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"nfl_draft\" (\n \"round\" real,\n \"pick\" real,\n \"player\" text,\n \"position\" text,\n \"school_club_team\" text\n);\n\nQuestion: Who was the back player with a pick less than 183 from the round greater than 12?"
},
{
"role": "assistant",
"content": "SELECT \"player\" FROM \"nfl_draft\" WHERE \"pick\"<183 AND \"position\"='back' AND \"round\">12;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"nfl_draft\" (\n \"round\" real,\n \"pick\" real,\n \"player\" text,\n \"position\" text,\n \"school_club_team\" text\n);\n\nQuestion: What is the total number of rounds of the end player with a pick number greater than 303?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"round\") FROM \"nfl_draft\" WHERE \"pick\">303 AND \"position\"='end';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"nfl_draft\" (\n \"round\" real,\n \"pick\" real,\n \"player\" text,\n \"position\" text,\n \"school_club_team\" text\n);\n\nQuestion: What is the highest pick of the back player from round 28?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"pick\") FROM \"nfl_draft\" WHERE \"position\"='back' AND \"round\"=28;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"nfl_draft\" (\n \"round\" real,\n \"pick\" real,\n \"player\" text,\n \"position\" text,\n \"school_club_team\" text\n);\n\nQuestion: What is position of the player with a pick number greater than 315 and a round of 30?"
},
{
"role": "assistant",
"content": "SELECT \"position\" FROM \"nfl_draft\" WHERE \"pick\">315 AND \"round\"=30;"
}
] |
[
{
"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 \"attendance\" real\n);\n\nQuestion: On what Week was the Result W 17-14?"
},
{
"role": "assistant",
"content": "SELECT AVG(\"week\") FROM \"schedule\" WHERE \"result\"='w 17-14';"
}
] |
[
{
"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 \"attendance\" real\n);\n\nQuestion: What was the Result after the Week 4 on November 3, 1968?"
},
{
"role": "assistant",
"content": "SELECT \"result\" FROM \"schedule\" WHERE \"week\">4 AND \"date\"='november 3, 1968';"
}
] |
[
{
"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 \"venue\" text,\n \"attendance\" real\n);\n\nQuestion: What is the attendance in week 4?"
},
{
"role": "assistant",
"content": "SELECT AVG(\"attendance\") FROM \"schedule\" WHERE \"week\"=4;"
}
] |
[
{
"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 \"record\" text\n);\n\nQuestion: What was the date of the game with a record of 17\u201325?"
},
{
"role": "assistant",
"content": "SELECT \"date\" FROM \"game_log\" WHERE \"record\"='17\u201325';"
}
] |
[
{
"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 \"record\" text\n);\n\nQuestion: Who was the opponent at the game with a score of 6\u20135 (10)?"
},
{
"role": "assistant",
"content": "SELECT \"opponent\" FROM \"game_log\" WHERE \"score\"='6\u20135 (10)';"
}
] |
[
{
"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\" real,\n \"time\" text,\n \"location\" text\n);\n\nQuestion: What was the result of the bout that led to a 4-4 record?"
},
{
"role": "assistant",
"content": "SELECT \"res\" FROM \"mixed_martial_arts_record\" WHERE \"record\"='4-4';"
}
] |
[
{
"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\" real,\n \"time\" text,\n \"location\" text\n);\n\nQuestion: Which location held the bout that led to a 4-3 record?"
},
{
"role": "assistant",
"content": "SELECT \"location\" FROM \"mixed_martial_arts_record\" WHERE \"record\"='4-3';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"dvd_releases\" (\n \"volume\" text,\n \"discs\" real,\n \"episodes\" real,\n \"region_1_release\" text,\n \"region_2_release\" text,\n \"region_4_release\" text\n);\n\nQuestion: What discs has a region 1 release date of January 22, 2008?"
},
{
"role": "assistant",
"content": "SELECT \"discs\" FROM \"dvd_releases\" WHERE \"region_1_release\"='january 22, 2008';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"first_quarter\" (\n \"rank\" real,\n \"name\" text,\n \"headquarters\" text,\n \"industry\" text,\n \"market_value_usd_million\" real\n);\n\nQuestion: What is the lowest rank of Citigroup?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"rank\") FROM \"first_quarter\" WHERE \"name\"='citigroup';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"first_quarter\" (\n \"rank\" real,\n \"name\" text,\n \"headquarters\" text,\n \"industry\" text,\n \"market_value_usd_million\" real\n);\n\nQuestion: What is the market value of the automotive industry?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"market_value_usd_million\") FROM \"first_quarter\" WHERE \"industry\"='automotive';"
}
] |
[
{
"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 \"attendance\" real\n);\n\nQuestion: Name the attendance with result of t 14-14"
},
{
"role": "assistant",
"content": "SELECT \"attendance\" FROM \"schedule\" WHERE \"result\"='t 14-14';"
}
] |
[
{
"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 \"attendance\" real\n);\n\nQuestion: Name the total number of attendance for october 20, 1946 with week less than 4"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"attendance\") FROM \"schedule\" WHERE \"date\"='october 20, 1946' AND \"week\"<4;"
}
] |
[
{
"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 \"attendance\" real\n);\n\nQuestion: Name the most attendance for november 17, 1946 and week more than 8"
},
{
"role": "assistant",
"content": "SELECT MAX(\"attendance\") FROM \"schedule\" WHERE \"date\"='november 17, 1946' AND \"week\">8;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"non_kickers\" (\n \"rank\" text,\n \"player\" text,\n \"position\" text,\n \"career\" text,\n \"points\" real\n);\n\nQuestion: What is the sum of the points for the player who was a rank of 61t?"
},
{
"role": "assistant",
"content": "SELECT SUM(\"points\") FROM \"non_kickers\" WHERE \"rank\"='61t';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"non_kickers\" (\n \"rank\" text,\n \"player\" text,\n \"position\" text,\n \"career\" text,\n \"points\" real\n);\n\nQuestion: Who is the player who had more than 1,052 points?"
},
{
"role": "assistant",
"content": "SELECT \"player\" FROM \"non_kickers\" WHERE \"points\">'1,052';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"non_kickers\" (\n \"rank\" text,\n \"player\" text,\n \"position\" text,\n \"career\" text,\n \"points\" real\n);\n\nQuestion: What are the highest points that Emmitt Smith had?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"points\") FROM \"non_kickers\" WHERE \"player\"='emmitt smith';"
}
] |
[
{
"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 \"record\" text,\n \"game_site\" text,\n \"attendance\" text\n);\n\nQuestion: Record of 6\u20138 had what attendance?"
},
{
"role": "assistant",
"content": "SELECT \"attendance\" FROM \"schedule\" WHERE \"record\"='6\u20138';"
}
] |
[
{
"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 \"record\" text,\n \"game_site\" text,\n \"attendance\" text\n);\n\nQuestion: Result of l 17\u201320 had what attendance?"
},
{
"role": "assistant",
"content": "SELECT \"attendance\" FROM \"schedule\" WHERE \"result\"='l 17\u201320';"
}
] |
[
{
"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 \"record\" text,\n \"game_site\" text,\n \"attendance\" text\n);\n\nQuestion: Game Site of hoosier dome, and a Result of l 7\u201331 involved what attendance?"
},
{
"role": "assistant",
"content": "SELECT \"attendance\" FROM \"schedule\" WHERE \"game_site\"='hoosier dome' AND \"result\"='l 7\u201331';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"winners\" (\n \"year\" real,\n \"champion\" text,\n \"country\" text,\n \"venue\" text,\n \"location\" text,\n \"score\" text,\n \"to_par\" text,\n \"purse\" real,\n \"winner_s_share\" real\n);\n\nQuestion: Which Year is the highest one that has a Venue of blackwolf run, composite course, and a Score of 281?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"year\") FROM \"winners\" WHERE \"venue\"='blackwolf run, composite course' AND \"score\"='281';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"winners\" (\n \"year\" real,\n \"champion\" text,\n \"country\" text,\n \"venue\" text,\n \"location\" text,\n \"score\" text,\n \"to_par\" text,\n \"purse\" real,\n \"winner_s_share\" real\n);\n\nQuestion: Which Champion has a Venue of old waverly golf club?"
},
{
"role": "assistant",
"content": "SELECT \"champion\" FROM \"winners\" WHERE \"venue\"='old waverly golf club';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"top_25_lists\" (\n \"year\" real,\n \"performance\" text,\n \"world_ranking\" real,\n \"venue\" text,\n \"date\" text\n);\n\nQuestion: How many world rankings are after Aug 5, 1980 ?"
},
{
"role": "assistant",
"content": "SELECT SUM(\"world_ranking\") FROM \"top_25_lists\" WHERE \"date\"='aug 5' AND \"year\">1980;"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"top_25_lists\" (\n \"year\" real,\n \"performance\" text,\n \"world_ranking\" real,\n \"venue\" text,\n \"date\" text\n);\n\nQuestion: On which date is there a performance of more than 8.22.72?"
},
{
"role": "assistant",
"content": "SELECT \"date\" FROM \"top_25_lists\" WHERE \"performance\"='8.22.72';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"top_25_lists\" (\n \"year\" real,\n \"performance\" text,\n \"world_ranking\" real,\n \"venue\" text,\n \"date\" text\n);\n\nQuestion: The venue of Rome has which date?"
},
{
"role": "assistant",
"content": "SELECT \"date\" FROM \"top_25_lists\" WHERE \"venue\"='rome';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"round_of_sixteen\" (\n \"team_1\" text,\n \"agg\" text,\n \"team_2\" text,\n \"1st_leg\" text,\n \"2nd_leg\" text\n);\n\nQuestion: What was the 1st leg of the match that had an aggregate of 4-3?"
},
{
"role": "assistant",
"content": "SELECT \"1st_leg\" FROM \"round_of_sixteen\" WHERE \"agg\"='4-3';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"round_of_sixteen\" (\n \"team_1\" text,\n \"agg\" text,\n \"team_2\" text,\n \"1st_leg\" text,\n \"2nd_leg\" text\n);\n\nQuestion: What was the 2nd leg fo the match that had a 1st leg of 1-3 and aggregate of 1-6?"
},
{
"role": "assistant",
"content": "SELECT \"2nd_leg\" FROM \"round_of_sixteen\" WHERE \"1st_leg\"='1-3' AND \"agg\"='1-6';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"performance_by_club\" (\n \"club\" text,\n \"wins\" text,\n \"last_win\" text,\n \"runners_up\" text,\n \"last_final_lost\" text\n);\n\nQuestion: When was the last final lost of the club with 7 wins?"
},
{
"role": "assistant",
"content": "SELECT \"last_final_lost\" FROM \"performance_by_club\" WHERE \"wins\"='7';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"performance_by_club\" (\n \"club\" text,\n \"wins\" text,\n \"last_win\" text,\n \"runners_up\" text,\n \"last_final_lost\" text\n);\n\nQuestion: How many runners-up did the club with the last final lost in 1985 have?"
},
{
"role": "assistant",
"content": "SELECT \"runners_up\" FROM \"performance_by_club\" WHERE \"last_final_lost\"='1985';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"performance_by_club\" (\n \"club\" text,\n \"wins\" text,\n \"last_win\" text,\n \"runners_up\" text,\n \"last_final_lost\" text\n);\n\nQuestion: When was the last final lost of the club with a last win in 1959?"
},
{
"role": "assistant",
"content": "SELECT \"last_final_lost\" FROM \"performance_by_club\" WHERE \"last_win\"='1959';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"performance_by_club\" (\n \"club\" text,\n \"wins\" text,\n \"last_win\" text,\n \"runners_up\" text,\n \"last_final_lost\" text\n);\n\nQuestion: When was the last win of Celtic?"
},
{
"role": "assistant",
"content": "SELECT \"last_win\" FROM \"performance_by_club\" WHERE \"club\"='celtic';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"performance_by_club\" (\n \"club\" text,\n \"wins\" text,\n \"last_win\" text,\n \"runners_up\" text,\n \"last_final_lost\" text\n);\n\nQuestion: Which club had 13 runners-up?"
},
{
"role": "assistant",
"content": "SELECT \"club\" FROM \"performance_by_club\" WHERE \"runners_up\"='13';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"decision\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: Who is the visitor in Philadelphia on March 6?"
},
{
"role": "assistant",
"content": "SELECT \"visitor\" FROM \"regular_season\" WHERE \"home\"='philadelphia' AND \"date\"='march 6';"
}
] |
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"round_16\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"ground\" text,\n \"crowd\" real,\n \"date\" text,\n \"report\" text\n);\n\nQuestion: what date were they playing in hawthorn"
},
{
"role": "assistant",
"content": "SELECT \"date\" FROM \"round_16\" WHERE \"away_team\"='hawthorn';"
}
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.