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 \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: Who was the winner when the score was 281 (-6)?" }, { "role": "assistant", "content": "SELECT \"winner\" FROM \"tournament_results\" WHERE \"score\"='281 (-6)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: How many scores were at the Northville Long Island Classic?" }, { "role": "assistant", "content": "SELECT COUNT(\"score\") FROM \"tournament_results\" WHERE \"tournament\"='Northville Long Island Classic';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: what's the\u00a0tournament\u00a0where\u00a0winner\u00a0is raymond floyd (1)" }, { "role": "assistant", "content": "SELECT \"tournament\" FROM \"tournament_results\" WHERE \"winner\"='Raymond Floyd (1)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: what is the total number of\u00a0purse( $ )\u00a0where\u00a0winner\u00a0is jimmy powell (2)" }, { "role": "assistant", "content": "SELECT COUNT(\"purse\") FROM \"tournament_results\" WHERE \"winner\"='Jimmy Powell (2)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: what's the\u00a0date\u00a0where\u00a0location\u00a0is illinois" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"tournament_results\" WHERE \"location\"='Illinois';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: what is the minimum\u00a0purse( $ )\u00a0where\u00a0tournament\u00a0is ko olina senior invitational" }, { "role": "assistant", "content": "SELECT MIN(\"purse\") FROM \"tournament_results\" WHERE \"tournament\"='Ko Olina Senior Invitational';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: what's the\u00a0location\u00a0where\u00a0tournament\u00a0is raley's senior gold rush" }, { "role": "assistant", "content": "SELECT \"location\" FROM \"tournament_results\" WHERE \"tournament\"='Raley''s Senior Gold Rush';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: what is the maximum\u00a01st prize( $ )\u00a0where\u00a0score\u00a0is 193 (-17)" }, { "role": "assistant", "content": "SELECT MAX(\"1st_prize\") FROM \"tournament_results\" WHERE \"score\"='193 (-17)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" text\n);\n\nQuestion: How much was the prize money for the 275000 purse?" }, { "role": "assistant", "content": "SELECT \"1st_prize\" FROM \"tournament_results\" WHERE \"purse\"=275000;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" text\n);\n\nQuestion: What is the prize money for Virginia?" }, { "role": "assistant", "content": "SELECT \"1st_prize\" FROM \"tournament_results\" WHERE \"location\"='Virginia';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: How many tournaments ended with a score of 204 (-12)?" }, { "role": "assistant", "content": "SELECT COUNT(\"tournament\") FROM \"tournament_results\" WHERE \"score\"='204 (-12)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: What's the winner of the Painewebber Invitational tournament?" }, { "role": "assistant", "content": "SELECT \"winner\" FROM \"tournament_results\" WHERE \"tournament\"='PaineWebber Invitational';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: Where was the GTE Suncoast Classic tournament held?" }, { "role": "assistant", "content": "SELECT \"location\" FROM \"tournament_results\" WHERE \"tournament\"='GTE Suncoast Classic';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: What was the minimal amount ($) of the 1st prize in the tournaments in New Mexico?" }, { "role": "assistant", "content": "SELECT MIN(\"1st_prize\") FROM \"tournament_results\" WHERE \"location\"='New Mexico';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: What are all the dates with a score of 203 (-13)?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"tournament_results\" WHERE \"score\"='203 (-13)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: For which tournaments was the score 135 (-7)?" }, { "role": "assistant", "content": "SELECT \"tournament\" FROM \"tournament_results\" WHERE \"score\"='135 (-7)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: Which tournaments have a first prize of $40000" }, { "role": "assistant", "content": "SELECT \"tournament\" FROM \"tournament_results\" WHERE \"1st_prize\"=40000;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: How many locations logged a score of 206 (-7)?" }, { "role": "assistant", "content": "SELECT COUNT(\"location\") FROM \"tournament_results\" WHERE \"score\"='206 (-7)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: How many tournaments recorded a score of 206 (-7)?" }, { "role": "assistant", "content": "SELECT COUNT(\"tournament\") FROM \"tournament_results\" WHERE \"score\"='206 (-7)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: Name all the tournaments that took place in Rhode Island." }, { "role": "assistant", "content": "SELECT \"tournament\" FROM \"tournament_results\" WHERE \"location\"='Rhode Island';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: What is the state that hosted a tournament with the score of 208 (-8)?" }, { "role": "assistant", "content": "SELECT \"location\" FROM \"tournament_results\" WHERE \"score\"='208 (-8)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: Where was the Fairfield Barnett classic tournament held?" }, { "role": "assistant", "content": "SELECT \"location\" FROM \"tournament_results\" WHERE \"tournament\"='Fairfield Barnett Classic';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: How many purses were there for the mar 16?" }, { "role": "assistant", "content": "SELECT COUNT(\"purse\") FROM \"tournament_results\" WHERE \"date\"='Mar 16';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_1_2007\" (\n \"series_no\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" real\n);\n\nQuestion: When did the series number 23 air?" }, { "role": "assistant", "content": "SELECT \"original_air_date\" FROM \"season_1_2007\" WHERE \"series_no\"=23;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_1_2007\" (\n \"series_no\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" real\n);\n\nQuestion: What is the production code of \"surprise, surprise\"?" }, { "role": "assistant", "content": "SELECT MAX(\"production_code\") FROM \"season_1_2007\" WHERE \"title\"='\\\"Surprise, Surprise\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_1_2007\" (\n \"series_no\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" real\n);\n\nQuestion: What was the airdate of 21 series number?" }, { "role": "assistant", "content": "SELECT \"original_air_date\" FROM \"season_1_2007\" WHERE \"series_no\"=21;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: Which located featured the first prize of 33500?" }, { "role": "assistant", "content": "SELECT \"location\" FROM \"tournament_results\" WHERE \"1st_prize\"=33500;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: Who won the Suntree Seniors Classic?" }, { "role": "assistant", "content": "SELECT \"winner\" FROM \"tournament_results\" WHERE \"tournament\"='Suntree Seniors Classic';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: How much was the prize in the tournament where the winning score was 289 (9)?" }, { "role": "assistant", "content": "SELECT \"purse\" FROM \"tournament_results\" WHERE \"score\"='289 (9)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tournament_results\" (\n \"date\" text,\n \"tournament\" text,\n \"location\" text,\n \"purse\" real,\n \"winner\" text,\n \"score\" text,\n \"1st_prize\" real\n);\n\nQuestion: When was the tournament that was won with a score of 204 (-6) played?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"tournament_results\" WHERE \"score\"='204 (-6)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11630008_5\" (\n \"series_num\" real,\n \"season_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" real\n);\n\nQuestion: Who wrote \"Stop Being all Funky\"?" }, { "role": "assistant", "content": "SELECT \"written_by\" FROM \"table1_11630008_5\" WHERE \"title\"='\\\"Stop Being All Funky\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11630008_5\" (\n \"series_num\" real,\n \"season_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" real\n);\n\nQuestion: What was the season number for the episode with the series number 61?" }, { "role": "assistant", "content": "SELECT MAX(\"season_num\") FROM \"table1_11630008_5\" WHERE \"series_num\"=61;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11630008_5\" (\n \"series_num\" real,\n \"season_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" real\n);\n\nQuestion: What was the title of the episode with the production code 311?" }, { "role": "assistant", "content": "SELECT \"title\" FROM \"table1_11630008_5\" WHERE \"production_code\"=311;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11630008_5\" (\n \"series_num\" real,\n \"season_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" real\n);\n\nQuestion: Who directed the episode written by Lamont Ferrell?" }, { "role": "assistant", "content": "SELECT \"directed_by\" FROM \"table1_11630008_5\" WHERE \"written_by\"='Lamont Ferrell';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"doubles_7\" (\n \"edition\" text,\n \"round\" text,\n \"date\" text,\n \"partnering\" text,\n \"against\" text,\n \"surface\" text,\n \"opponents\" text,\n \"w_l\" text,\n \"result\" text\n);\n\nQuestion: What date was the result 6\u20132, 4\u20136, 6\u20134?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"doubles_7\" WHERE \"result\"='6\u20132, 4\u20136, 6\u20134';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"doubles_7\" (\n \"edition\" text,\n \"round\" text,\n \"date\" text,\n \"partnering\" text,\n \"against\" text,\n \"surface\" text,\n \"opponents\" text,\n \"w_l\" text,\n \"result\" text\n);\n\nQuestion: How many matches had the result of 6\u20133, 6\u20132?" }, { "role": "assistant", "content": "SELECT COUNT(\"partnering\") FROM \"doubles_7\" WHERE \"result\"='6\u20133, 6\u20132';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11642945_1\" (\n \"total_no\" real,\n \"celebrity\" text,\n \"director\" text,\n \"original_air_date\" text,\n \"viewers\" text\n);\n\nQuestion: If the Original Air Date is 10January2008, what directors released on that date?" }, { "role": "assistant", "content": "SELECT \"director\" FROM \"table1_11642945_1\" WHERE \"original_air_date\"='10January2008';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11642945_1\" (\n \"total_no\" real,\n \"celebrity\" text,\n \"director\" text,\n \"original_air_date\" text,\n \"viewers\" text\n);\n\nQuestion: The original air date of 29November2007 has what total no.?" }, { "role": "assistant", "content": "SELECT \"total_no\" FROM \"table1_11642945_1\" WHERE \"original_air_date\"='29November2007';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11642945_1\" (\n \"total_no\" real,\n \"celebrity\" text,\n \"director\" text,\n \"original_air_date\" text,\n \"viewers\" text\n);\n\nQuestion: Margot Kidder had what director?" }, { "role": "assistant", "content": "SELECT \"director\" FROM \"table1_11642945_1\" WHERE \"celebrity\"='Margot Kidder';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11642945_1\" (\n \"total_no\" real,\n \"celebrity\" text,\n \"director\" text,\n \"original_air_date\" text,\n \"viewers\" text\n);\n\nQuestion: How many celebrities had an 18October2007 Original air Date?" }, { "role": "assistant", "content": "SELECT COUNT(\"celebrity\") FROM \"table1_11642945_1\" WHERE \"original_air_date\"='18October2007';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11642945_1\" (\n \"total_no\" real,\n \"celebrity\" text,\n \"director\" text,\n \"original_air_date\" text,\n \"viewers\" text\n);\n\nQuestion: Which viewers had Matt Gallagher as the director?" }, { "role": "assistant", "content": "SELECT \"viewers\" FROM \"table1_11642945_1\" WHERE \"director\"='Matt Gallagher';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_5_2008_09\" (\n \"series_num\" real,\n \"season_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" real\n);\n\nQuestion: What is the number of series of the title of \"your wife's a payne\"?" }, { "role": "assistant", "content": "SELECT MAX(\"series_num\") FROM \"season_5_2008_09\" WHERE \"title\"='\\\"Your Wife''s a Payne\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_5_2008_09\" (\n \"series_num\" real,\n \"season_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" real\n);\n\nQuestion: Who write \"a grand payne\"?" }, { "role": "assistant", "content": "SELECT \"written_by\" FROM \"season_5_2008_09\" WHERE \"title\"='\\\"A Grand Payne\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_5_2008_09\" (\n \"series_num\" real,\n \"season_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" real\n);\n\nQuestion: What is the number of series with a title of \"with friends like these\"?" }, { "role": "assistant", "content": "SELECT COUNT(\"series_num\") FROM \"season_5_2008_09\" WHERE \"title\"='\\\"With Friends Like These\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_5_2008_09\" (\n \"series_num\" real,\n \"season_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" real\n);\n\nQuestion: What is the number of series with production code 503?" }, { "role": "assistant", "content": "SELECT COUNT(\"series_num\") FROM \"season_5_2008_09\" WHERE \"production_code\"=503;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_5_2008_09\" (\n \"series_num\" real,\n \"season_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" real\n);\n\nQuestion: What is the title of production code 514?" }, { "role": "assistant", "content": "SELECT \"title\" FROM \"season_5_2008_09\" WHERE \"production_code\"=514;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_members\" (\n \"institution\" text,\n \"location\" text,\n \"founded\" real,\n \"type\" text,\n \"enrollment\" real,\n \"joined\" text,\n \"nickname\" text\n);\n\nQuestion: What is the location of the institution barton college" }, { "role": "assistant", "content": "SELECT \"location\" FROM \"current_members\" WHERE \"institution\"='Barton College';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_members\" (\n \"institution\" text,\n \"location\" text,\n \"founded\" real,\n \"type\" text,\n \"enrollment\" real,\n \"joined\" text,\n \"nickname\" text\n);\n\nQuestion: Which institutions joined in 1993" }, { "role": "assistant", "content": "SELECT \"institution\" FROM \"current_members\" WHERE \"joined\"='1993';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_members\" (\n \"institution\" text,\n \"location\" text,\n \"founded\" real,\n \"type\" text,\n \"enrollment\" real,\n \"joined\" text,\n \"nickname\" text\n);\n\nQuestion: what are the locations that joined in 2008" }, { "role": "assistant", "content": "SELECT \"location\" FROM \"current_members\" WHERE \"joined\"='2008';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_members\" (\n \"institution\" text,\n \"location\" text,\n \"founded\" real,\n \"type\" text,\n \"enrollment\" real,\n \"joined\" text,\n \"nickname\" text\n);\n\nQuestion: What is the minimum enrollment at barton college" }, { "role": "assistant", "content": "SELECT MIN(\"enrollment\") FROM \"current_members\" WHERE \"institution\"='Barton College';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_members\" (\n \"institution\" text,\n \"location\" text,\n \"founded\" real,\n \"type\" text,\n \"enrollment\" real,\n \"joined\" text,\n \"nickname\" text\n);\n\nQuestion: When was erskine college founded" }, { "role": "assistant", "content": "SELECT \"founded\" FROM \"current_members\" WHERE \"institution\"='Erskine College';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_and_capital_gains_tax_rates_for_\" (\n \"marginal_ordinary_income_tax_rate\" text,\n \"single\" text,\n \"married_filing_jointly_or_qualified_widow_er\" text,\n \"married_filing_separately\" text,\n \"head_of_household\" text\n);\n\nQuestion: What is ithe range for married filing separately where head of household is $117,451\u2013$190,200?" }, { "role": "assistant", "content": "SELECT \"married_filing_separately\" FROM \"regular_and_capital_gains_tax_rates_for_\" WHERE \"head_of_household\"='$117,451\u2013$190,200';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_and_capital_gains_tax_rates_for_\" (\n \"marginal_ordinary_income_tax_rate\" text,\n \"single\" text,\n \"married_filing_jointly_or_qualified_widow_er\" text,\n \"married_filing_separately\" text,\n \"head_of_household\" text\n);\n\nQuestion: What is the amount of marginal ordinary income tax rate for single in which the range is $8,351\u2013 $33,950?" }, { "role": "assistant", "content": "SELECT COUNT(\"marginal_ordinary_income_tax_rate\") FROM \"regular_and_capital_gains_tax_rates_for_\" WHERE \"single\"='$8,351\u2013 $33,950';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_and_capital_gains_tax_rates_for_\" (\n \"marginal_ordinary_income_tax_rate\" text,\n \"single\" text,\n \"married_filing_jointly_or_qualified_widow_er\" text,\n \"married_filing_separately\" text,\n \"head_of_household\" text\n);\n\nQuestion: What is the range for married filing separately in which the head of household is $117,451\u2013$190,200?" }, { "role": "assistant", "content": "SELECT \"married_filing_separately\" FROM \"regular_and_capital_gains_tax_rates_for_\" WHERE \"head_of_household\"='$117,451\u2013$190,200';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_and_capital_gains_tax_rates_for_\" (\n \"marginal_ordinary_income_tax_rate\" text,\n \"single\" text,\n \"married_filing_jointly_or_qualified_widow_er\" text,\n \"married_filing_separately\" text,\n \"head_of_household\" text\n);\n\nQuestion: What is the range of married filing jointly or qualified widower in which married filing separately is $33,951\u2013$68,525?" }, { "role": "assistant", "content": "SELECT \"married_filing_jointly_or_qualified_widow_er\" FROM \"regular_and_capital_gains_tax_rates_for_\" WHERE \"married_filing_separately\"='$33,951\u2013$68,525';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_and_capital_gains_tax_rates_for_\" (\n \"marginal_ordinary_income_tax_rate\" text,\n \"single\" text,\n \"married_filing_jointly_or_qualified_widow_er\" text,\n \"married_filing_separately\" text,\n \"head_of_household\" text\n);\n\nQuestion: What is the range of the head of household whereas single is $171,551\u2013$372,950?" }, { "role": "assistant", "content": "SELECT \"head_of_household\" FROM \"regular_and_capital_gains_tax_rates_for_\" WHERE \"single\"='$171,551\u2013$372,950';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_and_capital_gains_tax_rates_for_\" (\n \"marginal_ordinary_income_tax_rate\" text,\n \"single\" text,\n \"married_filing_jointly_or_qualified_widow_er\" text,\n \"married_filing_separately\" text,\n \"head_of_household\" text\n);\n\nQuestion: What is the amoun of marginal ordinary income tax rate where married filing jointly or qualified widow is $208,851\u2013$372,950?" }, { "role": "assistant", "content": "SELECT COUNT(\"marginal_ordinary_income_tax_rate\") FROM \"regular_and_capital_gains_tax_rates_for_\" WHERE \"married_filing_jointly_or_qualified_widow_er\"='$208,851\u2013$372,950';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"honour_board\" (\n \"season\" real,\n \"position\" real,\n \"win_loss\" text,\n \"coach\" text,\n \"captain\" text,\n \"dudley_tuckey_medal\" text,\n \"leading_goalkicker\" text\n);\n\nQuestion: who is the\u00a0coach\u00a0where\u00a0dudley tuckey medal\u00a0is ben howlett" }, { "role": "assistant", "content": "SELECT \"coach\" FROM \"honour_board\" WHERE \"dudley_tuckey_medal\"='Ben Howlett';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"honour_board\" (\n \"season\" real,\n \"position\" real,\n \"win_loss\" text,\n \"coach\" text,\n \"captain\" text,\n \"dudley_tuckey_medal\" text,\n \"leading_goalkicker\" text\n);\n\nQuestion: what is the total number of\u00a0coach\u00a0where\u00a0captain\u00a0is grant welsh and\u00a0win/loss\u00a0is 5-15" }, { "role": "assistant", "content": "SELECT COUNT(\"coach\") FROM \"honour_board\" WHERE \"captain\"='Grant Welsh' AND \"win_loss\"='5-15';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"honour_board\" (\n \"season\" real,\n \"position\" real,\n \"win_loss\" text,\n \"coach\" text,\n \"captain\" text,\n \"dudley_tuckey_medal\" text,\n \"leading_goalkicker\" text\n);\n\nQuestion: who is the\u00a0dudley tuckey medal\u00a0where\u00a0leading goalkicker\u00a0is scott simister (46)" }, { "role": "assistant", "content": "SELECT \"dudley_tuckey_medal\" FROM \"honour_board\" WHERE \"leading_goalkicker\"='Scott Simister (46)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"honour_board\" (\n \"season\" real,\n \"position\" real,\n \"win_loss\" text,\n \"coach\" text,\n \"captain\" text,\n \"dudley_tuckey_medal\" text,\n \"leading_goalkicker\" text\n);\n\nQuestion: what is the maximum\u00a0season\u00a0where\u00a0leading goalkicker\u00a0is scott simister (54)" }, { "role": "assistant", "content": "SELECT MAX(\"season\") FROM \"honour_board\" WHERE \"leading_goalkicker\"='Scott Simister (54)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"honour_board\" (\n \"season\" real,\n \"position\" real,\n \"win_loss\" text,\n \"coach\" text,\n \"captain\" text,\n \"dudley_tuckey_medal\" text,\n \"leading_goalkicker\" text\n);\n\nQuestion: what are all the\u00a0win/loss\u00a0where\u00a0season\u00a0is 2009" }, { "role": "assistant", "content": "SELECT \"win_loss\" FROM \"honour_board\" WHERE \"season\"=2009;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"honour_board\" (\n \"season\" real,\n \"position\" real,\n \"win_loss\" text,\n \"coach\" text,\n \"captain\" text,\n \"dudley_tuckey_medal\" text,\n \"leading_goalkicker\" text\n);\n\nQuestion: who is the\u00a0captain\u00a0where\u00a0coach\u00a0is geoff miles" }, { "role": "assistant", "content": "SELECT \"captain\" FROM \"honour_board\" WHERE \"coach\"='Geoff Miles';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"disaster_relief\" (\n \"disaster\" text,\n \"year\" text,\n \"countries_affected\" text,\n \"scale_of_disaster\" text,\n \"people_assisted\" text,\n \"nature_of_help\" text\n);\n\nQuestion: In 2005-06 what was the disaster?" }, { "role": "assistant", "content": "SELECT \"disaster\" FROM \"disaster_relief\" WHERE \"year\"='2005-06';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"disaster_relief\" (\n \"disaster\" text,\n \"year\" text,\n \"countries_affected\" text,\n \"scale_of_disaster\" text,\n \"people_assisted\" text,\n \"nature_of_help\" text\n);\n\nQuestion: What was the scale of disaster in Peru?" }, { "role": "assistant", "content": "SELECT \"scale_of_disaster\" FROM \"disaster_relief\" WHERE \"countries_affected\"='Peru';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"polish_voivodeships_and_separate_cities_\" (\n \"abbreviation\" text,\n \"voivodeship\" text,\n \"capital\" text,\n \"area_km_1998\" text,\n \"population_1980\" text,\n \"no_of_cities\" real,\n \"no_of_communes\" real\n);\n\nQuestion: What's the area of the voivodenship with 51 communes?" }, { "role": "assistant", "content": "SELECT \"area_km_1998\" FROM \"polish_voivodeships_and_separate_cities_\" WHERE \"no_of_communes\"=51;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"polish_voivodeships_and_separate_cities_\" (\n \"abbreviation\" text,\n \"voivodeship\" text,\n \"capital\" text,\n \"area_km_1998\" text,\n \"population_1980\" text,\n \"no_of_cities\" real,\n \"no_of_communes\" real\n);\n\nQuestion: How big (in km2) is the voivodenship also known by the abbreviation KN?" }, { "role": "assistant", "content": "SELECT \"area_km_1998\" FROM \"polish_voivodeships_and_separate_cities_\" WHERE \"abbreviation\"='kn';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"polish_voivodeships_and_separate_cities_\" (\n \"abbreviation\" text,\n \"voivodeship\" text,\n \"capital\" text,\n \"area_km_1998\" text,\n \"population_1980\" text,\n \"no_of_cities\" real,\n \"no_of_communes\" real\n);\n\nQuestion: How many people lived in the voivodenship whose capital is Siedlce in the year of 1980?" }, { "role": "assistant", "content": "SELECT \"population_1980\" FROM \"polish_voivodeships_and_separate_cities_\" WHERE \"capital\"='Siedlce';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"polish_voivodeships_and_separate_cities_\" (\n \"abbreviation\" text,\n \"voivodeship\" text,\n \"capital\" text,\n \"area_km_1998\" text,\n \"population_1980\" text,\n \"no_of_cities\" real,\n \"no_of_communes\" real\n);\n\nQuestion: How many different voivodenship have 747 900 citizes?" }, { "role": "assistant", "content": "SELECT COUNT(\"voivodeship\") FROM \"polish_voivodeships_and_separate_cities_\" WHERE \"population_1980\"='747 900';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"former_members\" (\n \"institution\" text,\n \"location\" text,\n \"founded\" real,\n \"type\" text,\n \"enrollment\" real,\n \"nickname\" text,\n \"joined\" real,\n \"left\" real,\n \"current_conference\" text\n);\n\nQuestion: What year did longwood university leave the conference?" }, { "role": "assistant", "content": "SELECT MIN(\"left\") FROM \"former_members\" WHERE \"institution\"='Longwood University';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"former_members\" (\n \"institution\" text,\n \"location\" text,\n \"founded\" real,\n \"type\" text,\n \"enrollment\" real,\n \"nickname\" text,\n \"joined\" real,\n \"left\" real,\n \"current_conference\" text\n);\n\nQuestion: What year did a school leave that was founded in 1880?" }, { "role": "assistant", "content": "SELECT \"left\" FROM \"former_members\" WHERE \"founded\"=1880;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"former_members\" (\n \"institution\" text,\n \"location\" text,\n \"founded\" real,\n \"type\" text,\n \"enrollment\" real,\n \"nickname\" text,\n \"joined\" real,\n \"left\" real,\n \"current_conference\" text\n);\n\nQuestion: What is the nickname of the school with an enrollment of 2386?" }, { "role": "assistant", "content": "SELECT \"nickname\" FROM \"former_members\" WHERE \"enrollment\"=2386;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"former_members\" (\n \"institution\" text,\n \"location\" text,\n \"founded\" real,\n \"type\" text,\n \"enrollment\" real,\n \"nickname\" text,\n \"joined\" real,\n \"left\" real,\n \"current_conference\" text\n);\n\nQuestion: What year did the school from mars hill, north carolina join?" }, { "role": "assistant", "content": "SELECT \"joined\" FROM \"former_members\" WHERE \"location\"='Mars Hill, North Carolina';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"former_members\" (\n \"institution\" text,\n \"location\" text,\n \"founded\" real,\n \"type\" text,\n \"enrollment\" real,\n \"nickname\" text,\n \"joined\" real,\n \"left\" real,\n \"current_conference\" text\n);\n\nQuestion: How many times did anderson university leave?" }, { "role": "assistant", "content": "SELECT COUNT(\"left\") FROM \"former_members\" WHERE \"institution\"='Anderson University';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"former_members\" (\n \"institution\" text,\n \"location\" text,\n \"founded\" real,\n \"type\" text,\n \"enrollment\" real,\n \"nickname\" text,\n \"joined\" real,\n \"left\" real,\n \"current_conference\" text\n);\n\nQuestion: What is the nickname of the newberry college?" }, { "role": "assistant", "content": "SELECT \"nickname\" FROM \"former_members\" WHERE \"institution\"='Newberry College';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"ships_of_the_great_eastern_railway\" (\n \"ships_name\" text,\n \"entered_service\" text,\n \"ended_service\" text,\n \"gross_tonnage\" real,\n \"type_of_vessel\" text\n);\n\nQuestion: What was the gross tonnage of the ship that ended service in 1866?" }, { "role": "assistant", "content": "SELECT \"gross_tonnage\" FROM \"ships_of_the_great_eastern_railway\" WHERE \"ended_service\"='1866';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"ships_of_the_great_eastern_railway\" (\n \"ships_name\" text,\n \"entered_service\" text,\n \"ended_service\" text,\n \"gross_tonnage\" real,\n \"type_of_vessel\" text\n);\n\nQuestion: What is the minimum gross tonnage of the Munich? " }, { "role": "assistant", "content": "SELECT MIN(\"gross_tonnage\") FROM \"ships_of_the_great_eastern_railway\" WHERE \"ships_name\"='Munich';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11665016_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: What is the air date for the episode written by Wendy Battles and directed by Oz Scott" }, { "role": "assistant", "content": "SELECT \"original_air_date\" FROM \"table1_11665016_2\" WHERE \"written_by\"='Wendy Battles' AND \"directed_by\"='Oz Scott';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11665016_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: How many US viewers (millions) were there for \"cold reveal\"" }, { "role": "assistant", "content": "SELECT \"u_s_viewers_millions\" FROM \"table1_11665016_2\" WHERE \"title\"='\\\"Cold Reveal\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11665016_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: Which episode was written by anthony e. zuiker & ken solarz" }, { "role": "assistant", "content": "SELECT \"title\" FROM \"table1_11665016_2\" WHERE \"written_by\"='Anthony E. Zuiker & Ken Solarz';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11665016_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: Which episode was directed by steven depaul" }, { "role": "assistant", "content": "SELECT \"title\" FROM \"table1_11665016_2\" WHERE \"directed_by\"='Steven DePaul';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"locomotives_and_rolling_stock\" (\n \"number\" text,\n \"tms_number\" text,\n \"builder\" text,\n \"year_built\" real,\n \"carriage_type\" text\n);\n\nQuestion: What where the tms numbers built in 1923" }, { "role": "assistant", "content": "SELECT \"tms_number\" FROM \"locomotives_and_rolling_stock\" WHERE \"year_built\"=1923;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"locomotives_and_rolling_stock\" (\n \"number\" text,\n \"tms_number\" text,\n \"builder\" text,\n \"year_built\" real,\n \"carriage_type\" text\n);\n\nQuestion: What year was the carriage type is 47' 6\" 'birdcage' gallery coach built" }, { "role": "assistant", "content": "SELECT \"year_built\" FROM \"locomotives_and_rolling_stock\" WHERE \"carriage_type\"='47'' 6\\\" ''Birdcage'' gallery coach';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"locomotives_and_rolling_stock\" (\n \"number\" text,\n \"tms_number\" text,\n \"builder\" text,\n \"year_built\" real,\n \"carriage_type\" text\n);\n\nQuestion: What tms were built nzr addington in the year 1913" }, { "role": "assistant", "content": "SELECT \"tms_number\" FROM \"locomotives_and_rolling_stock\" WHERE \"builder\"='NZR Addington' AND \"year_built\"=1913;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"ships_operated_by_zeeland_steamship_comp\" (\n \"ships_name\" text,\n \"date_entered_service\" text,\n \"date_withdrawn\" text,\n \"tonnage\" real,\n \"type_of_ship\" text\n);\n\nQuestion: what's the date entered service with ships name koningin wilhelmina" }, { "role": "assistant", "content": "SELECT \"date_entered_service\" FROM \"ships_operated_by_zeeland_steamship_comp\" WHERE \"ships_name\"='Koningin Wilhelmina';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"ships_operated_by_zeeland_steamship_comp\" (\n \"ships_name\" text,\n \"date_entered_service\" text,\n \"date_withdrawn\" text,\n \"tonnage\" real,\n \"type_of_ship\" text\n);\n\nQuestion: what's the\u00a0date where ships name is zeeland entered service" }, { "role": "assistant", "content": "SELECT \"date_entered_service\" FROM \"ships_operated_by_zeeland_steamship_comp\" WHERE \"ships_name\"='Zeeland';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"ships_operated_by_zeeland_steamship_comp\" (\n \"ships_name\" text,\n \"date_entered_service\" text,\n \"date_withdrawn\" text,\n \"tonnage\" real,\n \"type_of_ship\" text\n);\n\nQuestion: what is the maximum tonnage where date entered service is 25 march 1986 " }, { "role": "assistant", "content": "SELECT MAX(\"tonnage\") FROM \"ships_operated_by_zeeland_steamship_comp\" WHERE \"date_entered_service\"='25 March 1986';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"ships_operated_by_zeeland_steamship_comp\" (\n \"ships_name\" text,\n \"date_entered_service\" text,\n \"date_withdrawn\" text,\n \"tonnage\" real,\n \"type_of_ship\" text\n);\n\nQuestion: what are all the date withdrawn for service entered on 21 november 1945" }, { "role": "assistant", "content": "SELECT \"date_withdrawn\" FROM \"ships_operated_by_zeeland_steamship_comp\" WHERE \"date_entered_service\"='21 November 1945';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"ships_operated_by_zeeland_steamship_comp\" (\n \"ships_name\" text,\n \"date_entered_service\" text,\n \"date_withdrawn\" text,\n \"tonnage\" real,\n \"type_of_ship\" text\n);\n\nQuestion: what are all the date withdrawn for twin screw ro-ro motorship" }, { "role": "assistant", "content": "SELECT \"date_withdrawn\" FROM \"ships_operated_by_zeeland_steamship_comp\" WHERE \"type_of_ship\"='Twin Screw Ro-Ro Motorship';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"ships_operated_by_zeeland_steamship_comp\" (\n \"ships_name\" text,\n \"date_entered_service\" text,\n \"date_withdrawn\" text,\n \"tonnage\" real,\n \"type_of_ship\" text\n);\n\nQuestion: what are all the date withdrawn for koningin beatrix" }, { "role": "assistant", "content": "SELECT \"date_withdrawn\" FROM \"ships_operated_by_zeeland_steamship_comp\" WHERE \"ships_name\"='Koningin Beatrix';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11664625_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: Where is the first season that Anthony Hemingway appears?" }, { "role": "assistant", "content": "SELECT MIN(\"no_in_season\") FROM \"table1_11664625_2\" WHERE \"directed_by\"='Anthony Hemingway';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11664625_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: What is the original air date of season 18?" }, { "role": "assistant", "content": "SELECT \"original_air_date\" FROM \"table1_11664625_2\" WHERE \"no_in_season\"=18;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11664625_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: When is the first season there were 14.57 million U.S viewers?" }, { "role": "assistant", "content": "SELECT MIN(\"no_in_season\") FROM \"table1_11664625_2\" WHERE \"u_s_viewers_millions\"='14.57';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_1167698_1\" (\n \"season\" text,\n \"champion\" text,\n \"runner_up\" text,\n \"third_place\" text,\n \"top_scorer\" text\n);\n\nQuestion: How many champions were there in 2009?" }, { "role": "assistant", "content": "SELECT COUNT(\"champion\") FROM \"table1_1167698_1\" WHERE \"season\"='2009';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_1167698_1\" (\n \"season\" text,\n \"champion\" text,\n \"runner_up\" text,\n \"third_place\" text,\n \"top_scorer\" text\n);\n\nQuestion: Who won third place with the runner up being dynamo moscow?" }, { "role": "assistant", "content": "SELECT \"third_place\" FROM \"table1_1167698_1\" WHERE \"runner_up\"='Dynamo Moscow';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11677100_15\" (\n \"player\" text,\n \"position\" text,\n \"school\" text,\n \"hometown\" text,\n \"mlb_draft\" text\n);\n\nQuestion: What position does Matt Hobgood play?" }, { "role": "assistant", "content": "SELECT \"position\" FROM \"table1_11677100_15\" WHERE \"player\"='Matt Hobgood';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11677100_15\" (\n \"player\" text,\n \"position\" text,\n \"school\" text,\n \"hometown\" text,\n \"mlb_draft\" text\n);\n\nQuestion: How many players were from high point, nc?" }, { "role": "assistant", "content": "SELECT COUNT(\"mlb_draft\") FROM \"table1_11677100_15\" WHERE \"hometown\"='High Point, NC';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11677100_15\" (\n \"player\" text,\n \"position\" text,\n \"school\" text,\n \"hometown\" text,\n \"mlb_draft\" text\n);\n\nQuestion: What high school did Jeff Malm attend?" }, { "role": "assistant", "content": "SELECT \"school\" FROM \"table1_11677100_15\" WHERE \"player\"='Jeff Malm';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11677100_15\" (\n \"player\" text,\n \"position\" text,\n \"school\" text,\n \"hometown\" text,\n \"mlb_draft\" text\n);\n\nQuestion: How many hometowns does the catcher have?" }, { "role": "assistant", "content": "SELECT COUNT(\"hometown\") FROM \"table1_11677100_15\" WHERE \"position\"='Catcher';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_11677100_16\" (\n \"player\" text,\n \"position\" text,\n \"school\" text,\n \"hometown\" text,\n \"mlb_draft\" text\n);\n\nQuestion: Who was drafted from the school Mountain Pointe High School?" }, { "role": "assistant", "content": "SELECT \"mlb_draft\" FROM \"table1_11677100_16\" WHERE \"school\"='Mountain Pointe High School';" } ]