output
stringlengths
27
479
instruction
stringlengths
407
1.39k
SELECT "player" FROM "made_the_cut" WHERE "finish"='t48' AND "year_s_won"='1997';
## Task Generate a SQL query to answer the following question: `Who won in 1997 with a finish of t48?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "made_the_cut" ( "player" text, "country" text, "year_s_won" text, "total" real, "to_par" text, "finish" text ); ### SQL Given the database schema, here is the SQL query that answers `Who won in 1997 with a finish of t48?`: ```sql
SELECT "player" FROM "made_the_cut" WHERE "country"='united states' AND "total"=297;
## Task Generate a SQL query to answer the following question: `What player from the United States had a total of 297?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "made_the_cut" ( "player" text, "country" text, "year_s_won" text, "total" real, "to_par" text, "finish" text ); ### SQL Given the database schema, here is the SQL query that answers `What player from the United States had a total of 297?`: ```sql
SELECT "country" FROM "made_the_cut" WHERE "year_s_won"='1988';
## Task Generate a SQL query to answer the following question: `Which country won in 1988?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "made_the_cut" ( "player" text, "country" text, "year_s_won" text, "total" real, "to_par" text, "finish" text ); ### SQL Given the database schema, here is the SQL query that answers `Which country won in 1988?`: ```sql
SELECT "party" FROM "deputy_ministers" WHERE "term_start"='5 august 1999';
## Task Generate a SQL query to answer the following question: `Which party had a term start of 5 august 1999?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "deputy_ministers" ( "minister" text, "party" text, "governments" text, "term_start" text, "term_end" text ); ### SQL Given the database schema, here is the SQL query that answers `Which party had a term start of 5 august 1999?`: ```sql
SELECT "term_end" FROM "deputy_ministers" WHERE "minister"='danny ayalon';
## Task Generate a SQL query to answer the following question: `What term end had minister Danny Ayalon?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "deputy_ministers" ( "minister" text, "party" text, "governments" text, "term_start" text, "term_end" text ); ### SQL Given the database schema, here is the SQL query that answers `What term end had minister Danny Ayalon?`: ```sql
SELECT "governments" FROM "deputy_ministers" WHERE "party"='yisrael beiteinu';
## Task Generate a SQL query to answer the following question: `Which goverment had a party of yisrael beiteinu?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "deputy_ministers" ( "minister" text, "party" text, "governments" text, "term_start" text, "term_end" text ); ### SQL Given the database schema, here is the SQL query that answers `Which goverment had a party of yisrael beiteinu?`: ```sql
SELECT "minister" FROM "deputy_ministers" WHERE "party"='labor party' AND "governments"='26';
## Task Generate a SQL query to answer the following question: `Who was the minister of the labor party and had 26 goverments?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "deputy_ministers" ( "minister" text, "party" text, "governments" text, "term_start" text, "term_end" text ); ### SQL Given the database schema, here is the SQL query that answers `Who was the minister of the labor party and had 26 goverments?`: ```sql
SELECT "category" FROM "awards_and_nominations" WHERE "year"<2011;
## Task Generate a SQL query to answer the following question: `What is the category that came before 2011?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "awards_and_nominations" ( "year" real, "award" text, "category" text, "nominated" text, "result" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the category that came before 2011?`: ```sql
SELECT "year" FROM "awards_and_nominations" WHERE "award"='premios carlos gardel 2009';
## Task Generate a SQL query to answer the following question: `What is the year of the Premios Carlos Gardel 2009 award?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "awards_and_nominations" ( "year" real, "award" text, "category" text, "nominated" text, "result" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the year of the Premios Carlos Gardel 2009 award?`: ```sql
SELECT "height" FROM "delegates" WHERE "contestant"='andrea suarez lazaro';
## Task Generate a SQL query to answer the following question: `What is Andrea Suarez Lazaro's height?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "delegates" ( "province_community" text, "contestant" text, "height" text, "hometown" text, "geographical_regions" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Andrea Suarez Lazaro's height?`: ```sql
SELECT "height" FROM "delegates" WHERE "contestant"='niurbi encarnación ynoa';
## Task Generate a SQL query to answer the following question: `What is niurbi encarnación ynoa's height?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "delegates" ( "province_community" text, "contestant" text, "height" text, "hometown" text, "geographical_regions" text ); ### SQL Given the database schema, here is the SQL query that answers `What is niurbi encarnación ynoa's height?`: ```sql
SELECT "province_community" FROM "delegates" WHERE "hometown"='jamao afuera';
## Task Generate a SQL query to answer the following question: `What is the province for Jamao Afuera?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "delegates" ( "province_community" text, "contestant" text, "height" text, "hometown" text, "geographical_regions" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the province for Jamao Afuera?`: ```sql
SELECT "hometown" FROM "delegates" WHERE "province_community"='santiago';
## Task Generate a SQL query to answer the following question: `What is the hometown for Santiago?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "delegates" ( "province_community" text, "contestant" text, "height" text, "hometown" text, "geographical_regions" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the hometown for Santiago?`: ```sql
SELECT "geographical_regions" FROM "delegates" WHERE "hometown"='imbert';
## Task Generate a SQL query to answer the following question: `What is the geographical region for hometown Imbert?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "delegates" ( "province_community" text, "contestant" text, "height" text, "hometown" text, "geographical_regions" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the geographical region for hometown Imbert?`: ```sql
SELECT "name_of_ship" FROM "ships_attacked" WHERE "date"='20february1942';
## Task Generate a SQL query to answer the following question: `What is the Name of the Ship attacked on 20February1942?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "ships_attacked" ( "date" text, "time" text, "name_of_ship" text, "flag" text, "tonnage" real, "fate" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the Name of the Ship attacked on 20February1942?`: ```sql
SELECT "name_of_ship" FROM "ships_attacked" WHERE "fate"='sunk at' AND "time"='01:00';
## Task Generate a SQL query to answer the following question: `Which ship was sunk at 01:00?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "ships_attacked" ( "date" text, "time" text, "name_of_ship" text, "flag" text, "tonnage" real, "fate" text ); ### SQL Given the database schema, here is the SQL query that answers `Which ship was sunk at 01:00?`: ```sql
SELECT "to_par" FROM "third_round" WHERE "score"='68-72-73=213';
## Task Generate a SQL query to answer the following question: `What is the to par for the 68-72-73=213 score?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "third_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the to par for the 68-72-73=213 score?`: ```sql
SELECT "to_par" FROM "third_round" WHERE "score"='69-70-72=211';
## Task Generate a SQL query to answer the following question: `What is the to par for the 69-70-72=211 score?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "third_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the to par for the 69-70-72=211 score?`: ```sql
SELECT "to_par" FROM "third_round" WHERE "country"='united states' AND "score"='67-71-73=211';
## Task Generate a SQL query to answer the following question: `What is the to par for the United States with a 67-71-73=211 score?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "third_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the to par for the United States with a 67-71-73=211 score?`: ```sql
SELECT "country" FROM "third_round" WHERE "place"='t4' AND "score"='67-71-73=211';
## Task Generate a SQL query to answer the following question: `What country has t4 place and a 67-71-73=211 score?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "third_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What country has t4 place and a 67-71-73=211 score?`: ```sql
SELECT "to_par" FROM "third_round" WHERE "country"='australia' AND "score"='73-69-71=213';
## Task Generate a SQL query to answer the following question: `What is the to par for Australia and a 73-69-71=213 score?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "third_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the to par for Australia and a 73-69-71=213 score?`: ```sql
SELECT "location" FROM "plants" WHERE "partner"='app' AND "population_served">2000 AND "design_flow_lpm"=375;
## Task Generate a SQL query to answer the following question: `What Location has a Partner of app, a Population Served larger than 2000, and a Design flow (LPM) of 375?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "plants" ( "location" text, "partner" text, "construction_start" text, "inauguration_date" text, "population_served" real, "design_flow_lpm" real ); ### SQL Given the database schema, here is the SQL query that answers `What Location has a Partner of app, a Population Served larger than 2000, and a Design flow (LPM) of 375?`: ```sql
SELECT "construction_start" FROM "plants" WHERE "inauguration_date"='2010 june';
## Task Generate a SQL query to answer the following question: `What Construction Start has an Inauguration Date of 2010 june?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "plants" ( "location" text, "partner" text, "construction_start" text, "inauguration_date" text, "population_served" real, "design_flow_lpm" real ); ### SQL Given the database schema, here is the SQL query that answers `What Construction Start has an Inauguration Date of 2010 june?`: ```sql
SELECT "construction_start" FROM "plants" WHERE "design_flow_lpm"=1300;
## Task Generate a SQL query to answer the following question: `What Construction Start has a Design flow (LPM) of 1300?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "plants" ( "location" text, "partner" text, "construction_start" text, "inauguration_date" text, "population_served" real, "design_flow_lpm" real ); ### SQL Given the database schema, here is the SQL query that answers `What Construction Start has a Design flow (LPM) of 1300?`: ```sql
SELECT "location" FROM "plants" WHERE "design_flow_lpm"<1900 AND "construction_start"='2006 june';
## Task Generate a SQL query to answer the following question: `What Location has a Design flow (LPM) smaller than 1900, and a Construction Start of 2006 june?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "plants" ( "location" text, "partner" text, "construction_start" text, "inauguration_date" text, "population_served" real, "design_flow_lpm" real ); ### SQL Given the database schema, here is the SQL query that answers `What Location has a Design flow (LPM) smaller than 1900, and a Construction Start of 2006 june?`: ```sql
SELECT "partner" FROM "plants" WHERE "construction_start"='2008 january';
## Task Generate a SQL query to answer the following question: `What Partner has a Construction Start of 2008 january?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "plants" ( "location" text, "partner" text, "construction_start" text, "inauguration_date" text, "population_served" real, "design_flow_lpm" real ); ### SQL Given the database schema, here is the SQL query that answers `What Partner has a Construction Start of 2008 january?`: ```sql
SELECT SUM("design_flow_lpm") FROM "plants" WHERE "partner"='app' AND "construction_start"='2008 january' AND "population_served">3500;
## Task Generate a SQL query to answer the following question: `What is the total Design flow (LPM) with a Partner of app, a Construction Start of 2008 january, and a Population Served larger than 3500?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "plants" ( "location" text, "partner" text, "construction_start" text, "inauguration_date" text, "population_served" real, "design_flow_lpm" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the total Design flow (LPM) with a Partner of app, a Construction Start of 2008 january, and a Population Served larger than 3500?`: ```sql
SELECT "to_par" FROM "second_round" WHERE "player"='sandy lyle';
## Task Generate a SQL query to answer the following question: `What is Sandy Lyle's To Par?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Sandy Lyle's To Par?`: ```sql
SELECT "score" FROM "second_round" WHERE "country"='australia' AND "place"='t1';
## Task Generate a SQL query to answer the following question: `What is Australia's score where they were in place t1?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Australia's score where they were in place t1?`: ```sql
SELECT "place" FROM "second_round" WHERE "country"='wales';
## Task Generate a SQL query to answer the following question: `What place has Wales as a country?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What place has Wales as a country?`: ```sql
SELECT "to_par" FROM "second_round" WHERE "country"='australia' AND "player"='peter senior';
## Task Generate a SQL query to answer the following question: `What is the To Par of Peter Senior from Australia?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the To Par of Peter Senior from Australia?`: ```sql
SELECT "score" FROM "second_round" WHERE "to_par"='+1' AND "country"='england' AND "player"='howard clark';
## Task Generate a SQL query to answer the following question: `What is the score of Howard Clark from England with a To Par of +1?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the score of Howard Clark from England with a To Par of +1?`: ```sql
SELECT "score" FROM "second_round" WHERE "to_par"='+1' AND "country"='spain';
## Task Generate a SQL query to answer the following question: `What is the score of the player with a To Par of +1 from Spain?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the score of the player with a To Par of +1 from Spain?`: ```sql
SELECT "status" FROM "2001" WHERE "opposing_teams"='u.s.a.';
## Task Generate a SQL query to answer the following question: `Who won the event against U.S.A.?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2001" ( "opposing_teams" text, "against" real, "date" text, "venue" text, "status" text ); ### SQL Given the database schema, here is the SQL query that answers `Who won the event against U.S.A.?`: ```sql
SELECT "venue" FROM "2001" WHERE "against"=15 AND "date"='10/11/2001';
## Task Generate a SQL query to answer the following question: `Where was the match on 10/11/2001 against 15?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2001" ( "opposing_teams" text, "against" real, "date" text, "venue" text, "status" text ); ### SQL Given the database schema, here is the SQL query that answers `Where was the match on 10/11/2001 against 15?`: ```sql
SELECT MIN("against") FROM "2001" WHERE "status"='six nations' AND "venue"='lansdowne road, dublin';
## Task Generate a SQL query to answer the following question: `What is the lowest against team in the Six Nations status in Lansdowne Road, Dublin?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2001" ( "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 lowest against team in the Six Nations status in Lansdowne Road, Dublin?`: ```sql
SELECT "2008" FROM "singles_performance_timeline" WHERE "2010"='1r' AND "2007"='a' AND "2009"='1r';
## Task Generate a SQL query to answer the following question: `What 2008 has 1r as a 2010, A as the 2007, and 1r as the 2009?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "singles_performance_timeline" ( "tournament" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `What 2008 has 1r as a 2010, A as the 2007, and 1r as the 2009?`: ```sql
SELECT "2008" FROM "singles_performance_timeline" WHERE "2007"='a' AND "2010"='2r';
## Task Generate a SQL query to answer the following question: `What 2008 has A as the 2007, and 2r as the 2010?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "singles_performance_timeline" ( "tournament" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `What 2008 has A as the 2007, and 2r as the 2010?`: ```sql
SELECT "2009" FROM "singles_performance_timeline" WHERE "2011"='lq';
## Task Generate a SQL query to answer the following question: `What 2009 has lq as the 2011?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "singles_performance_timeline" ( "tournament" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `What 2009 has lq as the 2011?`: ```sql
SELECT "2009" FROM "singles_performance_timeline" WHERE "2007"='345';
## Task Generate a SQL query to answer the following question: `What 2009 has 345 as the 2007?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "singles_performance_timeline" ( "tournament" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `What 2009 has 345 as the 2007?`: ```sql
SELECT "nation" FROM "list" WHERE "sport"='weightlifting' AND "pinyin"='kùkè qúndǎo';
## Task Generate a SQL query to answer the following question: `What nation has a sport of weightlifting and a pinyin of kùkè qúndǎo?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "list" ( "order" real, "nation" text, "chinese_name" text, "pinyin" text, "sport" text ); ### SQL Given the database schema, here is the SQL query that answers `What nation has a sport of weightlifting and a pinyin of kùkè qúndǎo?`: ```sql
SELECT "date" FROM "matches" WHERE "team"='glentoran' AND "venue"='windsor park, belfast';
## Task Generate a SQL query to answer the following question: `What day did Glentoran play at Windsor Park, Belfast?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "matches" ( "date" text, "teams" text, "score" text, "team" text, "venue" text ); ### SQL Given the database schema, here is the SQL query that answers `What day did Glentoran play at Windsor Park, Belfast?`: ```sql
SELECT "date" FROM "matches" WHERE "score"='1-0';
## Task Generate a SQL query to answer the following question: `What day was the score 1-0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "matches" ( "date" text, "teams" text, "score" text, "team" text, "venue" text ); ### SQL Given the database schema, here is the SQL query that answers `What day was the score 1-0?`: ```sql
SELECT "team" FROM "matches" WHERE "score"='2-1';
## Task Generate a SQL query to answer the following question: `Which team scored 2-1?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "matches" ( "date" text, "teams" text, "score" text, "team" text, "venue" text ); ### SQL Given the database schema, here is the SQL query that answers `Which team scored 2-1?`: ```sql
SELECT "1998" FROM "grand_slam_performance_timeline" WHERE "2003"='2r';
## Task Generate a SQL query to answer the following question: `What is the 1998 value with 2r in 2003?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "grand_slam_performance_timeline" ( "tournament" text, "1993" text, "1994" text, "1995" text, "1996" text, "1998" text, "2003" text, "2004" text, "2005" text, "career" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the 1998 value with 2r in 2003?`: ```sql
SELECT "2004" FROM "grand_slam_performance_timeline" WHERE "1994"='2r';
## Task Generate a SQL query to answer the following question: `What is the 2004 value with 2r in 1994?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "grand_slam_performance_timeline" ( "tournament" text, "1993" text, "1994" text, "1995" text, "1996" text, "1998" text, "2003" text, "2004" text, "2005" text, "career" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the 2004 value with 2r in 1994?`: ```sql
SELECT "2003" FROM "grand_slam_performance_timeline" WHERE "1994"='1r' AND "tournament"='french open';
## Task Generate a SQL query to answer the following question: `What is the 2003 value for the french open, which has a 1r in 1994?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "grand_slam_performance_timeline" ( "tournament" text, "1993" text, "1994" text, "1995" text, "1996" text, "1998" text, "2003" text, "2004" text, "2005" text, "career" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the 2003 value for the french open, which has a 1r in 1994?`: ```sql
SELECT "2003" FROM "grand_slam_performance_timeline" WHERE "1998"='1r' AND "1994"='1r' AND "career"='7-12';
## Task Generate a SQL query to answer the following question: `What is the 2003 value with a 1r in 1998, a 14 in 1994, and a 7-12 career?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "grand_slam_performance_timeline" ( "tournament" text, "1993" text, "1994" text, "1995" text, "1996" text, "1998" text, "2003" text, "2004" text, "2005" text, "career" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the 2003 value with a 1r in 1998, a 14 in 1994, and a 7-12 career?`: ```sql
SELECT "driver" FROM "results" WHERE "fin_pos"=8;
## Task Generate a SQL query to answer the following question: `Which driver finished in position 8?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "results" ( "fin_pos" real, "car_no" real, "driver" text, "team" text, "laps" real, "time_retired" text, "grid" real, "laps_led" real, "points" text ); ### SQL Given the database schema, here is the SQL query that answers `Which driver finished in position 8?`: ```sql
SELECT SUM("laps") FROM "results" WHERE "points"='16' AND "laps_led">0;
## Task Generate a SQL query to answer the following question: `How many laps have 16 points and With a Laps Led of greater than 0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "results" ( "fin_pos" real, "car_no" real, "driver" text, "team" text, "laps" real, "time_retired" text, "grid" real, "laps_led" real, "points" text ); ### SQL Given the database schema, here is the SQL query that answers `How many laps have 16 points and With a Laps Led of greater than 0?`: ```sql
SELECT AVG("grid") FROM "results" WHERE "driver"='marco andretti' AND "fin_pos">19;
## Task Generate a SQL query to answer the following question: `What is the average grid for Marco Andretti with a finishing position higher than 19?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "results" ( "fin_pos" real, "car_no" real, "driver" text, "team" text, "laps" real, "time_retired" text, "grid" real, "laps_led" real, "points" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the average grid for Marco Andretti with a finishing position higher than 19?`: ```sql
SELECT MIN("grid") FROM "results" WHERE "car_no"=98;
## Task Generate a SQL query to answer the following question: `What is Car number 98's lowest grid?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "results" ( "fin_pos" real, "car_no" real, "driver" text, "team" text, "laps" real, "time_retired" text, "grid" real, "laps_led" real, "points" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Car number 98's lowest grid?`: ```sql
SELECT MAX("laps_led") FROM "results" WHERE "grid"<4 AND "fin_pos"=15;
## Task Generate a SQL query to answer the following question: `What is the highest Laps Led with a grid of less than 4 and a finishing position of 15?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "results" ( "fin_pos" real, "car_no" real, "driver" text, "team" text, "laps" real, "time_retired" text, "grid" real, "laps_led" real, "points" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the highest Laps Led with a grid of less than 4 and a finishing position of 15?`: ```sql
SELECT AVG("qiangshu") FROM "women_s_jianshu_qiangshu_combined" WHERE "rank">4 AND "jianshu"<9.22;
## Task Generate a SQL query to answer the following question: `What is the average Qiangshu lower than rank 4 and less than 9.22 Jianshu?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "women_s_jianshu_qiangshu_combined" ( "rank" real, "athlete" text, "qiangshu" real, "jianshu" real, "total" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the average Qiangshu lower than rank 4 and less than 9.22 Jianshu?`: ```sql
SELECT AVG("jianshu") FROM "women_s_jianshu_qiangshu_combined" WHERE "rank"<2 AND "qiangshu"<9.85;
## Task Generate a SQL query to answer the following question: `What is the average Jianshu higher than rank 2, with a Qiangshu smaller than 9.85?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "women_s_jianshu_qiangshu_combined" ( "rank" real, "athlete" text, "qiangshu" real, "jianshu" real, "total" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the average Jianshu higher than rank 2, with a Qiangshu smaller than 9.85?`: ```sql
SELECT "became_consort" FROM "princely_consort_of_monaco" WHERE "spouse"='louis ii';
## Task Generate a SQL query to answer the following question: `On what date did the woman married to Louis II become consort?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "princely_consort_of_monaco" ( "name" text, "birth" text, "marriage" text, "became_consort" text, "ceased_to_be_consort" text, "spouse" text ); ### SQL Given the database schema, here is the SQL query that answers `On what date did the woman married to Louis II become consort?`: ```sql
SELECT "date" FROM "regular_season" WHERE "record"='32–31–6';
## Task Generate a SQL query to answer the following question: `What is the Date of the game when the Record is 32–31–6?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "regular_season" ( "date" text, "opponent" text, "score" text, "loss" text, "attendance" real, "record" text, "arena" text, "points" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the Date of the game when the Record is 32–31–6?`: ```sql
SELECT "opponent" FROM "regular_season" WHERE "arena"='honda center' AND "date"='march 29';
## Task Generate a SQL query to answer the following question: `What is the Opponent at the Honda Center on March 29?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "regular_season" ( "date" text, "opponent" text, "score" text, "loss" text, "attendance" real, "record" text, "arena" text, "points" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the Opponent at the Honda Center on March 29?`: ```sql
SELECT "opponent" FROM "regular_season" WHERE "record"='34–31–6';
## Task Generate a SQL query to answer the following question: `What is the Opponent when the Record is 34–31–6?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "regular_season" ( "date" text, "opponent" text, "score" text, "loss" text, "attendance" real, "record" text, "arena" text, "points" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the Opponent when the Record is 34–31–6?`: ```sql
SELECT "date" FROM "first_round_proper" WHERE "away_team"='minehead';
## Task Generate a SQL query to answer the following question: `What is Date, when Away Team is "Minehead"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_proper" ( "tie_no" text, "home_team" text, "score" text, "away_team" text, "date" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Date, when Away Team is "Minehead"?`: ```sql
SELECT "date" FROM "first_round_proper" WHERE "away_team"='barnet';
## Task Generate a SQL query to answer the following question: `What is Date, when Away Team is "Barnet"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_proper" ( "tie_no" text, "home_team" text, "score" text, "away_team" text, "date" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Date, when Away Team is "Barnet"?`: ```sql
SELECT "tie_no" FROM "first_round_proper" WHERE "home_team"='hull city';
## Task Generate a SQL query to answer the following question: `What is Tie no, when Home Team is "Hull City"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_proper" ( "tie_no" text, "home_team" text, "score" text, "away_team" text, "date" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Tie no, when Home Team is "Hull City"?`: ```sql
SELECT "away_team" FROM "first_round_proper" WHERE "home_team"='swindon town';
## Task Generate a SQL query to answer the following question: `What is Away Team, when Home Team is "Swindon Town"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_proper" ( "tie_no" text, "home_team" text, "score" text, "away_team" text, "date" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Away Team, when Home Team is "Swindon Town"?`: ```sql
SELECT "away_team" FROM "first_round_proper" WHERE "home_team"='boston united';
## Task Generate a SQL query to answer the following question: `What is Away Team, when Home Team is "Boston United"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_proper" ( "tie_no" text, "home_team" text, "score" text, "away_team" text, "date" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Away Team, when Home Team is "Boston United"?`: ```sql
SELECT "score" FROM "third_round" WHERE "player"='nick faldo';
## Task Generate a SQL query to answer the following question: `What was Nick Faldo's score?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "third_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What was Nick Faldo's score?`: ```sql
SELECT "country" FROM "third_round" WHERE "place"='t8' AND "score"='71-71-71=213';
## Task Generate a SQL query to answer the following question: `What country placed t8 and scored 71-71-71=213?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "third_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What country placed t8 and scored 71-71-71=213?`: ```sql
SELECT "place" FROM "third_round" WHERE "score"='67-73-73=213';
## Task Generate a SQL query to answer the following question: `What was the place when the score was 67-73-73=213?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "third_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What was the place when the score was 67-73-73=213?`: ```sql
SELECT "place" FROM "third_round" WHERE "score"='70-69-74=213';
## Task Generate a SQL query to answer the following question: `What was the place when the score was 70-69-74=213?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "third_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What was the place when the score was 70-69-74=213?`: ```sql
SELECT "place" FROM "third_round" WHERE "country"='united states' AND "player"='fred couples';
## Task Generate a SQL query to answer the following question: `What was United States place when the player was Fred Couples?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "third_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What was United States place when the player was Fred Couples?`: ```sql
SELECT "tournament" FROM "men_s_coubles" WHERE "2008"='a' AND "2011"='a';
## Task Generate a SQL query to answer the following question: `WHAT IS THE TOURNAMENT WITH 2008 AND 2011 WITH A?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "men_s_coubles" ( "tournament" text, "2005" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE TOURNAMENT WITH 2008 AND 2011 WITH A?`: ```sql
SELECT "2012" FROM "men_s_coubles" WHERE "2005"='1r';
## Task Generate a SQL query to answer the following question: `WHAT IS THE 2012 WITH 2005 OF 1R?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "men_s_coubles" ( "tournament" text, "2005" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE 2012 WITH 2005 OF 1R?`: ```sql
SELECT "2010" FROM "men_s_coubles" WHERE "2012"='2r' AND "tournament"='miami masters';
## Task Generate a SQL query to answer the following question: `WHAT IS THE 2010 WITH 2012 OF 2R AT MIAMI MASTERS?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "men_s_coubles" ( "tournament" text, "2005" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE 2010 WITH 2012 OF 2R AT MIAMI MASTERS?`: ```sql
SELECT "2008" FROM "men_s_coubles" WHERE "tournament"='win-loss' AND "2005"='a';
## Task Generate a SQL query to answer the following question: `WHAT IS THE 2008 WITH TOURNAMENT OF WIN-LOSS, AND 2005 A?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "men_s_coubles" ( "tournament" text, "2005" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE 2008 WITH TOURNAMENT OF WIN-LOSS, AND 2005 A?`: ```sql
SELECT "2007" FROM "men_s_coubles" WHERE "tournament"='madrid masters';
## Task Generate a SQL query to answer the following question: `WHAT IS THE 2007 AT MADRID MASTERS?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "men_s_coubles" ( "tournament" text, "2005" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE 2007 AT MADRID MASTERS?`: ```sql
SELECT "2011" FROM "men_s_coubles" WHERE "2007"='a' AND "2008"='3r';
## Task Generate a SQL query to answer the following question: `WHAT IS THE 2011 WITH 2007 AT A AND2 008 AT 3R?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "men_s_coubles" ( "tournament" text, "2005" text, "2006" text, "2007" text, "2008" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE 2011 WITH 2007 AT A AND2 008 AT 3R?`: ```sql
SELECT "game_title" FROM "games" WHERE "metacritic"='85/100' AND "year_released"<2010;
## Task Generate a SQL query to answer the following question: `What game was released before 2010 with a Metacritic of 85/100?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "games" ( "game_title" text, "year_released" real, "platform" text, "game_rankings" text, "metacritic" text ); ### SQL Given the database schema, here is the SQL query that answers `What game was released before 2010 with a Metacritic of 85/100?`: ```sql
SELECT "metacritic" FROM "games" WHERE "year_released">2005 AND "platform"='playstation 3' AND "game_rankings"='84.44%';
## Task Generate a SQL query to answer the following question: `What is the Metacritic released after 2005, with a Platform of playstation 3 and a GameRankings of 84.44%?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "games" ( "game_title" text, "year_released" real, "platform" text, "game_rankings" text, "metacritic" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the Metacritic released after 2005, with a Platform of playstation 3 and a GameRankings of 84.44%?`: ```sql
SELECT "game_rankings" FROM "games" WHERE "metacritic"='83/100' AND "year_released"=2011;
## Task Generate a SQL query to answer the following question: `What is the GameRankings Released of 2011 with a Metacritic of 83/100?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "games" ( "game_title" text, "year_released" real, "platform" text, "game_rankings" text, "metacritic" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the GameRankings Released of 2011 with a Metacritic of 83/100?`: ```sql
SELECT SUM("week") FROM "schedule" WHERE "attendance"<'26,048';
## Task Generate a SQL query to answer the following question: `How many weeks have an attendance less than 26,048?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "game_site" text, "record" text, "attendance" real ); ### SQL Given the database schema, here is the SQL query that answers `How many weeks have an attendance less than 26,048?`: ```sql
SELECT "11_00_am" FROM "fall_1999" WHERE "4_00_pm"='local programs' AND "3_00_pm"='general hospital';
## Task Generate a SQL query to answer the following question: `WHAT IS THE 11AM WITH LOCAL PROGRAMS AT 4PM AND GENERAL HOSPITAL AT 3PM?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "fall_1999" ( "7_00_am" text, "7_30_am" text, "8_00_am" text, "9_00_am" text, "10_00_am" text, "11_00_am" text, "noon" text, "12_30_pm" text, "1_00_pm" text, "1_30_pm" text, "2_00_pm" text, "3_00_pm" text, "3_30_pm" text, "4_00_pm" text, "4_30_pm" text, "5_00_pm" text, "6_30_pm" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE 11AM WITH LOCAL PROGRAMS AT 4PM AND GENERAL HOSPITAL AT 3PM?`: ```sql
SELECT "4_30_pm" FROM "fall_1999" WHERE "8_00_am"='cbs this morning';
## Task Generate a SQL query to answer the following question: `WHAT IS THE 4:30PM WITH AN 8:00AM CBS THIS MORNING?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "fall_1999" ( "7_00_am" text, "7_30_am" text, "8_00_am" text, "9_00_am" text, "10_00_am" text, "11_00_am" text, "noon" text, "12_30_pm" text, "1_00_pm" text, "1_30_pm" text, "2_00_pm" text, "3_00_pm" text, "3_30_pm" text, "4_00_pm" text, "4_30_pm" text, "5_00_pm" text, "6_30_pm" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE 4:30PM WITH AN 8:00AM CBS THIS MORNING?`: ```sql
SELECT "4_30_pm" FROM "fall_1999" WHERE "1_30_pm"='local programs';
## Task Generate a SQL query to answer the following question: `WHAT IS THE 4:30PM WITH 1:30PM LOCAL PROGRAMS?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "fall_1999" ( "7_00_am" text, "7_30_am" text, "8_00_am" text, "9_00_am" text, "10_00_am" text, "11_00_am" text, "noon" text, "12_30_pm" text, "1_00_pm" text, "1_30_pm" text, "2_00_pm" text, "3_00_pm" text, "3_30_pm" text, "4_00_pm" text, "4_30_pm" text, "5_00_pm" text, "6_30_pm" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE 4:30PM WITH 1:30PM LOCAL PROGRAMS?`: ```sql
SELECT "8_00_am" FROM "fall_1999" WHERE "12_30_pm"='port charles';
## Task Generate a SQL query to answer the following question: `WHAT IS THE 8:00AM WITH PORT CHARLES AT 12:30PM?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "fall_1999" ( "7_00_am" text, "7_30_am" text, "8_00_am" text, "9_00_am" text, "10_00_am" text, "11_00_am" text, "noon" text, "12_30_pm" text, "1_00_pm" text, "1_30_pm" text, "2_00_pm" text, "3_00_pm" text, "3_30_pm" text, "4_00_pm" text, "4_30_pm" text, "5_00_pm" text, "6_30_pm" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE 8:00AM WITH PORT CHARLES AT 12:30PM?`: ```sql
SELECT "record" FROM "regular_season" WHERE "game_site"='bears stadium' AND "opponent"='new york titans';
## Task Generate a SQL query to answer the following question: `What was the record when the Denver Broncos played the New York Titans at Bears Stadium?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "regular_season" ( "week" real, "date" text, "opponent" text, "result" text, "game_site" text, "record" text, "attendance" real ); ### SQL Given the database schema, here is the SQL query that answers `What was the record when the Denver Broncos played the New York Titans at Bears Stadium?`: ```sql
SELECT "result" FROM "regular_season" WHERE "date"='december 9, 1962';
## Task Generate a SQL query to answer the following question: `What was the result of the match on December 9, 1962?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "regular_season" ( "week" real, "date" text, "opponent" text, "result" text, "game_site" text, "record" text, "attendance" real ); ### SQL Given the database schema, here is the SQL query that answers `What was the result of the match on December 9, 1962?`: ```sql
SELECT "to_par" FROM "final_leaderboard" WHERE "score"='70-68-68-71=277';
## Task Generate a SQL query to answer the following question: `What is To par, when Score is "70-68-68-71=277"?` ### 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 is To par, when Score is "70-68-68-71=277"?`: ```sql
SELECT "score" FROM "international_goals" WHERE "date"='12 september 1990';
## Task Generate a SQL query to answer the following question: `What is the score of the match on 12 September 1990?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "international_goals" ( "date" text, "venue" text, "score" text, "result" text, "competition" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the score of the match on 12 September 1990?`: ```sql
SELECT "league_from" FROM "round_three" WHERE "position"='g';
## Task Generate a SQL query to answer the following question: `For what league was the player in G position drafted?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_three" ( "pick_num" real, "player" text, "nationality" text, "position" text, "team_from" text, "league_from" text ); ### SQL Given the database schema, here is the SQL query that answers `For what league was the player in G position drafted?`: ```sql
SELECT AVG("pick_num") FROM "round_three" WHERE "player"='greg mckegg';
## Task Generate a SQL query to answer the following question: `What pick number was player Greg McKegg?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_three" ( "pick_num" real, "player" text, "nationality" text, "position" text, "team_from" text, "league_from" text ); ### SQL Given the database schema, here is the SQL query that answers `What pick number was player Greg McKegg?`: ```sql
SELECT "place" FROM "second_round" WHERE "player"='tony jacklin';
## Task Generate a SQL query to answer the following question: `What Place has a Player of tony jacklin?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What Place has a Player of tony jacklin?`: ```sql
SELECT "place" FROM "second_round" WHERE "player"='bernhard langer';
## Task Generate a SQL query to answer the following question: `What Place has a Player of bernhard langer?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What Place has a Player of bernhard langer?`: ```sql
SELECT "player" FROM "second_round" WHERE "country"='west germany';
## Task Generate a SQL query to answer the following question: `What Player has a Country of west germany?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What Player has a Country of west germany?`: ```sql
SELECT "player" FROM "second_round" WHERE "to_par"='–2';
## Task Generate a SQL query to answer the following question: `What Player has a To par of –2?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What Player has a To par of –2?`: ```sql
SELECT "to_par" FROM "second_round" WHERE "place"='t2' AND "country"='united states';
## Task Generate a SQL query to answer the following question: `What To par has a Place of t2, and a Country of united states?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What To par has a Place of t2, and a Country of united states?`: ```sql
SELECT "score" FROM "second_round" WHERE "place"='t2' AND "country"='england';
## Task Generate a SQL query to answer the following question: `What Score has a Place of t2, and a Country of england?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); ### SQL Given the database schema, here is the SQL query that answers `What Score has a Place of t2, and a Country of england?`: ```sql
SELECT "tries_against" FROM "league_table" WHERE "club"='cwmtwrch rfc';
## Task Generate a SQL query to answer the following question: `How many tries were there for club cwmtwrch rfc?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "league_table" ( "club" text, "played" text, "drawn" text, "lost" text, "points_for" text, "points_against" text, "tries_for" text, "tries_against" text, "try_bonus" text ); ### SQL Given the database schema, here is the SQL query that answers `How many tries were there for club cwmtwrch rfc?`: ```sql
SELECT "drawn" FROM "league_table" WHERE "tries_against"='69';
## Task Generate a SQL query to answer the following question: `What is the draw when the tries against was 69?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "league_table" ( "club" text, "played" text, "drawn" text, "lost" text, "points_for" text, "points_against" text, "tries_for" text, "tries_against" text, "try_bonus" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the draw when the tries against was 69?`: ```sql
SELECT "try_bonus" FROM "league_table" WHERE "lost"='13' AND "drawn"='2';
## Task Generate a SQL query to answer the following question: `What is the try bonus when the loss is 13 and the draw is 2?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "league_table" ( "club" text, "played" text, "drawn" text, "lost" text, "points_for" text, "points_against" text, "tries_for" text, "tries_against" text, "try_bonus" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the try bonus when the loss is 13 and the draw is 2?`: ```sql
SELECT AVG("finish") FROM "daytona_500_results" WHERE "team"='buck baker' AND "start"<13;
## Task Generate a SQL query to answer the following question: `What is the average Finish, when Team is "Buck Baker", and when Start is less than 13?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "daytona_500_results" ( "year" real, "manufacturer" text, "start" real, "finish" real, "team" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the average Finish, when Team is "Buck Baker", and when Start is less than 13?`: ```sql
SELECT AVG("year") FROM "daytona_500_results" WHERE "start"=11;
## Task Generate a SQL query to answer the following question: `What is the average Year, when Start is "11"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "daytona_500_results" ( "year" real, "manufacturer" text, "start" real, "finish" real, "team" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the average Year, when Start is "11"?`: ```sql