output
stringlengths
27
479
instruction
stringlengths
407
1.39k
SELECT "production" FROM "awards" WHERE "result"='nominated' AND "year"=2009 AND "award_ceremony"='helpmann awards';
## Task Generate a SQL query to answer the following question: `Which Production in 2009 had a Result of Nominated at the Helpmann awards Award Ceremony?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "awards" ( "year" real, "award_ceremony" text, "role" text, "production" text, "result" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Production in 2009 had a Result of Nominated at the Helpmann awards Award Ceremony?`: ```sql
SELECT "award_ceremony" FROM "awards" WHERE "role"='glinda' AND "year"=2009;
## Task Generate a SQL query to answer the following question: `Which Award Ceremony in 2009 has a Role of Glinda?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "awards" ( "year" real, "award_ceremony" text, "role" text, "production" text, "result" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Award Ceremony in 2009 has a Role of Glinda?`: ```sql
SELECT "year" FROM "awards" WHERE "production"='wicked' AND "award_ceremony"='helpmann awards';
## Task Generate a SQL query to answer the following question: `Which Year saw the Production of Wicked at the Helpmann Awards Award ceremony?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "awards" ( "year" real, "award_ceremony" text, "role" text, "production" text, "result" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Year saw the Production of Wicked at the Helpmann Awards Award ceremony?`: ```sql
SELECT "result" FROM "awards" WHERE "year"=2013;
## Task Generate a SQL query to answer the following question: `What was the Result in 2013?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "awards" ( "year" real, "award_ceremony" text, "role" text, "production" text, "result" text ); ### SQL Given the database schema, here is the SQL query that answers `What was the Result in 2013?`: ```sql
SELECT "rider" FROM "supersport_race_classification" WHERE "laps"<22 AND "grid">19 AND "time"='retirement' AND "bike"='kawasaki zx-6r';
## Task Generate a SQL query to answer the following question: `Who was the rider riding the Kawasaki ZX-6r, that rode less than 22 laps, and the grid was greater than 19, and retirement was the time?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "supersport_race_classification" ( "rider" text, "bike" text, "laps" real, "time" text, "grid" real ); ### SQL Given the database schema, here is the SQL query that answers `Who was the rider riding the Kawasaki ZX-6r, that rode less than 22 laps, and the grid was greater than 19, and retirement was the time?`: ```sql
SELECT MAX("grid") FROM "supersport_race_classification" WHERE "laps">22;
## Task Generate a SQL query to answer the following question: `What is the maximum grid when the laps were greater than 22?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "supersport_race_classification" ( "rider" text, "bike" text, "laps" real, "time" text, "grid" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the maximum grid when the laps were greater than 22?`: ```sql
SELECT MIN("grid") FROM "supersport_race_classification" WHERE "laps">22;
## Task Generate a SQL query to answer the following question: `What is the minimum grid when there was more than 22 laps?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "supersport_race_classification" ( "rider" text, "bike" text, "laps" real, "time" text, "grid" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the minimum grid when there was more than 22 laps?`: ```sql
SELECT SUM("laps") FROM "supersport_race_classification" WHERE "bike"='honda cbr600rr' AND "grid"=7;
## Task Generate a SQL query to answer the following question: `How many total laps were ridden when the grid was 7 and the rider rode the Honda CBR600RR?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "supersport_race_classification" ( "rider" text, "bike" text, "laps" real, "time" text, "grid" real ); ### SQL Given the database schema, here is the SQL query that answers `How many total laps were ridden when the grid was 7 and the rider rode the Honda CBR600RR?`: ```sql
SELECT "sign" FROM "table_of_the_most_commonly_used_of_the_t" WHERE "fall"='venus';
## Task Generate a SQL query to answer the following question: `Which sign has a fall of Venus?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "table_of_the_most_commonly_used_of_the_t" ( "sign" text, "domicile" text, "detriment" text, "exaltation" text, "fall" text ); ### SQL Given the database schema, here is the SQL query that answers `Which sign has a fall of Venus?`: ```sql
SELECT "exaltation" FROM "table_of_the_most_commonly_used_of_the_t" WHERE "fall"='moon';
## Task Generate a SQL query to answer the following question: `Which exaltation has a fall of moon?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "table_of_the_most_commonly_used_of_the_t" ( "sign" text, "domicile" text, "detriment" text, "exaltation" text, "fall" text ); ### SQL Given the database schema, here is the SQL query that answers `Which exaltation has a fall of moon?`: ```sql
SELECT "exaltation" FROM "table_of_the_most_commonly_used_of_the_t" WHERE "domicile"='saturn' AND "fall"='jupiter';
## Task Generate a SQL query to answer the following question: `Which exaltation has a domicile of Saturn and a fall of Jupiter?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "table_of_the_most_commonly_used_of_the_t" ( "sign" text, "domicile" text, "detriment" text, "exaltation" text, "fall" text ); ### SQL Given the database schema, here is the SQL query that answers `Which exaltation has a domicile of Saturn and a fall of Jupiter?`: ```sql
SELECT "exaltation" FROM "table_of_the_most_commonly_used_of_the_t" WHERE "domicile"='saturn' AND "sign"='capricorn';
## Task Generate a SQL query to answer the following question: `Which exaltation has a domicile of Saturn and Capricorn as a sign?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "table_of_the_most_commonly_used_of_the_t" ( "sign" text, "domicile" text, "detriment" text, "exaltation" text, "fall" text ); ### SQL Given the database schema, here is the SQL query that answers `Which exaltation has a domicile of Saturn and Capricorn as a sign?`: ```sql
SELECT "detriment" FROM "table_of_the_most_commonly_used_of_the_t" WHERE "domicile"='mercury' AND "sign"='virgo';
## Task Generate a SQL query to answer the following question: `Which detriment has a domicile of mercury and Virgo as a sign?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "table_of_the_most_commonly_used_of_the_t" ( "sign" text, "domicile" text, "detriment" text, "exaltation" text, "fall" text ); ### SQL Given the database schema, here is the SQL query that answers `Which detriment has a domicile of mercury and Virgo as a sign?`: ```sql
SELECT "exaltation" FROM "table_of_the_most_commonly_used_of_the_t" WHERE "detriment"='saturn' AND "sign"='cancer';
## Task Generate a SQL query to answer the following question: `Which exaltation has a detriment of Saturn and Cancer as a sign?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "table_of_the_most_commonly_used_of_the_t" ( "sign" text, "domicile" text, "detriment" text, "exaltation" text, "fall" text ); ### SQL Given the database schema, here is the SQL query that answers `Which exaltation has a detriment of Saturn and Cancer as a sign?`: ```sql
SELECT "drawn" FROM "league_table" WHERE "points_against"='234';
## Task Generate a SQL query to answer the following question: `What was the draw when the points against was 234?` ### 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, "losing_bonus" text, "points" text ); ### SQL Given the database schema, here is the SQL query that answers `What was the draw when the points against was 234?`: ```sql
SELECT "try_bonus" FROM "league_table" WHERE "points_for"='608';
## Task Generate a SQL query to answer the following question: `What was the try bonus when the points for was 608?` ### 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, "losing_bonus" text, "points" text ); ### SQL Given the database schema, here is the SQL query that answers `What was the try bonus when the points for was 608?`: ```sql
SELECT "team" FROM "selections" WHERE "previous_team"='san diego rockets' AND "pos"='f';
## Task Generate a SQL query to answer the following question: `Which Team has a Previous team of san diego rockets, and a Position of f?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "selections" ( "player" text, "pos" text, "nationality" text, "team" text, "previous_team" text, "years_of_nba_experience_a" real, "career_with_the_franchise_b" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Team has a Previous team of san diego rockets, and a Position of f?`: ```sql
SELECT "nationality" FROM "selections" WHERE "previous_team"='new york knicks' AND "years_of_nba_experience_a">3;
## Task Generate a SQL query to answer the following question: `Which Nationality has a Previous team of new york knicks, and more than 3 Years of NBA experience?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "selections" ( "player" text, "pos" text, "nationality" text, "team" text, "previous_team" text, "years_of_nba_experience_a" real, "career_with_the_franchise_b" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Nationality has a Previous team of new york knicks, and more than 3 Years of NBA experience?`: ```sql
SELECT "team_1" FROM "round_of_16" WHERE "team_2"='manchester united';
## Task Generate a SQL query to answer the following question: `What is team 1 when team 2 is Manchester United?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_of_16" ( "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 1 when team 2 is Manchester United?`: ```sql
SELECT "agg" FROM "round_of_16" WHERE "team_1"='milan';
## Task Generate a SQL query to answer the following question: `What is the agg when team 1 is Milan?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_of_16" ( "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 when team 1 is Milan?`: ```sql
SELECT "team" FROM "general_standings" WHERE "rank"=10;
## Task Generate a SQL query to answer the following question: `Which team is ranked #10?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "general_standings" ( "rank" real, "cyclist" text, "team" text, "time" text, "uci_pro_tour_points" real ); ### SQL Given the database schema, here is the SQL query that answers `Which team is ranked #10?`: ```sql
SELECT "cyclist" FROM "general_standings" WHERE "uci_pro_tour_points"=40;
## Task Generate a SQL query to answer the following question: `Which cyclist has UCI ProTour points of 40?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "general_standings" ( "rank" real, "cyclist" text, "team" text, "time" text, "uci_pro_tour_points" real ); ### SQL Given the database schema, here is the SQL query that answers `Which cyclist has UCI ProTour points of 40?`: ```sql
SELECT "province_community" FROM "delegates" WHERE "contestant"='tatiana vargas rosales';
## Task Generate a SQL query to answer the following question: `What is the province with a contestant of tatiana vargas rosales?` ### 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 with a contestant of tatiana vargas rosales?`: ```sql
SELECT "province_community" FROM "delegates" WHERE "contestant"='elixandra tobias carasco';
## Task Generate a SQL query to answer the following question: `Which province has the contestant elixandra tobias carasco?` ### 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 `Which province has the contestant elixandra tobias carasco?`: ```sql
SELECT SUM("2005") FROM "statistics" WHERE "2009"<'1,850,654';
## Task Generate a SQL query to answer the following question: `What is the 2005 sum with a 2009 less than 1,850,654?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "statistics" ( "2010" text, "2009" real, "2008" real, "2007" text, "2006" real, "2005" real, "2004" real, "2003" real, "2002" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the 2005 sum with a 2009 less than 1,850,654?`: ```sql
SELECT AVG("2003") FROM "statistics" WHERE "2010"='2,154,170' AND "2008"<'2,266,716';
## Task Generate a SQL query to answer the following question: `What is the average 2003 with 2,154,170 in 2010 and a 2008 less than 2,266,716?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "statistics" ( "2010" text, "2009" real, "2008" real, "2007" text, "2006" real, "2005" real, "2004" real, "2003" real, "2002" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the average 2003 with 2,154,170 in 2010 and a 2008 less than 2,266,716?`: ```sql
SELECT AVG("2009") FROM "statistics" WHERE "2003">'3,791' AND "2007"='107,982' AND "2006"<'98,264';
## Task Generate a SQL query to answer the following question: `What is the average 2009 with a 2003 greater than 3,791, 107,982 in 2007, and a 2006 less than 98,264?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "statistics" ( "2010" text, "2009" real, "2008" real, "2007" text, "2006" real, "2005" real, "2004" real, "2003" real, "2002" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the average 2009 with a 2003 greater than 3,791, 107,982 in 2007, and a 2006 less than 98,264?`: ```sql
SELECT SUM("2008") FROM "statistics" WHERE "2007"='4,244,115' AND "2003"<'3,296,267';
## Task Generate a SQL query to answer the following question: `What is the sum of the 2008 with a 2007 of 4,244,115 and less than 3,296,267 in 2003?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "statistics" ( "2010" text, "2009" real, "2008" real, "2007" text, "2006" real, "2005" real, "2004" real, "2003" real, "2002" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the sum of the 2008 with a 2007 of 4,244,115 and less than 3,296,267 in 2003?`: ```sql
SELECT "2011" FROM "doubles" WHERE "2009"='a';
## Task Generate a SQL query to answer the following question: `What is 2011, when 2009 is "A"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "doubles" ( "tournament" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `What is 2011, when 2009 is "A"?`: ```sql
SELECT "2009" FROM "doubles" WHERE "tournament"='year-end ranking';
## Task Generate a SQL query to answer the following question: `What is 2009, when Tournament is "Year-End Ranking"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "doubles" ( "tournament" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `What is 2009, when Tournament is "Year-End Ranking"?`: ```sql
SELECT "2011" FROM "doubles" WHERE "2012"='1r';
## Task Generate a SQL query to answer the following question: `What is 2011, when 2012 is "1R"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "doubles" ( "tournament" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `What is 2011, when 2012 is "1R"?`: ```sql
SELECT "2012" FROM "doubles" WHERE "2009"='a';
## Task Generate a SQL query to answer the following question: `What is 2012, when 2009 is "A"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "doubles" ( "tournament" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `What is 2012, when 2009 is "A"?`: ```sql
SELECT "2011" FROM "doubles" WHERE "2012"='a' AND "tournament"='french open';
## Task Generate a SQL query to answer the following question: `What is 2011, when 2012 is "A", and when Tournament is "French Open"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "doubles" ( "tournament" text, "2009" text, "2010" text, "2011" text, "2012" text ); ### SQL Given the database schema, here is the SQL query that answers `What is 2011, when 2012 is "A", and when Tournament is "French Open"?`: ```sql
SELECT MAX("against") FROM "1989" WHERE "opposing_teams"='wales';
## Task Generate a SQL query to answer the following question: `What is the largest Against with an Opposing Teams of wales?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1989" ( "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 largest Against with an Opposing Teams of wales?`: ```sql
SELECT "status" FROM "1989" WHERE "date"='18/03/1989';
## Task Generate a SQL query to answer the following question: `What Status has a Date of 18/03/1989?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1989" ( "opposing_teams" text, "against" real, "date" text, "venue" text, "status" text ); ### SQL Given the database schema, here is the SQL query that answers `What Status has a Date of 18/03/1989?`: ```sql
SELECT "venue" FROM "1989" WHERE "status"='five nations' AND "against"=0;
## Task Generate a SQL query to answer the following question: `What Venue has a Status of five nations, and Against of 0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1989" ( "opposing_teams" text, "against" real, "date" text, "venue" text, "status" text ); ### SQL Given the database schema, here is the SQL query that answers `What Venue has a Status of five nations, and Against of 0?`: ```sql
SELECT MIN("against") FROM "1989" WHERE "date"='18/02/1989';
## Task Generate a SQL query to answer the following question: `What is the smallest Against with a Date of 18/02/1989?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1989" ( "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 smallest Against with a Date of 18/02/1989?`: ```sql
SELECT "additional_notes" FROM "domestic_violence" WHERE "location"='cotabato';
## Task Generate a SQL query to answer the following question: `What are the additional notes for Cotabato?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "domestic_violence" ( "perpetrator" text, "date" text, "year" real, "location" text, "country" text, "killed" real, "additional_notes" text ); ### SQL Given the database schema, here is the SQL query that answers `What are the additional notes for Cotabato?`: ```sql
SELECT "country" FROM "domestic_violence" WHERE "location"='kunlong';
## Task Generate a SQL query to answer the following question: `What country in Kunlong in?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "domestic_violence" ( "perpetrator" text, "date" text, "year" real, "location" text, "country" text, "killed" real, "additional_notes" text ); ### SQL Given the database schema, here is the SQL query that answers `What country in Kunlong in?`: ```sql
SELECT "perpetrator" FROM "domestic_violence" WHERE "location"='baghdad';
## Task Generate a SQL query to answer the following question: `Who went on a rampage in Baghdad?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "domestic_violence" ( "perpetrator" text, "date" text, "year" real, "location" text, "country" text, "killed" real, "additional_notes" text ); ### SQL Given the database schema, here is the SQL query that answers `Who went on a rampage in Baghdad?`: ```sql
SELECT SUM("rank") FROM "performances_by_nation" WHERE "total"<1;
## Task Generate a SQL query to answer the following question: `What's the rank that has a total of less than 1?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "performances_by_nation" ( "rank" real, "gold" real, "silver" real, "bronze" real, "total" real ); ### SQL Given the database schema, here is the SQL query that answers `What's the rank that has a total of less than 1?`: ```sql
SELECT SUM("bronze") FROM "performances_by_nation" WHERE "gold"=1 AND "silver"<3;
## Task Generate a SQL query to answer the following question: `What's the bronze medal count when the silver is less than 3 and the gold is 1?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "performances_by_nation" ( "rank" real, "gold" real, "silver" real, "bronze" real, "total" real ); ### SQL Given the database schema, here is the SQL query that answers `What's the bronze medal count when the silver is less than 3 and the gold is 1?`: ```sql
SELECT COUNT("gold") FROM "performances_by_nation" WHERE "rank"=2 AND "total">21;
## Task Generate a SQL query to answer the following question: `What's the gold medal count ranked 2 with a total of more than 21?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "performances_by_nation" ( "rank" real, "gold" real, "silver" real, "bronze" real, "total" real ); ### SQL Given the database schema, here is the SQL query that answers `What's the gold medal count ranked 2 with a total of more than 21?`: ```sql
SELECT MIN("total") FROM "performances_by_nation" WHERE "bronze"=5 AND "gold"<8;
## Task Generate a SQL query to answer the following question: `What's the smallest total with a bronze count of 5 and a gold count less than 8?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "performances_by_nation" ( "rank" real, "gold" real, "silver" real, "bronze" real, "total" real ); ### SQL Given the database schema, here is the SQL query that answers `What's the smallest total with a bronze count of 5 and a gold count less than 8?`: ```sql
SELECT "party" FROM "oklahoma" WHERE "results"='re-elected' AND "first_elected"<2002;
## Task Generate a SQL query to answer the following question: `What is the party for the representative who was first elected before 2002 and the results were re-elected?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "oklahoma" ( "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 party for the representative who was first elected before 2002 and the results were re-elected?`: ```sql
SELECT MAX("first_elected") FROM "oklahoma" WHERE "incumbent"='john sullivan';
## Task Generate a SQL query to answer the following question: `Incumbent John Sullivan has what as biggest first elected?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "oklahoma" ( "district" text, "incumbent" text, "party" text, "first_elected" real, "results" text ); ### SQL Given the database schema, here is the SQL query that answers `Incumbent John Sullivan has what as biggest first elected?`: ```sql
SELECT "location" FROM "former_members" WHERE "years_member"='1963–1968';
## Task Generate a SQL query to answer the following question: `What Location has Years Member of 1963–1968?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "former_members" ( "school" text, "location" text, "nickname_s" text, "colors" text, "years_member" text ); ### SQL Given the database schema, here is the SQL query that answers `What Location has Years Member of 1963–1968?`: ```sql
SELECT "school" FROM "former_members" WHERE "colors"='navy blue orange';
## Task Generate a SQL query to answer the following question: `What School has Colors of navy blue orange?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "former_members" ( "school" text, "location" text, "nickname_s" text, "colors" text, "years_member" text ); ### SQL Given the database schema, here is the SQL query that answers `What School has Colors of navy blue orange?`: ```sql
SELECT "years_member" FROM "former_members" WHERE "school"='cairo high school';
## Task Generate a SQL query to answer the following question: `What Years Member has a School of cairo high school?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "former_members" ( "school" text, "location" text, "nickname_s" text, "colors" text, "years_member" text ); ### SQL Given the database schema, here is the SQL query that answers `What Years Member has a School of cairo high school?`: ```sql
SELECT "colors" FROM "former_members" WHERE "school"='sesser high school';
## Task Generate a SQL query to answer the following question: `What Colors has a School of sesser high school?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "former_members" ( "school" text, "location" text, "nickname_s" text, "colors" text, "years_member" text ); ### SQL Given the database schema, here is the SQL query that answers `What Colors has a School of sesser high school?`: ```sql
SELECT "colors" FROM "former_members" WHERE "school"='zeigler high school';
## Task Generate a SQL query to answer the following question: `What Colors has a School of zeigler high school?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "former_members" ( "school" text, "location" text, "nickname_s" text, "colors" text, "years_member" text ); ### SQL Given the database schema, here is the SQL query that answers `What Colors has a School of zeigler high school?`: ```sql
SELECT "nickname_s" FROM "former_members" WHERE "location"='elkville, illinois';
## Task Generate a SQL query to answer the following question: `What Nickname(s) has a Location of elkville, illinois?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "former_members" ( "school" text, "location" text, "nickname_s" text, "colors" text, "years_member" text ); ### SQL Given the database schema, here is the SQL query that answers `What Nickname(s) has a Location of elkville, illinois?`: ```sql
SELECT "season_1" FROM "english_version" WHERE "season_7"='david chilton';
## Task Generate a SQL query to answer the following question: `Which Season 1 has a Season 7 of david chilton?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "english_version" ( "seat" real, "season_1" text, "season_2" text, "season_3" text, "season_6" text, "season_7" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Season 1 has a Season 7 of david chilton?`: ```sql
SELECT MAX("seat") FROM "english_version" WHERE "season_6"='kevin o''leary';
## Task Generate a SQL query to answer the following question: `Which Seat has a Season 6 of kevin o'leary?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "english_version" ( "seat" real, "season_1" text, "season_2" text, "season_3" text, "season_6" text, "season_7" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Seat has a Season 6 of kevin o'leary?`: ```sql
SELECT "season_7" FROM "english_version" WHERE "season_6"='jim treliving';
## Task Generate a SQL query to answer the following question: `Which Season 7 has a Season 6 of jim treliving?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "english_version" ( "seat" real, "season_1" text, "season_2" text, "season_3" text, "season_6" text, "season_7" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Season 7 has a Season 6 of jim treliving?`: ```sql
SELECT "season_7" FROM "english_version" WHERE "seat">1 AND "season_3"='w. brett wilson';
## Task Generate a SQL query to answer the following question: `Which Season 7 has a Seat larger than 1, and a Season 3 of w. brett wilson?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "english_version" ( "seat" real, "season_1" text, "season_2" text, "season_3" text, "season_6" text, "season_7" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Season 7 has a Seat larger than 1, and a Season 3 of w. brett wilson?`: ```sql
SELECT "season_3" FROM "english_version" WHERE "season_7"='jim treliving';
## Task Generate a SQL query to answer the following question: `Which Season 3 has a Season 7 of jim treliving?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "english_version" ( "seat" real, "season_1" text, "season_2" text, "season_3" text, "season_6" text, "season_7" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Season 3 has a Season 7 of jim treliving?`: ```sql
SELECT "weekly_winner" FROM "ratings_and_results" WHERE "air_date"='july 4, 2008';
## Task Generate a SQL query to answer the following question: `What is Weekly Winner, when Air Date is "July 4, 2008"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "ratings_and_results" ( "air_date" text, "rating" text, "18_49" text, "viewers" text, "weekly_winner" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Weekly Winner, when Air Date is "July 4, 2008"?`: ```sql
SELECT "rating" FROM "ratings_and_results" WHERE "air_date"='july 24, 2008*' AND "weekly_winner"='sales rep. oscar ledezma';
## Task Generate a SQL query to answer the following question: `What is Rating, when Air Date is "July 24, 2008*", and when Weekly Winner is "Sales Rep. Oscar Ledezma"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "ratings_and_results" ( "air_date" text, "rating" text, "18_49" text, "viewers" text, "weekly_winner" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Rating, when Air Date is "July 24, 2008*", and when Weekly Winner is "Sales Rep. Oscar Ledezma"?`: ```sql
SELECT "viewers" FROM "ratings_and_results" WHERE "18_49"='n/a' AND "weekly_winner"='wedding dj chris dixon';
## Task Generate a SQL query to answer the following question: `What is Viewers, when 18-49 is "N/A", and when Weekly Winner is "Wedding DJ Chris Dixon"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "ratings_and_results" ( "air_date" text, "rating" text, "18_49" text, "viewers" text, "weekly_winner" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Viewers, when 18-49 is "N/A", and when Weekly Winner is "Wedding DJ Chris Dixon"?`: ```sql
SELECT "18_49" FROM "ratings_and_results" WHERE "weekly_winner"='youth counselor justin meece';
## Task Generate a SQL query to answer the following question: `What is 18-49, when Weekly Winner is "Youth Counselor Justin Meece"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "ratings_and_results" ( "air_date" text, "rating" text, "18_49" text, "viewers" text, "weekly_winner" text ); ### SQL Given the database schema, here is the SQL query that answers `What is 18-49, when Weekly Winner is "Youth Counselor Justin Meece"?`: ```sql
SELECT "viewers" FROM "ratings_and_results" WHERE "air_date"='july 4, 2008';
## Task Generate a SQL query to answer the following question: `What is Viewers, when Air Date is "July 4, 2008"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "ratings_and_results" ( "air_date" text, "rating" text, "18_49" text, "viewers" text, "weekly_winner" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Viewers, when Air Date is "July 4, 2008"?`: ```sql
SELECT "air_date" FROM "ratings_and_results" WHERE "rating"='n/a' AND "weekly_winner"='wedding dj chris dixon';
## Task Generate a SQL query to answer the following question: `What is Air Date, when Rating is "N/A", and when Weekly Winner is "Wedding DJ Chris Dixon"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "ratings_and_results" ( "air_date" text, "rating" text, "18_49" text, "viewers" text, "weekly_winner" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Air Date, when Rating is "N/A", and when Weekly Winner is "Wedding DJ Chris Dixon"?`: ```sql
SELECT "record" FROM "game_log" WHERE "date"='dec 16';
## Task Generate a SQL query to answer the following question: `What was the record for Dec 16?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "game_log" ( "game" real, "date" text, "opponent" text, "score" text, "location_attendance" text, "record" text, "streak" text ); ### SQL Given the database schema, here is the SQL query that answers `What was the record for Dec 16?`: ```sql
SELECT "2010" FROM "doubles_performance_timeline" WHERE "2011"='qf';
## Task Generate a SQL query to answer the following question: `What is the 2010 with a qf in 2011?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "doubles_performance_timeline" ( "tournament" text, "2009" text, "2010" text, "2011" text, "2012" text, "2013" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the 2010 with a qf in 2011?`: ```sql
SELECT "2013" FROM "doubles_performance_timeline" WHERE "tournament"='grand slam tournaments';
## Task Generate a SQL query to answer the following question: `What is the 2013 of the grand slam tournaments?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "doubles_performance_timeline" ( "tournament" text, "2009" text, "2010" text, "2011" text, "2012" text, "2013" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the 2013 of the grand slam tournaments?`: ```sql
SELECT "2013" FROM "doubles_performance_timeline" WHERE "2010"='2r' AND "2011"='qf';
## Task Generate a SQL query to answer the following question: `What is the 2013 with a 2r in 2010 and a qf in 2011?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "doubles_performance_timeline" ( "tournament" text, "2009" text, "2010" text, "2011" text, "2012" text, "2013" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the 2013 with a 2r in 2010 and a qf in 2011?`: ```sql
SELECT "2011" FROM "doubles_performance_timeline" WHERE "2010"='1r';
## Task Generate a SQL query to answer the following question: `What is the 2011 with 1r in 2010?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "doubles_performance_timeline" ( "tournament" text, "2009" text, "2010" text, "2011" text, "2012" text, "2013" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the 2011 with 1r in 2010?`: ```sql
SELECT "2012" FROM "doubles_performance_timeline" WHERE "2009"='a' AND "2010"='2r';
## Task Generate a SQL query to answer the following question: `What is the 2012 with A in 2009 and 2r in 2010?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "doubles_performance_timeline" ( "tournament" text, "2009" text, "2010" text, "2011" text, "2012" text, "2013" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the 2012 with A in 2009 and 2r in 2010?`: ```sql
SELECT "poison_klesha" FROM "five_poisons" WHERE "pali"='moha avijja';
## Task Generate a SQL query to answer the following question: `What is the poison/klesha word for moha avijja in pali?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "five_poisons" ( "poison_klesha" text, "sanskrit" text, "pali" text, "tibetan" text, "alternate_translations" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the poison/klesha word for moha avijja in pali?`: ```sql
SELECT "poison_klesha" FROM "five_poisons" WHERE "tibetan"='gti mug ma rig pa';
## Task Generate a SQL query to answer the following question: `What is the poision/klesha word for the tibetan word gti mug ma rig pa?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "five_poisons" ( "poison_klesha" text, "sanskrit" text, "pali" text, "tibetan" text, "alternate_translations" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the poision/klesha word for the tibetan word gti mug ma rig pa?`: ```sql
SELECT "pali" FROM "five_poisons" WHERE "poison_klesha"='pride';
## Task Generate a SQL query to answer the following question: `What is the pali word for pride in poison/klesha?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "five_poisons" ( "poison_klesha" text, "sanskrit" text, "pali" text, "tibetan" text, "alternate_translations" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the pali word for pride in poison/klesha?`: ```sql
SELECT "pali" FROM "five_poisons" WHERE "tibetan"='phrag dog';
## Task Generate a SQL query to answer the following question: `What is the pali word for phrag dog in tibetan?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "five_poisons" ( "poison_klesha" text, "sanskrit" text, "pali" text, "tibetan" text, "alternate_translations" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the pali word for phrag dog in tibetan?`: ```sql
SELECT "pali" FROM "five_poisons" WHERE "sanskrit"='rāga';
## Task Generate a SQL query to answer the following question: `What is the pali word for rāga in sanskrit?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "five_poisons" ( "poison_klesha" text, "sanskrit" text, "pali" text, "tibetan" text, "alternate_translations" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the pali word for rāga in sanskrit?`: ```sql
SELECT COUNT("attendance") FROM "ties" WHERE "away_team"='southend manor' AND "tie_no"<93;
## Task Generate a SQL query to answer the following question: `What is the attendance total when Southend Manor is the away team and there are less than 93 ties?` ### 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 attendance total when Southend Manor is the away team and there are less than 93 ties?`: ```sql
SELECT "score" FROM "ties" WHERE "attendance"<83 AND "away_team"='raunds town';
## Task Generate a SQL query to answer the following question: `What is the score when the attendance is less than 83 and Raunds Town is the away team?` ### 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 score when the attendance is less than 83 and Raunds Town is the away team?`: ```sql
SELECT "player" FROM "round_seven" WHERE "pick_num"<205 AND "team_from"='michigan state spartans';
## Task Generate a SQL query to answer the following question: `Who was the player that was picked at a number less than 205 from the Michigan State Spartans?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_seven" ( "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 `Who was the player that was picked at a number less than 205 from the Michigan State Spartans?`: ```sql
SELECT AVG("density_per_km") FROM "list" WHERE "no_munic"=53;
## Task Generate a SQL query to answer the following question: `What is the average Density of 53 No. munic.?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "list" ( "abbr" text, "canton" text, "capital" text, "density_per_km" real, "no_munic" real, "s_official_language" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the average Density of 53 No. munic.?`: ```sql
SELECT "status" FROM "1963" WHERE "venue"='sydney sports ground , sydney';
## Task Generate a SQL query to answer the following question: `Name the Status of Venue of sydney sports ground , sydney?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1963" ( "opposing_teams" text, "against" real, "date" text, "venue" text, "status" text ); ### SQL Given the database schema, here is the SQL query that answers `Name the Status of Venue of sydney sports ground , sydney?`: ```sql
SELECT "status" FROM "1963" WHERE "opposing_teams"='wales';
## Task Generate a SQL query to answer the following question: `Which Status has a Opposing Teams of wales?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1963" ( "opposing_teams" text, "against" real, "date" text, "venue" text, "status" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Status has a Opposing Teams of wales?`: ```sql
SELECT "date" FROM "1963" WHERE "venue"='lancaster park , christchurch';
## Task Generate a SQL query to answer the following question: `WHICH Date has a Venue of lancaster park , christchurch?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1963" ( "opposing_teams" text, "against" real, "date" text, "venue" text, "status" text ); ### SQL Given the database schema, here is the SQL query that answers `WHICH Date has a Venue of lancaster park , christchurch?`: ```sql
SELECT "team" FROM "first_round_selections" WHERE "player"='dave coggin';
## Task Generate a SQL query to answer the following question: `WHAT IS THE TEAM WITH DAVE COGGIN?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_selections" ( "pick" real, "player" text, "team" text, "position" text, "hometown_school" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE TEAM WITH DAVE COGGIN?`: ```sql
SELECT "team" FROM "first_round_selections" WHERE "position"='of' AND "pick"=24;
## Task Generate a SQL query to answer the following question: `WHAT IS THE TEAM WITH AN OF POSITION AND PICK OF 24?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_selections" ( "pick" real, "player" text, "team" text, "position" text, "hometown_school" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE TEAM WITH AN OF POSITION AND PICK OF 24?`: ```sql
SELECT "position" FROM "first_round_selections" WHERE "team"='boston red sox' AND "player"='corey jenkins';
## Task Generate a SQL query to answer the following question: `WHAT IS THE POSITION WITH BOSTON RED SOX FOR COREY JENKINS?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_selections" ( "pick" real, "player" text, "team" text, "position" text, "hometown_school" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT IS THE POSITION WITH BOSTON RED SOX FOR COREY JENKINS?`: ```sql
SELECT "player" FROM "first_round_selections" WHERE "hometown_school"='upland high school';
## Task Generate a SQL query to answer the following question: `WHAT PLAYER HAS UPLAND HIGH SCHOOL?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_selections" ( "pick" real, "player" text, "team" text, "position" text, "hometown_school" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT PLAYER HAS UPLAND HIGH SCHOOL?`: ```sql
SELECT "player" FROM "first_round_selections" WHERE "team"='oakland athletics';
## Task Generate a SQL query to answer the following question: `WHAT PLAYER HAS THE OAKLAND ATHLETICS?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_selections" ( "pick" real, "player" text, "team" text, "position" text, "hometown_school" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT PLAYER HAS THE OAKLAND ATHLETICS?`: ```sql
SELECT "team" FROM "first_round_selections" WHERE "pick">29;
## Task Generate a SQL query to answer the following question: `WHAT TEAM HAS A PICK LARGER THAN 29?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_round_selections" ( "pick" real, "player" text, "team" text, "position" text, "hometown_school" text ); ### SQL Given the database schema, here is the SQL query that answers `WHAT TEAM HAS A PICK LARGER THAN 29?`: ```sql
SELECT "name" FROM "vehicular_manslaughter" WHERE "killed"='8' AND "country"='israel';
## Task Generate a SQL query to answer the following question: `Which rampage killed 8 in Israel?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "vehicular_manslaughter" ( "name" text, "date" text, "year" real, "country" text, "killed" text, "injured" text ); ### SQL Given the database schema, here is the SQL query that answers `Which rampage killed 8 in Israel?`: ```sql
SELECT "country" FROM "vehicular_manslaughter" WHERE "killed"='14' AND "year"=1965;
## Task Generate a SQL query to answer the following question: `What coutry had a rampaged killing 14 in 1965?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "vehicular_manslaughter" ( "name" text, "date" text, "year" real, "country" text, "killed" text, "injured" text ); ### SQL Given the database schema, here is the SQL query that answers `What coutry had a rampaged killing 14 in 1965?`: ```sql
SELECT "club" FROM "league_table" WHERE "drawn"='0' AND "try_bonus"='5';
## Task Generate a SQL query to answer the following question: `What is Club, when Drawn is "0", and when Try Bonus is "5"?` ### 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, "losing_bonus" text, "points" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Club, when Drawn is "0", and when Try Bonus is "5"?`: ```sql
SELECT "club" FROM "league_table" WHERE "points"='82';
## Task Generate a SQL query to answer the following question: `What is Club, when Points is "82"?` ### 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, "losing_bonus" text, "points" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Club, when Points is "82"?`: ```sql
SELECT "played" FROM "league_table" WHERE "points_against"='374';
## Task Generate a SQL query to answer the following question: `What is Played, when Points Against is "374"?` ### 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, "losing_bonus" text, "points" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Played, when Points Against is "374"?`: ```sql
SELECT "points_against" FROM "league_table" WHERE "try_bonus"='try bonus';
## Task Generate a SQL query to answer the following question: `What is Points Against, when Try Bonus is "Try bonus"?` ### 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, "losing_bonus" text, "points" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Points Against, when Try Bonus is "Try bonus"?`: ```sql
SELECT "try_bonus" FROM "league_table" WHERE "losing_bonus"='1' AND "points_for"='179';
## Task Generate a SQL query to answer the following question: `What is Try Bonus, when Losing Bonus is "1", and when Points For is "179"?` ### 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, "losing_bonus" text, "points" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Try Bonus, when Losing Bonus is "1", and when Points For is "179"?`: ```sql
SELECT "points_for" FROM "league_table" WHERE "club"='tycroes rfc';
## Task Generate a SQL query to answer the following question: `What is Points For, when Club is "Tycroes 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, "losing_bonus" text, "points" text ); ### SQL Given the database schema, here is the SQL query that answers `What is Points For, when Club is "Tycroes RFC"?`: ```sql
SELECT "date" FROM "mining_disasters_in_the_rhondda_valley_1" WHERE "cause"='gas explosion' AND "death_toll"<63 AND "location"='penygraig';
## Task Generate a SQL query to answer the following question: `When has a cause of gas explosion, a Death toll smaller than 63, and a Location of penygraig?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "mining_disasters_in_the_rhondda_valley_1" ( "colliery" text, "location" text, "date" text, "year" real, "death_toll" real, "cause" text ); ### SQL Given the database schema, here is the SQL query that answers `When has a cause of gas explosion, a Death toll smaller than 63, and a Location of penygraig?`: ```sql
SELECT "location" FROM "mining_disasters_in_the_rhondda_valley_1" WHERE "cause"='gas explosion' AND "death_toll">38 AND "date"='10 june';
## Task Generate a SQL query to answer the following question: `Where has a cause of gas explosion, a Death toll larger than 38 on 10 june?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "mining_disasters_in_the_rhondda_valley_1" ( "colliery" text, "location" text, "date" text, "year" real, "death_toll" real, "cause" text ); ### SQL Given the database schema, here is the SQL query that answers `Where has a cause of gas explosion, a Death toll larger than 38 on 10 june?`: ```sql
SELECT "year" FROM "mining_disasters_in_the_rhondda_valley_1" WHERE "location"='dinas' AND "date"='13 january';
## Task Generate a SQL query to answer the following question: `Which Year has a Location of dinas on 13 january?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "mining_disasters_in_the_rhondda_valley_1" ( "colliery" text, "location" text, "date" text, "year" real, "death_toll" real, "cause" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Year has a Location of dinas on 13 january?`: ```sql
SELECT SUM("year") FROM "mining_disasters_in_the_rhondda_valley_1" WHERE "cause"='firedamp' AND "death_toll">11;
## Task Generate a SQL query to answer the following question: `Which Year has a cause of firedamp and a Death toll larger than 11?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "mining_disasters_in_the_rhondda_valley_1" ( "colliery" text, "location" text, "date" text, "year" real, "death_toll" real, "cause" text ); ### SQL Given the database schema, here is the SQL query that answers `Which Year has a cause of firedamp and a Death toll larger than 11?`: ```sql
SELECT MIN("year") FROM "mining_disasters_in_the_rhondda_valley_1" WHERE "cause"='gas explosion' AND "colliery"='tylorstown colliery' AND "death_toll">57;
## Task Generate a SQL query to answer the following question: `Count the lowest Year which has gas explosion, Colliery of tylorstown colliery, and a Death toll larger than 57?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "mining_disasters_in_the_rhondda_valley_1" ( "colliery" text, "location" text, "date" text, "year" real, "death_toll" real, "cause" text ); ### SQL Given the database schema, here is the SQL query that answers `Count the lowest Year which has gas explosion, Colliery of tylorstown colliery, and a Death toll larger than 57?`: ```sql