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 \"round_16\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: What date has a Home team score of 11.18 (84)?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"round_16\" WHERE \"home_team_score\"='11.18 (84)';" } ]
[ { "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 \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: What home team score has a Away team of melbourne?" }, { "role": "assistant", "content": "SELECT \"home_team_score\" FROM \"round_16\" WHERE \"away_team\"='melbourne';" } ]
[ { "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 \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: What away team is the home team richmond?" }, { "role": "assistant", "content": "SELECT \"away_team\" FROM \"round_16\" WHERE \"home_team\"='richmond';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"classification\" (\n \"driver\" text,\n \"constructor\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real\n);\n\nQuestion: When Giancarlo Fisichella was the Driver and there were less than 52 Laps, what was the highest Grid?" }, { "role": "assistant", "content": "SELECT MAX(\"grid\") FROM \"classification\" WHERE \"driver\"='giancarlo fisichella' AND \"laps\"<52;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"classification\" (\n \"driver\" text,\n \"constructor\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real\n);\n\nQuestion: Which Constructor has a Grid less than 17, Laps under 52, and Olivier Panis as the Driver?" }, { "role": "assistant", "content": "SELECT \"constructor\" FROM \"classification\" WHERE \"grid\"<17 AND \"laps\"<52 AND \"driver\"='olivier panis';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_six\" (\n \"pick_num\" text,\n \"cfl_team\" text,\n \"player\" text,\n \"position\" text,\n \"college\" text\n);\n\nQuestion: Which 2006 cfl draft pick played college ball at Idaho state?" }, { "role": "assistant", "content": "SELECT \"pick_num\" FROM \"round_six\" WHERE \"college\"='idaho state';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_six\" (\n \"pick_num\" text,\n \"cfl_team\" text,\n \"player\" text,\n \"position\" text,\n \"college\" text\n);\n\nQuestion: What position did the CFL player drafted out of college of toronto in 2007 play?" }, { "role": "assistant", "content": "SELECT \"position\" FROM \"round_six\" WHERE \"college\"='toronto';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"house_of_valois_burgundy_1405_1482\" (\n \"name\" text,\n \"date_of_birth\" text,\n \"date_of_death\" text,\n \"reign\" text,\n \"relationship_with_predecessor\" text\n);\n\nQuestion: What was the Date of Death of the person whose Date of Birth was 28 May 1371?" }, { "role": "assistant", "content": "SELECT \"date_of_death\" FROM \"house_of_valois_burgundy_1405_1482\" WHERE \"date_of_birth\"='28 may 1371';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"house_of_valois_burgundy_1405_1482\" (\n \"name\" text,\n \"date_of_birth\" text,\n \"date_of_death\" text,\n \"reign\" text,\n \"relationship_with_predecessor\" text\n);\n\nQuestion: What was the Reign of the person whose Date of Birth was 22 March 1459?" }, { "role": "assistant", "content": "SELECT \"reign\" FROM \"house_of_valois_burgundy_1405_1482\" WHERE \"date_of_birth\"='22 march 1459';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"year_by_year_record\" (\n \"year\" real,\n \"record\" text,\n \"finish\" text,\n \"manager\" text,\n \"playoffs\" text\n);\n\nQuestion: Tell me the average year with a record of 33-33" }, { "role": "assistant", "content": "SELECT AVG(\"year\") FROM \"year_by_year_record\" WHERE \"record\"='33-33';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"year_by_year_record\" (\n \"year\" real,\n \"record\" text,\n \"finish\" text,\n \"manager\" text,\n \"playoffs\" text\n);\n\nQuestion: Name the total number of years for a 39-31 record" }, { "role": "assistant", "content": "SELECT COUNT(\"year\") FROM \"year_by_year_record\" WHERE \"record\"='39-31';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"year_by_year_record\" (\n \"year\" real,\n \"record\" text,\n \"finish\" text,\n \"manager\" text,\n \"playoffs\" text\n);\n\nQuestion: Name the least year for gene hassell manager and 6th finish" }, { "role": "assistant", "content": "SELECT MIN(\"year\") FROM \"year_by_year_record\" WHERE \"manager\"='gene hassell' AND \"finish\"='6th';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"year_by_year_record\" (\n \"year\" real,\n \"record\" text,\n \"finish\" text,\n \"manager\" text,\n \"playoffs\" text\n);\n\nQuestion: Name the finish for a 39-31 record" }, { "role": "assistant", "content": "SELECT \"finish\" FROM \"year_by_year_record\" WHERE \"record\"='39-31';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"final_table\" (\n \"position\" real,\n \"club\" text,\n \"played\" real,\n \"points\" text,\n \"wins\" real,\n \"draws\" real,\n \"losses\" real,\n \"goals_for\" real,\n \"goals_against\" real,\n \"goal_difference\" real\n);\n\nQuestion: What is the lowest goal difference for the club ud alzira, with a played larger than 38?" }, { "role": "assistant", "content": "SELECT MIN(\"goal_difference\") FROM \"final_table\" WHERE \"club\"='ud alzira' AND \"played\">38;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"final_table\" (\n \"position\" real,\n \"club\" text,\n \"played\" real,\n \"points\" text,\n \"wins\" real,\n \"draws\" real,\n \"losses\" real,\n \"goals_for\" real,\n \"goals_against\" real,\n \"goal_difference\" real\n);\n\nQuestion: What is the goal difference sum that has goals against smaller than 33, draws larger than 13?" }, { "role": "assistant", "content": "SELECT SUM(\"goal_difference\") FROM \"final_table\" WHERE \"goals_against\"<33 AND \"draws\">13;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"out\" (\n \"name\" text,\n \"country\" text,\n \"status\" text,\n \"moving_to\" text,\n \"transfer_window\" text,\n \"transfer_fee\" text\n);\n\nQuestion: Name the transfer fee for damia" }, { "role": "assistant", "content": "SELECT \"transfer_fee\" FROM \"out\" WHERE \"name\"='damia';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"out\" (\n \"name\" text,\n \"country\" text,\n \"status\" text,\n \"moving_to\" text,\n \"transfer_window\" text,\n \"transfer_fee\" text\n);\n\nQuestion: Name the moving to with a transfer fee of free with a transfer status for rodri" }, { "role": "assistant", "content": "SELECT \"moving_to\" FROM \"out\" WHERE \"transfer_fee\"='free' AND \"status\"='transfer' AND \"name\"='rodri';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_3\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: When was the game played at the Western Oval venue?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"round_3\" WHERE \"venue\"='western oval';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_3\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: What is the home team score for the team that played an away game at North Melbourne?" }, { "role": "assistant", "content": "SELECT \"home_team_score\" FROM \"round_3\" WHERE \"away_team\"='north melbourne';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"locomotives\" (\n \"locomotive\" text,\n \"serial_no\" text,\n \"entered_service\" text,\n \"gauge\" text,\n \"livery\" text\n);\n\nQuestion: What is the livery of the locomotive with a serial number 83-1010?" }, { "role": "assistant", "content": "SELECT \"livery\" FROM \"locomotives\" WHERE \"serial_no\"='83-1010';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"locomotives\" (\n \"locomotive\" text,\n \"serial_no\" text,\n \"entered_service\" text,\n \"gauge\" text,\n \"livery\" text\n);\n\nQuestion: What is the livery on the locomotive with a serial number 83-1011?" }, { "role": "assistant", "content": "SELECT \"livery\" FROM \"locomotives\" WHERE \"serial_no\"='83-1011';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"locomotives\" (\n \"locomotive\" text,\n \"serial_no\" text,\n \"entered_service\" text,\n \"gauge\" text,\n \"livery\" text\n);\n\nQuestion: What is the locomotive with a standard gauge and a serial number of 83-1015?" }, { "role": "assistant", "content": "SELECT \"locomotive\" FROM \"locomotives\" WHERE \"gauge\"='standard' AND \"serial_no\"='83-1015';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"locomotives\" (\n \"locomotive\" text,\n \"serial_no\" text,\n \"entered_service\" text,\n \"gauge\" text,\n \"livery\" text\n);\n\nQuestion: What is the date of entered service for the locomotive with a broad gauge and a serial no of 83-1018?" }, { "role": "assistant", "content": "SELECT \"entered_service\" FROM \"locomotives\" WHERE \"gauge\"='broad' AND \"serial_no\"='83-1018';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"international_goals\" (\n \"date\" text,\n \"venue\" text,\n \"score\" text,\n \"result\" text,\n \"competition\" text\n);\n\nQuestion: What was the venue on October 16, 1996?" }, { "role": "assistant", "content": "SELECT \"venue\" FROM \"international_goals\" WHERE \"date\"='october 16, 1996';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"international_goals\" (\n \"date\" text,\n \"venue\" text,\n \"score\" text,\n \"result\" text,\n \"competition\" text\n);\n\nQuestion: What's the score at the October 30, 1996 1998 fifa world cup qualification with a result of win?" }, { "role": "assistant", "content": "SELECT \"score\" FROM \"international_goals\" WHERE \"result\"='win' AND \"competition\"='1998 fifa world cup qualification' AND \"date\"='october 30, 1996';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"international_goals\" (\n \"date\" text,\n \"venue\" text,\n \"score\" text,\n \"result\" text,\n \"competition\" text\n);\n\nQuestion: When was the friendship cup?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"international_goals\" WHERE \"competition\"='friendship cup';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"class_253_and_254\" (\n \"class\" text,\n \"operator\" text,\n \"number\" real,\n \"year_built\" text,\n \"cars_per_set\" real,\n \"unit_numbers\" text\n);\n\nQuestion: What is the smallest number for Cars per Set built in 1977-1979 larger than 32?" }, { "role": "assistant", "content": "SELECT MIN(\"cars_per_set\") FROM \"class_253_and_254\" WHERE \"year_built\"='1977-1979' AND \"number\">32;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"class_253_and_254\" (\n \"class\" text,\n \"operator\" text,\n \"number\" real,\n \"year_built\" text,\n \"cars_per_set\" real,\n \"unit_numbers\" text\n);\n\nQuestion: What unit has cars per set larger than 9 built in 1982?" }, { "role": "assistant", "content": "SELECT \"unit_numbers\" FROM \"class_253_and_254\" WHERE \"cars_per_set\">9 AND \"year_built\"='1982';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"class_253_and_254\" (\n \"class\" text,\n \"operator\" text,\n \"number\" real,\n \"year_built\" text,\n \"cars_per_set\" real,\n \"unit_numbers\" text\n);\n\nQuestion: What is the largest number of cars per set that is less than 9?" }, { "role": "assistant", "content": "SELECT MAX(\"number\") FROM \"class_253_and_254\" WHERE \"cars_per_set\"<9;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"class_253_and_254\" (\n \"class\" text,\n \"operator\" text,\n \"number\" real,\n \"year_built\" text,\n \"cars_per_set\" real,\n \"unit_numbers\" text\n);\n\nQuestion: What year was the class 253 larger than 18 built?" }, { "role": "assistant", "content": "SELECT \"year_built\" FROM \"class_253_and_254\" WHERE \"class\"='class 253' AND \"number\">18;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"wins_14\" (\n \"year\" real,\n \"championship\" text,\n \"54_holes\" text,\n \"winning_score\" text,\n \"margin\" text,\n \"runner_s_up\" text\n);\n\nQuestion: What is the margin for the Masters Tournament (2) championship?" }, { "role": "assistant", "content": "SELECT \"margin\" FROM \"wins_14\" WHERE \"championship\"='masters tournament (2)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"wins_14\" (\n \"year\" real,\n \"championship\" text,\n \"54_holes\" text,\n \"winning_score\" text,\n \"margin\" text,\n \"runner_s_up\" text\n);\n\nQuestion: How many years had 54 holes and a 2 shot lead?" }, { "role": "assistant", "content": "SELECT COUNT(\"year\") FROM \"wins_14\" WHERE \"54_holes\"='2 shot lead';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"wins_14\" (\n \"year\" real,\n \"championship\" text,\n \"54_holes\" text,\n \"winning_score\" text,\n \"margin\" text,\n \"runner_s_up\" text\n);\n\nQuestion: What is the round of 54 holes in which Phil Mickelson was the runner-up?" }, { "role": "assistant", "content": "SELECT \"54_holes\" FROM \"wins_14\" WHERE \"runner_s_up\"='phil mickelson';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"wins_14\" (\n \"year\" real,\n \"championship\" text,\n \"54_holes\" text,\n \"winning_score\" text,\n \"margin\" text,\n \"runner_s_up\" text\n);\n\nQuestion: What is the championship when the margin was 2 strokes, there were 54 holes with a 1 shot lead, and the runner-up was David Duval?" }, { "role": "assistant", "content": "SELECT \"championship\" FROM \"wins_14\" WHERE \"margin\"='2 strokes' AND \"54_holes\"='1 shot lead' AND \"runner_s_up\"='david duval';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"quarter_finals_1_vs_nashville_predators_\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"decision\" text,\n \"attendance\" real,\n \"series\" text\n);\n\nQuestion: What is the home team of the April 14 game?" }, { "role": "assistant", "content": "SELECT \"home\" FROM \"quarter_finals_1_vs_nashville_predators_\" WHERE \"date\"='april 14';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"quarter_finals_1_vs_nashville_predators_\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"decision\" text,\n \"attendance\" real,\n \"series\" text\n);\n\nQuestion: What is the date of the game with Detroit as the visitor team?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"quarter_finals_1_vs_nashville_predators_\" WHERE \"visitor\"='detroit';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"u_s_nielsen_ratings\" (\n \"episode\" text,\n \"airdate\" text,\n \"rating\" real,\n \"share\" real,\n \"18_49_rating_share\" text,\n \"viewers_m\" real,\n \"rank_num\" text\n);\n\nQuestion: How many vieweres for the episode with a share of 1, a Rating larger than 0.7000000000000001, and a Rank (#) of 100/102?" }, { "role": "assistant", "content": "SELECT \"viewers_m\" FROM \"u_s_nielsen_ratings\" WHERE \"share\"=1 AND \"rating\">0.7000000000000001 AND \"rank_num\"='100/102';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"history_of_ggb_members\" (\n \"alto_1\" text,\n \"alto_2\" text,\n \"tenor\" text,\n \"lead_tpt\" text,\n \"tpt_2\" text,\n \"tpt_3\" text,\n \"mello\" text,\n \"lead_bone\" text,\n \"bass_bone\" text,\n \"bass\" text,\n \"drums\" text\n);\n\nQuestion: Name the lead tpt for bass of kevin tomanka and alto 1 of alan moffett" }, { "role": "assistant", "content": "SELECT \"lead_tpt\" FROM \"history_of_ggb_members\" WHERE \"bass\"='kevin tomanka' AND \"alto_1\"='alan moffett';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_13\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: What was the crowd size at the moorabbin oval venue?" }, { "role": "assistant", "content": "SELECT COUNT(\"crowd\") FROM \"round_13\" WHERE \"venue\"='moorabbin oval';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_13\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: What was the home team score in the game where the away team scored 11.8 (74)?" }, { "role": "assistant", "content": "SELECT \"home_team_score\" FROM \"round_13\" WHERE \"away_team_score\"='11.8 (74)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_13\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: What did the home team score against the away team collingwood?" }, { "role": "assistant", "content": "SELECT \"home_team_score\" FROM \"round_13\" WHERE \"away_team\"='collingwood';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table_of_standard_amino_acid_abbreviatio\" (\n \"amino_acid\" text,\n \"3_letter\" text,\n \"1_letter\" text,\n \"side_chain_polarity\" text,\n \"side_chain_charge_p_h_7_4\" text,\n \"hydropathy_index\" text\n);\n\nQuestion: what is the 1-letter for the amino acid asparagine?" }, { "role": "assistant", "content": "SELECT \"1_letter\" FROM \"table_of_standard_amino_acid_abbreviatio\" WHERE \"amino_acid\"='asparagine';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table_of_standard_amino_acid_abbreviatio\" (\n \"amino_acid\" text,\n \"3_letter\" text,\n \"1_letter\" text,\n \"side_chain_polarity\" text,\n \"side_chain_charge_p_h_7_4\" text,\n \"hydropathy_index\" text\n);\n\nQuestion: what is the side-chain polarity for the amino acid with the 1-letter v?" }, { "role": "assistant", "content": "SELECT \"side_chain_polarity\" FROM \"table_of_standard_amino_acid_abbreviatio\" WHERE \"1_letter\"='v';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table_of_standard_amino_acid_abbreviatio\" (\n \"amino_acid\" text,\n \"3_letter\" text,\n \"1_letter\" text,\n \"side_chain_polarity\" text,\n \"side_chain_charge_p_h_7_4\" text,\n \"hydropathy_index\" text\n);\n\nQuestion: What is the side-chain charge (ph 7.4) for the amino acid with the 1-letter p?" }, { "role": "assistant", "content": "SELECT \"side_chain_charge_p_h_7_4\" FROM \"table_of_standard_amino_acid_abbreviatio\" WHERE \"1_letter\"='p';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_9\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: What was home team North Melbourne's opponents score?" }, { "role": "assistant", "content": "SELECT \"away_team_score\" FROM \"round_9\" WHERE \"home_team\"='north melbourne';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_9\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: What was Melbourne's score as the home team?" }, { "role": "assistant", "content": "SELECT \"home_team_score\" FROM \"round_9\" WHERE \"home_team\"='melbourne';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_9\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: Who was the away team at Junction Oval?" }, { "role": "assistant", "content": "SELECT \"away_team\" FROM \"round_9\" WHERE \"venue\"='junction oval';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"major_awards\" (\n \"year\" real,\n \"mrhma\" text,\n \"usca\" text,\n \"rthk\" text,\n \"joint_music_award\" text,\n \"total\" real\n);\n\nQuestion: What is the USCA that's Total is smaller than 14, with 1 Joint Music Award, MRHMA of 2, and RTHK of 3?" }, { "role": "assistant", "content": "SELECT \"usca\" FROM \"major_awards\" WHERE \"total\"<14 AND \"joint_music_award\"='1' AND \"mrhma\"='2' AND \"rthk\"='3';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"major_awards\" (\n \"year\" real,\n \"mrhma\" text,\n \"usca\" text,\n \"rthk\" text,\n \"joint_music_award\" text,\n \"total\" real\n);\n\nQuestion: What is the Total with a Joint Music Award of 1, RTHK of 4, and USCA of 4?" }, { "role": "assistant", "content": "SELECT \"total\" FROM \"major_awards\" WHERE \"joint_music_award\"='1' AND \"rthk\"='4' AND \"usca\"='4';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"major_awards\" (\n \"year\" real,\n \"mrhma\" text,\n \"usca\" text,\n \"rthk\" text,\n \"joint_music_award\" text,\n \"total\" real\n);\n\nQuestion: How many Joint Music Awards were there with a RTHK of 1, in a Year before 2006?" }, { "role": "assistant", "content": "SELECT \"joint_music_award\" FROM \"major_awards\" WHERE \"year\"<2006 AND \"rthk\"='1';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"major_awards\" (\n \"year\" real,\n \"mrhma\" text,\n \"usca\" text,\n \"rthk\" text,\n \"joint_music_award\" text,\n \"total\" real\n);\n\nQuestion: How many Joint Music Awards are there when the Total is larger than 18, in a Year after 2007?" }, { "role": "assistant", "content": "SELECT \"joint_music_award\" FROM \"major_awards\" WHERE \"total\">18 AND \"year\">2007;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"final_classification\" (\n \"athlete\" text,\n \"final\" real,\n \"lane\" real,\n \"semi\" real,\n \"quart\" real,\n \"heat\" real\n);\n\nQuestion: Which lane did the athlete swim in who had a semi-final time of 49.19?" }, { "role": "assistant", "content": "SELECT MIN(\"lane\") FROM \"final_classification\" WHERE \"semi\"=49.19;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"original_farthing_wood_animals\" (\n \"animal_name\" text,\n \"species\" text,\n \"books\" text,\n \"tv_series\" text,\n \"gender\" text,\n \"tv_seasons\" text\n);\n\nQuestion: Which species is male?" }, { "role": "assistant", "content": "SELECT \"species\" FROM \"original_farthing_wood_animals\" WHERE \"gender\"='male';" } ]
[ { "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 \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: What was the home teams score at Junction Oval?" }, { "role": "assistant", "content": "SELECT \"home_team_score\" FROM \"round_1\" WHERE \"venue\"='junction oval';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_presidents\" (\n \"presidency\" real,\n \"president\" text,\n \"date_of_birth\" text,\n \"took_office\" real,\n \"left_office\" text\n);\n\nQuestion: What President has a Presidency greater than 7?" }, { "role": "assistant", "content": "SELECT \"president\" FROM \"list_of_presidents\" WHERE \"presidency\">7;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_presidents\" (\n \"presidency\" real,\n \"president\" text,\n \"date_of_birth\" text,\n \"took_office\" real,\n \"left_office\" text\n);\n\nQuestion: What is the highest Presidency that Took Office after 1974 and Left Office in 1998?" }, { "role": "assistant", "content": "SELECT MAX(\"presidency\") FROM \"list_of_presidents\" WHERE \"left_office\"='1998' AND \"took_office\">1974;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_presidents\" (\n \"presidency\" real,\n \"president\" text,\n \"date_of_birth\" text,\n \"took_office\" real,\n \"left_office\" text\n);\n\nQuestion: What is the Took Office Date of the Presidency that Left Office Incumbent?" }, { "role": "assistant", "content": "SELECT SUM(\"took_office\") FROM \"list_of_presidents\" WHERE \"left_office\"='incumbent';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_presidents\" (\n \"presidency\" real,\n \"president\" text,\n \"date_of_birth\" text,\n \"took_office\" real,\n \"left_office\" text\n);\n\nQuestion: What was the greatest Took Office dates that Left Office in 1998?" }, { "role": "assistant", "content": "SELECT MAX(\"took_office\") FROM \"list_of_presidents\" WHERE \"left_office\"='1998';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"race\" (\n \"driver\" text,\n \"constructor\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real\n);\n\nQuestion: What is the average Laps for andrea de cesaris?" }, { "role": "assistant", "content": "SELECT AVG(\"laps\") FROM \"race\" WHERE \"driver\"='andrea de cesaris';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"race\" (\n \"driver\" text,\n \"constructor\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real\n);\n\nQuestion: What is the lowest Grid for jj lehto with over 51 laps?" }, { "role": "assistant", "content": "SELECT MIN(\"grid\") FROM \"race\" WHERE \"laps\">51 AND \"driver\"='jj lehto';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"race\" (\n \"driver\" text,\n \"constructor\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real\n);\n\nQuestion: What is the average Grid that has a Time/Retired of +2 laps, and under 51 laps?" }, { "role": "assistant", "content": "SELECT AVG(\"grid\") FROM \"race\" WHERE \"time_retired\"='+2 laps' AND \"laps\"<51;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_18\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: What's the Home teams Venue near Victoria Park?" }, { "role": "assistant", "content": "SELECT \"home_team\" FROM \"round_18\" WHERE \"venue\"='victoria park';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_18\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: What is the Home team with a crowd relevant to footscray?" }, { "role": "assistant", "content": "SELECT \"crowd\" FROM \"round_18\" WHERE \"home_team\"='footscray';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"december\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"decision\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What is the team's record when they play nashville at home?" }, { "role": "assistant", "content": "SELECT \"record\" FROM \"december\" WHERE \"home\"='nashville';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"december\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"decision\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What is the decision when they're at phoenix?" }, { "role": "assistant", "content": "SELECT \"decision\" FROM \"december\" WHERE \"visitor\"='phoenix';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2006\" (\n \"tournament\" text,\n \"winner\" text,\n \"runner_up\" text,\n \"score\" text,\n \"third_place\" text\n);\n\nQuestion: What was the score in the Tournament of Frankfurt?" }, { "role": "assistant", "content": "SELECT \"score\" FROM \"2006\" WHERE \"tournament\"='frankfurt';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2006\" (\n \"tournament\" text,\n \"winner\" text,\n \"runner_up\" text,\n \"score\" text,\n \"third_place\" text\n);\n\nQuestion: Who was the winner in the Tournament of Graz-Seiersberg?" }, { "role": "assistant", "content": "SELECT \"winner\" FROM \"2006\" WHERE \"tournament\"='graz-seiersberg';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2006\" (\n \"tournament\" text,\n \"winner\" text,\n \"runner_up\" text,\n \"score\" text,\n \"third_place\" text\n);\n\nQuestion: Who earned third place when the winner was Paul Haarhuis?" }, { "role": "assistant", "content": "SELECT \"third_place\" FROM \"2006\" WHERE \"winner\"='paul haarhuis';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"classification\" (\n \"driver\" text,\n \"constructor\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real\n);\n\nQuestion: what is the most laps with the time/retired is differential and the grid is more than 2?" }, { "role": "assistant", "content": "SELECT MAX(\"laps\") FROM \"classification\" WHERE \"time_retired\"='differential' AND \"grid\">2;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"classification\" (\n \"driver\" text,\n \"constructor\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real\n);\n\nQuestion: what is the least laps when the grid is 5?" }, { "role": "assistant", "content": "SELECT MIN(\"laps\") FROM \"classification\" WHERE \"grid\"=5;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"superfund_sites\" (\n \"cerclis_id\" text,\n \"name\" text,\n \"county\" text,\n \"proposed\" text,\n \"listed\" text,\n \"construction_completed\" text,\n \"partially_deleted\" text,\n \"deleted\" text\n);\n\nQuestion: On what date was Anniston Army Depot (SE Industrial Area) deleted?" }, { "role": "assistant", "content": "SELECT \"deleted\" FROM \"superfund_sites\" WHERE \"name\"='anniston army depot (se industrial area)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"superfund_sites\" (\n \"cerclis_id\" text,\n \"name\" text,\n \"county\" text,\n \"proposed\" text,\n \"listed\" text,\n \"construction_completed\" text,\n \"partially_deleted\" text,\n \"deleted\" text\n);\n\nQuestion: In what county is the entry that has a Construction Completed date of 07/19/2000 and a Listed date of 09/21/1984 located?" }, { "role": "assistant", "content": "SELECT \"county\" FROM \"superfund_sites\" WHERE \"listed\"='09/21/1984' AND \"construction_completed\"='07/19/2000';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"superfund_sites\" (\n \"cerclis_id\" text,\n \"name\" text,\n \"county\" text,\n \"proposed\" text,\n \"listed\" text,\n \"construction_completed\" text,\n \"partially_deleted\" text,\n \"deleted\" text\n);\n\nQuestion: On what date was Stauffer Chemical Company (Lemoyne Plant), which was listed on 09/21/1984, deleted?" }, { "role": "assistant", "content": "SELECT \"deleted\" FROM \"superfund_sites\" WHERE \"listed\"='09/21/1984' AND \"name\"='stauffer chemical company (lemoyne plant)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"superfund_sites\" (\n \"cerclis_id\" text,\n \"name\" text,\n \"county\" text,\n \"proposed\" text,\n \"listed\" text,\n \"construction_completed\" text,\n \"partially_deleted\" text,\n \"deleted\" text\n);\n\nQuestion: What was the Proposed date of the entry that has a CERCLIS ID of al0001058056?" }, { "role": "assistant", "content": "SELECT \"proposed\" FROM \"superfund_sites\" WHERE \"cerclis_id\"='al0001058056';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"x\" (\n \"name\" text,\n \"original_publisher\" text,\n \"first_appearance\" text,\n \"year\" real,\n \"date\" text\n);\n\nQuestion: What first appeared in 1966 in the comic X-2-Y?" }, { "role": "assistant", "content": "SELECT \"first_appearance\" FROM \"x\" WHERE \"year\"=1966 AND \"name\"='x-2-y';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"former_current_professional_teams\" (\n \"team\" text,\n \"sport\" text,\n \"league\" text,\n \"played\" text,\n \"class\" text,\n \"championships\" text\n);\n\nQuestion: Which baseball team is class AAA?" }, { "role": "assistant", "content": "SELECT \"team\" FROM \"former_current_professional_teams\" WHERE \"sport\"='baseball' AND \"class\"='aaa';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_3\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: Where does Collingwood play their games?" }, { "role": "assistant", "content": "SELECT \"venue\" FROM \"round_3\" WHERE \"away_team\"='collingwood';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2012_team\" (\n \"player\" text,\n \"position\" text,\n \"school\" text,\n \"hometown\" text,\n \"college\" text\n);\n\nQuestion: Which position does Robert Nkemdiche play?" }, { "role": "assistant", "content": "SELECT \"position\" FROM \"2012_team\" WHERE \"player\"='robert nkemdiche';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2012_team\" (\n \"player\" text,\n \"position\" text,\n \"school\" text,\n \"hometown\" text,\n \"college\" text\n);\n\nQuestion: What is Reuben Foster's college?" }, { "role": "assistant", "content": "SELECT \"college\" FROM \"2012_team\" WHERE \"player\"='reuben foster';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2012_team\" (\n \"player\" text,\n \"position\" text,\n \"school\" text,\n \"hometown\" text,\n \"college\" text\n);\n\nQuestion: Which position does the player from Muscle Shoals, Alabama play?" }, { "role": "assistant", "content": "SELECT \"position\" FROM \"2012_team\" WHERE \"hometown\"='muscle shoals, alabama';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2012_team\" (\n \"player\" text,\n \"position\" text,\n \"school\" text,\n \"hometown\" text,\n \"college\" text\n);\n\nQuestion: Which player is attending college at Virginia?" }, { "role": "assistant", "content": "SELECT \"player\" FROM \"2012_team\" WHERE \"college\"='virginia';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2012_team\" (\n \"player\" text,\n \"position\" text,\n \"school\" text,\n \"hometown\" text,\n \"college\" text\n);\n\nQuestion: Which player attended Hoover High School?" }, { "role": "assistant", "content": "SELECT \"player\" FROM \"2012_team\" WHERE \"school\"='hoover high school';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What is the team's record on may 12 when they play the giants?" }, { "role": "assistant", "content": "SELECT \"record\" FROM \"game_log\" WHERE \"opponent\"='giants' AND \"date\"='may 12';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"western_conference_semi_finals\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"decision\" text,\n \"attendance\" real\n);\n\nQuestion: What is the attendance at the game where San Jose was the visitor on May 4?" }, { "role": "assistant", "content": "SELECT \"attendance\" FROM \"western_conference_semi_finals\" WHERE \"visitor\"='san jose' AND \"date\"='may 4';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"western_conference_semi_finals\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"decision\" text,\n \"attendance\" real\n);\n\nQuestion: Who was the home team on the May 2 game?" }, { "role": "assistant", "content": "SELECT \"home\" FROM \"western_conference_semi_finals\" WHERE \"date\"='may 2';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"western_conference_semi_finals\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"decision\" text,\n \"attendance\" real\n);\n\nQuestion: What is the decision of the game with more than 17,496 attendance on April 30?" }, { "role": "assistant", "content": "SELECT \"decision\" FROM \"western_conference_semi_finals\" WHERE \"attendance\">'17,496' AND \"date\"='april 30';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_4\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: What date is the crowd larger than 20,000?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"round_4\" WHERE \"crowd\">'20,000';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"round_4\" (\n \"home_team\" text,\n \"home_team_score\" text,\n \"away_team\" text,\n \"away_team_score\" text,\n \"venue\" text,\n \"crowd\" real,\n \"date\" text\n);\n\nQuestion: Which away team has a score of more that 11.13 (79)" }, { "role": "assistant", "content": "SELECT \"away_team\" FROM \"round_4\" WHERE \"away_team_score\"='11.13 (79)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" text,\n \"record\" text\n);\n\nQuestion: What was the record when the score was 11-10?" }, { "role": "assistant", "content": "SELECT \"record\" FROM \"game_log\" WHERE \"score\"='11-10';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" text,\n \"record\" text\n);\n\nQuestion: What was the record when the attendance was 22,713?" }, { "role": "assistant", "content": "SELECT \"record\" FROM \"game_log\" WHERE \"attendance\"='22,713';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" text,\n \"record\" text\n);\n\nQuestion: What was the attendance at the game when the record was 49-61?" }, { "role": "assistant", "content": "SELECT \"attendance\" FROM \"game_log\" WHERE \"record\"='49-61';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" text,\n \"record\" text\n);\n\nQuestion: On what date was there a game in which the opponent was the Detroit Tigers, and the attendance was 38,639?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"game_log\" WHERE \"opponent\"='detroit tigers' AND \"attendance\"='38,639';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"general\" (\n \"software\" text,\n \"latest_stable_date_version\" text,\n \"cost_usd\" text,\n \"open_source\" text,\n \"license\" text\n);\n\nQuestion: What is the free sotware with the latest stable date version of 1.1?" }, { "role": "assistant", "content": "SELECT \"software\" FROM \"general\" WHERE \"cost_usd\"='free' AND \"latest_stable_date_version\"='1.1';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"general\" (\n \"software\" text,\n \"latest_stable_date_version\" text,\n \"cost_usd\" text,\n \"open_source\" text,\n \"license\" text\n);\n\nQuestion: Name the software with the latest stable date of 0.6.1" }, { "role": "assistant", "content": "SELECT \"software\" FROM \"general\" WHERE \"latest_stable_date_version\"='0.6.1';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"general\" (\n \"software\" text,\n \"latest_stable_date_version\" text,\n \"cost_usd\" text,\n \"open_source\" text,\n \"license\" text\n);\n\nQuestion: Name the cost for latest stable date of online" }, { "role": "assistant", "content": "SELECT \"cost_usd\" FROM \"general\" WHERE \"latest_stable_date_version\"='online';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"prime_ministers\" (\n \"name\" text,\n \"entered_office\" text,\n \"left_office\" text,\n \"political_party\" text,\n \"monarchs_served\" text,\n \"birth_place\" text\n);\n\nQuestion: What is the birth place of the prime minister who served George V and entered office on 23 October 1922?" }, { "role": "assistant", "content": "SELECT \"birth_place\" FROM \"prime_ministers\" WHERE \"monarchs_served\"='george v' AND \"entered_office\"='23 october 1922';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"prime_ministers\" (\n \"name\" text,\n \"entered_office\" text,\n \"left_office\" text,\n \"political_party\" text,\n \"monarchs_served\" text,\n \"birth_place\" text\n);\n\nQuestion: To which political party did the prime minister who served under George V and was born in Manchester belong?" }, { "role": "assistant", "content": "SELECT \"political_party\" FROM \"prime_ministers\" WHERE \"monarchs_served\"='george v' AND \"birth_place\"='manchester';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"prime_ministers\" (\n \"name\" text,\n \"entered_office\" text,\n \"left_office\" text,\n \"political_party\" text,\n \"monarchs_served\" text,\n \"birth_place\" text\n);\n\nQuestion: What date did the prime minister who entered office on 7 December 1916 leave office?" }, { "role": "assistant", "content": "SELECT \"left_office\" FROM \"prime_ministers\" WHERE \"entered_office\"='7 december 1916';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"prime_ministers\" (\n \"name\" text,\n \"entered_office\" text,\n \"left_office\" text,\n \"political_party\" text,\n \"monarchs_served\" text,\n \"birth_place\" text\n);\n\nQuestion: What monarch(s) did Stanley Baldwin (1st ministry) serve?" }, { "role": "assistant", "content": "SELECT \"monarchs_served\" FROM \"prime_ministers\" WHERE \"name\"='stanley baldwin (1st ministry)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"schedule\" (\n \"week\" real,\n \"date\" text,\n \"opponent\" text,\n \"result\" text,\n \"game_site\" text,\n \"attendance\" text\n);\n\nQuestion: What is the date of the game played at rich stadium?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"schedule\" WHERE \"game_site\"='rich stadium';" } ]