text
stringlengths
310
1.28k
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "stations" ( "station" text, "city_of_license" text, "channels_tv_rf" text, "first_air_date" text, "haat" text, "facility_id" real, "public_license_information" text ); Question: Which HAAT has 65944? <|assistant|> SELECT "haat" FROM "stations" WHERE "facility_id"=65944;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "stations" ( "station" text, "city_of_license" text, "channels_tv_rf" text, "first_air_date" text, "haat" text, "facility_id" real, "public_license_information" text ); Question: Which City of license has a Channels TV / RF of 36 (psip) 36 (uhf)? Question 5 <|assistant|> SELECT "city_of_license" FROM "stations" WHERE "channels_tv_rf"='36 (psip) 36 (uhf)';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "release_history" ( "country" text, "date" text, "label" text, "format" text, "catalogue_num" text ); Question: What format is dated October 29, 2004? <|assistant|> SELECT "format" FROM "release_history" WHERE "date"='october 29, 2004';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "release_history" ( "country" text, "date" text, "label" text, "format" text, "catalogue_num" text ); Question: What is the date with the catalogue number ptcd-1015-6? <|assistant|> SELECT "date" FROM "release_history" WHERE "catalogue_num"='ptcd-1015-6';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "release_history" ( "country" text, "date" text, "label" text, "format" text, "catalogue_num" text ); Question: What is the label for December 2004? <|assistant|> SELECT "label" FROM "release_history" WHERE "date"='december 2004';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "release_history" ( "country" text, "date" text, "label" text, "format" text, "catalogue_num" text ); Question: What is the date for Hydra Head Records with a CD format? <|assistant|> SELECT "date" FROM "release_history" WHERE "label"='hydra head records' AND "format"='cd';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "release_history" ( "country" text, "date" text, "label" text, "format" text, "catalogue_num" text ); Question: Which country has Hydra Head Records on February 2005? <|assistant|> SELECT "country" FROM "release_history" WHERE "label"='hydra head records' AND "date"='february 2005';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "release_history" ( "country" text, "date" text, "label" text, "format" text, "catalogue_num" text ); Question: Which country has Hydra Head Records with a 2lp format? <|assistant|> SELECT "country" FROM "release_history" WHERE "format"='2lp' AND "label"='hydra head records';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "race_starters" ( "saddle_cloth" real, "horse" text, "trainer" text, "jockey" text, "weight_kg" real, "barrier_b" text, "placing" text ); Question: Who rode mad rush? <|assistant|> SELECT "jockey" FROM "race_starters" WHERE "horse"='mad rush';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "race_starters" ( "saddle_cloth" real, "horse" text, "trainer" text, "jockey" text, "weight_kg" real, "barrier_b" text, "placing" text ); Question: What place was the horse with a barrier of 20 and weighing less than 54 kg <|assistant|> SELECT "placing" FROM "race_starters" WHERE "weight_kg"<54 AND "barrier_b"='20';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "race_starters" ( "saddle_cloth" real, "horse" text, "trainer" text, "jockey" text, "weight_kg" real, "barrier_b" text, "placing" text ); Question: What place was the viewed horse? <|assistant|> SELECT "placing" FROM "race_starters" WHERE "horse"='viewed';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "nascar_nationwide_series" ( "year" real, "starts" real, "wins" real, "top_5" real, "top_10" real, "poles" real, "avg_start" real, "avg_finish" real, "winnings" text, "position" text ); Question: What is the average number of wins of the year with less than 5 top 10s, a winning of $39,190 and less than 2 starts? <|assistant|> SELECT AVG("wins") FROM "nascar_nationwide_series" WHERE "top_10"<5 AND "winnings"='$39,190' AND "starts"<2;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "nascar_nationwide_series" ( "year" real, "starts" real, "wins" real, "top_5" real, "top_10" real, "poles" real, "avg_start" real, "avg_finish" real, "winnings" text, "position" text ); Question: What is the highest number of poles of the year before 1992 with more than 18 starts and winnings of $125,102? <|assistant|> SELECT MAX("poles") FROM "nascar_nationwide_series" WHERE "starts">18 AND "winnings"='$125,102' AND "year"<1992;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "notable_works" ( "year" real, "play" text, "author" text, "theatre" text, "type" text, "role" text ); Question: Author of stanisław wyspiański, and a Year of 1969 happened in what theatre? <|assistant|> SELECT "theatre" FROM "notable_works" WHERE "author"='stanisław wyspiański' AND "year"=1969;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule_and_results" ( "game" real, "february" real, "opponent" text, "score" text, "record" text ); Question: Which game did New Jersey Devils played in? <|assistant|> SELECT "game" FROM "schedule_and_results" WHERE "opponent"='new jersey devils';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule_and_results" ( "game" real, "february" real, "opponent" text, "score" text, "record" text ); Question: What score has a record of 21-25-7-4? <|assistant|> SELECT "score" FROM "schedule_and_results" WHERE "record"='21-25-7-4';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule_and_results" ( "game" real, "february" real, "opponent" text, "score" text, "record" text ); Question: What score has a record of 22-28-7-4? <|assistant|> SELECT "score" FROM "schedule_and_results" WHERE "record"='22-28-7-4';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "2000_01_season_as_a_two_year_old" ( "result" text, "date" text, "race" text, "venue" text, "group" text, "distance" text, "weight_kg" real, "time" text, "jockey" text, "winner_2nd" text ); Question: What group has 1200 m as the distance? <|assistant|> SELECT "group" FROM "2000_01_season_as_a_two_year_old" WHERE "distance"='1200 m';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "2000_01_season_as_a_two_year_old" ( "result" text, "date" text, "race" text, "venue" text, "group" text, "distance" text, "weight_kg" real, "time" text, "jockey" text, "winner_2nd" text ); Question: What venue has g1 as the group? <|assistant|> SELECT "venue" FROM "2000_01_season_as_a_two_year_old" WHERE "group"='g1';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "torneo_apertura" ( "position" real, "team" text, "played" real, "wins" real, "draws" real, "losses" real, "scored" real, "conceded" real, "points" real ); Question: What's the highest Points with the Team of Tacuary, and has Losses that's smaller than 4? <|assistant|> SELECT MAX("points") FROM "torneo_apertura" WHERE "team"='tacuary' AND "losses"<4;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "torneo_apertura" ( "position" real, "team" text, "played" real, "wins" real, "draws" real, "losses" real, "scored" real, "conceded" real, "points" real ); Question: What's the sum of Losses that Scored larger than 15, has Points that's larger than 16, and Played that's larger than 9? <|assistant|> SELECT SUM("losses") FROM "torneo_apertura" WHERE "scored">15 AND "points">16 AND "played">9;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "torneo_apertura" ( "position" real, "team" text, "played" real, "wins" real, "draws" real, "losses" real, "scored" real, "conceded" real, "points" real ); Question: What's the highest Played with a Scored of 15, and Draws that's less than 1? <|assistant|> SELECT MAX("played") FROM "torneo_apertura" WHERE "scored"=15 AND "draws"<1;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "torneo_apertura" ( "position" real, "team" text, "played" real, "wins" real, "draws" real, "losses" real, "scored" real, "conceded" real, "points" real ); Question: What's the sum of WIns with Draws that's larger than 1, Losses that's smaller than 4, and Conceded of 20? <|assistant|> SELECT SUM("wins") FROM "torneo_apertura" WHERE "draws">1 AND "losses"<4 AND "conceded"=20;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "torneo_apertura" ( "position" real, "team" text, "played" real, "wins" real, "draws" real, "losses" real, "scored" real, "conceded" real, "points" real ); Question: What's the lowest Position with a Conceded that's larger than 16, Draws of 3, and Losses that's larger than 3? <|assistant|> SELECT MIN("position") FROM "torneo_apertura" WHERE "conceded">16 AND "draws"=3 AND "losses">3;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "series" ( "model" text, "processors_supported" text, "fsb_ht_frequency_m_hz" text, "memory" text, "pci_express" text, "sata" text, "pata" text, "sound" text ); Question: Which processors are supported with a PCI-express of x16: 1 slot x1: 4 slots and the nforce 550 model? <|assistant|> SELECT "processors_supported" FROM "series" WHERE "pci_express"='x16: 1 slot x1: 4 slots' AND "model"='nforce 550';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "series" ( "model" text, "processors_supported" text, "fsb_ht_frequency_m_hz" text, "memory" text, "pci_express" text, "sata" text, "pata" text, "sound" text ); Question: What are the processors supported by a ddr2 memory and the nforce 550 model? <|assistant|> SELECT "processors_supported" FROM "series" WHERE "memory"='ddr2' AND "model"='nforce 550';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "series" ( "model" text, "processors_supported" text, "fsb_ht_frequency_m_hz" text, "memory" text, "pci_express" text, "sata" text, "pata" text, "sound" text ); Question: What is the PCI-express with a ddr2 memory and a nforce 520 model? <|assistant|> SELECT "pci_express" FROM "series" WHERE "memory"='ddr2' AND "model"='nforce 520';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "liquid_measures" ( "unit" text, "russian" text, "translation" text, "ratio" text, "cubic_inches_exact" text, "metric_value" text, "imperial" text, "us_customary" text ); Question: What is the Russian word for wine glass that contains 4.16 fl. oz.? <|assistant|> SELECT "russian" FROM "liquid_measures" WHERE "us_customary"='4.16 fl. oz.';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "liquid_measures" ( "unit" text, "russian" text, "translation" text, "ratio" text, "cubic_inches_exact" text, "metric_value" text, "imperial" text, "us_customary" text ); Question: What are the imperial size for the unit that has a ratio of 1/20? <|assistant|> SELECT "imperial" FROM "liquid_measures" WHERE "ratio"='1/20';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "liquid_measures" ( "unit" text, "russian" text, "translation" text, "ratio" text, "cubic_inches_exact" text, "metric_value" text, "imperial" text, "us_customary" text ); Question: How big in metric terms is the unit that has a ratio of 1/20? <|assistant|> SELECT "metric_value" FROM "liquid_measures" WHERE "ratio"='1/20';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "liquid_measures" ( "unit" text, "russian" text, "translation" text, "ratio" text, "cubic_inches_exact" text, "metric_value" text, "imperial" text, "us_customary" text ); Question: How large in US customary terms is the unit called butylka (vodochnaya)? <|assistant|> SELECT "us_customary" FROM "liquid_measures" WHERE "unit"='butylka (vodochnaya)';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "liquid_measures" ( "unit" text, "russian" text, "translation" text, "ratio" text, "cubic_inches_exact" text, "metric_value" text, "imperial" text, "us_customary" text ); Question: What is the translation of chetvert? <|assistant|> SELECT "translation" FROM "liquid_measures" WHERE "unit"='chetvert';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "liquid_measures" ( "unit" text, "russian" text, "translation" text, "ratio" text, "cubic_inches_exact" text, "metric_value" text, "imperial" text, "us_customary" text ); Question: What Russian word translates to bucket? <|assistant|> SELECT "russian" FROM "liquid_measures" WHERE "translation"='bucket';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "results" ( "pos" real, "matches" real, "wins" real, "loses" real, "results" text, "points" real, "diff" text ); Question: Points larger than 6, and a Results of 522:443 had what lowest matches? <|assistant|> SELECT MIN("matches") FROM "results" WHERE "points">6 AND "results"='522:443';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "results" ( "pos" real, "matches" real, "wins" real, "loses" real, "results" text, "points" real, "diff" text ); Question: Loses of 2, and a Pos. smaller than 2 had how many highest matches? <|assistant|> SELECT MAX("matches") FROM "results" WHERE "loses"=2 AND "pos"<2;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "doubles_6_5_titles_1_runner_up" ( "outcome" text, "date" text, "tournament" text, "surface" text, "partner" text, "opponent" text, "score" text ); Question: What was the outcome when the game was played on clay and on 2 May 2009? <|assistant|> SELECT "outcome" FROM "doubles_6_5_titles_1_runner_up" WHERE "surface"='clay' AND "date"='2 may 2009';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "doubles_6_5_titles_1_runner_up" ( "outcome" text, "date" text, "tournament" text, "surface" text, "partner" text, "opponent" text, "score" text ); Question: What person was played against when the playing surface was hard? <|assistant|> SELECT "opponent" FROM "doubles_6_5_titles_1_runner_up" WHERE "surface"='hard';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "doubles_6_5_titles_1_runner_up" ( "outcome" text, "date" text, "tournament" text, "surface" text, "partner" text, "opponent" text, "score" text ); Question: With the score of 6–3, 2–6, [10–8] and played on clay who was the opponent? <|assistant|> SELECT "opponent" FROM "doubles_6_5_titles_1_runner_up" WHERE "surface"='clay' AND "score"='6–3, 2–6, [10–8]';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "1900_1912" ( "average_population_x_1_000" real, "live_births" real, "deaths" real, "natural_change" real, "crude_birth_rate_per_1_000" real, "crude_death_rate_per_1_000" real, "natural_change_per_1_000" real ); Question: What is the lowest number of live births of Syria when the natural change was 9.4 and the crude death rate was greater than 29.3? <|assistant|> SELECT MIN("live_births") FROM "1900_1912" WHERE "natural_change_per_1_000"=9.4 AND "crude_death_rate_per_1_000">29.3;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "1900_1912" ( "average_population_x_1_000" real, "live_births" real, "deaths" real, "natural_change" real, "crude_birth_rate_per_1_000" real, "crude_death_rate_per_1_000" real, "natural_change_per_1_000" real ); Question: What is the natural change number of Syria when there were 67,000 deaths and an average population greater than 2,820? <|assistant|> SELECT SUM("natural_change") FROM "1900_1912" WHERE "deaths"='67,000' AND "average_population_x_1_000">'2,820';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "2013_winners" ( "category" text, "rank" real, "2013_recipient" text, "location" text, "vote" text ); Question: What is the rank of the park in pigeon forge, tennessee in the best food category? <|assistant|> SELECT COUNT("rank") FROM "2013_winners" WHERE "location"='pigeon forge, tennessee' AND "category"='best food';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "under_construction" ( "name" text, "pinnacle_height" text, "floors" real, "completion" real, "city" text ); Question: What building is in Shenzhen, have less than 115 floors, and was completed before 2017? <|assistant|> SELECT "name" FROM "under_construction" WHERE "city"='shenzhen' AND "completion"<2017 AND "floors"<115;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "official_versions" ( "version" text, "length" text, "album" text, "remixed_by" text, "year" real ); Question: What is the earliest year having a length of 11:25? <|assistant|> SELECT MIN("year") FROM "official_versions" WHERE "length"='11:25';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "official_versions" ( "version" text, "length" text, "album" text, "remixed_by" text, "year" real ); Question: What year had a version called Wolf Mix? <|assistant|> SELECT AVG("year") FROM "official_versions" WHERE "version"='wolf mix';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "cowboys_drafted_into_the_nfl" ( "draft_year" real, "player" text, "position" text, "round" real, "overall" real, "nfl_team" text ); Question: In 1978 what is the NFL team? <|assistant|> SELECT "nfl_team" FROM "cowboys_drafted_into_the_nfl" WHERE "draft_year"=1978;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "game_site" text, "record" text, "attendance" text ); Question: Who was the opponent with attendance at 64,002? <|assistant|> SELECT "opponent" FROM "schedule" WHERE "attendance"='64,002';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "game_site" text, "record" text, "attendance" text ); Question: What was the highest week with 84,856 in attendance? <|assistant|> SELECT MAX("week") FROM "schedule" WHERE "attendance"='84,856';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "game_site" text, "record" text, "attendance" text ); Question: What was the record in a week less than 13 on November 9, 2003? <|assistant|> SELECT "record" FROM "schedule" WHERE "week"<13 AND "date"='november 9, 2003';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "game_site" text, "record" text, "attendance" text ); Question: On what date was the result w 20-17? <|assistant|> SELECT "date" FROM "schedule" WHERE "result"='w 20-17';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "game_site" text, "record" text, "attendance" text ); Question: What was the attendance for record 2-0? <|assistant|> SELECT "attendance" FROM "schedule" WHERE "record"='2-0';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "game_site" text, "record" text, "attendance" text ); Question: On what date was the game at Lincoln Financial Field? <|assistant|> SELECT "date" FROM "schedule" WHERE "game_site"='lincoln financial field';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "nfl_draft" ( "round" real, "pick" real, "player" text, "position" text, "school_club_team" text ); Question: Which player has a pick of 175? <|assistant|> SELECT "player" FROM "nfl_draft" WHERE "pick"=175;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "nfl_draft" ( "round" real, "pick" real, "player" text, "position" text, "school_club_team" text ); Question: Zack Jordan has the lowest pick and a round of less than 28? <|assistant|> SELECT MIN("pick") FROM "nfl_draft" WHERE "player"='zack jordan' AND "round"<28;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "nfl_draft" ( "round" real, "pick" real, "player" text, "position" text, "school_club_team" text ); Question: What is the sum of the pick for player roger zatkoff? <|assistant|> SELECT SUM("pick") FROM "nfl_draft" WHERE "player"='roger zatkoff';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "aluminium_series" ( "denomination" text, "metal" text, "weight" text, "shape" text, "size" text ); Question: Which metal has a size that is 26mm (across scallops)? <|assistant|> SELECT "metal" FROM "aluminium_series" WHERE "size"='26mm (across scallops)';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "aluminium_series" ( "denomination" text, "metal" text, "weight" text, "shape" text, "size" text ); Question: What is the weight with the shape of scalloped, and that is a size of 20mm (across scallops)? <|assistant|> SELECT "weight" FROM "aluminium_series" WHERE "shape"='scalloped' AND "size"='20mm (across scallops)';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "aluminium_series" ( "denomination" text, "metal" text, "weight" text, "shape" text, "size" text ); Question: What is the weight with a denomination that is three paise? <|assistant|> SELECT "weight" FROM "aluminium_series" WHERE "denomination"='three paise';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "aluminium_series" ( "denomination" text, "metal" text, "weight" text, "shape" text, "size" text ); Question: What is the weight with a denomination that is ten paise? <|assistant|> SELECT "weight" FROM "aluminium_series" WHERE "denomination"='ten paise';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "world_championship_group_c_hungary" ( "games" real, "drawn" real, "lost" real, "points_difference" text, "points" real ); Question: What is the highest number of games drawn, where the games played was less than 7? <|assistant|> SELECT MAX("drawn") FROM "world_championship_group_c_hungary" WHERE "games"<7;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "game_log" ( "game" real, "october" real, "opponent" text, "score" text, "record" text, "points" real ); Question: Which October is the lowest one that has an Opponent of washington capitals? <|assistant|> SELECT MIN("october") FROM "game_log" WHERE "opponent"='washington capitals';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "game_log" ( "game" real, "october" real, "opponent" text, "score" text, "record" text, "points" real ); Question: Which Score has a Game larger than 7, and Points smaller than 14? <|assistant|> SELECT "score" FROM "game_log" WHERE "game">7 AND "points"<14;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "game_log" ( "game" real, "october" real, "opponent" text, "score" text, "record" text, "points" real ); Question: How many Points have an Opponent of @ calgary flames? <|assistant|> SELECT SUM("points") FROM "game_log" WHERE "opponent"='@ calgary flames';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "leaders" ( "rank" real, "player" text, "country" text, "earnings" real, "events" real, "wins" real ); Question: What is the mean number of events where the rank is 1 and there are more than 3 wins? <|assistant|> SELECT AVG("events") FROM "leaders" WHERE "rank"=1 AND "wins">3;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "argentine_clubs_in_international_competi" ( "team" text, "recopa_1994" text, "supercopa_1994" text, "conmebol_1994" text, "copa_libertadores_1995" text ); Question: Which Supercopa 1994 has a Team of estudiantes? <|assistant|> SELECT "supercopa_1994" FROM "argentine_clubs_in_international_competi" WHERE "team"='estudiantes';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "argentine_clubs_in_international_competi" ( "team" text, "recopa_1994" text, "supercopa_1994" text, "conmebol_1994" text, "copa_libertadores_1995" text ); Question: Which CONMEBOL 1994 has a Supercopa 1994 of n/a, and a Recopa 1994 of n/a, and a Team of san lorenzo? <|assistant|> SELECT "conmebol_1994" FROM "argentine_clubs_in_international_competi" WHERE "supercopa_1994"='n/a' AND "recopa_1994"='n/a' AND "team"='san lorenzo';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "argentine_clubs_in_international_competi" ( "team" text, "recopa_1994" text, "supercopa_1994" text, "conmebol_1994" text, "copa_libertadores_1995" text ); Question: Which Recopa 1994 has a Supercopa 1994 of 1st round, and a Team of argentinos juniors? <|assistant|> SELECT "recopa_1994" FROM "argentine_clubs_in_international_competi" WHERE "supercopa_1994"='1st round' AND "team"='argentinos juniors';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "argentine_clubs_in_international_competi" ( "team" text, "recopa_1994" text, "supercopa_1994" text, "conmebol_1994" text, "copa_libertadores_1995" text ); Question: Which Team has a Recopa 1994 of n/a and a CONMEBOL 1994 of 1st round? <|assistant|> SELECT "team" FROM "argentine_clubs_in_international_competi" WHERE "recopa_1994"='n/a' AND "conmebol_1994"='1st round';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "summary_of_election_results_1973_2003" ( "election" real, "labour" real, "conservative" real, "liberal" real, "social_democratic_party" real, "social_and_liberal_democrats_liberal_democrats" real, "independent" real, "green" real, "other" text, "control" text ); Question: Which Social and Liberal Democrats/ Liberal Democrats has a Control of labour hold, and a Liberal larger than 0? <|assistant|> SELECT SUM("social_and_liberal_democrats_liberal_democrats") FROM "summary_of_election_results_1973_2003" WHERE "control"='labour hold' AND "liberal">0;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "summary_of_election_results_1973_2003" ( "election" real, "labour" real, "conservative" real, "liberal" real, "social_democratic_party" real, "social_and_liberal_democrats_liberal_democrats" real, "independent" real, "green" real, "other" text, "control" text ); Question: Which Social and Liberal Democrats/ Liberal Democrats has an Independent of 1, and an Election larger than 1988, and a Green smaller than 1? <|assistant|> SELECT "social_and_liberal_democrats_liberal_democrats" FROM "summary_of_election_results_1973_2003" WHERE "independent"=1 AND "election">1988 AND "green"<1;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "summary_of_election_results_1973_2003" ( "election" real, "labour" real, "conservative" real, "liberal" real, "social_democratic_party" real, "social_and_liberal_democrats_liberal_democrats" real, "independent" real, "green" real, "other" text, "control" text ); Question: Which Other has a Green of 0, and an Independent of 1, and a Labour smaller than 45, and a Control of labour lose to no overall control? <|assistant|> SELECT "other" FROM "summary_of_election_results_1973_2003" WHERE "green"=0 AND "independent"=1 AND "labour"<45 AND "control"='labour lose to no overall control';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "summary_of_election_results_1973_2003" ( "election" real, "labour" real, "conservative" real, "liberal" real, "social_democratic_party" real, "social_and_liberal_democrats_liberal_democrats" real, "independent" real, "green" real, "other" text, "control" text ); Question: Which Social Democratic Party has a Green smaller than 0? <|assistant|> SELECT AVG("social_democratic_party") FROM "summary_of_election_results_1973_2003" WHERE "green"<0;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "2009_2010_table" ( "club" text, "played" text, "drawn" text, "lost" text, "points_for" text, "points_against" text, "tries_for" text, "tries_against" text, "try_bonus" text, "losing_bonus" text, "points" text ); Question: When the try bonus was 10 what was the losing bonus? <|assistant|> SELECT "losing_bonus" FROM "2009_2010_table" WHERE "try_bonus"='10';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "2009_2010_table" ( "club" text, "played" text, "drawn" text, "lost" text, "points_for" text, "points_against" text, "tries_for" text, "tries_against" text, "try_bonus" text, "losing_bonus" text, "points" text ); Question: When the losing bonus was 2 what was drawn score? <|assistant|> SELECT "drawn" FROM "2009_2010_table" WHERE "losing_bonus"='2';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "2009_2010_table" ( "club" text, "played" text, "drawn" text, "lost" text, "points_for" text, "points_against" text, "tries_for" text, "tries_against" text, "try_bonus" text, "losing_bonus" text, "points" text ); Question: If the try bonus was 5 what was the try against score? <|assistant|> SELECT "tries_against" FROM "2009_2010_table" WHERE "try_bonus"='5';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "2009_2010_table" ( "club" text, "played" text, "drawn" text, "lost" text, "points_for" text, "points_against" text, "tries_for" text, "tries_against" text, "try_bonus" text, "losing_bonus" text, "points" text ); Question: When the tries against is 90 how many points are there? <|assistant|> SELECT "points" FROM "2009_2010_table" WHERE "tries_against"='90';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "2009_2010_table" ( "club" text, "played" text, "drawn" text, "lost" text, "points_for" text, "points_against" text, "tries_for" text, "tries_against" text, "try_bonus" text, "losing_bonus" text, "points" text ); Question: What club has tries against of 75? <|assistant|> SELECT "club" FROM "2009_2010_table" WHERE "tries_against"='75';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "atlanta_falcons_draft_history" ( "round" real, "pick_num" real, "overall" real, "name" text, "position" text, "college" text ); Question: What is the total number of overall figures when duke was the college and the round was higher than 7? <|assistant|> SELECT SUM("overall") FROM "atlanta_falcons_draft_history" WHERE "college"='duke' AND "round">7;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "atlanta_falcons_draft_history" ( "round" real, "pick_num" real, "overall" real, "name" text, "position" text, "college" text ); Question: Which of the highest pick numbers had a round of less than 2? <|assistant|> SELECT MAX("pick_num") FROM "atlanta_falcons_draft_history" WHERE "round"<2;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "atlanta_falcons_draft_history" ( "round" real, "pick_num" real, "overall" real, "name" text, "position" text, "college" text ); Question: Which pick number had a round of less than 7, an overall of less than 127, and where the name was Robert Alford? <|assistant|> SELECT "pick_num" FROM "atlanta_falcons_draft_history" WHERE "round"<7 AND "overall"<127 AND "name"='robert alford';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "atlanta_falcons_draft_history" ( "round" real, "pick_num" real, "overall" real, "name" text, "position" text, "college" text ); Question: Which highest overall figure had Robert Alford as a name and a round of more than 2? <|assistant|> SELECT MAX("overall") FROM "atlanta_falcons_draft_history" WHERE "name"='robert alford' AND "round">2;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "game_site" text, "attendance" real ); Question: What Game site has an Opponent of Miami Dolphins? <|assistant|> SELECT "game_site" FROM "schedule" WHERE "opponent"='miami dolphins';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "game_site" text, "attendance" real ); Question: What's the Lowest Attendance with a Game site of Riverfront Stadium? <|assistant|> SELECT MIN("attendance") FROM "schedule" WHERE "game_site"='riverfront stadium';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "game_site" text, "attendance" real ); Question: What's the lowest Attendance for a Week of 2? <|assistant|> SELECT MIN("attendance") FROM "schedule" WHERE "week"=2;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "medal_table" ( "rank" text, "nation" text, "gold" real, "silver" real, "bronze" real, "total" real ); Question: How many bronze medals does South Korea have? <|assistant|> SELECT "bronze" FROM "medal_table" WHERE "nation"='south korea';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "medal_table" ( "rank" text, "nation" text, "gold" real, "silver" real, "bronze" real, "total" real ); Question: What is the smallest number of total medals for Georgia with 0 silver and 1 bronze? <|assistant|> SELECT MIN("total") FROM "medal_table" WHERE "silver">0 AND "nation"='georgia' AND "bronze"<1;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "achievements" ( "year" real, "competition" text, "venue" text, "position" text, "event" text ); Question: What is the lowest year that had foil team as the event at Melbourne? <|assistant|> SELECT MIN("year") FROM "achievements" WHERE "event"='foil team' AND "venue"='melbourne';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "achievements" ( "year" real, "competition" text, "venue" text, "position" text, "event" text ); Question: What is the number of years that the event was foil team and took place in Los Angeles? <|assistant|> SELECT COUNT("year") FROM "achievements" WHERE "venue"='los angeles' AND "event"='foil team';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "achievements" ( "year" real, "competition" text, "venue" text, "position" text, "event" text ); Question: What was the position at the venue of lyon? <|assistant|> SELECT "position" FROM "achievements" WHERE "venue"='lyon';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "achievements" ( "year" real, "competition" text, "venue" text, "position" text, "event" text ); Question: What was the position for mauro at the world championships in 1985 during the foil individual event? <|assistant|> SELECT "position" FROM "achievements" WHERE "event"='foil individual' AND "competition"='world championships' AND "year"=1985;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "season_by_season_record" ( "season" text, "points" text, "finish" text, "playoffs" text, "head_coach" text ); Question: What was the playoff status when the head coach was Brent Sutter, the finish was 4th central, and the points were 82? <|assistant|> SELECT "playoffs" FROM "season_by_season_record" WHERE "head_coach"='brent sutter' AND "finish"='4th central' AND "points"='82';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "grand_slam_tournaments" ( "tournament" text, "1998" text, "2000" text, "2001" text, "2002" text, "2003" text, "2004" text, "2005" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text, "2013" text ); Question: 2001 of 2–4 was in which tournament? <|assistant|> SELECT "tournament" FROM "grand_slam_tournaments" WHERE "2001"='2–4';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "grand_slam_tournaments" ( "tournament" text, "1998" text, "2000" text, "2001" text, "2002" text, "2003" text, "2004" text, "2005" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text, "2013" text ); Question: 2013 of 4–4 is involved in what 2006? <|assistant|> SELECT "2006" FROM "grand_slam_tournaments" WHERE "2013"='4–4';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "grand_slam_tournaments" ( "tournament" text, "1998" text, "2000" text, "2001" text, "2002" text, "2003" text, "2004" text, "2005" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text, "2013" text ); Question: 2007 of 1r is involved in what 2001? <|assistant|> SELECT "2001" FROM "grand_slam_tournaments" WHERE "2007"='1r';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "grand_slam_tournaments" ( "tournament" text, "1998" text, "2000" text, "2001" text, "2002" text, "2003" text, "2004" text, "2005" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text, "2013" text ); Question: 2007 of 8–4 is involved in what 2002? <|assistant|> SELECT "2002" FROM "grand_slam_tournaments" WHERE "2007"='8–4';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "grand_slam_tournaments" ( "tournament" text, "1998" text, "2000" text, "2001" text, "2002" text, "2003" text, "2004" text, "2005" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text, "2013" text ); Question: 2005 of 3r, and a 2000 of lq, and a 2002 of 3r is in what 2004? <|assistant|> SELECT "2004" FROM "grand_slam_tournaments" WHERE "2005"='3r' AND "2000"='lq' AND "2002"='3r';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "grand_slam_tournaments" ( "tournament" text, "1998" text, "2000" text, "2001" text, "2002" text, "2003" text, "2004" text, "2005" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text, "2013" text ); Question: 2006 of 10–4 is in which 2000? <|assistant|> SELECT "2000" FROM "grand_slam_tournaments" WHERE "2006"='10–4';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "world_championship_group_c_poland" ( "games" real, "drawn" real, "lost" real, "points_difference" text, "points" real ); Question: What is the smallest number of drawn games when there are fewer than 4 points and more than 4 lost games? <|assistant|> SELECT MIN("drawn") FROM "world_championship_group_c_poland" WHERE "points"<4 AND "lost">4;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "world_championship_group_c_poland" ( "games" real, "drawn" real, "lost" real, "points_difference" text, "points" real ); Question: What is the sum of the points when there are fewer than 4 games? <|assistant|> SELECT SUM("points") FROM "world_championship_group_c_poland" WHERE "games"<4;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "teams" ( "country" text, "skip" text, "third" text, "second" text, "lead" text ); Question: Who holds the lead role when Aanders Brorson is third? <|assistant|> SELECT "lead" FROM "teams" WHERE "third"='aanders brorson';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "teams" ( "country" text, "skip" text, "third" text, "second" text, "lead" text ); Question: Who has the role of skip when the lead is Dominik Greindl? <|assistant|> SELECT "skip" FROM "teams" WHERE "lead"='dominik greindl';<|endoftext|>