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 \"lifetime_grosses\" (\n \"year\" real,\n \"film\" text,\n \"budget\" text,\n \"domestic_box_office\" text,\n \"foreign_box_office\" text,\n \"total\" text,\n \"us_dvd_sales\" text,\n \"total_with_dvd_sales\" text\n);\n\nQuestion: What was the domestic box office for the film that had a foreign box office of $26,600,000?" }, { "role": "assistant", "content": "SELECT \"domestic_box_office\" FROM \"lifetime_grosses\" WHERE \"foreign_box_office\"='$26,600,000';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"lifetime_grosses\" (\n \"year\" real,\n \"film\" text,\n \"budget\" text,\n \"domestic_box_office\" text,\n \"foreign_box_office\" text,\n \"total\" text,\n \"us_dvd_sales\" text,\n \"total_with_dvd_sales\" text\n);\n\nQuestion: What was the domestic box office for \"House on Haunted Hill\"?" }, { "role": "assistant", "content": "SELECT \"domestic_box_office\" FROM \"lifetime_grosses\" WHERE \"film\"='House on Haunted Hill';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"lifetime_grosses\" (\n \"year\" real,\n \"film\" text,\n \"budget\" text,\n \"domestic_box_office\" text,\n \"foreign_box_office\" text,\n \"total\" text,\n \"us_dvd_sales\" text,\n \"total_with_dvd_sales\" text\n);\n\nQuestion: What was the budget for \"Thirteen Ghosts\"?" }, { "role": "assistant", "content": "SELECT \"budget\" FROM \"lifetime_grosses\" WHERE \"film\"='Thirteen Ghosts';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_member_schools\" (\n \"school\" text,\n \"location\" text,\n \"enrolment\" real,\n \"founded\" real,\n \"denomination\" text,\n \"boys_girls\" text,\n \"day_boarding\" text,\n \"school_colors\" text\n);\n\nQuestion: What is every school for the Adelaide location?" }, { "role": "assistant", "content": "SELECT \"school\" FROM \"current_member_schools\" WHERE \"location\"='Adelaide';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_member_schools\" (\n \"school\" text,\n \"location\" text,\n \"enrolment\" real,\n \"founded\" real,\n \"denomination\" text,\n \"boys_girls\" text,\n \"day_boarding\" text,\n \"school_colors\" text\n);\n\nQuestion: How many values for founded when enrollment is 850?" }, { "role": "assistant", "content": "SELECT COUNT(\"founded\") FROM \"current_member_schools\" WHERE \"enrolment\"=850;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_member_schools\" (\n \"school\" text,\n \"location\" text,\n \"enrolment\" real,\n \"founded\" real,\n \"denomination\" text,\n \"boys_girls\" text,\n \"day_boarding\" text,\n \"school_colors\" text\n);\n\nQuestion: What is every denomination for the school Seymour college?" }, { "role": "assistant", "content": "SELECT \"denomination\" FROM \"current_member_schools\" WHERE \"school\"='Seymour College';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2011_events\" (\n \"date\" text,\n \"event_num\" text,\n \"event\" text,\n \"winner\" text,\n \"prize\" text,\n \"entries\" text,\n \"prize_pool\" text,\n \"elapsed_time\" text\n);\n\nQuestion: Event number 38m was held on which date? " }, { "role": "assistant", "content": "SELECT \"date\" FROM \"2011_events\" WHERE \"event_num\"='38M';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2011_events\" (\n \"date\" text,\n \"event_num\" text,\n \"event\" text,\n \"winner\" text,\n \"prize\" text,\n \"entries\" text,\n \"prize_pool\" text,\n \"elapsed_time\" text\n);\n\nQuestion: Who won the $109 no limit hold'em w/rebuys [turbo]?" }, { "role": "assistant", "content": "SELECT \"winner\" FROM \"2011_events\" WHERE \"event\"='$109 No Limit Hold''em w/rebuys [Turbo]';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2011_events\" (\n \"date\" text,\n \"event_num\" text,\n \"event\" text,\n \"winner\" text,\n \"prize\" text,\n \"entries\" text,\n \"prize_pool\" text,\n \"elapsed_time\" text\n);\n\nQuestion: Which event had 25,883 entries? " }, { "role": "assistant", "content": "SELECT \"event\" FROM \"2011_events\" WHERE \"entries\"='25,883';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2011_events\" (\n \"date\" text,\n \"event_num\" text,\n \"event\" text,\n \"winner\" text,\n \"prize\" text,\n \"entries\" text,\n \"prize_pool\" text,\n \"elapsed_time\" text\n);\n\nQuestion: How many categories for elapsed time exist for the $16.50 fixed-limit badugi game?" }, { "role": "assistant", "content": "SELECT COUNT(\"elapsed_time\") FROM \"2011_events\" WHERE \"event\"='$16.50 Fixed-Limit Badugi';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2011_events\" (\n \"date\" text,\n \"event_num\" text,\n \"event\" text,\n \"winner\" text,\n \"prize\" text,\n \"entries\" text,\n \"prize_pool\" text,\n \"elapsed_time\" text\n);\n\nQuestion: How many elapsed times were recorded for the game that had a prize pool of $1,678,200?" }, { "role": "assistant", "content": "SELECT COUNT(\"elapsed_time\") FROM \"2011_events\" WHERE \"prize_pool\"='$1,678,200';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"slovak_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What year did jaroslav vojtek category:articles with hcards Direct?" }, { "role": "assistant", "content": "SELECT \"year_ceremony\" FROM \"submissions\" WHERE \"director\"='Jaroslav Vojtek Category:Articles with hCards';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"slovak_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What was the result for Gypsy?" }, { "role": "assistant", "content": "SELECT \"result\" FROM \"submissions\" WHERE \"film_title_used_in_nomination\"='Gypsy';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"slovak_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: HOw many films did martin repka category:articles with hcards direct?" }, { "role": "assistant", "content": "SELECT COUNT(\"film_title_used_in_nomination\") FROM \"submissions\" WHERE \"director\"='Martin Repka Category:Articles with hCards';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"slovak_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What was the result for City of the Sun?" }, { "role": "assistant", "content": "SELECT \"result\" FROM \"submissions\" WHERE \"film_title_used_in_nomination\"='City of the Sun';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"language_s\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What was the language for the movie \"Late Bloomers\"?" }, { "role": "assistant", "content": "SELECT \"language_s\" FROM \"submissions\" WHERE \"film_title_used_in_nomination\"='Late Bloomers';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"language_s\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: How many original titles were listed as \"If the Sun Never Returns\"?" }, { "role": "assistant", "content": "SELECT COUNT(\"original_title\") FROM \"submissions\" WHERE \"film_title_used_in_nomination\"='If the Sun Never Returns';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"language_s\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What was the language of \"Mein Name Ist Bach\"?" }, { "role": "assistant", "content": "SELECT \"language_s\" FROM \"submissions\" WHERE \"film_title_used_in_nomination\"='Mein Name Ist Bach';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"language_s\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What was the year for the film \"Vitus\"?" }, { "role": "assistant", "content": "SELECT \"year_ceremony\" FROM \"submissions\" WHERE \"original_title\"='Vitus';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"language_s\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: How many films are titled \"Dans la Ville Blanche\"?" }, { "role": "assistant", "content": "SELECT COUNT(\"film_title_used_in_nomination\") FROM \"submissions\" WHERE \"original_title\"='Dans la ville blanche';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22053239_1\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: How many of the writers had 5.35 viewers?" }, { "role": "assistant", "content": "SELECT COUNT(\"written_by\") FROM \"table1_22053239_1\" WHERE \"u_s_viewers_millions\"='5.35';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2012_events\" (\n \"date\" text,\n \"event_num\" text,\n \"event\" text,\n \"winner\" text,\n \"prize\" text,\n \"entries\" text,\n \"prize_pool\" text,\n \"elapsed_time\" text\n);\n\nQuestion: What was the elapsed time for the championship that had $9,377.42 in prize money? " }, { "role": "assistant", "content": "SELECT \"elapsed_time\" FROM \"2012_events\" WHERE \"prize\"='$9,377.42';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2012_events\" (\n \"date\" text,\n \"event_num\" text,\n \"event\" text,\n \"winner\" text,\n \"prize\" text,\n \"entries\" text,\n \"prize_pool\" text,\n \"elapsed_time\" text\n);\n\nQuestion: Who won a prize pool of $61,100?" }, { "role": "assistant", "content": "SELECT \"winner\" FROM \"2012_events\" WHERE \"prize_pool\"='$61,100';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2012_events\" (\n \"date\" text,\n \"event_num\" text,\n \"event\" text,\n \"winner\" text,\n \"prize\" text,\n \"entries\" text,\n \"prize_pool\" text,\n \"elapsed_time\" text\n);\n\nQuestion: What was the prize pool for the event number 27H? " }, { "role": "assistant", "content": "SELECT \"prize_pool\" FROM \"2012_events\" WHERE \"event_num\"='27H';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2012_events\" (\n \"date\" text,\n \"event_num\" text,\n \"event\" text,\n \"winner\" text,\n \"prize\" text,\n \"entries\" text,\n \"prize_pool\" text,\n \"elapsed_time\" text\n);\n\nQuestion: What is the event name with the number 8M? " }, { "role": "assistant", "content": "SELECT \"event\" FROM \"2012_events\" WHERE \"event_num\"='8M';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"population\" (\n \"country\" text,\n \"area_000s\" text,\n \"1950_mil\" text,\n \"1970_mil\" text,\n \"1980_mil\" text,\n \"1985_mil\" text,\n \"annual_growth_1950_1985\" text,\n \"density_1980\" text\n);\n\nQuestion: Name the total number 1980 mil for soviet union" }, { "role": "assistant", "content": "SELECT COUNT(\"1980_mil\") FROM \"population\" WHERE \"country\"='Soviet Union';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"population\" (\n \"country\" text,\n \"area_000s\" text,\n \"1950_mil\" text,\n \"1970_mil\" text,\n \"1980_mil\" text,\n \"1985_mil\" text,\n \"annual_growth_1950_1985\" text,\n \"density_1980\" text\n);\n\nQuestion: Name the country for 37.23 1985" }, { "role": "assistant", "content": "SELECT \"country\" FROM \"population\" WHERE \"1985_mil\"='37.23';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"population\" (\n \"country\" text,\n \"area_000s\" text,\n \"1950_mil\" text,\n \"1970_mil\" text,\n \"1980_mil\" text,\n \"1985_mil\" text,\n \"annual_growth_1950_1985\" text,\n \"density_1980\" text\n);\n\nQuestion: Name the country for 2.16 " }, { "role": "assistant", "content": "SELECT \"country\" FROM \"population\" WHERE \"1970_mil\"='2.16';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"languages\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: How many languages have elles as the film title used in nomination?" }, { "role": "assistant", "content": "SELECT COUNT(\"languages\") FROM \"submissions\" WHERE \"film_title_used_in_nomination\"='Elles';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"languages\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: How many languages is refractaire as the film title used in nomination?" }, { "role": "assistant", "content": "SELECT COUNT(\"languages\") FROM \"submissions\" WHERE \"film_title_used_in_nomination\"='Refractaire';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"languages\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: How many languages have le roman de renart as the original title?" }, { "role": "assistant", "content": "SELECT COUNT(\"languages\") FROM \"submissions\" WHERE \"original_title\"='Le Roman de Renart';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"languages\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: Who is the director of the original title perl oder pica?" }, { "role": "assistant", "content": "SELECT \"director\" FROM \"submissions\" WHERE \"original_title\"='Perl oder Pica';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"languages\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What is the result of the 2005 (78th) year ceremony?" }, { "role": "assistant", "content": "SELECT \"result\" FROM \"submissions\" WHERE \"year_ceremony\"='2005 (78th)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22078691_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: What is the title that has 14.59 u.s. viewers (millions)?" }, { "role": "assistant", "content": "SELECT \"title\" FROM \"table1_22078691_2\" WHERE \"u_s_viewers_millions\"='14.59';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22078691_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: How many number of series have the title \"call of silence\"?" }, { "role": "assistant", "content": "SELECT \"no_in_series\" FROM \"table1_22078691_2\" WHERE \"title\"='\\\"Call of Silence\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22078691_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: What is the title that had 13.59 u.s. viewers (millions)?" }, { "role": "assistant", "content": "SELECT \"title\" FROM \"table1_22078691_2\" WHERE \"u_s_viewers_millions\"='13.59';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"lpga_tour_career_summary\" (\n \"year\" real,\n \"tournaments_played\" real,\n \"cuts_made\" real,\n \"wins\" real,\n \"3rds\" real,\n \"top_10s\" real,\n \"best_finish\" text,\n \"earnings\" text,\n \"money_list_rank\" real,\n \"scoring_average\" text\n);\n\nQuestion: If the earning amount is $309,886, what is the money list ranking?" }, { "role": "assistant", "content": "SELECT \"money_list_rank\" FROM \"lpga_tour_career_summary\" WHERE \"earnings\"='309,886';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"lpga_tour_career_summary\" (\n \"year\" real,\n \"tournaments_played\" real,\n \"cuts_made\" real,\n \"wins\" real,\n \"3rds\" real,\n \"top_10s\" real,\n \"best_finish\" text,\n \"earnings\" text,\n \"money_list_rank\" real,\n \"scoring_average\" text\n);\n\nQuestion: What was the maximum number of wins?" }, { "role": "assistant", "content": "SELECT MAX(\"wins\") FROM \"lpga_tour_career_summary\";" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"lpga_tour_career_summary\" (\n \"year\" real,\n \"tournaments_played\" real,\n \"cuts_made\" real,\n \"wins\" real,\n \"3rds\" real,\n \"top_10s\" real,\n \"best_finish\" text,\n \"earnings\" text,\n \"money_list_rank\" real,\n \"scoring_average\" text\n);\n\nQuestion: If the year is 2010, what was the average score?" }, { "role": "assistant", "content": "SELECT \"scoring_average\" FROM \"lpga_tour_career_summary\" WHERE \"year\"=2010;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"race_calendar\" (\n \"event\" real,\n \"round\" real,\n \"circuit\" text,\n \"date\" text,\n \"pole_position\" text,\n \"fastest_lap\" text,\n \"winning_driver\" text,\n \"winning_team\" text\n);\n\nQuestion: How many times did Tim Macrow and Joey Foster both got the fastest lap and pole position respectively?" }, { "role": "assistant", "content": "SELECT COUNT(\"event\") FROM \"race_calendar\" WHERE \"fastest_lap\"='Tim Macrow' AND \"pole_position\"='Joey Foster';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"race_calendar\" (\n \"event\" real,\n \"round\" real,\n \"circuit\" text,\n \"date\" text,\n \"pole_position\" text,\n \"fastest_lap\" text,\n \"winning_driver\" text,\n \"winning_team\" text\n);\n\nQuestion: What was the winning team where Tim Macrow won the fastest lap on Queensland Raceway circuit?" }, { "role": "assistant", "content": "SELECT \"winning_team\" FROM \"race_calendar\" WHERE \"circuit\"='Queensland Raceway' AND \"fastest_lap\"='Tim Macrow';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22078972_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: What's the series number of the episode whose writer is David North?" }, { "role": "assistant", "content": "SELECT MAX(\"no_in_series\") FROM \"table1_22078972_2\" WHERE \"written_by\"='David North';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22078972_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: What's the series number of the episode seen by 17.04 million people in the US?" }, { "role": "assistant", "content": "SELECT MAX(\"no_in_series\") FROM \"table1_22078972_2\" WHERE \"u_s_viewers_millions\"='17.04';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22078972_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: What's the title of the episode first seen by 18.15 million people in the US?" }, { "role": "assistant", "content": "SELECT \"title\" FROM \"table1_22078972_2\" WHERE \"u_s_viewers_millions\"='18.15';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22078972_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: How many millions of people in the US saw the episode with series number 103?" }, { "role": "assistant", "content": "SELECT \"u_s_viewers_millions\" FROM \"table1_22078972_2\" WHERE \"no_in_series\"=103;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22078906_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_airdate\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: What number episode in the series was watched by 15.89 million U.S. viewers? " }, { "role": "assistant", "content": "SELECT \"no_in_series\" FROM \"table1_22078906_2\" WHERE \"u_s_viewers_millions\"='15.89';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22078906_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_airdate\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: What is the title of the episode directed by William Webb? " }, { "role": "assistant", "content": "SELECT \"title\" FROM \"table1_22078906_2\" WHERE \"directed_by\"='William Webb';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22078906_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_airdate\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: How many millions of U.S. viewers watched the episode titled \"Once a Hero\"?" }, { "role": "assistant", "content": "SELECT \"u_s_viewers_millions\" FROM \"table1_22078906_2\" WHERE \"title\"='\\\"Once a Hero\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22078906_2\" (\n \"no_in_series\" real,\n \"no_in_season\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_airdate\" text,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: Who wrote the episode titled \"In the Dark\"?" }, { "role": "assistant", "content": "SELECT \"written_by\" FROM \"table1_22078906_2\" WHERE \"title\"='\\\"In the Dark\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"finals\" (\n \"season\" text,\n \"champion\" text,\n \"runner_up\" text,\n \"result\" text,\n \"league_mvp\" text,\n \"finals_mvp\" text,\n \"winning_coach\" text\n);\n\nQuestion: What was the final score when River Plate was the runner-up?" }, { "role": "assistant", "content": "SELECT \"result\" FROM \"finals\" WHERE \"runner_up\"='River Plate';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"campaign_expenses\" (\n \"candidate_party\" text,\n \"amount_raised_php\" text,\n \"amount_spent_php\" text,\n \"votes\" real,\n \"spent_per_vote_php\" text,\n \"spent_per_voter_php\" text\n);\n\nQuestion: What was spent per voter when total amount spent was 210,280,000?" }, { "role": "assistant", "content": "SELECT \"spent_per_voter_php\" FROM \"campaign_expenses\" WHERE \"amount_spent_php\"='210,280,000';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"campaign_expenses\" (\n \"candidate_party\" text,\n \"amount_raised_php\" text,\n \"amount_spent_php\" text,\n \"votes\" real,\n \"spent_per_vote_php\" text,\n \"spent_per_voter_php\" text\n);\n\nQuestion: What was spent per voter when the spent per vote was 20.07?" }, { "role": "assistant", "content": "SELECT \"spent_per_voter_php\" FROM \"campaign_expenses\" WHERE \"spent_per_vote_php\"='20.07';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22123920_4\" (\n \"dates_mdy\" text,\n \"gross_sales\" text,\n \"tickets_sold_available\" text,\n \"shows_sellout\" text,\n \"sellout_pct\" text\n);\n\nQuestion: Between November 25\u201330, 2008 the sellout rate was at 75%, indicating that the ration between shows to sellout was what?" }, { "role": "assistant", "content": "SELECT \"shows_sellout\" FROM \"table1_22123920_4\" WHERE \"sellout_pct\"='75%';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22123920_4\" (\n \"dates_mdy\" text,\n \"gross_sales\" text,\n \"tickets_sold_available\" text,\n \"shows_sellout\" text,\n \"sellout_pct\" text\n);\n\nQuestion: During the period in which gross sales totals for \"The Show Girl Must Go On\" reached $2,628,457, what did the numbers show for tickets sold/ available at the box office? " }, { "role": "assistant", "content": "SELECT \"tickets_sold_available\" FROM \"table1_22123920_4\" WHERE \"gross_sales\"='$2,628,457';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22123920_4\" (\n \"dates_mdy\" text,\n \"gross_sales\" text,\n \"tickets_sold_available\" text,\n \"shows_sellout\" text,\n \"sellout_pct\" text\n);\n\nQuestion: Which specific dates encompass the time period when \"The Show Girl Must Go On\" showed a gross sales figure total of $2,877,906?" }, { "role": "assistant", "content": "SELECT \"dates_mdy\" FROM \"table1_22123920_4\" WHERE \"gross_sales\"='$2,877,906';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22102732_1\" (\n \"year_ceremony\" text,\n \"english_title\" text,\n \"spanish_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What year and the corresponding ceremony was the english titled movie \"time out\" submitted?" }, { "role": "assistant", "content": "SELECT \"year_ceremony\" FROM \"table1_22102732_1\" WHERE \"english_title\"='Time Out';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22102732_1\" (\n \"year_ceremony\" text,\n \"english_title\" text,\n \"spanish_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: How many english titles were directed by carlos moreno?" }, { "role": "assistant", "content": "SELECT COUNT(\"english_title\") FROM \"table1_22102732_1\" WHERE \"director\"='Carlos Moreno';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"honour_roll\" (\n \"year\" real,\n \"w_l_d\" text,\n \"position\" text,\n \"chairman\" text,\n \"ceo\" text,\n \"coach\" text,\n \"captain\" text,\n \"vice_captain\" text,\n \"best_and_fairest\" text,\n \"leading_goalkicker\" text\n);\n\nQuestion: How many years was their W/L/D record 13:10:0?" }, { "role": "assistant", "content": "SELECT COUNT(\"chairman\") FROM \"honour_roll\" WHERE \"w_l_d\"='13:10:0';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22098274_1\" (\n \"date\" text,\n \"time\" text,\n \"opponent\" text,\n \"ranknum\" text,\n \"site\" text,\n \"result\" text,\n \"attendance\" text,\n \"winning_pitcher\" text,\n \"losing_pitcher\" text\n);\n\nQuestion: What is the rank # of kelli miller the winning pitcher?" }, { "role": "assistant", "content": "SELECT \"ranknum\" FROM \"table1_22098274_1\" WHERE \"winning_pitcher\"='Kelli Miller';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22098274_1\" (\n \"date\" text,\n \"time\" text,\n \"opponent\" text,\n \"ranknum\" text,\n \"site\" text,\n \"result\" text,\n \"attendance\" text,\n \"winning_pitcher\" text,\n \"losing_pitcher\" text\n);\n\nQuestion: How many number of site have May 1, 2004 as the date?" }, { "role": "assistant", "content": "SELECT COUNT(\"site\") FROM \"table1_22098274_1\" WHERE \"date\"='May 1, 2004';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22098274_1\" (\n \"date\" text,\n \"time\" text,\n \"opponent\" text,\n \"ranknum\" text,\n \"site\" text,\n \"result\" text,\n \"attendance\" text,\n \"winning_pitcher\" text,\n \"losing_pitcher\" text\n);\n\nQuestion: At what time is the site usf softball field \u2022 tampa, fl and w4-0 is the result?" }, { "role": "assistant", "content": "SELECT \"time\" FROM \"table1_22098274_1\" WHERE \"site\"='USF Softball Field \u2022 Tampa, FL' AND \"result\"='W4-0';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22118197_1\" (\n \"year_ceremony\" text,\n \"english_title\" text,\n \"portuguese_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What was the result for the film with the English name of Morning Undersea? " }, { "role": "assistant", "content": "SELECT \"result\" FROM \"table1_22118197_1\" WHERE \"english_title\"='Morning Undersea';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22118197_1\" (\n \"year_ceremony\" text,\n \"english_title\" text,\n \"portuguese_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What was the result of the film with the Portuguese title, Um Filme Falado? " }, { "role": "assistant", "content": "SELECT \"result\" FROM \"table1_22118197_1\" WHERE \"portuguese_title\"='Um Filme Falado';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_22118197_1\" (\n \"year_ceremony\" text,\n \"english_title\" text,\n \"portuguese_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What is the Portuguese name of the film who's English title is, Belle Toujours? " }, { "role": "assistant", "content": "SELECT \"portuguese_title\" FROM \"table1_22118197_1\" WHERE \"english_title\"='Belle Toujours';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"english_title\" text,\n \"vietnamese_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What is every result for the ceremony year of 2007 (80th)?" }, { "role": "assistant", "content": "SELECT \"result\" FROM \"submissions\" WHERE \"year_ceremony\"='2007 (80th)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"english_title\" text,\n \"vietnamese_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What is every English title for the result of nominee?" }, { "role": "assistant", "content": "SELECT \"english_title\" FROM \"submissions\" WHERE \"result\"='Nominee';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"english_title\" text,\n \"vietnamese_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: How many directors have vietnamese titles of Gate, Gate, Paragate?" }, { "role": "assistant", "content": "SELECT COUNT(\"director\") FROM \"submissions\" WHERE \"vietnamese_title\"='Gate, gate, paragate';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"english_title\" text,\n \"vietnamese_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What is every ceremony year for the result of nominee?" }, { "role": "assistant", "content": "SELECT \"year_ceremony\" FROM \"submissions\" WHERE \"result\"='Nominee';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_221315_3\" (\n \"pilot\" text,\n \"organization\" text,\n \"total_flights\" real,\n \"usaf_space_flights\" real,\n \"fai_space_flights\" real,\n \"max_mach\" text,\n \"max_speed_mph\" real,\n \"max_altitude_miles\" text\n);\n\nQuestion: Who was the pilot of max altitude of 55.9 miles?" }, { "role": "assistant", "content": "SELECT \"pilot\" FROM \"table1_221315_3\" WHERE \"max_altitude_miles\"='55.9';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_221315_3\" (\n \"pilot\" text,\n \"organization\" text,\n \"total_flights\" real,\n \"usaf_space_flights\" real,\n \"fai_space_flights\" real,\n \"max_mach\" text,\n \"max_speed_mph\" real,\n \"max_altitude_miles\" text\n);\n\nQuestion: What is the highest number of fai space flights when max mach is 5.65?" }, { "role": "assistant", "content": "SELECT MAX(\"fai_space_flights\") FROM \"table1_221315_3\" WHERE \"max_mach\"='5.65';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_221315_3\" (\n \"pilot\" text,\n \"organization\" text,\n \"total_flights\" real,\n \"usaf_space_flights\" real,\n \"fai_space_flights\" real,\n \"max_mach\" text,\n \"max_speed_mph\" real,\n \"max_altitude_miles\" text\n);\n\nQuestion: What was the maximum altitude for Neil Armstrong?" }, { "role": "assistant", "content": "SELECT \"max_altitude_miles\" FROM \"table1_221315_3\" WHERE \"pilot\"='Neil Armstrong';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_221315_3\" (\n \"pilot\" text,\n \"organization\" text,\n \"total_flights\" real,\n \"usaf_space_flights\" real,\n \"fai_space_flights\" real,\n \"max_mach\" text,\n \"max_speed_mph\" real,\n \"max_altitude_miles\" text\n);\n\nQuestion: How many numbers were recorded under max speed for 1 USAF space flight and total flights 34?" }, { "role": "assistant", "content": "SELECT COUNT(\"max_speed_mph\") FROM \"table1_221315_3\" WHERE \"usaf_space_flights\"=1 AND \"total_flights\"=34;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_221315_3\" (\n \"pilot\" text,\n \"organization\" text,\n \"total_flights\" real,\n \"usaf_space_flights\" real,\n \"fai_space_flights\" real,\n \"max_mach\" text,\n \"max_speed_mph\" real,\n \"max_altitude_miles\" text\n);\n\nQuestion: What were all USAF space flights when the aximum speed was 3822?" }, { "role": "assistant", "content": "SELECT \"usaf_space_flights\" FROM \"table1_221315_3\" WHERE \"max_speed_mph\"=3822;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_221315_3\" (\n \"pilot\" text,\n \"organization\" text,\n \"total_flights\" real,\n \"usaf_space_flights\" real,\n \"fai_space_flights\" real,\n \"max_mach\" text,\n \"max_speed_mph\" real,\n \"max_altitude_miles\" text\n);\n\nQuestion: What was the max mach when the maximum speed was 3887?" }, { "role": "assistant", "content": "SELECT \"max_mach\" FROM \"table1_221315_3\" WHERE \"max_speed_mph\"=3887;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"european_record\" (\n \"season\" text,\n \"round\" real,\n \"opponents\" text,\n \"home_leg\" text,\n \"away_leg\" text,\n \"aggregate\" text\n);\n\nQuestion: What is the record for the away leg in round 1 and aggregate 2-0?" }, { "role": "assistant", "content": "SELECT \"away_leg\" FROM \"european_record\" WHERE \"round\"=1 AND \"aggregate\"='2-0';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_221375_1\" (\n \"district\" text,\n \"municipalities\" real,\n \"parishes\" real,\n \"province_of_1936\" text,\n \"region\" text\n);\n\nQuestion: Name the parishes for beira baixa province" }, { "role": "assistant", "content": "SELECT COUNT(\"parishes\") FROM \"table1_221375_1\" WHERE \"province_of_1936\"='Beira Baixa Province';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_221375_1\" (\n \"district\" text,\n \"municipalities\" real,\n \"parishes\" real,\n \"province_of_1936\" text,\n \"region\" text\n);\n\nQuestion: Name the most municipalities for alto alentejo province (partly ribatejo)" }, { "role": "assistant", "content": "SELECT MAX(\"municipalities\") FROM \"table1_221375_1\" WHERE \"province_of_1936\"='Alto Alentejo Province (partly Ribatejo)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_221375_1\" (\n \"district\" text,\n \"municipalities\" real,\n \"parishes\" real,\n \"province_of_1936\" text,\n \"region\" text\n);\n\nQuestion: Name province of 1936 viana do castelo" }, { "role": "assistant", "content": "SELECT \"province_of_1936\" FROM \"table1_221375_1\" WHERE \"district\"='Viana do Castelo';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"doubles_9_finals_5_titles_4_runner_ups\" (\n \"outcome\" text,\n \"year\" real,\n \"championship\" text,\n \"surface\" text,\n \"partner\" text,\n \"opponents\" text,\n \"score\" text\n);\n\nQuestion: What was the score when the partner is Rafael Osuna?" }, { "role": "assistant", "content": "SELECT \"score\" FROM \"doubles_9_finals_5_titles_4_runner_ups\" WHERE \"partner\"='Rafael Osuna';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"doubles_9_finals_5_titles_4_runner_ups\" (\n \"outcome\" text,\n \"year\" real,\n \"championship\" text,\n \"surface\" text,\n \"partner\" text,\n \"opponents\" text,\n \"score\" text\n);\n\nQuestion: What was the outcome of the game when the partner is Rafael Osuna?" }, { "role": "assistant", "content": "SELECT \"outcome\" FROM \"doubles_9_finals_5_titles_4_runner_ups\" WHERE \"partner\"='Rafael Osuna';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"doubles_9_finals_5_titles_4_runner_ups\" (\n \"outcome\" text,\n \"year\" real,\n \"championship\" text,\n \"surface\" text,\n \"partner\" text,\n \"opponents\" text,\n \"score\" text\n);\n\nQuestion: What is the surface of the French Championships?" }, { "role": "assistant", "content": "SELECT \"surface\" FROM \"doubles_9_finals_5_titles_4_runner_ups\" WHERE \"championship\"='French Championships';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"doubles_9_finals_5_titles_4_runner_ups\" (\n \"outcome\" text,\n \"year\" real,\n \"championship\" text,\n \"surface\" text,\n \"partner\" text,\n \"opponents\" text,\n \"score\" text\n);\n\nQuestion: How many outcomes were there for matches played with Chuck McKinley on grass in 1962?" }, { "role": "assistant", "content": "SELECT COUNT(\"outcome\") FROM \"doubles_9_finals_5_titles_4_runner_ups\" WHERE \"surface\"='Grass' AND \"partner\"='Chuck McKinley' AND \"year\"=1962;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"european_record\" (\n \"season\" real,\n \"round\" real,\n \"opponents\" text,\n \"home_leg\" text,\n \"away_leg\" text,\n \"aggregate\" text\n);\n\nQuestion: What was the home leg score against partizani tirana?" }, { "role": "assistant", "content": "SELECT \"home_leg\" FROM \"european_record\" WHERE \"opponents\"='Partizani Tirana';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"european_record\" (\n \"season\" real,\n \"round\" real,\n \"opponents\" text,\n \"home_leg\" text,\n \"away_leg\" text,\n \"aggregate\" text\n);\n\nQuestion: What round did they face fc st. gallen?" }, { "role": "assistant", "content": "SELECT COUNT(\"round\") FROM \"european_record\" WHERE \"opponents\"='FC St. Gallen';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"european_record\" (\n \"season\" real,\n \"round\" real,\n \"opponents\" text,\n \"home_leg\" text,\n \"away_leg\" text,\n \"aggregate\" text\n);\n\nQuestion: What was the home leg score against fc schalke 04?" }, { "role": "assistant", "content": "SELECT \"home_leg\" FROM \"european_record\" WHERE \"opponents\"='FC Schalke 04';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"goalscorers\" (\n \"player\" text,\n \"bundesliga\" real,\n \"dfb_pokal\" real,\n \"uefa_intertoto_cup\" real,\n \"uefa_cup\" real,\n \"dfb_ligapokal\" real,\n \"total\" real\n);\n\nQuestion: How many dfb-pokal did kevin-prince boateng have?" }, { "role": "assistant", "content": "SELECT COUNT(\"dfb_pokal\") FROM \"goalscorers\" WHERE \"player\"='Kevin-Prince Boateng';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"conference_tournament_championships\" (\n \"tournament\" real,\n \"conference\" text,\n \"championship_game_opponent\" text,\n \"score\" text,\n \"location\" text,\n \"head_coach\" text\n);\n\nQuestion: Who is the head coach when Miami University is the championship game opponent?" }, { "role": "assistant", "content": "SELECT \"head_coach\" FROM \"conference_tournament_championships\" WHERE \"championship_game_opponent\"='Miami University';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"conference_tournament_championships\" (\n \"tournament\" real,\n \"conference\" text,\n \"championship_game_opponent\" text,\n \"score\" text,\n \"location\" text,\n \"head_coach\" text\n);\n\nQuestion: What is the location when 2-1 is the score?" }, { "role": "assistant", "content": "SELECT \"location\" FROM \"conference_tournament_championships\" WHERE \"score\"='2-1';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"conference_tournament_championships\" (\n \"tournament\" real,\n \"conference\" text,\n \"championship_game_opponent\" text,\n \"score\" text,\n \"location\" text,\n \"head_coach\" text\n);\n\nQuestion: What is the conference when Ferris State is the championship game opponent?" }, { "role": "assistant", "content": "SELECT \"conference\" FROM \"conference_tournament_championships\" WHERE \"championship_game_opponent\"='Ferris State';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"conference_tournament_championships\" (\n \"tournament\" real,\n \"conference\" text,\n \"championship_game_opponent\" text,\n \"score\" text,\n \"location\" text,\n \"head_coach\" text\n);\n\nQuestion: What is the location of the 1999 tournament?" }, { "role": "assistant", "content": "SELECT \"location\" FROM \"conference_tournament_championships\" WHERE \"tournament\"=1999;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"conference_tournament_championships\" (\n \"tournament\" real,\n \"conference\" text,\n \"championship_game_opponent\" text,\n \"score\" text,\n \"location\" text,\n \"head_coach\" text\n);\n\nQuestion: How many scores are there when the championship game opponent is Miami University?" }, { "role": "assistant", "content": "SELECT COUNT(\"score\") FROM \"conference_tournament_championships\" WHERE \"championship_game_opponent\"='Miami University';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"conference_tournament_championships\" (\n \"tournament\" real,\n \"conference\" text,\n \"championship_game_opponent\" text,\n \"score\" text,\n \"location\" text,\n \"head_coach\" text\n);\n\nQuestion: Who is the head coach for the score of 4-3?" }, { "role": "assistant", "content": "SELECT \"head_coach\" FROM \"conference_tournament_championships\" WHERE \"score\"='4-3';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"laboratory_findings_in_various_platelet_\" (\n \"condition\" text,\n \"prothrombin_time\" text,\n \"partial_thromboplastin_time\" text,\n \"bleeding_time\" text,\n \"platelet_count\" text\n);\n\nQuestion: What is the bleeding time when the platelet count is decreased or unaffected?" }, { "role": "assistant", "content": "SELECT \"bleeding_time\" FROM \"laboratory_findings_in_various_platelet_\" WHERE \"platelet_count\"='Decreased or unaffected';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"laboratory_findings_in_various_platelet_\" (\n \"condition\" text,\n \"prothrombin_time\" text,\n \"partial_thromboplastin_time\" text,\n \"bleeding_time\" text,\n \"platelet_count\" text\n);\n\nQuestion: What is the partial thromboplastin time when the condition factor x deficiency as seen in amyloid purpura?" }, { "role": "assistant", "content": "SELECT \"partial_thromboplastin_time\" FROM \"laboratory_findings_in_various_platelet_\" WHERE \"condition\"='Factor X deficiency as seen in amyloid purpura';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"laboratory_findings_in_various_platelet_\" (\n \"condition\" text,\n \"prothrombin_time\" text,\n \"partial_thromboplastin_time\" text,\n \"bleeding_time\" text,\n \"platelet_count\" text\n);\n\nQuestion: How many time does the platelet count occur when prothrombin time and bleeding time are prolonged?" }, { "role": "assistant", "content": "SELECT COUNT(\"platelet_count\") FROM \"laboratory_findings_in_various_platelet_\" WHERE \"prothrombin_time\"='Prolonged' AND \"bleeding_time\"='Prolonged';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"laboratory_findings_in_various_platelet_\" (\n \"condition\" text,\n \"prothrombin_time\" text,\n \"partial_thromboplastin_time\" text,\n \"bleeding_time\" text,\n \"platelet_count\" text\n);\n\nQuestion: What is the bleeding time for the disseminated intravascular coagulation condition?" }, { "role": "assistant", "content": "SELECT COUNT(\"bleeding_time\") FROM \"laboratory_findings_in_various_platelet_\" WHERE \"condition\"='Disseminated intravascular coagulation';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"laboratory_findings_in_various_platelet_\" (\n \"condition\" text,\n \"prothrombin_time\" text,\n \"partial_thromboplastin_time\" text,\n \"bleeding_time\" text,\n \"platelet_count\" text\n);\n\nQuestion: What is the result for partial thromboplastin time when prothrombin time and bleeding time are prolonged?" }, { "role": "assistant", "content": "SELECT \"partial_thromboplastin_time\" FROM \"laboratory_findings_in_various_platelet_\" WHERE \"prothrombin_time\"='Prolonged' AND \"bleeding_time\"='Prolonged';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"laboratory_findings_in_various_platelet_\" (\n \"condition\" text,\n \"prothrombin_time\" text,\n \"partial_thromboplastin_time\" text,\n \"bleeding_time\" text,\n \"platelet_count\" text\n);\n\nQuestion: What is the platelet count when partial thromboplastin time and bleeding time are unaffected?" }, { "role": "assistant", "content": "SELECT \"platelet_count\" FROM \"laboratory_findings_in_various_platelet_\" WHERE \"partial_thromboplastin_time\"='Unaffected' AND \"bleeding_time\"='Unaffected';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"new_zealand_tv2\" (\n \"episode_number\" real,\n \"title\" text,\n \"original_airing\" text,\n \"timeslot\" text,\n \"viewers\" real,\n \"top_50_ranking\" real,\n \"scripted_show_ranking\" real\n);\n\nQuestion: What is the lowest top 50 ranking that the episode titled \"the god-why-don't-you-love-me blues\" received?" }, { "role": "assistant", "content": "SELECT MIN(\"top_50_ranking\") FROM \"new_zealand_tv2\" WHERE \"title\"='The God-Why-Don''t-You-Love-Me Blues';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"new_zealand_tv2\" (\n \"episode_number\" real,\n \"title\" text,\n \"original_airing\" text,\n \"timeslot\" text,\n \"viewers\" real,\n \"top_50_ranking\" real,\n \"scripted_show_ranking\" real\n);\n\nQuestion: Which episodes originally aired on April 19, 2010?" }, { "role": "assistant", "content": "SELECT \"title\" FROM \"new_zealand_tv2\" WHERE \"original_airing\"='April 19, 2010';" } ]