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 \"summary\" (\n \"district\" real,\n \"incumbent\" text,\n \"2008_status\" text,\n \"democratic\" text,\n \"republican\" text\n);\n\nQuestion: Which Incumbent has a Republican of dan mansell?" }, { "role": "assistant", "content": "SELECT \"incumbent\" FROM \"summary\" WHERE \"republican\"='dan mansell';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"summary\" (\n \"district\" real,\n \"incumbent\" text,\n \"2008_status\" text,\n \"democratic\" text,\n \"republican\" text\n);\n\nQuestion: Which Democratic has a District smaller than 7, and a Republican of dan mansell?" }, { "role": "assistant", "content": "SELECT \"democratic\" FROM \"summary\" WHERE \"district\"<7 AND \"republican\"='dan mansell';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"playoffs\" (\n \"date\" text,\n \"opponent\" text,\n \"result\" text,\n \"score\" text,\n \"record\" text,\n \"streak\" text\n);\n\nQuestion: Which record has a score of 135\u2013134?" }, { "role": "assistant", "content": "SELECT \"record\" FROM \"playoffs\" WHERE \"score\"='135\u2013134';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2008_six_nations_championship_squads\" (\n \"player\" text,\n \"position\" text,\n \"date_of_birth_age\" text,\n \"caps\" real,\n \"club_province\" text\n);\n\nQuestion: Name the position for the player born 2 november 1987" }, { "role": "assistant", "content": "SELECT \"position\" FROM \"2008_six_nations_championship_squads\" WHERE \"date_of_birth_age\"='2 november 1987';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2008_six_nations_championship_squads\" (\n \"player\" text,\n \"position\" text,\n \"date_of_birth_age\" text,\n \"caps\" real,\n \"club_province\" text\n);\n\nQuestion: Name the club/province for steve borthwick" }, { "role": "assistant", "content": "SELECT \"club_province\" FROM \"2008_six_nations_championship_squads\" WHERE \"player\"='steve borthwick';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"apothecaries_system\" (\n \"unit\" text,\n \"russian\" text,\n \"translation\" text,\n \"ratio\" real,\n \"metric_value\" text,\n \"avoirdupois_value\" text,\n \"ordinary_value\" text\n);\n\nQuestion: What is the largest ration with an ordinary value of 84 zolotnik?" }, { "role": "assistant", "content": "SELECT MAX(\"ratio\") FROM \"apothecaries_system\" WHERE \"ordinary_value\"='84 zolotnik';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"apothecaries_system\" (\n \"unit\" text,\n \"russian\" text,\n \"translation\" text,\n \"ratio\" real,\n \"metric_value\" text,\n \"avoirdupois_value\" text,\n \"ordinary_value\" text\n);\n\nQuestion: What unit has an Avoirdupois value of 57.602 gr.?" }, { "role": "assistant", "content": "SELECT \"unit\" FROM \"apothecaries_system\" WHERE \"avoirdupois_value\"='57.602 gr.';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"apothecaries_system\" (\n \"unit\" text,\n \"russian\" text,\n \"translation\" text,\n \"ratio\" real,\n \"metric_value\" text,\n \"avoirdupois_value\" text,\n \"ordinary_value\" text\n);\n\nQuestion: Which translation had a unit of Uncia?" }, { "role": "assistant", "content": "SELECT \"translation\" FROM \"apothecaries_system\" WHERE \"unit\"='uncia';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"apothecaries_system\" (\n \"unit\" text,\n \"russian\" text,\n \"translation\" text,\n \"ratio\" real,\n \"metric_value\" text,\n \"avoirdupois_value\" text,\n \"ordinary_value\" text\n);\n\nQuestion: What ordinary value has a metric value of 29.861 g?" }, { "role": "assistant", "content": "SELECT \"ordinary_value\" FROM \"apothecaries_system\" WHERE \"metric_value\"='29.861 g';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"apothecaries_system\" (\n \"unit\" text,\n \"russian\" text,\n \"translation\" text,\n \"ratio\" real,\n \"metric_value\" text,\n \"avoirdupois_value\" text,\n \"ordinary_value\" text\n);\n\nQuestion: Which ordinary value has a Russian value of \u0443\u043d\u0446\u0438\u044f?" }, { "role": "assistant", "content": "SELECT \"ordinary_value\" FROM \"apothecaries_system\" WHERE \"russian\"='\u0443\u043d\u0446\u0438\u044f';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"apothecaries_system\" (\n \"unit\" text,\n \"russian\" text,\n \"translation\" text,\n \"ratio\" real,\n \"metric_value\" text,\n \"avoirdupois_value\" text,\n \"ordinary_value\" text\n);\n\nQuestion: Which Avoirdupois value is translated to grain?" }, { "role": "assistant", "content": "SELECT \"avoirdupois_value\" FROM \"apothecaries_system\" WHERE \"translation\"='grain';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_auto_racing_tracks_in_the_united\" (\n \"track\" text,\n \"city\" text,\n \"state\" text,\n \"opened\" text,\n \"major_series\" text,\n \"turns\" text\n);\n\nQuestion: What is the number of turns for the City of san antonio?" }, { "role": "assistant", "content": "SELECT \"turns\" FROM \"list_of_auto_racing_tracks_in_the_united\" WHERE \"city\"='san antonio';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_auto_racing_tracks_in_the_united\" (\n \"track\" text,\n \"city\" text,\n \"state\" text,\n \"opened\" text,\n \"major_series\" text,\n \"turns\" text\n);\n\nQuestion: What is the State with the imsa gt as the Major Series and a track in new orleans?" }, { "role": "assistant", "content": "SELECT \"state\" FROM \"list_of_auto_racing_tracks_in_the_united\" WHERE \"major_series\"='imsa gt' AND \"track\"='new orleans';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_auto_racing_tracks_in_the_united\" (\n \"track\" text,\n \"city\" text,\n \"state\" text,\n \"opened\" text,\n \"major_series\" text,\n \"turns\" text\n);\n\nQuestion: Where is the track located with 18 turns?" }, { "role": "assistant", "content": "SELECT \"track\" FROM \"list_of_auto_racing_tracks_in_the_united\" WHERE \"turns\"='18';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_auto_racing_tracks_in_the_united\" (\n \"track\" text,\n \"city\" text,\n \"state\" text,\n \"opened\" text,\n \"major_series\" text,\n \"turns\" text\n);\n\nQuestion: What is the State with the trans-am Major Series in Grand Rapids?" }, { "role": "assistant", "content": "SELECT \"state\" FROM \"list_of_auto_racing_tracks_in_the_united\" WHERE \"major_series\"='trans-am' AND \"city\"='grand rapids';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_auto_racing_tracks_in_the_united\" (\n \"track\" text,\n \"city\" text,\n \"state\" text,\n \"opened\" text,\n \"major_series\" text,\n \"turns\" text\n);\n\nQuestion: Where is the track located that opened in 1992?" }, { "role": "assistant", "content": "SELECT \"track\" FROM \"list_of_auto_racing_tracks_in_the_united\" WHERE \"opened\"='1992';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_auto_racing_tracks_in_the_united\" (\n \"track\" text,\n \"city\" text,\n \"state\" text,\n \"opened\" text,\n \"major_series\" text,\n \"turns\" text\n);\n\nQuestion: What shows for opened for the Nascar Major Series?" }, { "role": "assistant", "content": "SELECT \"opened\" FROM \"list_of_auto_racing_tracks_in_the_united\" WHERE \"major_series\"='nascar';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"scorers\" (\n \"player\" text,\n \"league\" real,\n \"malaysia_cup\" real,\n \"fa_cup\" real,\n \"total\" real\n);\n\nQuestion: What is the lowest number of FA cups associated with 0 malaysia cups?" }, { "role": "assistant", "content": "SELECT MIN(\"fa_cup\") FROM \"scorers\" WHERE \"malaysia_cup\"<0;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"scorers\" (\n \"player\" text,\n \"league\" real,\n \"malaysia_cup\" real,\n \"fa_cup\" real,\n \"total\" real\n);\n\nQuestion: How many league cups for m patrick maria with 0 total?" }, { "role": "assistant", "content": "SELECT SUM(\"league\") FROM \"scorers\" WHERE \"player\"='m patrick maria' AND \"total\"<0;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"scorers\" (\n \"player\" text,\n \"league\" real,\n \"malaysia_cup\" real,\n \"fa_cup\" real,\n \"total\" real\n);\n\nQuestion: What is the highest number of Malaysia Cups for a player with over 0 leagues and under 0 FA cups?" }, { "role": "assistant", "content": "SELECT MAX(\"malaysia_cup\") FROM \"scorers\" WHERE \"league\">0 AND \"fa_cup\"<0;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"results\" (\n \"date\" text,\n \"host\" text,\n \"agg\" text,\n \"visitor\" text,\n \"ground\" text,\n \"attendance\" real,\n \"tournament\" text\n);\n\nQuestion: What is the tournament on July 29 hosted by SK Brann?" }, { "role": "assistant", "content": "SELECT \"tournament\" FROM \"results\" WHERE \"host\"='sk brann' AND \"date\"='july 29';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"results\" (\n \"date\" text,\n \"host\" text,\n \"agg\" text,\n \"visitor\" text,\n \"ground\" text,\n \"attendance\" real,\n \"tournament\" text\n);\n\nQuestion: Who is the visitor of the match on July 29?" }, { "role": "assistant", "content": "SELECT \"visitor\" FROM \"results\" WHERE \"date\"='july 29';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_schedule\" (\n \"date\" text,\n \"opponent\" text,\n \"result\" text,\n \"score\" text,\n \"record\" text,\n \"streak\" text\n);\n\nQuestion: What is the game that has the phoenix suns as the opponent played against?" }, { "role": "assistant", "content": "SELECT \"result\" FROM \"season_schedule\" WHERE \"opponent\"='phoenix suns';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"april\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"leading_scorer\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What is the attendance of the game on 2007-04-07 with the Warriors as the visitor team?" }, { "role": "assistant", "content": "SELECT \"attendance\" FROM \"april\" WHERE \"visitor\"='warriors' AND \"date\"='2007-04-07';" } ]
[ { "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 day is their record 13-15?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"game_log\" WHERE \"record\"='13-15';" } ]
[ { "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: Who did they play when dickey (0-1) recorded the loss?" }, { "role": "assistant", "content": "SELECT \"opponent\" FROM \"game_log\" WHERE \"loss\"='dickey (0-1)';" } ]
[ { "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 \"time_et\" text,\n \"game_site\" text,\n \"result\" text,\n \"record\" text\n);\n\nQuestion: What is the result of the game of heinz field with a record of 2-5?" }, { "role": "assistant", "content": "SELECT \"result\" FROM \"schedule\" WHERE \"game_site\"='heinz field' AND \"record\"='2-5';" } ]
[ { "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 \"time_et\" text,\n \"game_site\" text,\n \"result\" text,\n \"record\" text\n);\n\nQuestion: What opponent has a record of 6-9?" }, { "role": "assistant", "content": "SELECT \"opponent\" FROM \"schedule\" WHERE \"record\"='6-9';" } ]
[ { "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 \"time_et\" text,\n \"game_site\" text,\n \"result\" text,\n \"record\" text\n);\n\nQuestion: What is the week with a record of 2-1?" }, { "role": "assistant", "content": "SELECT COUNT(\"week\") FROM \"schedule\" WHERE \"record\"='2-1';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"translators\" (\n \"call_sign\" text,\n \"frequency_m_hz\" real,\n \"city_of_license\" text,\n \"erp_w\" real,\n \"class\" text,\n \"fcc_info\" text\n);\n\nQuestion: What City of license has a Frequency MHz smaller than 95.9 with w223au as the call sign?" }, { "role": "assistant", "content": "SELECT \"city_of_license\" FROM \"translators\" WHERE \"frequency_m_hz\"<95.9 AND \"call_sign\"='w223au';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"translators\" (\n \"call_sign\" text,\n \"frequency_m_hz\" real,\n \"city_of_license\" text,\n \"erp_w\" real,\n \"class\" text,\n \"fcc_info\" text\n);\n\nQuestion: What is the Call sign for the ERP W 19?" }, { "role": "assistant", "content": "SELECT \"call_sign\" FROM \"translators\" WHERE \"erp_w\"=19;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"translators\" (\n \"call_sign\" text,\n \"frequency_m_hz\" real,\n \"city_of_license\" text,\n \"erp_w\" real,\n \"class\" text,\n \"fcc_info\" text\n);\n\nQuestion: What FCC info is listed for the ERP W of 2?" }, { "role": "assistant", "content": "SELECT \"fcc_info\" FROM \"translators\" WHERE \"erp_w\"=2;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"translators\" (\n \"call_sign\" text,\n \"frequency_m_hz\" real,\n \"city_of_license\" text,\n \"erp_w\" real,\n \"class\" text,\n \"fcc_info\" text\n);\n\nQuestion: What Call sign shows an ERP W of 80?" }, { "role": "assistant", "content": "SELECT \"call_sign\" FROM \"translators\" WHERE \"erp_w\"=80;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"translators\" (\n \"call_sign\" text,\n \"frequency_m_hz\" real,\n \"city_of_license\" text,\n \"erp_w\" real,\n \"class\" text,\n \"fcc_info\" text\n);\n\nQuestion: What is the Class for the ERP W of more than 2 and the call sign of w223au?" }, { "role": "assistant", "content": "SELECT \"class\" FROM \"translators\" WHERE \"erp_w\">2 AND \"call_sign\"='w223au';" } ]
[ { "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 \"time\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"record\" text\n);\n\nQuestion: what team lost on july 30" }, { "role": "assistant", "content": "SELECT \"loss\" FROM \"game_log\" WHERE \"date\"='july 30';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2010_2011\" (\n \"date\" text,\n \"site\" text,\n \"sport\" text,\n \"winning_team\" text,\n \"series\" text\n);\n\nQuestion: What sport was played on February 25, 2011?" }, { "role": "assistant", "content": "SELECT \"sport\" FROM \"2010_2011\" WHERE \"date\"='february 25, 2011';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2010_2011\" (\n \"date\" text,\n \"site\" text,\n \"sport\" text,\n \"winning_team\" text,\n \"series\" text\n);\n\nQuestion: Where was the sport played on September 10, 2010?" }, { "role": "assistant", "content": "SELECT \"site\" FROM \"2010_2011\" WHERE \"date\"='september 10, 2010';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"doubles_wins_38\" (\n \"date\" text,\n \"tournament\" text,\n \"surface\" text,\n \"partner\" text,\n \"opponent_in_the_final\" text,\n \"score\" text\n);\n\nQuestion: What type of surface was played on when julie halard-decugis was the partner on October 8, 2000?" }, { "role": "assistant", "content": "SELECT \"surface\" FROM \"doubles_wins_38\" WHERE \"partner\"='julie halard-decugis' AND \"date\"='october 8, 2000';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"summary_of_results_by_season\" (\n \"year\" text,\n \"played\" real,\n \"wins\" real,\n \"losses\" real,\n \"no_result\" real,\n \"pct_win\" text\n);\n\nQuestion: How many Played has a % Win of 50.00%, and Losses of 1, and Wins smaller than 1?" }, { "role": "assistant", "content": "SELECT COUNT(\"played\") FROM \"summary_of_results_by_season\" WHERE \"pct_win\"='50.00%' AND \"losses\"=1 AND \"wins\"<1;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"summary_of_results_by_season\" (\n \"year\" text,\n \"played\" real,\n \"wins\" real,\n \"losses\" real,\n \"no_result\" real,\n \"pct_win\" text\n);\n\nQuestion: WHAT kind of No Result has Wins smaller than 2, and Losses larger than 1?" }, { "role": "assistant", "content": "SELECT \"no_result\" FROM \"summary_of_results_by_season\" WHERE \"wins\"<2 AND \"losses\">1;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"summary_of_results_by_season\" (\n \"year\" text,\n \"played\" real,\n \"wins\" real,\n \"losses\" real,\n \"no_result\" real,\n \"pct_win\" text\n);\n\nQuestion: How many Played that has Losses of 6, and Wins larger than 33?" }, { "role": "assistant", "content": "SELECT AVG(\"played\") FROM \"summary_of_results_by_season\" WHERE \"losses\"=6 AND \"wins\">33;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"summary_of_results_by_season\" (\n \"year\" text,\n \"played\" real,\n \"wins\" real,\n \"losses\" real,\n \"no_result\" real,\n \"pct_win\" text\n);\n\nQuestion: What kind of No Result has a % Win of 100.00% and a Played larger than 4 in 2012?" }, { "role": "assistant", "content": "SELECT MIN(\"no_result\") FROM \"summary_of_results_by_season\" WHERE \"pct_win\"='100.00%' AND \"played\">4 AND \"year\"='2012';" } ]
[ { "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 Loss has an Attendance more than 43,095 and a Record of 31\u201329?" }, { "role": "assistant", "content": "SELECT \"loss\" FROM \"game_log\" WHERE \"attendance\">'43,095' AND \"record\"='31\u201329';" } ]
[ { "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: Which Loss has a Score of 6\u20135?" }, { "role": "assistant", "content": "SELECT \"loss\" FROM \"game_log\" WHERE \"score\"='6\u20135';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"location\" text,\n \"record\" text\n);\n\nQuestion: Date of wed. nov. 13 had how many number of games?" }, { "role": "assistant", "content": "SELECT COUNT(\"game\") FROM \"game_log\" WHERE \"date\"='wed. nov. 13';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"location\" text,\n \"record\" text\n);\n\nQuestion: Record of 6\u20131 had what score?" }, { "role": "assistant", "content": "SELECT \"score\" FROM \"game_log\" WHERE \"record\"='6\u20131';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"location\" text,\n \"record\" text\n);\n\nQuestion: Score of 118\u2013114, and a Record of 8\u20131 is what lowest game?" }, { "role": "assistant", "content": "SELECT MIN(\"game\") FROM \"game_log\" WHERE \"score\"='118\u2013114' AND \"record\"='8\u20131';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_calendar\" (\n \"date\" text,\n \"country\" text,\n \"circuit\" text,\n \"sprint_winner\" text,\n \"feature_winner\" text,\n \"report\" text\n);\n\nQuestion: Which circuit was in Great Britain with Ireland as the winner?" }, { "role": "assistant", "content": "SELECT \"circuit\" FROM \"season_calendar\" WHERE \"feature_winner\"='ireland' AND \"country\"='great britain';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"match_details\" (\n \"date\" text,\n \"league_position\" text,\n \"opponents\" text,\n \"venue\" text,\n \"result\" text,\n \"score_f_a\" text,\n \"attendance\" real\n);\n\nQuestion: How many were in attendance when the league position was 16th and the score was F\u2013A of 0\u20133?" }, { "role": "assistant", "content": "SELECT COUNT(\"attendance\") FROM \"match_details\" WHERE \"league_position\"='16th' AND \"score_f_a\"='0\u20133';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"match_details\" (\n \"date\" text,\n \"league_position\" text,\n \"opponents\" text,\n \"venue\" text,\n \"result\" text,\n \"score_f_a\" text,\n \"attendance\" real\n);\n\nQuestion: How many were in attendance for a result of D, at H venue, and Arsenal as an opponent?" }, { "role": "assistant", "content": "SELECT \"attendance\" FROM \"match_details\" WHERE \"result\"='d' AND \"venue\"='h' AND \"opponents\"='arsenal';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"match_details\" (\n \"date\" text,\n \"league_position\" text,\n \"opponents\" text,\n \"venue\" text,\n \"result\" text,\n \"score_f_a\" text,\n \"attendance\" real\n);\n\nQuestion: What is the largest number in attendance at H venue opposing Liverpool with a result of D?" }, { "role": "assistant", "content": "SELECT MAX(\"attendance\") FROM \"match_details\" WHERE \"venue\"='h' AND \"result\"='d' AND \"opponents\"='liverpool';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"norfolk_state\" (\n \"position\" text,\n \"number\" real,\n \"name\" text,\n \"height\" text,\n \"weight\" real,\n \"class\" text,\n \"hometown\" text,\n \"games\" real\n);\n\nQuestion: What is the number of Justin Jeffries?" }, { "role": "assistant", "content": "SELECT COUNT(\"number\") FROM \"norfolk_state\" WHERE \"name\"='justin jeffries';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"norfolk_state\" (\n \"position\" text,\n \"number\" real,\n \"name\" text,\n \"height\" text,\n \"weight\" real,\n \"class\" text,\n \"hometown\" text,\n \"games\" real\n);\n\nQuestion: How many games has number 61 played in?" }, { "role": "assistant", "content": "SELECT MIN(\"games\") FROM \"norfolk_state\" WHERE \"number\"=61;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"norfolk_state\" (\n \"position\" text,\n \"number\" real,\n \"name\" text,\n \"height\" text,\n \"weight\" real,\n \"class\" text,\n \"hometown\" text,\n \"games\" real\n);\n\nQuestion: What is the name of the player who is a wr and has a weight of 197?" }, { "role": "assistant", "content": "SELECT \"name\" FROM \"norfolk_state\" WHERE \"position\"='wr' AND \"weight\"=197;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"norfolk_state\" (\n \"position\" text,\n \"number\" real,\n \"name\" text,\n \"height\" text,\n \"weight\" real,\n \"class\" text,\n \"hometown\" text,\n \"games\" real\n);\n\nQuestion: What is the hometown of number 40?" }, { "role": "assistant", "content": "SELECT \"hometown\" FROM \"norfolk_state\" WHERE \"number\"=40;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"october\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"record\" text\n);\n\nQuestion: What date is the visitor Ottawa?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"october\" WHERE \"visitor\"='ottawa';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"expulsion_proceedings_not_resulting_in_e\" (\n \"year\" real,\n \"senator\" text,\n \"party\" text,\n \"state\" text,\n \"result\" text\n);\n\nQuestion: what is the sum of the year in rhode island" }, { "role": "assistant", "content": "SELECT SUM(\"year\") FROM \"expulsion_proceedings_not_resulting_in_e\" WHERE \"state\"='rhode island';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"expulsion_proceedings_not_resulting_in_e\" (\n \"year\" real,\n \"senator\" text,\n \"party\" text,\n \"state\" text,\n \"result\" text\n);\n\nQuestion: what is the senator in kentucky" }, { "role": "assistant", "content": "SELECT \"senator\" FROM \"expulsion_proceedings_not_resulting_in_e\" WHERE \"state\"='kentucky';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"rail\" (\n \"train_number\" text,\n \"train_name\" text,\n \"origin\" text,\n \"destination\" text,\n \"frequency_inbound_outbound\" text\n);\n\nQuestion: What is the destination of the rail with Dhanbad as the origin?" }, { "role": "assistant", "content": "SELECT \"destination\" FROM \"rail\" WHERE \"origin\"='dhanbad';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"rail\" (\n \"train_number\" text,\n \"train_name\" text,\n \"origin\" text,\n \"destination\" text,\n \"frequency_inbound_outbound\" text\n);\n\nQuestion: What is the destination of the Garib nwaz exp train?" }, { "role": "assistant", "content": "SELECT \"destination\" FROM \"rail\" WHERE \"train_name\"='garib nwaz exp';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"rail\" (\n \"train_number\" text,\n \"train_name\" text,\n \"origin\" text,\n \"destination\" text,\n \"frequency_inbound_outbound\" text\n);\n\nQuestion: What is the train name of the rail with a daily frequency and a destination of Rajgir?" }, { "role": "assistant", "content": "SELECT \"train_name\" FROM \"rail\" WHERE \"frequency_inbound_outbound\"='daily' AND \"destination\"='rajgir';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"rail\" (\n \"train_number\" text,\n \"train_name\" text,\n \"origin\" text,\n \"destination\" text,\n \"frequency_inbound_outbound\" text\n);\n\nQuestion: What is the train name of the rail with a daily frequency and Jammutawi as the destination?" }, { "role": "assistant", "content": "SELECT \"train_name\" FROM \"rail\" WHERE \"frequency_inbound_outbound\"='daily' AND \"destination\"='jammutawi';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"rail\" (\n \"train_number\" text,\n \"train_name\" text,\n \"origin\" text,\n \"destination\" text,\n \"frequency_inbound_outbound\" text\n);\n\nQuestion: What is the frequency of the rail with an origin of Ranchi?" }, { "role": "assistant", "content": "SELECT \"frequency_inbound_outbound\" FROM \"rail\" WHERE \"origin\"='ranchi';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"rail\" (\n \"train_number\" text,\n \"train_name\" text,\n \"origin\" text,\n \"destination\" text,\n \"frequency_inbound_outbound\" text\n);\n\nQuestion: What is the frequency of the train named Garib nwaz exp?" }, { "role": "assistant", "content": "SELECT \"frequency_inbound_outbound\" FROM \"rail\" WHERE \"train_name\"='garib nwaz exp';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_14_2009_2010\" (\n \"series_ep\" text,\n \"episode\" real,\n \"netflix\" text,\n \"segment_a\" text,\n \"segment_b\" text,\n \"segment_c\" text,\n \"segment_d\" text\n);\n\nQuestion: Name the segment c with episode less than 179 and segment b of s sticker" }, { "role": "assistant", "content": "SELECT \"segment_c\" FROM \"season_14_2009_2010\" WHERE \"episode\"<179 AND \"segment_b\"='s sticker';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_14_2009_2010\" (\n \"series_ep\" text,\n \"episode\" real,\n \"netflix\" text,\n \"segment_a\" text,\n \"segment_b\" text,\n \"segment_c\" text,\n \"segment_d\" text\n);\n\nQuestion: Name the segment c for ski goggles" }, { "role": "assistant", "content": "SELECT \"segment_c\" FROM \"season_14_2009_2010\" WHERE \"segment_a\"='ski goggles';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"player_roster\" (\n \"surname\" text,\n \"first\" text,\n \"d_o_b\" text,\n \"bats\" text,\n \"throws\" text,\n \"position\" text\n);\n\nQuestion: In which position did Steve play first?" }, { "role": "assistant", "content": "SELECT \"position\" FROM \"player_roster\" WHERE \"first\"='steve';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"player_roster\" (\n \"surname\" text,\n \"first\" text,\n \"d_o_b\" text,\n \"bats\" text,\n \"throws\" text,\n \"position\" text\n);\n\nQuestion: Which bats did mitchell play first?" }, { "role": "assistant", "content": "SELECT \"bats\" FROM \"player_roster\" WHERE \"first\"='mitchell';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"player_roster\" (\n \"surname\" text,\n \"first\" text,\n \"d_o_b\" text,\n \"bats\" text,\n \"throws\" text,\n \"position\" text\n);\n\nQuestion: When is mr. ryan's DOB?" }, { "role": "assistant", "content": "SELECT \"d_o_b\" FROM \"player_roster\" WHERE \"surname\"='ryan';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"player_roster\" (\n \"surname\" text,\n \"first\" text,\n \"d_o_b\" text,\n \"bats\" text,\n \"throws\" text,\n \"position\" text\n);\n\nQuestion: Which Throws have a Position of 3b/rhp?" }, { "role": "assistant", "content": "SELECT \"throws\" FROM \"player_roster\" WHERE \"position\"='3b/rhp';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"player_roster\" (\n \"surname\" text,\n \"first\" text,\n \"d_o_b\" text,\n \"bats\" text,\n \"throws\" text,\n \"position\" text\n);\n\nQuestion: When is Collins' DOB?" }, { "role": "assistant", "content": "SELECT \"d_o_b\" FROM \"player_roster\" WHERE \"surname\"='collins';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"player_roster\" (\n \"surname\" text,\n \"first\" text,\n \"d_o_b\" text,\n \"bats\" text,\n \"throws\" text,\n \"position\" text\n);\n\nQuestion: Which Position has a D.O.B. of 3 june 1989?" }, { "role": "assistant", "content": "SELECT \"position\" FROM \"player_roster\" WHERE \"d_o_b\"='3 june 1989';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"past_competitions\" (\n \"years\" text,\n \"competition\" text,\n \"vehicle_name\" text,\n \"original_vehicle\" text,\n \"architecture\" text\n);\n\nQuestion: What type of architecture does the Saturn Vue have?" }, { "role": "assistant", "content": "SELECT \"architecture\" FROM \"past_competitions\" WHERE \"vehicle_name\"='saturn vue';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"past_competitions\" (\n \"years\" text,\n \"competition\" text,\n \"vehicle_name\" text,\n \"original_vehicle\" text,\n \"architecture\" text\n);\n\nQuestion: What architecture type does the Ford Escort Wagon have?" }, { "role": "assistant", "content": "SELECT \"architecture\" FROM \"past_competitions\" WHERE \"original_vehicle\"='ford escort wagon';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"past_competitions\" (\n \"years\" text,\n \"competition\" text,\n \"vehicle_name\" text,\n \"original_vehicle\" text,\n \"architecture\" text\n);\n\nQuestion: What original vehicle has uwhvt homepage architecture?" }, { "role": "assistant", "content": "SELECT \"original_vehicle\" FROM \"past_competitions\" WHERE \"architecture\"='uwhvt homepage';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"prize_money\" (\n \"year\" text,\n \"winner\" text,\n \"runner_up\" text,\n \"semi_finalists\" text,\n \"quarter_finalists\" text,\n \"last_16\" text,\n \"last_32\" text,\n \"last_64\" text,\n \"total\" text\n);\n\nQuestion: Which Winner has a Last 16 of \u00a3400?" }, { "role": "assistant", "content": "SELECT \"winner\" FROM \"prize_money\" WHERE \"last_16\"='\u00a3400';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"prize_money\" (\n \"year\" text,\n \"winner\" text,\n \"runner_up\" text,\n \"semi_finalists\" text,\n \"quarter_finalists\" text,\n \"last_16\" text,\n \"last_32\" text,\n \"last_64\" text,\n \"total\" text\n);\n\nQuestion: Which Runner-Up has a Total of \u00a331,200?" }, { "role": "assistant", "content": "SELECT \"runner_up\" FROM \"prize_money\" WHERE \"total\"='\u00a331,200';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"prize_money\" (\n \"year\" text,\n \"winner\" text,\n \"runner_up\" text,\n \"semi_finalists\" text,\n \"quarter_finalists\" text,\n \"last_16\" text,\n \"last_32\" text,\n \"last_64\" text,\n \"total\" text\n);\n\nQuestion: Which Runner-Up has a Last 16 of \u00a3300?" }, { "role": "assistant", "content": "SELECT \"runner_up\" FROM \"prize_money\" WHERE \"last_16\"='\u00a3300';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"prize_money\" (\n \"year\" text,\n \"winner\" text,\n \"runner_up\" text,\n \"semi_finalists\" text,\n \"quarter_finalists\" text,\n \"last_16\" text,\n \"last_32\" text,\n \"last_64\" text,\n \"total\" text\n);\n\nQuestion: Which Last 64 has a Total of \u00a334,600?" }, { "role": "assistant", "content": "SELECT \"last_64\" FROM \"prize_money\" WHERE \"total\"='\u00a334,600';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"prize_money\" (\n \"year\" text,\n \"winner\" text,\n \"runner_up\" text,\n \"semi_finalists\" text,\n \"quarter_finalists\" text,\n \"last_16\" text,\n \"last_32\" text,\n \"last_64\" text,\n \"total\" text\n);\n\nQuestion: Which Winner has Semi-Finalists of \u00a32,000?" }, { "role": "assistant", "content": "SELECT \"winner\" FROM \"prize_money\" WHERE \"semi_finalists\"='\u00a32,000';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"prize_money\" (\n \"year\" text,\n \"winner\" text,\n \"runner_up\" text,\n \"semi_finalists\" text,\n \"quarter_finalists\" text,\n \"last_16\" text,\n \"last_32\" text,\n \"last_64\" text,\n \"total\" text\n);\n\nQuestion: Which Year has a Quarter-Finalists of \u00a31,000, and Semi-Finalists of \u00a31,500?" }, { "role": "assistant", "content": "SELECT \"year\" FROM \"prize_money\" WHERE \"quarter_finalists\"='\u00a31,000' AND \"semi_finalists\"='\u00a31,500';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"athletes\" (\n \"nationality\" text,\n \"height\" text,\n \"name\" text,\n \"sport\" text,\n \"lifespan\" text\n);\n\nQuestion: How tall is Dylan Postl?" }, { "role": "assistant", "content": "SELECT \"height\" FROM \"athletes\" WHERE \"name\"='dylan postl';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2008_squad\" (\n \"squad_no\" real,\n \"player\" text,\n \"position\" text,\n \"tries\" real,\n \"goals\" real,\n \"points\" real\n);\n\nQuestion: What is the largest amount of goals when the points are less than 0?" }, { "role": "assistant", "content": "SELECT MAX(\"goals\") FROM \"2008_squad\" WHERE \"points\"<0;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2008_squad\" (\n \"squad_no\" real,\n \"player\" text,\n \"position\" text,\n \"tries\" real,\n \"goals\" real,\n \"points\" real\n);\n\nQuestion: Which player has more than 0 goals and less than 12 tries?" }, { "role": "assistant", "content": "SELECT \"player\" FROM \"2008_squad\" WHERE \"goals\">0 AND \"tries\"<12;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2008_squad\" (\n \"squad_no\" real,\n \"player\" text,\n \"position\" text,\n \"tries\" real,\n \"goals\" real,\n \"points\" real\n);\n\nQuestion: What is the smallest number of tries when Matt Diskin is the player and there are more than 16 points?" }, { "role": "assistant", "content": "SELECT MIN(\"tries\") FROM \"2008_squad\" WHERE \"player\"='matt diskin' AND \"points\">16;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2008_squad\" (\n \"squad_no\" real,\n \"player\" text,\n \"position\" text,\n \"tries\" real,\n \"goals\" real,\n \"points\" real\n);\n\nQuestion: Which position has more than 4 points, less than 12 tries, a squad number of more than 1, and where Ali Lauitiiti is a player?" }, { "role": "assistant", "content": "SELECT \"position\" FROM \"2008_squad\" WHERE \"points\">4 AND \"tries\"<12 AND \"squad_no\">1 AND \"player\"='ali lauitiiti';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2008_squad\" (\n \"squad_no\" real,\n \"player\" text,\n \"position\" text,\n \"tries\" real,\n \"goals\" real,\n \"points\" real\n);\n\nQuestion: What is the total number of squad no when there are more than 8 points, Danny Mcguire is a player, and there are more than 0 goals?" }, { "role": "assistant", "content": "SELECT SUM(\"squad_no\") FROM \"2008_squad\" WHERE \"points\">8 AND \"player\"='danny mcguire' AND \"goals\">0;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"world_championship_group_b_yugoslavia\" (\n \"games\" real,\n \"drawn\" real,\n \"lost\" real,\n \"points_difference\" text,\n \"points\" real\n);\n\nQuestion: What is the lowest lost from drawn of 1 or greater?" }, { "role": "assistant", "content": "SELECT MIN(\"lost\") FROM \"world_championship_group_b_yugoslavia\" WHERE \"drawn\">1;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"world_championship_group_b_yugoslavia\" (\n \"games\" real,\n \"drawn\" real,\n \"lost\" real,\n \"points_difference\" text,\n \"points\" real\n);\n\nQuestion: What is the highest games from a game with points less than 4, drawn of 1 and a lost less than 6?" }, { "role": "assistant", "content": "SELECT MAX(\"games\") FROM \"world_championship_group_b_yugoslavia\" WHERE \"points\"<4 AND \"drawn\"=1 AND \"lost\"<6;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"record\" text\n);\n\nQuestion: What is the score of the game on January 18?" }, { "role": "assistant", "content": "SELECT \"score\" FROM \"regular_season\" WHERE \"date\"='january 18';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"record\" text\n);\n\nQuestion: What is the score of the game on January 10?" }, { "role": "assistant", "content": "SELECT \"score\" FROM \"regular_season\" WHERE \"date\"='january 10';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"date\" text,\n \"visitor\" text,\n \"score\" text,\n \"home\" text,\n \"record\" text\n);\n\nQuestion: What is the score of the game on November 12 with the Chicago Black Hawks as the visitor team?" }, { "role": "assistant", "content": "SELECT \"score\" FROM \"regular_season\" WHERE \"visitor\"='chicago black hawks' AND \"date\"='november 12';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"series\" text\n);\n\nQuestion: What is the series score of the game on May 6?" }, { "role": "assistant", "content": "SELECT \"series\" FROM \"game_log\" WHERE \"date\"='may 6';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"the_boats\" (\n \"ship\" text,\n \"builder\" text,\n \"laid_down\" text,\n \"launched\" text,\n \"commissioned\" text\n);\n\nQuestion: The Zeehond was built by whom?" }, { "role": "assistant", "content": "SELECT \"builder\" FROM \"the_boats\" WHERE \"ship\"='zeehond';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"nhl_entry_draft\" (\n \"round\" real,\n \"player\" text,\n \"position\" text,\n \"nationality\" text,\n \"college_junior_club_team\" text\n);\n\nQuestion: What college, junior, or club team did Victor Ignatjev play for?" }, { "role": "assistant", "content": "SELECT \"college_junior_club_team\" FROM \"nhl_entry_draft\" WHERE \"player\"='victor ignatjev';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"nhl_entry_draft\" (\n \"round\" real,\n \"player\" text,\n \"position\" text,\n \"nationality\" text,\n \"college_junior_club_team\" text\n);\n\nQuestion: Which player is from Sweden?" }, { "role": "assistant", "content": "SELECT \"player\" FROM \"nhl_entry_draft\" WHERE \"nationality\"='sweden';" } ]
[ { "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 \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What was the score on April 22?" }, { "role": "assistant", "content": "SELECT \"score\" FROM \"game_log\" WHERE \"date\"='april 22';" } ]
[ { "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 \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What opponent has a score of 1-3?" }, { "role": "assistant", "content": "SELECT \"opponent\" FROM \"game_log\" WHERE \"score\"='1-3';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What is the record for April 21?" }, { "role": "assistant", "content": "SELECT \"record\" FROM \"game_log\" WHERE \"date\"='april 21';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"nfl_draft\" (\n \"round\" real,\n \"pick\" real,\n \"player\" text,\n \"position\" text,\n \"school_club_team\" text\n);\n\nQuestion: Which Player has a Round larger than 5, and a School/Club Team of bethune-cookman?" }, { "role": "assistant", "content": "SELECT \"player\" FROM \"nfl_draft\" WHERE \"round\">5 AND \"school_club_team\"='bethune-cookman';" } ]