output
stringlengths
27
479
instruction
stringlengths
407
1.39k
SELECT "french" FROM "names_in_national_languages" WHERE "common_english"='fribourg';
## Task Generate a SQL query to answer the following question: `What is the french word for fribourg?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "names_in_national_languages" ( "abbr" text, "common_english" text, "french" text, "italian" text, "romansh" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the french word for fribourg?`: ```sql
SELECT "abbr" FROM "names_in_national_languages" WHERE "common_english"='zug';
## Task Generate a SQL query to answer the following question: `What is the abbr for zug?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "names_in_national_languages" ( "abbr" text, "common_english" text, "french" text, "italian" text, "romansh" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the abbr for zug?`: ```sql
SELECT "finish" FROM "race_record" WHERE "date"='june 1, 2008';
## Task Generate a SQL query to answer the following question: `What is the Finish on June 1, 2008?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "race_record" ( "date" text, "race" text, "track" text, "location" text, "distance" text, "surface" text, "purse" text, "finish" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the Finish on June 1, 2008?`: ```sql
SELECT "track" FROM "race_record" WHERE "location"='louisville, kentucky';
## Task Generate a SQL query to answer the following question: `What is the Track in Louisville, Kentucky?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "race_record" ( "date" text, "race" text, "track" text, "location" text, "distance" text, "surface" text, "purse" text, "finish" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the Track in Louisville, Kentucky?`: ```sql
SELECT "location" FROM "race_record" WHERE "date"='march 30, 2008';
## Task Generate a SQL query to answer the following question: `What is the Location of the Event on March 30, 2008?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "race_record" ( "date" text, "race" text, "track" text, "location" text, "distance" text, "surface" text, "purse" text, "finish" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the Location of the Event on March 30, 2008?`: ```sql
SELECT "race" FROM "race_record" WHERE "purse"='$300,000';
## Task Generate a SQL query to answer the following question: `What Race has a Purse of $300,000?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "race_record" ( "date" text, "race" text, "track" text, "location" text, "distance" text, "surface" text, "purse" text, "finish" text ); ### SQL Given the database schema, here is the SQL query that answers `What Race has a Purse of $300,000?`: ```sql
SELECT "purse" FROM "race_record" WHERE "date"='january 3, 2010';
## Task Generate a SQL query to answer the following question: `What is the Purse on January 3, 2010?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "race_record" ( "date" text, "race" text, "track" text, "location" text, "distance" text, "surface" text, "purse" text, "finish" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the Purse on January 3, 2010?`: ```sql
SELECT "place" FROM "final_leaderboard" WHERE "country"='united states' AND "score"='71-70-72-68=281';
## Task Generate a SQL query to answer the following question: `What did United States place when the score was 71-70-72-68=281?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "final_leaderboard" ( "place" text, "player" text, "country" text, "score" text, "to_par" text, "money" real ); ### SQL Given the database schema, here is the SQL query that answers `What did United States place when the score was 71-70-72-68=281?`: ```sql
SELECT AVG("money") FROM "final_leaderboard" WHERE "country"='united states' AND "player"='lanny wadkins';
## Task Generate a SQL query to answer the following question: `What was the average money for United States when Lanny Wadkins played?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "final_leaderboard" ( "place" text, "player" text, "country" text, "score" text, "to_par" text, "money" real ); ### SQL Given the database schema, here is the SQL query that answers `What was the average money for United States when Lanny Wadkins played?`: ```sql
SELECT "to_par" FROM "final_leaderboard" WHERE "score"='71-70-72-68=281';
## Task Generate a SQL query to answer the following question: `What was the to par when the score was 71-70-72-68=281?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "final_leaderboard" ( "place" text, "player" text, "country" text, "score" text, "to_par" text, "money" real ); ### SQL Given the database schema, here is the SQL query that answers `What was the to par when the score was 71-70-72-68=281?`: ```sql
SELECT "away_team" FROM "ties" WHERE "attendance"=117;
## Task Generate a SQL query to answer the following question: `What is the away team of the game with an attendance of 117?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "ties" ( "tie_no" real, "home_team" text, "score" text, "away_team" text, "attendance" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the away team of the game with an attendance of 117?`: ```sql
SELECT "career_sr" FROM "doubles_performance_timeline" WHERE "1996"='a' AND "tournament"='madrid (stuttgart)';
## Task Generate a SQL query to answer the following question: `Madrid (Stuttgart) tournament with a 1996 of A has this for a Career SR?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "doubles_performance_timeline" ( "tournament" text, "1990" text, "1991" text, "1992" text, "1993" text, "1994" text, "1995" text, "1996" text, "1997" text, "1998" text, "career_sr" text, "career_win_loss" text ); ### SQL Given the database schema, here is the SQL query that answers `Madrid (Stuttgart) tournament with a 1996 of A has this for a Career SR?`: ```sql
SELECT "election" FROM "m_ps_1832_1885" WHERE "first_party"='conservative' AND "first_member"='rowland smith' AND "second_member"='sir henry wilmot, bt';
## Task Generate a SQL query to answer the following question: `Which election has a conservative first party, Rowland Smith as first member, and Sir Henry Wilmot, Bt as second member?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "m_ps_1832_1885" ( "election" text, "first_member" text, "first_party" text, "second_member" text, "second_party" text ); ### SQL Given the database schema, here is the SQL query that answers `Which election has a conservative first party, Rowland Smith as first member, and Sir Henry Wilmot, Bt as second member?`: ```sql
SELECT "first_party" FROM "m_ps_1832_1885" WHERE "second_member"='charles robert colvile' AND "second_party"='liberal';
## Task Generate a SQL query to answer the following question: `Which of the first parties has second member as Charles Robert Colvile, and a liberal second party?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "m_ps_1832_1885" ( "election" text, "first_member" text, "first_party" text, "second_member" text, "second_party" text ); ### SQL Given the database schema, here is the SQL query that answers `Which of the first parties has second member as Charles Robert Colvile, and a liberal second party?`: ```sql
SELECT "election" FROM "m_ps_1832_1885" WHERE "second_member"='charles robert colvile' AND "first_party"='conservative' AND "first_member"='william mundy';
## Task Generate a SQL query to answer the following question: `Which election has second member Charles Robert Colvile, a conservative first party, and first member William Mundy?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "m_ps_1832_1885" ( "election" text, "first_member" text, "first_party" text, "second_member" text, "second_party" text ); ### SQL Given the database schema, here is the SQL query that answers `Which election has second member Charles Robert Colvile, a conservative first party, and first member William Mundy?`: ```sql
SELECT "second_party" FROM "m_ps_1832_1885" WHERE "second_member"='charles robert colvile' AND "first_party"='conservative' AND "first_member"='william mundy';
## Task Generate a SQL query to answer the following question: `Which of the second parties has second member Charles Robert Colvile, a conservative first party, and first member William Mundy?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "m_ps_1832_1885" ( "election" text, "first_member" text, "first_party" text, "second_member" text, "second_party" text ); ### SQL Given the database schema, here is the SQL query that answers `Which of the second parties has second member Charles Robert Colvile, a conservative first party, and first member William Mundy?`: ```sql
SELECT "first_member" FROM "m_ps_1832_1885" WHERE "election"='1868';
## Task Generate a SQL query to answer the following question: `Who is the first member in the 1868 election?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "m_ps_1832_1885" ( "election" text, "first_member" text, "first_party" text, "second_member" text, "second_party" text ); ### SQL Given the database schema, here is the SQL query that answers `Who is the first member in the 1868 election?`: ```sql
SELECT "source" FROM "out" WHERE "type"='transfer' AND "nat"='mex';
## Task Generate a SQL query to answer the following question: `WHAT IS THE SOURCE WITH A TYPE OF TRANSFER AND MEX?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "out" ( "nat" text, "name" text, "moving_to" text, "type" text, "transfer_window" text, "transfer_fee" text, "source" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE SOURCE WITH A TYPE OF TRANSFER AND MEX?`: ```sql
SELECT "name" FROM "out" WHERE "moving_to"='bayer leverkusen';
## Task Generate a SQL query to answer the following question: `WHAT IS THE NAME WITH BAYER LEVERKUSEN?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "out" ( "nat" text, "name" text, "moving_to" text, "type" text, "transfer_window" text, "transfer_fee" text, "source" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE NAME WITH BAYER LEVERKUSEN?`: ```sql
SELECT "name" FROM "out" WHERE "transfer_fee"='free' AND "moving_to"='retired';
## Task Generate a SQL query to answer the following question: `WHAT NAME HAS A FREE TRANSFER FREE AND RETIRED?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "out" ( "nat" text, "name" text, "moving_to" text, "type" text, "transfer_window" text, "transfer_fee" text, "source" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT NAME HAS A FREE TRANSFER FREE AND RETIRED?`: ```sql
SELECT "transfer_fee" FROM "out" WHERE "type"='transfer' AND "name"='dos santos';
## Task Generate a SQL query to answer the following question: `WHAT TRANSFER FEE HAS A TYPE OF TRANSFER FOR DOS SANTOS?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "out" ( "nat" text, "name" text, "moving_to" text, "type" text, "transfer_window" text, "transfer_fee" text, "source" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT TRANSFER FEE HAS A TYPE OF TRANSFER FOR DOS SANTOS?`: ```sql
SELECT SUM("all_around") FROM "finals_6_balls" WHERE "total"=37.75;
## Task Generate a SQL query to answer the following question: `What is the sum of the all around with a 37.75 total?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "finals_6_balls" ( "place" real, "nation" text, "all_around" real, "final" real, "total" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the sum of the all around with a 37.75 total?`: ```sql
SELECT AVG("final") FROM "finals_6_balls" WHERE "all_around">19.4 AND "total">39.9;
## Task Generate a SQL query to answer the following question: `What is the average final with an all around larger than 19.4 and total more than 39.9?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "finals_6_balls" ( "place" real, "nation" text, "all_around" real, "final" real, "total" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the average final with an all around larger than 19.4 and total more than 39.9?`: ```sql
SELECT "name" FROM "season_effects" WHERE "dates_active"='season aggregates';
## Task Generate a SQL query to answer the following question: `What is the name of the storm active during season aggregates?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "season_effects" ( "name" text, "dates_active" text, "windspeeds" text, "pressure" text, "deaths" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the name of the storm active during season aggregates?`: ```sql
SELECT "report" FROM "matches" WHERE "status"='tour match' AND "against"<22;
## Task Generate a SQL query to answer the following question: `What report has tour match as the status, with an against less than 22?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "matches" ( "opposing_team" text, "against" real, "date" text, "venue" text, "status" text, "report" text ); ### SQL Given the database schema, here is the SQL query that answers `What report has tour match as the status, with an against less than 22?`: ```sql
SELECT SUM("against") FROM "matches" WHERE "venue"='asba park, kimberley';
## Task Generate a SQL query to answer the following question: `How many againsts have asba park, kimberley as the venue?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "matches" ( "opposing_team" text, "against" real, "date" text, "venue" text, "status" text, "report" text ); ### SQL Given the database schema, here is the SQL query that answers `How many againsts have asba park, kimberley as the venue?`: ```sql
SELECT "status" FROM "matches" WHERE "opposing_team"='gauteng falcons';
## Task Generate a SQL query to answer the following question: `What status has gauteng falcons as the opposing team?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "matches" ( "opposing_team" text, "against" real, "date" text, "venue" text, "status" text, "report" text ); ### SQL Given the database schema, here is the SQL query that answers `What status has gauteng falcons as the opposing team?`: ```sql
SELECT "opposing_team" FROM "matches" WHERE "status"='second test';
## Task Generate a SQL query to answer the following question: `What opposing team has second test as the status?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "matches" ( "opposing_team" text, "against" real, "date" text, "venue" text, "status" text, "report" text ); ### SQL Given the database schema, here is the SQL query that answers `What opposing team has second test as the status?`: ```sql
SELECT "report" FROM "matches" WHERE "opposing_team"='gauteng falcons';
## Task Generate a SQL query to answer the following question: `What report has gauteng falcons as the opposing team?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "matches" ( "opposing_team" text, "against" real, "date" text, "venue" text, "status" text, "report" text ); ### SQL Given the database schema, here is the SQL query that answers `What report has gauteng falcons as the opposing team?`: ```sql
SELECT "status" FROM "matches" WHERE "against"=18;
## Task Generate a SQL query to answer the following question: `What status has 18 as the against?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "matches" ( "opposing_team" text, "against" real, "date" text, "venue" text, "status" text, "report" text ); ### SQL Given the database schema, here is the SQL query that answers `What status has 18 as the against?`: ```sql
SELECT "receipts_per_arrival_2010_col_2_col_1_usd" FROM "comparative_performance_in_the_latin_ame" WHERE "selected_caribbean_and_n_latin_america_countries"='colombia (1)';
## Task Generate a SQL query to answer the following question: `What is the number of recepits per arrival in 2010 (col 2)/(col 1) USD with colombia (1) as the selected carribean and latin american country?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "comparative_performance_in_the_latin_ame" ( "selected_caribbean_and_n_latin_america_countries" text, "internl_tourist_arrivals_2011_x1000" real, "internl_tourism_receipts_2011_million_usd" text, "receipts_per_arrival_2010_col_2_col_1_usd" text, "receipts_per_capita_2005_usd" real, "revenues_as_pct_of_exports_goods_and_services_2011" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the number of recepits per arrival in 2010 (col 2)/(col 1) USD with colombia (1) as the selected carribean and latin american country?`: ```sql
SELECT "17th_c" FROM "initial_unstressed_syllables" WHERE "initial_syllable_open_semi_open_unstressed_vowels"='o /ɵ/';
## Task Generate a SQL query to answer the following question: `What is 17th c., when Initial-Syllable Open/Semi-Open Unstressed Vowels is "o /ɵ/"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "initial_unstressed_syllables" ( "initial_syllable_open_semi_open_unstressed_vowels" text, "17th_c" text, "american" text, "british" text, "australian" text, "examples" text ); ### SQL Given the database schema, here is the SQL query that answers `What is 17th c., when Initial-Syllable Open/Semi-Open Unstressed Vowels is "o /ɵ/"?`: ```sql
SELECT "british" FROM "initial_unstressed_syllables" WHERE "examples"='november, rotunda, colossus, proscenium';
## Task Generate a SQL query to answer the following question: `What is British, when Examples is "November, rotunda, colossus, proscenium"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "initial_unstressed_syllables" ( "initial_syllable_open_semi_open_unstressed_vowels" text, "17th_c" text, "american" text, "british" text, "australian" text, "examples" text ); ### SQL Given the database schema, here is the SQL query that answers `What is British, when Examples is "November, rotunda, colossus, proscenium"?`: ```sql
SELECT "american" FROM "initial_unstressed_syllables" WHERE "british"='ɪ, ə' AND "initial_syllable_open_semi_open_unstressed_vowels"='æ /ɨ/';
## Task Generate a SQL query to answer the following question: `What is American, when British is "ɪ, ə", and when Initial-Syllable Open/Semi-Open Unstressed Vowels is "æ /ɨ/"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "initial_unstressed_syllables" ( "initial_syllable_open_semi_open_unstressed_vowels" text, "17th_c" text, "american" text, "british" text, "australian" text, "examples" text ); ### SQL Given the database schema, here is the SQL query that answers `What is American, when British is "ɪ, ə", and when Initial-Syllable Open/Semi-Open Unstressed Vowels is "æ /ɨ/"?`: ```sql
SELECT "initial_syllable_open_semi_open_unstressed_vowels" FROM "initial_unstressed_syllables" WHERE "australian"='ə';
## Task Generate a SQL query to answer the following question: `What is Initial-Syllable Open/Semi-Open Unstresses Vowels, when Australian is "ə"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "initial_unstressed_syllables" ( "initial_syllable_open_semi_open_unstressed_vowels" text, "17th_c" text, "american" text, "british" text, "australian" text, "examples" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Initial-Syllable Open/Semi-Open Unstresses Vowels, when Australian is "ə"?`: ```sql
SELECT "australian" FROM "initial_unstressed_syllables" WHERE "british"='aɪ, ɪ, ə';
## Task Generate a SQL query to answer the following question: `What is Australian, when British is "aɪ, ɪ, ə"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "initial_unstressed_syllables" ( "initial_syllable_open_semi_open_unstressed_vowels" text, "17th_c" text, "american" text, "british" text, "australian" text, "examples" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Australian, when British is "aɪ, ɪ, ə"?`: ```sql
SELECT "american" FROM "initial_unstressed_syllables" WHERE "initial_syllable_open_semi_open_unstressed_vowels"='y /aɪ, ɨ/';
## Task Generate a SQL query to answer the following question: `What is American, when Initial-Syllable Open/Semi-Open Unstressed Vowels is "y /aɪ, ɨ/"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "initial_unstressed_syllables" ( "initial_syllable_open_semi_open_unstressed_vowels" text, "17th_c" text, "american" text, "british" text, "australian" text, "examples" text ); ### SQL Given the database schema, here is the SQL query that answers `What is American, when Initial-Syllable Open/Semi-Open Unstressed Vowels is "y /aɪ, ɨ/"?`: ```sql
SELECT "date" FROM "release_history" WHERE "catalog"='rcd 10160';
## Task Generate a SQL query to answer the following question: `What is the date for catalog RCD 10160?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "release_history" ( "country" text, "date" text, "label" text, "format" text, "catalog" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the date for catalog RCD 10160?`: ```sql
SELECT "country" FROM "release_history" WHERE "format"='cd' AND "catalog"='rcd 10523';
## Task Generate a SQL query to answer the following question: `What country has CD format and catalog RCD 10523?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "release_history" ( "country" text, "date" text, "label" text, "format" text, "catalog" text ); ### SQL Given the database schema, here is the SQL query that answers `What country has CD format and catalog RCD 10523?`: ```sql
SELECT "country" FROM "release_history" WHERE "date"='october 20, 1976';
## Task Generate a SQL query to answer the following question: `Which country is dated October 20, 1976?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "release_history" ( "country" text, "date" text, "label" text, "format" text, "catalog" text ); ### SQL Given the database schema, here is the SQL query that answers `Which country is dated October 20, 1976?`: ```sql
SELECT "label" FROM "release_history" WHERE "catalog"='cdzap22';
## Task Generate a SQL query to answer the following question: `Which label has the catalog CDZAP22?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "release_history" ( "country" text, "date" text, "label" text, "format" text, "catalog" text ); ### SQL Given the database schema, here is the SQL query that answers `Which label has the catalog CDZAP22?`: ```sql
SELECT "date" FROM "release_history" WHERE "country"='united kingdom' AND "catalog"='cdzap22';
## Task Generate a SQL query to answer the following question: `What is the date for the catalog CDZAP22 in the United Kingdom?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "release_history" ( "country" text, "date" text, "label" text, "format" text, "catalog" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the date for the catalog CDZAP22 in the United Kingdom?`: ```sql
SELECT "place" FROM "first_round" WHERE "score"=66 AND "country"='united states' AND "player"='dudley hart';
## Task Generate a SQL query to answer the following question: `What is Place, when Score is "66", when Country is "United States", and when Player is "Dudley Hart"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round" ( "place" text, "player" text, "country" text, "score" real, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Place, when Score is "66", when Country is "United States", and when Player is "Dudley Hart"?`: ```sql
SELECT MIN("score") FROM "first_round" WHERE "place"='1';
## Task Generate a SQL query to answer the following question: `What is the lowest Score, when Place is "1"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round" ( "place" text, "player" text, "country" text, "score" real, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the lowest Score, when Place is "1"?`: ```sql
SELECT "to_par" FROM "first_round" WHERE "score"=66 AND "player"='brad faxon';
## Task Generate a SQL query to answer the following question: `What is To Par, when Score is "66", and when Player is "Brad Faxon"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round" ( "place" text, "player" text, "country" text, "score" real, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What is To Par, when Score is "66", and when Player is "Brad Faxon"?`: ```sql
SELECT "opponent_in_the_final" FROM "pro_am_event_finals_5_4_titles_1_runner_" WHERE "year">2008 AND "championship"='paul hunter classic';
## Task Generate a SQL query to answer the following question: `What is the Opponent in the final after 2008 at the Paul Hunter Classic?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "pro_am_event_finals_5_4_titles_1_runner_" ( "outcome" text, "year" real, "championship" text, "opponent_in_the_final" text, "score" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the Opponent in the final after 2008 at the Paul Hunter Classic?`: ```sql
SELECT MAX("first_elected") FROM "indiana" WHERE "results"='lost re-election democratic gain' AND "incumbent"='john hostettler';
## Task Generate a SQL query to answer the following question: `What is the latest year for first elected with john hostettler as incumbent and a result of lost re-election democratic gain?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "indiana" ( "district" text, "incumbent" text, "party" text, "first_elected" real, "results" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the latest year for first elected with john hostettler as incumbent and a result of lost re-election democratic gain?`: ```sql
SELECT "owner_operator" FROM "onshore_pipelines" WHERE "from_to"='kambalda to esperance';
## Task Generate a SQL query to answer the following question: `Who is the owner/operator of the line from Kambalda to Esperance?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "onshore_pipelines" ( "name_year_commissioned" text, "owner_operator" text, "length" text, "maximum_diameter" text, "from_to" text, "licence_number" text ); ### SQL Given the database schema, here is the SQL query that answers `Who is the owner/operator of the line from Kambalda to Esperance?`: ```sql
SELECT "name_year_commissioned" FROM "onshore_pipelines" WHERE "from_to"='karratha to port hedland';
## Task Generate a SQL query to answer the following question: `What is the name of the line from Karratha to Port Hedland?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "onshore_pipelines" ( "name_year_commissioned" text, "owner_operator" text, "length" text, "maximum_diameter" text, "from_to" text, "licence_number" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the name of the line from Karratha to Port Hedland?`: ```sql
SELECT "maximum_diameter" FROM "onshore_pipelines" WHERE "name_year_commissioned"='mid west gas pipeline (1999)';
## Task Generate a SQL query to answer the following question: `What is the maximum diameter of the Mid West Gas Pipeline (1999)?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "onshore_pipelines" ( "name_year_commissioned" text, "owner_operator" text, "length" text, "maximum_diameter" text, "from_to" text, "licence_number" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the maximum diameter of the Mid West Gas Pipeline (1999)?`: ```sql
SELECT "owner_operator" FROM "onshore_pipelines" WHERE "licence_number"='pl 59';
## Task Generate a SQL query to answer the following question: `Who is the owner operator who has license number PL 59?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "onshore_pipelines" ( "name_year_commissioned" text, "owner_operator" text, "length" text, "maximum_diameter" text, "from_to" text, "licence_number" text ); ### SQL Given the database schema, here is the SQL query that answers `Who is the owner operator who has license number PL 59?`: ```sql
SELECT "licence_number" FROM "onshore_pipelines" WHERE "maximum_diameter"='400 mm';
## Task Generate a SQL query to answer the following question: `What is the license number where the maximum diameter is 400 mm?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "onshore_pipelines" ( "name_year_commissioned" text, "owner_operator" text, "length" text, "maximum_diameter" text, "from_to" text, "licence_number" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the license number where the maximum diameter is 400 mm?`: ```sql
SELECT "name_year_commissioned" FROM "onshore_pipelines" WHERE "licence_number"='pl 22';
## Task Generate a SQL query to answer the following question: `What is the name where the license number is PL 22?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "onshore_pipelines" ( "name_year_commissioned" text, "owner_operator" text, "length" text, "maximum_diameter" text, "from_to" text, "licence_number" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the name where the license number is PL 22?`: ```sql
SELECT "venue" FROM "1978" WHERE "against"=16;
## Task Generate a SQL query to answer the following question: `Which venue has 16 against?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1978" ( "opposing_teams" text, "against" real, "date" text, "venue" text, "status" text ); ### SQL Given the database schema, here is the SQL query that answers `Which venue has 16 against?`: ```sql
SELECT AVG("against") FROM "1978" WHERE "status"='five nations' AND "opposing_teams"='wales';
## Task Generate a SQL query to answer the following question: `What is the against for the opposing team of Wales with the status of Five Nations?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1978" ( "opposing_teams" text, "against" real, "date" text, "venue" text, "status" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the against for the opposing team of Wales with the status of Five Nations?`: ```sql
SELECT AVG("average") FROM "one_day_internationals" WHERE "rank">4 AND "player"='dean minors';
## Task Generate a SQL query to answer the following question: `Can you tell me the average Average that has the Rank larger than 4, and the Player of dean minors?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "one_day_internationals" ( "rank" real, "player" text, "runs" real, "average" real, "career" text ); ### SQL Given the database schema, here is the SQL query that answers `Can you tell me the average Average that has the Rank larger than 4, and the Player of dean minors?`: ```sql
SELECT "venue" FROM "winners" WHERE "runner_up"='john zibnack';
## Task Generate a SQL query to answer the following question: `What is the venue where john zibnack was the runner-up?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "winners" ( "year" text, "winner" text, "runner_up" text, "venue" text, "location" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the venue where john zibnack was the runner-up?`: ```sql
SELECT "winner" FROM "winners" WHERE "location"='des moines, iowa' AND "runner_up"='p.h. finkbank';
## Task Generate a SQL query to answer the following question: `Who is the winner in des moines, iowa where p.h. finkbank was the runner-up?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "winners" ( "year" text, "winner" text, "runner_up" text, "venue" text, "location" text ); ### SQL Given the database schema, here is the SQL query that answers `Who is the winner in des moines, iowa where p.h. finkbank was the runner-up?`: ```sql
SELECT "location" FROM "winners" WHERE "runner_up"='ed c. kingsley' AND "year"='1939';
## Task Generate a SQL query to answer the following question: `What is the location where ed c. kingsley was the runner-up in 1939?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "winners" ( "year" text, "winner" text, "runner_up" text, "venue" text, "location" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the location where ed c. kingsley was the runner-up in 1939?`: ```sql
SELECT "winner" FROM "winners" WHERE "runner_up"='mark fuller';
## Task Generate a SQL query to answer the following question: `Who is the winner when mark fuller was the runner-up?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "winners" ( "year" text, "winner" text, "runner_up" text, "venue" text, "location" text ); ### SQL Given the database schema, here is the SQL query that answers `Who is the winner when mark fuller was the runner-up?`: ```sql
SELECT "venue" FROM "winners" WHERE "year"='2002';
## Task Generate a SQL query to answer the following question: `What is the venue in 2002?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "winners" ( "year" text, "winner" text, "runner_up" text, "venue" text, "location" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the venue in 2002?`: ```sql
SELECT "runner_up" FROM "winners" WHERE "year"='1901';
## Task Generate a SQL query to answer the following question: `Who is the runner-up in 1901?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "winners" ( "year" text, "winner" text, "runner_up" text, "venue" text, "location" text ); ### SQL Given the database schema, here is the SQL query that answers `Who is the runner-up in 1901?`: ```sql
SELECT "australian" FROM "short_vowels" WHERE "short_vowels"='e /ɛ/';
## Task Generate a SQL query to answer the following question: `What Australian sound is equivalent to e /ɛ/?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "short_vowels" ( "short_vowels" text, "17th_c" text, "american" text, "british" text, "australian" text ); ### SQL Given the database schema, here is the SQL query that answers `What Australian sound is equivalent to e /ɛ/?`: ```sql
SELECT "score" FROM "regular_season" WHERE "home"='new york islanders';
## Task Generate a SQL query to answer the following question: `What was the score of the game when they played at new york islanders?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "regular_season" ( "date" text, "visitor" text, "score" text, "home" text, "record" text ); ### SQL Given the database schema, here is the SQL query that answers `What was the score of the game when they played at new york islanders?`: ```sql
SELECT "r_epp" FROM "spelling" WHERE "j_thiessen"='tjoatj';
## Task Generate a SQL query to answer the following question: `Which of the R. Epp, has J Thiessen of Tjoatj?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "spelling" ( "a_dyck" text, "h_rempel" text, "r_epp" text, "j_thiessen" text, "j_j_neufeld" text, "ed_zacharias" text, "word_meaning" text ); ### SQL Given the database schema, here is the SQL query that answers `Which of the R. Epp, has J Thiessen of Tjoatj?`: ```sql
SELECT "r_epp" FROM "spelling" WHERE "ed_zacharias"='rollen, jerolt, golt';
## Task Generate a SQL query to answer the following question: `Which of the R. Epp, has Ed Zacharias from Rollen, Jerolt, Golt?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "spelling" ( "a_dyck" text, "h_rempel" text, "r_epp" text, "j_thiessen" text, "j_j_neufeld" text, "ed_zacharias" text, "word_meaning" text ); ### SQL Given the database schema, here is the SQL query that answers `Which of the R. Epp, has Ed Zacharias from Rollen, Jerolt, Golt?`: ```sql
SELECT "a_dyck" FROM "spelling" WHERE "j_thiessen"='du';
## Task Generate a SQL query to answer the following question: `Which of the A. Dyck has J. Thiessen of Du?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "spelling" ( "a_dyck" text, "h_rempel" text, "r_epp" text, "j_thiessen" text, "j_j_neufeld" text, "ed_zacharias" text, "word_meaning" text ); ### SQL Given the database schema, here is the SQL query that answers `Which of the A. Dyck has J. Thiessen of Du?`: ```sql
SELECT "h_rempel" FROM "spelling" WHERE "j_j_neufeld"='sajen';
## Task Generate a SQL query to answer the following question: `Which of the H. Rempel has J. J. Neufeld of Sajen?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "spelling" ( "a_dyck" text, "h_rempel" text, "r_epp" text, "j_thiessen" text, "j_j_neufeld" text, "ed_zacharias" text, "word_meaning" text ); ### SQL Given the database schema, here is the SQL query that answers `Which of the H. Rempel has J. J. Neufeld of Sajen?`: ```sql
SELECT SUM("against") FROM "2003" WHERE "status"='six nations' AND "date"='30/03/2003';
## Task Generate a SQL query to answer the following question: `What is the sum of Against, when Status is "Six Nations", and when Date is "30/03/2003"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2003" ( "opposing_teams" text, "against" real, "date" text, "venue" text, "status" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the sum of Against, when Status is "Six Nations", and when Date is "30/03/2003"?`: ```sql
SELECT "opposing_teams" FROM "2003" WHERE "against"<6;
## Task Generate a SQL query to answer the following question: `What is Opposing Teams, when Against is less than 6?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2003" ( "opposing_teams" text, "against" real, "date" text, "venue" text, "status" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Opposing Teams, when Against is less than 6?`: ```sql
SELECT "date" FROM "2003" WHERE "against"=22;
## Task Generate a SQL query to answer the following question: `What is Date, when Against is "22"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2003" ( "opposing_teams" text, "against" real, "date" text, "venue" text, "status" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Date, when Against is "22"?`: ```sql
SELECT MAX("money") FROM "final_round" WHERE "country"='south africa';
## Task Generate a SQL query to answer the following question: `What shows for money (£) when South Africa is the country?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "final_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text, "money" real ); ### SQL Given the database schema, here is the SQL query that answers `What shows for money (£) when South Africa is the country?`: ```sql
SELECT "to_par" FROM "final_round" WHERE "player"='lanny wadkins';
## Task Generate a SQL query to answer the following question: `What is the To par when Lanny Wadkins is the player?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "final_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text, "money" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the To par when Lanny Wadkins is the player?`: ```sql
SELECT "score" FROM "singles_9_6_3" WHERE "outcome"='runner-up' AND "tournament"='marco island';
## Task Generate a SQL query to answer the following question: `What was the score of the marco island tournament match when Kathleen Horvath won runner-up?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "singles_9_6_3" ( "outcome" text, "date" text, "tournament" text, "surface" text, "opponent" text, "score" text ); ### SQL Given the database schema, here is the SQL query that answers `What was the score of the marco island tournament match when Kathleen Horvath won runner-up?`: ```sql
SELECT "tournament" FROM "singles_9_6_3" WHERE "date"='july 6, 1987';
## Task Generate a SQL query to answer the following question: `What was the tournament that was on july 6, 1987?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "singles_9_6_3" ( "outcome" text, "date" text, "tournament" text, "surface" text, "opponent" text, "score" text ); ### SQL Given the database schema, here is the SQL query that answers `What was the tournament that was on july 6, 1987?`: ```sql
SELECT "position" FROM "1962_pro_draftees" WHERE "pick"=246;
## Task Generate a SQL query to answer the following question: `What is pick 246's position?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1962_pro_draftees" ( "player" text, "draft" text, "round" real, "pick" real, "position" text, "nfl_club" text ); ### SQL Given the database schema, here is the SQL query that answers `What is pick 246's position?`: ```sql
SELECT "pick" FROM "1962_pro_draftees" WHERE "player"='chuck bryant' AND "nfl_club"='san diego chargers';
## Task Generate a SQL query to answer the following question: `Which Pick has a Player of chuck bryant, and an NFL Club of san diego chargers?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1962_pro_draftees" ( "player" text, "draft" text, "round" real, "pick" real, "position" text, "nfl_club" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Pick has a Player of chuck bryant, and an NFL Club of san diego chargers?`: ```sql
SELECT "position" FROM "1962_pro_draftees" WHERE "nfl_club"='pittsburgh steelers';
## Task Generate a SQL query to answer the following question: `What is the position of the pittsburgh steelers?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1962_pro_draftees" ( "player" text, "draft" text, "round" real, "pick" real, "position" text, "nfl_club" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the position of the pittsburgh steelers?`: ```sql
SELECT "nfl_club" FROM "1962_pro_draftees" WHERE "player"='sam tidmore' AND "pick"=81;
## Task Generate a SQL query to answer the following question: `Which NFL Club has a Player of sam tidmore, and a Pick of 81?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1962_pro_draftees" ( "player" text, "draft" text, "round" real, "pick" real, "position" text, "nfl_club" text ); ### SQL Given the database schema, here is the SQL query that answers `Which NFL Club has a Player of sam tidmore, and a Pick of 81?`: ```sql
SELECT "club" FROM "european_history" WHERE "round"='group stage round 1 and 5';
## Task Generate a SQL query to answer the following question: `Which club had round of group stage round 1 and 5?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "european_history" ( "round" text, "club" text, "home" text, "away" text, "aggregate" text ); ### SQL Given the database schema, here is the SQL query that answers `Which club had round of group stage round 1 and 5?`: ```sql
SELECT "aggregate" FROM "european_history" WHERE "round"='first round' AND "club"='k.s.v. waregem';
## Task Generate a SQL query to answer the following question: `What is the aggregate for the first round for K.S.V. Waregem?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "european_history" ( "round" text, "club" text, "home" text, "away" text, "aggregate" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the aggregate for the first round for K.S.V. Waregem?`: ```sql
SELECT "away" FROM "european_history" WHERE "round"='second round';
## Task Generate a SQL query to answer the following question: `What is the away where the round is the second round?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "european_history" ( "round" text, "club" text, "home" text, "away" text, "aggregate" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the away where the round is the second round?`: ```sql
SELECT "team_1" FROM "round_16_matches" WHERE "2nd_leg"='1-3';
## Task Generate a SQL query to answer the following question: `Which Team 1 has a 2nd leg of 1-3?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_16_matches" ( "team_1" text, "agg" text, "team_2" text, "1st_leg" text, "2nd_leg" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Team 1 has a 2nd leg of 1-3?`: ```sql
SELECT "agg" FROM "round_16_matches" WHERE "1st_leg"='1-2' AND "2nd_leg"='withdrew';
## Task Generate a SQL query to answer the following question: `What is the Agg for 1st Leg 1-2 and 2nd leg of Withdrew?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_16_matches" ( "team_1" text, "agg" text, "team_2" text, "1st_leg" text, "2nd_leg" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the Agg for 1st Leg 1-2 and 2nd leg of Withdrew?`: ```sql
SELECT "2nd_leg" FROM "round_16_matches" WHERE "1st_leg"='3-1' AND "team_2"='union sportive de la médina d''alger';
## Task Generate a SQL query to answer the following question: `What is the 2nd leg if the 1st leg is 3-1 and the Team 2 is union sportive de la médina d'alger?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_16_matches" ( "team_1" text, "agg" text, "team_2" text, "1st_leg" text, "2nd_leg" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the 2nd leg if the 1st leg is 3-1 and the Team 2 is union sportive de la médina d'alger?`: ```sql
SELECT "team_2" FROM "round_16_matches" WHERE "1st_leg"='3-1' AND "2nd_leg"='4-1';
## Task Generate a SQL query to answer the following question: `What is Team 2 if the 1st Leg is 3-1 and the 2nd Leg is 4-1?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_16_matches" ( "team_1" text, "agg" text, "team_2" text, "1st_leg" text, "2nd_leg" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Team 2 if the 1st Leg is 3-1 and the 2nd Leg is 4-1?`: ```sql
SELECT "broadcast_date" FROM "serial_details_by_episode" WHERE "run_time"='24:44';
## Task Generate a SQL query to answer the following question: `What was the broadcaste date for the episode with a run time of 24:44?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "serial_details_by_episode" ( "episode" text, "broadcast_date" text, "run_time" text, "viewers_in_millions" text, "archive" text ); ### SQL Given the database schema, here is the SQL query that answers `What was the broadcaste date for the episode with a run time of 24:44?`: ```sql
SELECT "episode" FROM "serial_details_by_episode" WHERE "viewers_in_millions"='9.1';
## Task Generate a SQL query to answer the following question: `Which Episode had 9.1 million viewers?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "serial_details_by_episode" ( "episode" text, "broadcast_date" text, "run_time" text, "viewers_in_millions" text, "archive" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Episode had 9.1 million viewers?`: ```sql
SELECT "country" FROM "first_round_history" WHERE "previous_team_league"='kingston frontenacs ( ohl )' AND "player"='anthony stewart category:articles with hcards';
## Task Generate a SQL query to answer the following question: `What is Country, when Previous Team (League) is "Kingston Frontenacs ( OHL )", and when Player is "Anthony Stewart Category:Articles with hCards"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_history" ( "year" real, "pick" text, "player" text, "position" text, "country" text, "previous_team_league" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Country, when Previous Team (League) is "Kingston Frontenacs ( OHL )", and when Player is "Anthony Stewart Category:Articles with hCards"?`: ```sql
SELECT "player" FROM "first_round_history" WHERE "pick"='3' AND "position"='defense' AND "year"<2010;
## Task Generate a SQL query to answer the following question: `What is Player, when Pick is "3", when Position is "Defense", and when Year is less than 2010?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_history" ( "year" real, "pick" text, "player" text, "position" text, "country" text, "previous_team_league" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Player, when Pick is "3", when Position is "Defense", and when Year is less than 2010?`: ```sql
SELECT "position" FROM "first_round_history" WHERE "year"<2000 AND "player"='radek dvorak category:articles with hcards';
## Task Generate a SQL query to answer the following question: `What is Position, when Year is less than 2000, and when Player is "Radek Dvorak Category:Articles with hCards"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_history" ( "year" real, "pick" text, "player" text, "position" text, "country" text, "previous_team_league" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Position, when Year is less than 2000, and when Player is "Radek Dvorak Category:Articles with hCards"?`: ```sql
SELECT "player" FROM "first_round_history" WHERE "previous_team_league"='medicine hat tigers ( whl )' AND "year"<2002;
## Task Generate a SQL query to answer the following question: `What is Player, when Previous Team (League) is "Medicine Hat Tigers ( WHL )", and when Year is less than 2002?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_history" ( "year" real, "pick" text, "player" text, "position" text, "country" text, "previous_team_league" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Player, when Previous Team (League) is "Medicine Hat Tigers ( WHL )", and when Year is less than 2002?`: ```sql
SELECT "country" FROM "first_round_history" WHERE "year"=1994;
## Task Generate a SQL query to answer the following question: `What is Country, when Year is "1994"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_history" ( "year" real, "pick" text, "player" text, "position" text, "country" text, "previous_team_league" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Country, when Year is "1994"?`: ```sql
SELECT "episode" FROM "serial_details_by_episode" WHERE "viewers_in_millions"='7.8';
## Task Generate a SQL query to answer the following question: `What episode has 7.8 million viewers?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "serial_details_by_episode" ( "episode" text, "broadcast_date" text, "run_time" text, "viewers_in_millions" text, "archive" text ); ### SQL Given the database schema, here is the SQL query that answers `What episode has 7.8 million viewers?`: ```sql
SELECT "episode" FROM "serial_details_by_episode" WHERE "run_time"='25:12';
## Task Generate a SQL query to answer the following question: `What episode has a run time of 25:12?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "serial_details_by_episode" ( "episode" text, "broadcast_date" text, "run_time" text, "viewers_in_millions" text, "archive" text ); ### SQL Given the database schema, here is the SQL query that answers `What episode has a run time of 25:12?`: ```sql
SELECT "broadcast_date" FROM "serial_details_by_episode" WHERE "viewers_in_millions"='7.0';
## Task Generate a SQL query to answer the following question: `What is the broadcast date with 7.0 million viewers?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "serial_details_by_episode" ( "episode" text, "broadcast_date" text, "run_time" text, "viewers_in_millions" text, "archive" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the broadcast date with 7.0 million viewers?`: ```sql
SELECT AVG("total") FROM "missed_the_cut" WHERE "player"='dave stockton';
## Task Generate a SQL query to answer the following question: `What is the average total for Dave Stockton?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "missed_the_cut" ( "player" text, "country" text, "year_s_won" text, "total" real, "to_par" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the average total for Dave Stockton?`: ```sql
SELECT SUM("to_par") FROM "missed_the_cut" WHERE "country"='united states' AND "year_s_won"='1967' AND "total">146;
## Task Generate a SQL query to answer the following question: `What is the sum of the to par for the United States in the winning year of 1967, and has a total of more than 146?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "missed_the_cut" ( "player" text, "country" text, "year_s_won" text, "total" real, "to_par" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the sum of the to par for the United States in the winning year of 1967, and has a total of more than 146?`: ```sql
SELECT "score" FROM "fourth_round_proper" WHERE "away_team"='arsenal';
## Task Generate a SQL query to answer the following question: `What is the score for the game in which Arsenal was the away team?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "fourth_round_proper" ( "tie_no" text, "home_team" text, "score" text, "away_team" text, "attendance" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the score for the game in which Arsenal was the away team?`: ```sql
SELECT "score" FROM "fourth_round_proper" WHERE "tie_no"='15';
## Task Generate a SQL query to answer the following question: `What is the score for the tie number 15?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "fourth_round_proper" ( "tie_no" text, "home_team" text, "score" text, "away_team" text, "attendance" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the score for the tie number 15?`: ```sql