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 \"major_intersections\" (\n \"county\" text,\n \"location\" text,\n \"distance\" real,\n \"total\" real,\n \"notes\" text\n);\n\nQuestion: Which Notes have a Distance larger than 7, and a Location of aplin?" }, { "role": "assistant", "content": "SELECT \"notes\" FROM \"major_intersections\" WHERE \"distance\">7 AND \"location\"='aplin';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"major_intersections\" (\n \"county\" text,\n \"location\" text,\n \"distance\" real,\n \"total\" real,\n \"notes\" text\n);\n\nQuestion: How much Distance has a County of faulkner, and a Total smaller than 1.5?" }, { "role": "assistant", "content": "SELECT SUM(\"distance\") FROM \"major_intersections\" WHERE \"county\"='faulkner' AND \"total\"<1.5;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"major_intersections\" (\n \"county\" text,\n \"location\" text,\n \"distance\" real,\n \"total\" real,\n \"notes\" text\n);\n\nQuestion: How much Distance has Notes of north end terminus of ar 155?" }, { "role": "assistant", "content": "SELECT SUM(\"distance\") FROM \"major_intersections\" WHERE \"notes\"='north end terminus of ar 155';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"y\" (\n \"township\" text,\n \"county\" text,\n \"pop_2010\" real,\n \"land_sqmi\" real,\n \"water_sqmi\" real,\n \"latitude\" real,\n \"longitude\" real,\n \"geo_id\" real,\n \"ansi_code\" real\n);\n\nQuestion: How much Latitude has a Water (sqmi) smaller than 0?" }, { "role": "assistant", "content": "SELECT COUNT(\"latitude\") FROM \"y\" WHERE \"water_sqmi\"<0;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"y\" (\n \"township\" text,\n \"county\" text,\n \"pop_2010\" real,\n \"land_sqmi\" real,\n \"water_sqmi\" real,\n \"latitude\" real,\n \"longitude\" real,\n \"geo_id\" real,\n \"ansi_code\" real\n);\n\nQuestion: Which Land (sqmi) has a GEO ID smaller than 3800587900?" }, { "role": "assistant", "content": "SELECT MIN(\"land_sqmi\") FROM \"y\" WHERE \"geo_id\"<3800587900;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"y\" (\n \"township\" text,\n \"county\" text,\n \"pop_2010\" real,\n \"land_sqmi\" real,\n \"water_sqmi\" real,\n \"latitude\" real,\n \"longitude\" real,\n \"geo_id\" real,\n \"ansi_code\" real\n);\n\nQuestion: Which Water (sqmi) has a Township of yorktown, and a GEO ID smaller than 3802187940?" }, { "role": "assistant", "content": "SELECT MIN(\"water_sqmi\") FROM \"y\" WHERE \"township\"='yorktown' AND \"geo_id\"<3802187940;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"supplemental_first_round_selections\" (\n \"pick\" real,\n \"player\" text,\n \"team\" text,\n \"position\" text,\n \"school\" text\n);\n\nQuestion: What school had Jeff Urban playing at the p position?" }, { "role": "assistant", "content": "SELECT \"school\" FROM \"supplemental_first_round_selections\" WHERE \"position\"='p' AND \"player\"='jeff urban';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"supplemental_first_round_selections\" (\n \"pick\" real,\n \"player\" text,\n \"team\" text,\n \"position\" text,\n \"school\" text\n);\n\nQuestion: What school has the Kansas City Royals for a team?" }, { "role": "assistant", "content": "SELECT \"school\" FROM \"supplemental_first_round_selections\" WHERE \"team\"='kansas city royals';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"luchas_de_apuestas_record\" (\n \"wager\" text,\n \"winner\" text,\n \"loser\" text,\n \"location\" text,\n \"date\" text\n);\n\nQuestion: What is the date of the match where vampiro was the winner in Mexico City?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"luchas_de_apuestas_record\" WHERE \"location\"='mexico city' AND \"winner\"='vampiro';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"luchas_de_apuestas_record\" (\n \"wager\" text,\n \"winner\" text,\n \"loser\" text,\n \"location\" text,\n \"date\" text\n);\n\nQuestion: What is the wager on August 23, 1992 where vampiro was the winner?" }, { "role": "assistant", "content": "SELECT \"wager\" FROM \"luchas_de_apuestas_record\" WHERE \"winner\"='vampiro' AND \"date\"='august 23, 1992';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"luchas_de_apuestas_record\" (\n \"wager\" text,\n \"winner\" text,\n \"loser\" text,\n \"location\" text,\n \"date\" text\n);\n\nQuestion: What is the location where shocker was the winner?" }, { "role": "assistant", "content": "SELECT \"location\" FROM \"luchas_de_apuestas_record\" WHERE \"winner\"='shocker';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"luchas_de_apuestas_record\" (\n \"wager\" text,\n \"winner\" text,\n \"loser\" text,\n \"location\" text,\n \"date\" text\n);\n\nQuestion: What is the location where aaron grundy was the loser?" }, { "role": "assistant", "content": "SELECT \"location\" FROM \"luchas_de_apuestas_record\" WHERE \"loser\"='aaron grundy';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"singles_performance_timeline\" (\n \"tournament\" text,\n \"2000\" text,\n \"1999\" text,\n \"1998\" text,\n \"1997\" text,\n \"1996\" text,\n \"1995\" text,\n \"1994\" text,\n \"1993\" text,\n \"1992\" text,\n \"1991\" text\n);\n\nQuestion: What is the 1994 when QF is 1999?" }, { "role": "assistant", "content": "SELECT \"1994\" FROM \"singles_performance_timeline\" WHERE \"1999\"='qf';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"singles_performance_timeline\" (\n \"tournament\" text,\n \"2000\" text,\n \"1999\" text,\n \"1998\" text,\n \"1997\" text,\n \"1996\" text,\n \"1995\" text,\n \"1994\" text,\n \"1993\" text,\n \"1992\" text,\n \"1991\" text\n);\n\nQuestion: What is the 1991 when 1997 is 18?" }, { "role": "assistant", "content": "SELECT \"1991\" FROM \"singles_performance_timeline\" WHERE \"1997\"='18';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"singles_performance_timeline\" (\n \"tournament\" text,\n \"2000\" text,\n \"1999\" text,\n \"1998\" text,\n \"1997\" text,\n \"1996\" text,\n \"1995\" text,\n \"1994\" text,\n \"1993\" text,\n \"1992\" text,\n \"1991\" text\n);\n\nQuestion: What's the 1991 when 1999 is 14?" }, { "role": "assistant", "content": "SELECT \"1991\" FROM \"singles_performance_timeline\" WHERE \"1999\"='14';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"singles_performance_timeline\" (\n \"tournament\" text,\n \"2000\" text,\n \"1999\" text,\n \"1998\" text,\n \"1997\" text,\n \"1996\" text,\n \"1995\" text,\n \"1994\" text,\n \"1993\" text,\n \"1992\" text,\n \"1991\" text\n);\n\nQuestion: What's the 1996 when 1997 is 3R?" }, { "role": "assistant", "content": "SELECT \"1996\" FROM \"singles_performance_timeline\" WHERE \"1997\"='3r';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"singles_performance_timeline\" (\n \"tournament\" text,\n \"2000\" text,\n \"1999\" text,\n \"1998\" text,\n \"1997\" text,\n \"1996\" text,\n \"1995\" text,\n \"1994\" text,\n \"1993\" text,\n \"1992\" text,\n \"1991\" text\n);\n\nQuestion: What is 1994 when 1996 is 3R?" }, { "role": "assistant", "content": "SELECT \"1994\" FROM \"singles_performance_timeline\" WHERE \"1996\"='3r';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"singles_performance_timeline\" (\n \"tournament\" text,\n \"2000\" text,\n \"1999\" text,\n \"1998\" text,\n \"1997\" text,\n \"1996\" text,\n \"1995\" text,\n \"1994\" text,\n \"1993\" text,\n \"1992\" text,\n \"1991\" text\n);\n\nQuestion: What is 1996 during the US Open?" }, { "role": "assistant", "content": "SELECT \"1996\" FROM \"singles_performance_timeline\" WHERE \"tournament\"='us open';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"adsl_standards\" (\n \"version\" text,\n \"standard_name\" text,\n \"common_name\" text,\n \"downstream_rate\" text,\n \"upstream_rate\" text\n);\n\nQuestion: What's the standard name with an ADSL2 version and a 01.5 1.5 mbit/s downstream rate?" }, { "role": "assistant", "content": "SELECT \"standard_name\" FROM \"adsl_standards\" WHERE \"version\"='adsl2' AND \"downstream_rate\"='01.5 1.5 mbit/s';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"adsl_standards\" (\n \"version\" text,\n \"standard_name\" text,\n \"common_name\" text,\n \"downstream_rate\" text,\n \"upstream_rate\" text\n);\n\nQuestion: What's the downstream rate for the Itu g.992.2 having a version of ADSL?" }, { "role": "assistant", "content": "SELECT \"downstream_rate\" FROM \"adsl_standards\" WHERE \"version\"='adsl' AND \"standard_name\"='itu g.992.2';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"adsl_standards\" (\n \"version\" text,\n \"standard_name\" text,\n \"common_name\" text,\n \"downstream_rate\" text,\n \"upstream_rate\" text\n);\n\nQuestion: What's the version of Itu g.992.3 Annex J?" }, { "role": "assistant", "content": "SELECT \"version\" FROM \"adsl_standards\" WHERE \"standard_name\"='itu g.992.3 annex j';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"adsl_standards\" (\n \"version\" text,\n \"standard_name\" text,\n \"common_name\" text,\n \"downstream_rate\" text,\n \"upstream_rate\" text\n);\n\nQuestion: What's the version that has a 20.0 mbit/s downstream rate?" }, { "role": "assistant", "content": "SELECT \"version\" FROM \"adsl_standards\" WHERE \"downstream_rate\"='20.0 mbit/s';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"adsl_standards\" (\n \"version\" text,\n \"standard_name\" text,\n \"common_name\" text,\n \"downstream_rate\" text,\n \"upstream_rate\" text\n);\n\nQuestion: What's the standard name that has a common name of ADSL Over Pots and ADSL version?" }, { "role": "assistant", "content": "SELECT \"standard_name\" FROM \"adsl_standards\" WHERE \"version\"='adsl' AND \"common_name\"='adsl over pots';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"adsl_standards\" (\n \"version\" text,\n \"standard_name\" text,\n \"common_name\" text,\n \"downstream_rate\" text,\n \"upstream_rate\" text\n);\n\nQuestion: What's the upstream rate for Itu g.992.2 with a version of ADSL?" }, { "role": "assistant", "content": "SELECT \"upstream_rate\" FROM \"adsl_standards\" WHERE \"version\"='adsl' AND \"standard_name\"='itu g.992.2';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"w_league_records\" (\n \"name\" text,\n \"games\" text,\n \"w_league\" text,\n \"finals\" text,\n \"goals\" real,\n \"years\" text\n);\n\nQuestion: How many games does the player with 1 (0) finals and a w-league of 28 (1) have?" }, { "role": "assistant", "content": "SELECT \"games\" FROM \"w_league_records\" WHERE \"finals\"='1 (0)' AND \"w_league\"='28 (1)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"w_league_records\" (\n \"name\" text,\n \"games\" text,\n \"w_league\" text,\n \"finals\" text,\n \"goals\" real,\n \"years\" text\n);\n\nQuestion: What year had more than 2 goals and 11 (2) games?" }, { "role": "assistant", "content": "SELECT \"years\" FROM \"w_league_records\" WHERE \"goals\">2 AND \"games\"='11 (2)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"w_league_records\" (\n \"name\" text,\n \"games\" text,\n \"w_league\" text,\n \"finals\" text,\n \"goals\" real,\n \"years\" text\n);\n\nQuestion: What is the lowest number of goals with 8 (2) w-leagues?" }, { "role": "assistant", "content": "SELECT MIN(\"goals\") FROM \"w_league_records\" WHERE \"w_league\"='8 (2)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"goal_scorers\" (\n \"name\" text,\n \"la_liga\" real,\n \"copa_del_rey\" real,\n \"uefa_champions_league\" real,\n \"fifa_club_world_championship\" real,\n \"total\" real\n);\n\nQuestion: Which UEFA Champions League has a La Liga of 17, and a Copa del Rey larger than 0?" }, { "role": "assistant", "content": "SELECT MIN(\"uefa_champions_league\") FROM \"goal_scorers\" WHERE \"la_liga\"=17 AND \"copa_del_rey\">0;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"goal_scorers\" (\n \"name\" text,\n \"la_liga\" real,\n \"copa_del_rey\" real,\n \"uefa_champions_league\" real,\n \"fifa_club_world_championship\" real,\n \"total\" real\n);\n\nQuestion: Which Copa del Rey has a Name of guti, and a FIFA Club World Championship smaller than 0?" }, { "role": "assistant", "content": "SELECT SUM(\"copa_del_rey\") FROM \"goal_scorers\" WHERE \"name\"='guti' AND \"fifa_club_world_championship\"<0;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"goal_scorers\" (\n \"name\" text,\n \"la_liga\" real,\n \"copa_del_rey\" real,\n \"uefa_champions_league\" real,\n \"fifa_club_world_championship\" real,\n \"total\" real\n);\n\nQuestion: Which Copa del Rey has a La Liga smaller than 0?" }, { "role": "assistant", "content": "SELECT SUM(\"copa_del_rey\") FROM \"goal_scorers\" WHERE \"la_liga\"<0;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"goal_scorers\" (\n \"name\" text,\n \"la_liga\" real,\n \"copa_del_rey\" real,\n \"uefa_champions_league\" real,\n \"fifa_club_world_championship\" real,\n \"total\" real\n);\n\nQuestion: Which FIFA Club World Championship has a UEFA Champions League of 0, and a Total smaller than 3, and a Name of geremi?" }, { "role": "assistant", "content": "SELECT MIN(\"fifa_club_world_championship\") FROM \"goal_scorers\" WHERE \"uefa_champions_league\"=0 AND \"total\"<3 AND \"name\"='geremi';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"heat_2\" (\n \"rank\" real,\n \"athletes\" text,\n \"country\" text,\n \"time\" text,\n \"notes\" text\n);\n\nQuestion: What is the average rank for Hungary?" }, { "role": "assistant", "content": "SELECT AVG(\"rank\") FROM \"heat_2\" WHERE \"country\"='hungary';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"heat_2\" (\n \"rank\" real,\n \"athletes\" text,\n \"country\" text,\n \"time\" text,\n \"notes\" text\n);\n\nQuestion: What country has a time of 3:19.167?" }, { "role": "assistant", "content": "SELECT \"country\" FROM \"heat_2\" WHERE \"time\"='3:19.167';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"heat_2\" (\n \"rank\" real,\n \"athletes\" text,\n \"country\" text,\n \"time\" text,\n \"notes\" text\n);\n\nQuestion: What are the notes for the time at 3:19.167?" }, { "role": "assistant", "content": "SELECT \"notes\" FROM \"heat_2\" WHERE \"time\"='3:19.167';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"top_10_albums\" (\n \"rank\" real,\n \"artist\" text,\n \"album\" text,\n \"peak_position\" text,\n \"sales\" real,\n \"certification\" text\n);\n\nQuestion: What was the album Closer: The Best of Sarah Mclachlan certified as?" }, { "role": "assistant", "content": "SELECT \"certification\" FROM \"top_10_albums\" WHERE \"album\"='closer: the best of sarah mclachlan';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"superbike_race_2_classification\" (\n \"rider\" text,\n \"bike\" text,\n \"laps\" real,\n \"time\" text,\n \"grid\" real\n);\n\nQuestion: What is the average Laps that have gregorio lavilla as the rider, with a grid greater than 13?" }, { "role": "assistant", "content": "SELECT AVG(\"laps\") FROM \"superbike_race_2_classification\" WHERE \"rider\"='gregorio lavilla' AND \"grid\">13;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"superbike_race_2_classification\" (\n \"rider\" text,\n \"bike\" text,\n \"laps\" real,\n \"time\" text,\n \"grid\" real\n);\n\nQuestion: What bike has 26 as the grid?" }, { "role": "assistant", "content": "SELECT \"bike\" FROM \"superbike_race_2_classification\" WHERE \"grid\"=26;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"superbike_race_2_classification\" (\n \"rider\" text,\n \"bike\" text,\n \"laps\" real,\n \"time\" text,\n \"grid\" real\n);\n\nQuestion: What is the highest grid that has +44.866 as the time, with laps greater than 25?" }, { "role": "assistant", "content": "SELECT MAX(\"grid\") FROM \"superbike_race_2_classification\" WHERE \"time\"='+44.866' AND \"laps\">25;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"game\" real,\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: who has the high points on june 16?" }, { "role": "assistant", "content": "SELECT \"high_points\" FROM \"regular_season\" WHERE \"date\"='june 16';" } ]
[ { "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 \"tv_time\" text,\n \"attendance\" text\n);\n\nQuestion: What was the attendance on november 2, 2003?" }, { "role": "assistant", "content": "SELECT \"attendance\" FROM \"schedule\" WHERE \"date\"='november 2, 2003';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"final\" (\n \"name\" text,\n \"nationality\" text,\n \"1_85\" text,\n \"1_93\" text,\n \"height\" real\n);\n\nQuestion: What is the 1.93 that is 2.05 in height?" }, { "role": "assistant", "content": "SELECT \"1_93\" FROM \"final\" WHERE \"height\"=2.05;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"final\" (\n \"name\" text,\n \"nationality\" text,\n \"1_85\" text,\n \"1_93\" text,\n \"height\" real\n);\n\nQuestion: What is the 1.93 for Svetlana Shkolina?" }, { "role": "assistant", "content": "SELECT \"1_93\" FROM \"final\" WHERE \"name\"='svetlana shkolina';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"final\" (\n \"name\" text,\n \"nationality\" text,\n \"1_85\" text,\n \"1_93\" text,\n \"height\" real\n);\n\nQuestion: What is the name for the play from the Ukraine, and a 1.93 xxo?" }, { "role": "assistant", "content": "SELECT \"name\" FROM \"final\" WHERE \"nationality\"='ukraine' AND \"1_93\"='xxo';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"since_1963\" (\n \"season\" text,\n \"division\" text,\n \"rank\" text,\n \"avg_att\" text,\n \"europe\" text,\n \"top_goalscorer\" text,\n \"goals\" real\n);\n\nQuestion: What country in Europe is ranked 4, with top goal scorer Karl-Heinz Rummenigge with 14 goals?" }, { "role": "assistant", "content": "SELECT \"europe\" FROM \"since_1963\" WHERE \"rank\"='4' AND \"top_goalscorer\"='karl-heinz rummenigge' AND \"goals\"=14;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"since_1963\" (\n \"season\" text,\n \"division\" text,\n \"rank\" text,\n \"avg_att\" text,\n \"europe\" text,\n \"top_goalscorer\" text,\n \"goals\" real\n);\n\nQuestion: Wha is the rank for 52 574 avg. att?" }, { "role": "assistant", "content": "SELECT \"rank\" FROM \"since_1963\" WHERE \"avg_att\"='52 574';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"since_1963\" (\n \"season\" text,\n \"division\" text,\n \"rank\" text,\n \"avg_att\" text,\n \"europe\" text,\n \"top_goalscorer\" text,\n \"goals\" real\n);\n\nQuestion: What european country had more than 14 goals, and 52 538 avg att?" }, { "role": "assistant", "content": "SELECT \"europe\" FROM \"since_1963\" WHERE \"goals\">14 AND \"avg_att\"='52 538';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"by_name\" (\n \"country\" text,\n \"seasons\" text,\n \"championship_titles\" text,\n \"race_entries_starts\" text,\n \"poles\" real,\n \"wins\" real,\n \"podiums\" real,\n \"fastest_laps\" real,\n \"points\" text\n);\n\nQuestion: What's the least amount of wins for Germany in the 1999 season having 0 points?" }, { "role": "assistant", "content": "SELECT MIN(\"wins\") FROM \"by_name\" WHERE \"points\"='0' AND \"country\"='germany' AND \"seasons\"='1999';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"by_name\" (\n \"country\" text,\n \"seasons\" text,\n \"championship_titles\" text,\n \"race_entries_starts\" text,\n \"poles\" real,\n \"wins\" real,\n \"podiums\" real,\n \"fastest_laps\" real,\n \"points\" text\n);\n\nQuestion: How many wins when the points are 0 and podiums are less than 0?" }, { "role": "assistant", "content": "SELECT SUM(\"wins\") FROM \"by_name\" WHERE \"points\"='0' AND \"podiums\"<0;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"by_name\" (\n \"country\" text,\n \"seasons\" text,\n \"championship_titles\" text,\n \"race_entries_starts\" text,\n \"poles\" real,\n \"wins\" real,\n \"podiums\" real,\n \"fastest_laps\" real,\n \"points\" text\n);\n\nQuestion: What's the fastest laps during the 1995 season having poles & podiums at 0?" }, { "role": "assistant", "content": "SELECT SUM(\"fastest_laps\") FROM \"by_name\" WHERE \"poles\"=0 AND \"podiums\"=0 AND \"seasons\"='1995';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"awards_and_nominations_received_by_ang_l\" (\n \"award\" text,\n \"category\" text,\n \"year\" real,\n \"title\" text,\n \"result\" text\n);\n\nQuestion: How many years have an Award of venice film festival, and a Title of lust, caution?" }, { "role": "assistant", "content": "SELECT COUNT(\"year\") FROM \"awards_and_nominations_received_by_ang_l\" WHERE \"award\"='venice film festival' AND \"title\"='lust, caution';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"awards_and_nominations_received_by_ang_l\" (\n \"award\" text,\n \"category\" text,\n \"year\" real,\n \"title\" text,\n \"result\" text\n);\n\nQuestion: Which Category has a Year larger than 1996, and a Result of won, and a Title of brokeback mountain, and an Award of golden globe award?" }, { "role": "assistant", "content": "SELECT \"category\" FROM \"awards_and_nominations_received_by_ang_l\" WHERE \"year\">1996 AND \"result\"='won' AND \"title\"='brokeback mountain' AND \"award\"='golden globe award';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"awards_and_nominations_received_by_ang_l\" (\n \"award\" text,\n \"category\" text,\n \"year\" real,\n \"title\" text,\n \"result\" text\n);\n\nQuestion: Which Title has a Year smaller than 2001, and an Award of independent spirit awards?" }, { "role": "assistant", "content": "SELECT \"title\" FROM \"awards_and_nominations_received_by_ang_l\" WHERE \"year\"<2001 AND \"award\"='independent spirit awards';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"complete_formula_one_results\" (\n \"year\" real,\n \"entrant\" text,\n \"chassis\" text,\n \"engine\" text,\n \"points\" real\n);\n\nQuestion: Which chassis has 17 points?" }, { "role": "assistant", "content": "SELECT \"chassis\" FROM \"complete_formula_one_results\" WHERE \"points\"=17;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"all_time_table\" (\n \"league\" text,\n \"number_of_seasons\" real,\n \"total_games\" real,\n \"draw\" real,\n \"loss\" real\n);\n\nQuestion: What is the average draw for 186 games?" }, { "role": "assistant", "content": "SELECT AVG(\"draw\") FROM \"all_time_table\" WHERE \"total_games\"=186;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"all_time_table\" (\n \"league\" text,\n \"number_of_seasons\" real,\n \"total_games\" real,\n \"draw\" real,\n \"loss\" real\n);\n\nQuestion: What is the number of games for less than 2 seasons and more than 7 draws?" }, { "role": "assistant", "content": "SELECT SUM(\"total_games\") FROM \"all_time_table\" WHERE \"number_of_seasons\"<2 AND \"draw\">7;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"all_time_table\" (\n \"league\" text,\n \"number_of_seasons\" real,\n \"total_games\" real,\n \"draw\" real,\n \"loss\" real\n);\n\nQuestion: What is the total number of losses for less than 48 games, and less than 7 draws?" }, { "role": "assistant", "content": "SELECT COUNT(\"loss\") FROM \"all_time_table\" WHERE \"total_games\"<48 AND \"draw\"<7;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"all_time_table\" (\n \"league\" text,\n \"number_of_seasons\" real,\n \"total_games\" real,\n \"draw\" real,\n \"loss\" real\n);\n\nQuestion: What is the total number of games with more than 18 loses, a Total League, and more than 317 draws?" }, { "role": "assistant", "content": "SELECT COUNT(\"total_games\") FROM \"all_time_table\" WHERE \"loss\">18 AND \"league\"='total' AND \"draw\">317;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"draft_picks\" (\n \"round\" real,\n \"player\" text,\n \"position\" text,\n \"nationality\" text,\n \"college_junior_club_team_league\" text\n);\n\nQuestion: What is Bobby Ryan's nationality?" }, { "role": "assistant", "content": "SELECT \"nationality\" FROM \"draft_picks\" WHERE \"player\"='bobby ryan';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"race_calendar\" (\n \"race_title\" text,\n \"circuit\" text,\n \"city_state\" text,\n \"date\" text,\n \"winner\" text,\n \"team\" text\n);\n\nQuestion: What's the location of the team Peter Stuyvesant International Racing?" }, { "role": "assistant", "content": "SELECT \"city_state\" FROM \"race_calendar\" WHERE \"team\"='peter stuyvesant international racing';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"race_calendar\" (\n \"race_title\" text,\n \"circuit\" text,\n \"city_state\" text,\n \"date\" text,\n \"winner\" text,\n \"team\" text\n);\n\nQuestion: Who was the winner of the Adelaide International Raceway circuit?" }, { "role": "assistant", "content": "SELECT \"winner\" FROM \"race_calendar\" WHERE \"circuit\"='adelaide international raceway';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"race_calendar\" (\n \"race_title\" text,\n \"circuit\" text,\n \"city_state\" text,\n \"date\" text,\n \"winner\" text,\n \"team\" text\n);\n\nQuestion: What date has the Surfers Paradise International Raceway circuit?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"race_calendar\" WHERE \"circuit\"='surfers paradise international raceway';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"race_calendar\" (\n \"race_title\" text,\n \"circuit\" text,\n \"city_state\" text,\n \"date\" text,\n \"winner\" text,\n \"team\" text\n);\n\nQuestion: What is the race title of Dick Johnson Racing?" }, { "role": "assistant", "content": "SELECT \"race_title\" FROM \"race_calendar\" WHERE \"team\"='dick johnson racing';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"doubles_performance_timeline\" (\n \"tournament\" text,\n \"1989\" text,\n \"1990\" text,\n \"1991\" text,\n \"1992\" text,\n \"1993\" text,\n \"1994\" text,\n \"1995\" text,\n \"1996\" text,\n \"1997\" text,\n \"1998\" text,\n \"1999\" text,\n \"2000\" text,\n \"2001\" text,\n \"2002\" text,\n \"career_sr\" text,\n \"career_win_loss\" text\n);\n\nQuestion: What is the career win-loss for the ATP Masters Series?" }, { "role": "assistant", "content": "SELECT \"career_win_loss\" FROM \"doubles_performance_timeline\" WHERE \"1995\"='atp masters series';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table\" (\n \"name\" text,\n \"lwat\" real,\n \"100\" real,\n \"140\" real,\n \"180s\" real\n);\n\nQuestion: What's the least 180's of John Part having a LWAT less than 28 with 100+ less than 180?" }, { "role": "assistant", "content": "SELECT MIN(\"180s\") FROM \"table\" WHERE \"lwat\"<28 AND \"name\"='john part' AND \"100\"<180;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table\" (\n \"name\" text,\n \"lwat\" real,\n \"100\" real,\n \"140\" real,\n \"180s\" real\n);\n\nQuestion: What's the LWAT having more than 43 for 180s, 194 for 100+, and more than 128 for 140+?" }, { "role": "assistant", "content": "SELECT AVG(\"lwat\") FROM \"table\" WHERE \"180s\">43 AND \"100\"=194 AND \"140\">128;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table\" (\n \"name\" text,\n \"lwat\" real,\n \"100\" real,\n \"140\" real,\n \"180s\" real\n);\n\nQuestion: What's the total 140+ when the 100+ is 173?" }, { "role": "assistant", "content": "SELECT COUNT(\"140\") FROM \"table\" WHERE \"100\"=173;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table\" (\n \"name\" text,\n \"lwat\" real,\n \"100\" real,\n \"140\" real,\n \"180s\" real\n);\n\nQuestion: What's the 100+ when the 140+ is less than 128 and the LWAT of 29?" }, { "role": "assistant", "content": "SELECT SUM(\"100\") FROM \"table\" WHERE \"lwat\"=29 AND \"140\"<128;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_clubs\" (\n \"name\" text,\n \"nickname\" text,\n \"location\" text,\n \"home_ground_s\" text,\n \"coach\" text,\n \"captain\" text\n);\n\nQuestion: What's the Home ground(s) listed for the Name Melville Cricket Club?" }, { "role": "assistant", "content": "SELECT \"home_ground_s\" FROM \"current_clubs\" WHERE \"name\"='melville cricket club';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_clubs\" (\n \"name\" text,\n \"nickname\" text,\n \"location\" text,\n \"home_ground_s\" text,\n \"coach\" text,\n \"captain\" text\n);\n\nQuestion: What Name has the Captain Aaron Heal?" }, { "role": "assistant", "content": "SELECT \"name\" FROM \"current_clubs\" WHERE \"captain\"='aaron heal';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_clubs\" (\n \"name\" text,\n \"nickname\" text,\n \"location\" text,\n \"home_ground_s\" text,\n \"coach\" text,\n \"captain\" text\n);\n\nQuestion: What's the Nickname listed for the Name of University Cricket Club?" }, { "role": "assistant", "content": "SELECT \"nickname\" FROM \"current_clubs\" WHERE \"name\"='university cricket club';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_clubs\" (\n \"name\" text,\n \"nickname\" text,\n \"location\" text,\n \"home_ground_s\" text,\n \"coach\" text,\n \"captain\" text\n);\n\nQuestion: What Nickname has a Location of Southern River?" }, { "role": "assistant", "content": "SELECT \"nickname\" FROM \"current_clubs\" WHERE \"location\"='southern river';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_clubs\" (\n \"name\" text,\n \"nickname\" text,\n \"location\" text,\n \"home_ground_s\" text,\n \"coach\" text,\n \"captain\" text\n);\n\nQuestion: What is the Name listed for the Nickname of Storm?" }, { "role": "assistant", "content": "SELECT \"name\" FROM \"current_clubs\" WHERE \"nickname\"='storm';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_clubs\" (\n \"name\" text,\n \"nickname\" text,\n \"location\" text,\n \"home_ground_s\" text,\n \"coach\" text,\n \"captain\" text\n);\n\nQuestion: What Name has the Location of Bayswater?" }, { "role": "assistant", "content": "SELECT \"name\" FROM \"current_clubs\" WHERE \"location\"='bayswater';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"singles_as\" (\n \"year\" real,\n \"title\" text,\n \"from_album\" text,\n \"label\" text,\n \"label_nr\" text\n);\n\nQuestion: How many years have a Form album of the thing?" }, { "role": "assistant", "content": "SELECT SUM(\"year\") FROM \"singles_as\" WHERE \"from_album\"='the thing';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"singles_as\" (\n \"year\" real,\n \"title\" text,\n \"from_album\" text,\n \"label\" text,\n \"label_nr\" text\n);\n\nQuestion: Which Label-Nr has a Year smaller than 1968, and a Label of world pacific, and an album of chile con soul?" }, { "role": "assistant", "content": "SELECT \"label_nr\" FROM \"singles_as\" WHERE \"year\"<1968 AND \"label\"='world pacific' AND \"from_album\"='chile con soul';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"singles_as\" (\n \"year\" real,\n \"title\" text,\n \"from_album\" text,\n \"label\" text,\n \"label_nr\" text\n);\n\nQuestion: Which Year has a Label-Nr of 88146?" }, { "role": "assistant", "content": "SELECT \"year\" FROM \"singles_as\" WHERE \"label_nr\"='88146';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"singles_as\" (\n \"year\" real,\n \"title\" text,\n \"from_album\" text,\n \"label\" text,\n \"label_nr\" text\n);\n\nQuestion: How many years were there albums by heat wave?" }, { "role": "assistant", "content": "SELECT SUM(\"year\") FROM \"singles_as\" WHERE \"from_album\"='heat wave';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"singles_as\" (\n \"year\" real,\n \"title\" text,\n \"from_album\" text,\n \"label\" text,\n \"label_nr\" text\n);\n\nQuestion: Which Title has an album of tough talk, and a Label-Nr of x-371?" }, { "role": "assistant", "content": "SELECT \"title\" FROM \"singles_as\" WHERE \"from_album\"='tough talk' AND \"label_nr\"='x-371';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"approved_proposed\" (\n \"rank\" real,\n \"name\" text,\n \"status\" text,\n \"city\" text,\n \"floors\" real\n);\n\nQuestion: What is the lowest number of floors for the number 2 ranked Joyus Housing?" }, { "role": "assistant", "content": "SELECT MIN(\"floors\") FROM \"approved_proposed\" WHERE \"name\"='joyus housing' AND \"rank\"<2;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"approved_proposed\" (\n \"rank\" real,\n \"name\" text,\n \"status\" text,\n \"city\" text,\n \"floors\" real\n);\n\nQuestion: What is the number of floors when the r Rank larger than 41, and a City of parel?" }, { "role": "assistant", "content": "SELECT \"floors\" FROM \"approved_proposed\" WHERE \"rank\">41 AND \"city\"='parel';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"approved_proposed\" (\n \"rank\" real,\n \"name\" text,\n \"status\" text,\n \"city\" text,\n \"floors\" real\n);\n\nQuestion: What is the rank for the city of sewri?" }, { "role": "assistant", "content": "SELECT COUNT(\"rank\") FROM \"approved_proposed\" WHERE \"city\"='sewri';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"approved_proposed\" (\n \"rank\" real,\n \"name\" text,\n \"status\" text,\n \"city\" text,\n \"floors\" real\n);\n\nQuestion: What rank has a status of proposed, with 80 floors for Celestia Spaces 4?" }, { "role": "assistant", "content": "SELECT AVG(\"rank\") FROM \"approved_proposed\" WHERE \"status\"='proposed' AND \"floors\"=80 AND \"name\"='celestia spaces 4';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table_of_forms\" (\n \"english\" text,\n \"german\" text,\n \"dutch\" text,\n \"latin\" text,\n \"romanian\" text,\n \"portuguese\" text,\n \"spanish\" text,\n \"italian\" text,\n \"french\" text,\n \"greek_modern\" text,\n \"bulgarian\" text,\n \"macedonian\" text,\n \"polish_extinct\" text\n);\n\nQuestion: What's the English Pluperfect when the Bulgarian is \u0431\u044f\u0445\u0430 \u0447\u0443\u043b\u0438?" }, { "role": "assistant", "content": "SELECT \"english\" FROM \"table_of_forms\" WHERE \"bulgarian\"='\u0431\u044f\u0445\u0430 \u0447\u0443\u043b\u0438';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table_of_forms\" (\n \"english\" text,\n \"german\" text,\n \"dutch\" text,\n \"latin\" text,\n \"romanian\" text,\n \"portuguese\" text,\n \"spanish\" text,\n \"italian\" text,\n \"french\" text,\n \"greek_modern\" text,\n \"bulgarian\" text,\n \"macedonian\" text,\n \"polish_extinct\" text\n);\n\nQuestion: What's the Italian Pluperfect when the English is We Had Heard?" }, { "role": "assistant", "content": "SELECT \"italian\" FROM \"table_of_forms\" WHERE \"english\"='we had heard';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table_of_forms\" (\n \"english\" text,\n \"german\" text,\n \"dutch\" text,\n \"latin\" text,\n \"romanian\" text,\n \"portuguese\" text,\n \"spanish\" text,\n \"italian\" text,\n \"french\" text,\n \"greek_modern\" text,\n \"bulgarian\" text,\n \"macedonian\" text,\n \"polish_extinct\" text\n);\n\nQuestion: What is the Portuguese Pluperfect when the French is Ils/Elles Avaient Entendu?" }, { "role": "assistant", "content": "SELECT \"portuguese\" FROM \"table_of_forms\" WHERE \"french\"='ils/elles avaient entendu';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table_of_forms\" (\n \"english\" text,\n \"german\" text,\n \"dutch\" text,\n \"latin\" text,\n \"romanian\" text,\n \"portuguese\" text,\n \"spanish\" text,\n \"italian\" text,\n \"french\" text,\n \"greek_modern\" text,\n \"bulgarian\" text,\n \"macedonian\" text,\n \"polish_extinct\" text\n);\n\nQuestion: What's the German Pluperfect when the Macedonian is \u0431\u0435\u0448\u0435 \u0441\u043b\u0443\u0448\u043d\u0430\u043b/-\u0430/-\u043e?" }, { "role": "assistant", "content": "SELECT \"german\" FROM \"table_of_forms\" WHERE \"macedonian\"='\u0431\u0435\u0448\u0435 \u0441\u043b\u0443\u0448\u043d\u0430\u043b/-\u0430/-\u043e';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"medals_table\" (\n \"rank\" text,\n \"nation\" text,\n \"gold\" real,\n \"silver\" real,\n \"bronze\" real,\n \"total\" real\n);\n\nQuestion: What is the least amount of silver for Italy with a total less than 5?" }, { "role": "assistant", "content": "SELECT MIN(\"silver\") FROM \"medals_table\" WHERE \"nation\"='italy' AND \"total\"<5;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"medals_table\" (\n \"rank\" text,\n \"nation\" text,\n \"gold\" real,\n \"silver\" real,\n \"bronze\" real,\n \"total\" real\n);\n\nQuestion: What is the total for Austria when there is less than 1 bronze?" }, { "role": "assistant", "content": "SELECT AVG(\"total\") FROM \"medals_table\" WHERE \"nation\"='austria' AND \"bronze\"<1;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"medals_table\" (\n \"rank\" text,\n \"nation\" text,\n \"gold\" real,\n \"silver\" real,\n \"bronze\" real,\n \"total\" real\n);\n\nQuestion: What is the total when silver is more than 3, and rank is 2?" }, { "role": "assistant", "content": "SELECT MAX(\"total\") FROM \"medals_table\" WHERE \"silver\">3 AND \"rank\"='2';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"medals_table\" (\n \"rank\" text,\n \"nation\" text,\n \"gold\" real,\n \"silver\" real,\n \"bronze\" real,\n \"total\" real\n);\n\nQuestion: What is the gold number when total is more than 1, and bronze is 0, and rank is 5?" }, { "role": "assistant", "content": "SELECT SUM(\"gold\") FROM \"medals_table\" WHERE \"total\">1 AND \"bronze\"=0 AND \"rank\"='5';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"road_to_redemption_presented_by_nike\" (\n \"episode\" text,\n \"date\" text,\n \"time\" text,\n \"network\" text,\n \"length\" text\n);\n\nQuestion: What date was the episode that aired at 7:30 pm ET?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"road_to_redemption_presented_by_nike\" WHERE \"time\"='7:30 pm et';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"road_to_redemption_presented_by_nike\" (\n \"episode\" text,\n \"date\" text,\n \"time\" text,\n \"network\" text,\n \"length\" text\n);\n\nQuestion: What date did episode one air on?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"road_to_redemption_presented_by_nike\" WHERE \"episode\"='one';" } ]
[ { "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: At what venue was the 2010 FIFA World Cup Qualification?" }, { "role": "assistant", "content": "SELECT \"venue\" FROM \"international_goals\" WHERE \"competition\"='2010 fifa world cup qualification';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"records\" (\n \"world_record\" text,\n \"snatch\" text,\n \"mu_shuangshuang_chn\" text,\n \"139kg\" text,\n \"doha_qatar\" text\n);\n\nQuestion: What's the snatch when the 139kg was 305kg and the Olympic Record was the world record?" }, { "role": "assistant", "content": "SELECT \"snatch\" FROM \"records\" WHERE \"world_record\"='olympic record' AND \"139kg\"='305kg';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"major_tournaments\" (\n \"year\" real,\n \"tournament\" text,\n \"venue\" text,\n \"discipline\" text,\n \"result\" text,\n \"extra\" text\n);\n\nQuestion: What is the discipline for the summer Olympics in 2008?" }, { "role": "assistant", "content": "SELECT \"discipline\" FROM \"major_tournaments\" WHERE \"tournament\"='summer olympics' AND \"year\"=2008;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"major_tournaments\" (\n \"year\" real,\n \"tournament\" text,\n \"venue\" text,\n \"discipline\" text,\n \"result\" text,\n \"extra\" text\n);\n\nQuestion: What venue has an extra of 45.08 S?" }, { "role": "assistant", "content": "SELECT \"venue\" FROM \"major_tournaments\" WHERE \"extra\"='45.08 s';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"major_tournaments\" (\n \"year\" real,\n \"tournament\" text,\n \"venue\" text,\n \"discipline\" text,\n \"result\" text,\n \"extra\" text\n);\n\nQuestion: What is the extra when the result is 4th at the NCAA Championships?" }, { "role": "assistant", "content": "SELECT \"extra\" FROM \"major_tournaments\" WHERE \"result\"='4th' AND \"tournament\"='ncaa championships';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"major_tournaments\" (\n \"year\" real,\n \"tournament\" text,\n \"venue\" text,\n \"discipline\" text,\n \"result\" text,\n \"extra\" text\n);\n\nQuestion: What tournament had an extra of 3:06.94 s?" }, { "role": "assistant", "content": "SELECT \"tournament\" FROM \"major_tournaments\" WHERE \"extra\"='3:06.94 s';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"heat_2\" (\n \"rank\" real,\n \"lane\" real,\n \"name\" text,\n \"nationality\" text,\n \"time\" real\n);\n\nQuestion: Name the lowest Time of jamaica with a Lane larger than 4 and a Rank smaller than 1?" }, { "role": "assistant", "content": "SELECT MIN(\"time\") FROM \"heat_2\" WHERE \"nationality\"='jamaica' AND \"lane\">4 AND \"rank\"<1;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"heat_2\" (\n \"rank\" real,\n \"lane\" real,\n \"name\" text,\n \"nationality\" text,\n \"time\" real\n);\n\nQuestion: Name the lowest Rank with a Lane of 5 and a Time smaller than 11.06?" }, { "role": "assistant", "content": "SELECT MIN(\"rank\") FROM \"heat_2\" WHERE \"lane\"=5 AND \"time\"<11.06;" } ]