cfahlgren1/wiki_sql_pg_converted huggingface dataset:
## Task
Generate a SQL query to answer the following question:
`Which of the opponents has a record of 17-25?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "game_log" (
  "date" text,
  "opponent" text,
  "score" text,
  "loss" text,
  "attendance" text,
  "record" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which of the opponents has a record of 17-25?`:
```sql
                SELECT "opponent" FROM "game_log" WHERE "record"='17-25';
```
## Task
Generate a SQL query to answer the following question:
`Who was the opponent that played on may 12?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "game_log" (
  "date" text,
  "opponent" text,
  "score" text,
  "loss" text,
  "attendance" text,
  "record" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the opponent that played on may 12?`:
```sql
                SELECT "opponent" FROM "game_log" WHERE "date"='may 12';
```
## Task
Generate a SQL query to answer the following question:
`When in the 1st league position, how many people watch as they faced West Ham United?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "premier_league" (
  "date" text,
  "opponents" text,
  "result_f_a" text,
  "attendance" real,
  "league_position" text
);
### SQL
Given the database schema, here is the SQL query that answers `When in the 1st league position, how many people watch as they faced West Ham United?`:
```sql
                SELECT MIN("attendance") FROM "premier_league" WHERE "league_position"='1st' AND "opponents"='west ham united';
```
## Task
Generate a SQL query to answer the following question:
`What was the result with West Ham United with more than 67,577 in attendance?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "premier_league" (
  "date" text,
  "opponents" text,
  "result_f_a" text,
  "attendance" real,
  "league_position" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the result with West Ham United with more than 67,577 in attendance?`:
```sql
                SELECT "result_f_a" FROM "premier_league" WHERE "attendance">'67,577' AND "opponents"='west ham united';
```
## Task
Generate a SQL query to answer the following question:
`What is the average bronze medals of Uganda's swimmers when they earned over 2 medals?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "medals_table" (
  "nation" text,
  "gold" real,
  "silver" real,
  "bronze" real,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average bronze medals of Uganda's swimmers when they earned over 2 medals?`:
```sql
                SELECT AVG("bronze") FROM "medals_table" WHERE "nation"='uganda' AND "total">2;
```
## Task
Generate a SQL query to answer the following question:
`What is the highest number of silver medals that Ireland earned when they scored less than 3 bronze medals and earned 1 medal?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "medals_table" (
  "nation" text,
  "gold" real,
  "silver" real,
  "bronze" real,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest number of silver medals that Ireland earned when they scored less than 3 bronze medals and earned 1 medal?`:
```sql
                SELECT MAX("silver") FROM "medals_table" WHERE "bronze"<3 AND "gold"<1 AND "total"=1 AND "nation"='ireland';
```
## Task
Generate a SQL query to answer the following question:
`What's the highest silver and 1 gold that the nation of djibouti received with a total less than 3?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "total" (
  "rank" real,
  "nation" text,
  "gold" real,
  "silver" real,
  "bronze" real,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What's the highest silver and 1 gold that the nation of djibouti received with a total less than 3?`:
```sql
                SELECT MAX("silver") FROM "total" WHERE "gold"=1 AND "nation"='djibouti' AND "total"<3;
```
## Task
Generate a SQL query to answer the following question:
`What's the total number that had a rank larger than 17 and a gold greater than 0?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "total" (
  "rank" real,
  "nation" text,
  "gold" real,
  "silver" real,
  "bronze" real,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What's the total number that had a rank larger than 17 and a gold greater than 0?`:
```sql
                SELECT COUNT("total") FROM "total" WHERE "rank">17 AND "gold">0;
```
## Task
Generate a SQL query to answer the following question:
`Which opponent was faced before week 2?`

### 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,
  "attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which opponent was faced before week 2?`:
```sql
                SELECT "opponent" FROM "schedule" WHERE "week"<2;
```
## Task
Generate a SQL query to answer the following question:
`Name the least total for 1978 years won`

### 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 `Name the least total for 1978 years won`:
```sql
                SELECT MIN("total") FROM "made_the_cut" WHERE "year_s_won"='1978';
```
## Task
Generate a SQL query to answer the following question:
`Name the total with finish of t22`

### 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 `Name the total with finish of t22`:
```sql
                SELECT "total" FROM "made_the_cut" WHERE "finish"='t22';
```
## Task
Generate a SQL query to answer the following question:
`Name the average total for years won of 1975`

### 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 `Name the average total for years won of 1975`:
```sql
                SELECT AVG("total") FROM "made_the_cut" WHERE "year_s_won"='1975';
```
## Task
Generate a SQL query to answer the following question:
`Name the finish with player lou graham`

### 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 `Name the finish with player lou graham`:
```sql
                SELECT "finish" FROM "made_the_cut" WHERE "player"='lou graham';
```
## Task
Generate a SQL query to answer the following question:
`Name the total number of total with finish of t45`

### 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 `Name the total number of total with finish of t45`:
```sql
                SELECT COUNT("total") FROM "made_the_cut" WHERE "finish"='t45';
```
## Task
Generate a SQL query to answer the following question:
`What year was the League the malaysian super league, and a Malaysia Cup of group stage?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "achievements" (
  "year" text,
  "position" text,
  "league" text,
  "fa_cup" text,
  "malaysia_cup" text
);
### SQL
Given the database schema, here is the SQL query that answers `What year was the League the malaysian super league, and a Malaysia Cup of group stage?`:
```sql
                SELECT "year" FROM "achievements" WHERE "league"='malaysian super league' AND "malaysia_cup"='group stage';
```
## Task
Generate a SQL query to answer the following question:
`What is the position when the League is the malaysian super league, and a Year of 2011?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "achievements" (
  "year" text,
  "position" text,
  "league" text,
  "fa_cup" text,
  "malaysia_cup" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the position when the League is the malaysian super league, and a Year of 2011?`:
```sql
                SELECT "position" FROM "achievements" WHERE "league"='malaysian super league' AND "year"='2011';
```
## Task
Generate a SQL query to answer the following question:
`What year was the position 6/13?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "achievements" (
  "year" text,
  "position" text,
  "league" text,
  "fa_cup" text,
  "malaysia_cup" text
);
### SQL
Given the database schema, here is the SQL query that answers `What year was the position 6/13?`:
```sql
                SELECT "year" FROM "achievements" WHERE "position"='6/13';
```
## Task
Generate a SQL query to answer the following question:
`What year was the League of malaysian super league, and the Position was 10/14?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "achievements" (
  "year" text,
  "position" text,
  "league" text,
  "fa_cup" text,
  "malaysia_cup" text
);
### SQL
Given the database schema, here is the SQL query that answers `What year was the League of malaysian super league, and the Position was 10/14?`:
```sql
                SELECT "year" FROM "achievements" WHERE "league"='malaysian super league' AND "position"='10/14';
```
## Task
Generate a SQL query to answer the following question:
`tell me the average roll for the featherston area and integrated authority.`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "south_wairarapa_district" (
  "name" text,
  "years" text,
  "gender" text,
  "area" text,
  "authority" text,
  "decile" real,
  "roll" real
);
### SQL
Given the database schema, here is the SQL query that answers `tell me the average roll for the featherston area and integrated authority.`:
```sql
                SELECT AVG("roll") FROM "south_wairarapa_district" WHERE "area"='featherston' AND "authority"='integrated';
```
## Task
Generate a SQL query to answer the following question:
`tell me the authority that has a decile less than 6 and roll less than 65.`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "south_wairarapa_district" (
  "name" text,
  "years" text,
  "gender" text,
  "area" text,
  "authority" text,
  "decile" real,
  "roll" real
);
### SQL
Given the database schema, here is the SQL query that answers `tell me the authority that has a decile less than 6 and roll less than 65.`:
```sql
                SELECT "authority" FROM "south_wairarapa_district" WHERE "decile"<6 AND "roll"<65;
```
## Task
Generate a SQL query to answer the following question:
`tell me the average roll for pirinoa school.`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "south_wairarapa_district" (
  "name" text,
  "years" text,
  "gender" text,
  "area" text,
  "authority" text,
  "decile" real,
  "roll" real
);
### SQL
Given the database schema, here is the SQL query that answers `tell me the average roll for pirinoa school.`:
```sql
                SELECT AVG("roll") FROM "south_wairarapa_district" WHERE "name"='pirinoa school';
```
## Task
Generate a SQL query to answer the following question:
`tell me the total number of decile with a roll showing 251.`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "south_wairarapa_district" (
  "name" text,
  "years" text,
  "gender" text,
  "area" text,
  "authority" text,
  "decile" real,
  "roll" real
);
### SQL
Given the database schema, here is the SQL query that answers `tell me the total number of decile with a roll showing 251.`:
```sql
                SELECT COUNT("decile") FROM "south_wairarapa_district" WHERE "roll"=251;
```
## Task
Generate a SQL query to answer the following question:
`What is the score for 2004?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "external_links" (
  "year" real,
  "champion" text,
  "score" text,
  "defeated" text,
  "location" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the score for 2004?`:
```sql
                SELECT "score" FROM "external_links" WHERE "year"=2004;
```
## Task
Generate a SQL query to answer the following question:
`what is the location when the champion is brigham young-hawaii, defeated is western oregon and the score is 3-0 (15-5, 15-9, 15-6)?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "external_links" (
  "year" real,
  "champion" text,
  "score" text,
  "defeated" text,
  "location" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the location when the champion is brigham young-hawaii, defeated is western oregon and the score is 3-0 (15-5, 15-9, 15-6)?`:
```sql
                SELECT "location" FROM "external_links" WHERE "champion"='brigham young-hawaii' AND "defeated"='western oregon' AND "score"='3-0 (15-5, 15-9, 15-6)';
```
## Task
Generate a SQL query to answer the following question:
`what is the year when the location is san diego, california and defeated is houston baptist (texas)?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "external_links" (
  "year" real,
  "champion" text,
  "score" text,
  "defeated" text,
  "location" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the year when the location is san diego, california and defeated is houston baptist (texas)?`:
```sql
                SELECT COUNT("year") FROM "external_links" WHERE "location"='san diego, california' AND "defeated"='houston baptist (texas)';
```
## Task
Generate a SQL query to answer the following question:
`Operation start of 2015 has what gross mw?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "units" (
  "unit" text,
  "type" text,
  "gross_mw" text,
  "construction_start" text,
  "operation_start" text
);
### SQL
Given the database schema, here is the SQL query that answers `Operation start of 2015 has what gross mw?`:
```sql
                SELECT "gross_mw" FROM "units" WHERE "operation_start"='2015';
```
## Task
Generate a SQL query to answer the following question:
`Gross MW of 220, and a Unit of kakrapar 1 involves what operation start?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "units" (
  "unit" text,
  "type" text,
  "gross_mw" text,
  "construction_start" text,
  "operation_start" text
);
### SQL
Given the database schema, here is the SQL query that answers `Gross MW of 220, and a Unit of kakrapar 1 involves what operation start?`:
```sql
                SELECT "operation_start" FROM "units" WHERE "gross_mw"='220' AND "unit"='kakrapar 1';
```
## Task
Generate a SQL query to answer the following question:
`Type of phase ii has what gross mw?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "units" (
  "unit" text,
  "type" text,
  "gross_mw" text,
  "construction_start" text,
  "operation_start" text
);
### SQL
Given the database schema, here is the SQL query that answers `Type of phase ii has what gross mw?`:
```sql
                SELECT "gross_mw" FROM "units" WHERE "type"='phase ii';
```
## Task
Generate a SQL query to answer the following question:
`Construction start of phase i includes what type?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "units" (
  "unit" text,
  "type" text,
  "gross_mw" text,
  "construction_start" text,
  "operation_start" text
);
### SQL
Given the database schema, here is the SQL query that answers `Construction start of phase i includes what type?`:
```sql
                SELECT "type" FROM "units" WHERE "construction_start"='phase i';
```
## Task
Generate a SQL query to answer the following question:
`Construction start of 1 december 1984 is what unit?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "units" (
  "unit" text,
  "type" text,
  "gross_mw" text,
  "construction_start" text,
  "operation_start" text
);
### SQL
Given the database schema, here is the SQL query that answers `Construction start of 1 december 1984 is what unit?`:
```sql
                SELECT "unit" FROM "units" WHERE "construction_start"='1 december 1984';
```
## Task
Generate a SQL query to answer the following question:
`Construction start of phase ii has what operation start?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "units" (
  "unit" text,
  "type" text,
  "gross_mw" text,
  "construction_start" text,
  "operation_start" text
);
### SQL
Given the database schema, here is the SQL query that answers `Construction start of phase ii has what operation start?`:
```sql
                SELECT "operation_start" FROM "units" WHERE "construction_start"='phase ii';
```
## Task
Generate a SQL query to answer the following question:
`what's the ungen for ត្រីទស?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "sanskrit_and_pali_influence" (
  "value" text,
  "khmer" text,
  "word_form" text,
  "ungegn" text,
  "ala_lc" text,
  "notes" text
);
### SQL
Given the database schema, here is the SQL query that answers `what's the ungen for ត្រីទស?`:
```sql
                SELECT "ungegn" FROM "sanskrit_and_pali_influence" WHERE "word_form"='ត្រីទស';
```
## Task
Generate a SQL query to answer the following question:
`what notes have the khmer ២៨?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "sanskrit_and_pali_influence" (
  "value" text,
  "khmer" text,
  "word_form" text,
  "ungegn" text,
  "ala_lc" text,
  "notes" text
);
### SQL
Given the database schema, here is the SQL query that answers `what notes have the khmer ២៨?`:
```sql
                SELECT "notes" FROM "sanskrit_and_pali_influence" WHERE "khmer"='២៨';
```
## Task
Generate a SQL query to answer the following question:
`what's the ungegn for the ១០០ khmer?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "sanskrit_and_pali_influence" (
  "value" text,
  "khmer" text,
  "word_form" text,
  "ungegn" text,
  "ala_lc" text,
  "notes" text
);
### SQL
Given the database schema, here is the SQL query that answers `what's the ungegn for the ១០០ khmer?`:
```sql
                SELECT "ungegn" FROM "sanskrit_and_pali_influence" WHERE "khmer"='១០០';
```
## Task
Generate a SQL query to answer the following question:
`What was the population of Puerto Rico in 2010?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "inhabited_territories_of_the_united_stat" (
  "territory" text,
  "abbr" text,
  "capital" text,
  "acquired" real,
  "territorial_status" text,
  "population_2010" real,
  "house_seat" real
);
### SQL
Given the database schema, here is the SQL query that answers `What was the population of Puerto Rico in 2010?`:
```sql
                SELECT MAX("population_2010") FROM "inhabited_territories_of_the_united_stat" WHERE "territory"='puerto rico';
```
## Task
Generate a SQL query to answer the following question:
`What is the territory that was acquired past 1899 and has a capital of saipan?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "inhabited_territories_of_the_united_stat" (
  "territory" text,
  "abbr" text,
  "capital" text,
  "acquired" real,
  "territorial_status" text,
  "population_2010" real,
  "house_seat" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the territory that was acquired past 1899 and has a capital of saipan?`:
```sql
                SELECT "territory" FROM "inhabited_territories_of_the_united_stat" WHERE "acquired">1899 AND "capital"='saipan';
```
## Task
Generate a SQL query to answer the following question:
`Name the termination of mission for appointed by of franklin pierce`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "see_also" (
  "representative" text,
  "title" text,
  "presentation_of_credentials" text,
  "termination_of_mission" text,
  "appointed_by" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the termination of mission for appointed by of franklin pierce`:
```sql
                SELECT "termination_of_mission" FROM "see_also" WHERE "appointed_by"='franklin pierce';
```
## Task
Generate a SQL query to answer the following question:
`Name the representative with presentation of credentials of august 16, 1928`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "see_also" (
  "representative" text,
  "title" text,
  "presentation_of_credentials" text,
  "termination_of_mission" text,
  "appointed_by" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the representative with presentation of credentials of august 16, 1928`:
```sql
                SELECT "representative" FROM "see_also" WHERE "presentation_of_credentials"='august 16, 1928';
```
## Task
Generate a SQL query to answer the following question:
`Name the representative appointed by george w. bush with presentation of credentials 9 november 2007`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "see_also" (
  "representative" text,
  "title" text,
  "presentation_of_credentials" text,
  "termination_of_mission" text,
  "appointed_by" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the representative appointed by george w. bush with presentation of credentials 9 november 2007`:
```sql
                SELECT "representative" FROM "see_also" WHERE "appointed_by"='george w. bush' AND "presentation_of_credentials"='9 november 2007';
```
## Task
Generate a SQL query to answer the following question:
`Name the title with representative edward h. strobel`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "see_also" (
  "representative" text,
  "title" text,
  "presentation_of_credentials" text,
  "termination_of_mission" text,
  "appointed_by" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the title with representative edward h. strobel`:
```sql
                SELECT "title" FROM "see_also" WHERE "representative"='edward h. strobel';
```
## Task
Generate a SQL query to answer the following question:
`Which Country that has 600?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "final_round" (
  "place" text,
  "player" text,
  "country" text,
  "score" text,
  "to_par" text,
  "money" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Country that has 600?`:
```sql
                SELECT "country" FROM "final_round" WHERE "money"=600;
```
## Task
Generate a SQL query to answer the following question:
`What is the to par that has macdonald smith as the player?`

### 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 that has macdonald smith as the player?`:
```sql
                SELECT "to_par" FROM "second_round" WHERE "player"='macdonald smith';
```
## Task
Generate a SQL query to answer the following question:
`Which country has t6 as a place and 75-70=145 as the score?`

### 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 `Which country has t6 as a place and 75-70=145 as the score?`:
```sql
                SELECT "country" FROM "second_round" WHERE "place"='t6' AND "score"='75-70=145';
```
## Task
Generate a SQL query to answer the following question:
`What is the to par that has jimmy hines as the player?`

### 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 that has jimmy hines as the player?`:
```sql
                SELECT "to_par" FROM "second_round" WHERE "player"='jimmy hines';
```
## Task
Generate a SQL query to answer the following question:
`Which score has t3 as the place?`

### 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 `Which score has t3 as the place?`:
```sql
                SELECT "score" FROM "second_round" WHERE "place"='t3';
```
## Task
Generate a SQL query to answer the following question:
`Which place has horton smith as the player?`

### 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 `Which place has horton smith as the player?`:
```sql
                SELECT "place" FROM "second_round" WHERE "player"='horton smith';
```
## Task
Generate a SQL query to answer the following question:
`Which place has United States as the country and Craig Wood as the player?`

### 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 `Which place has United States as the country and Craig Wood as the player?`:
```sql
                SELECT "place" FROM "second_round" WHERE "country"='united states' AND "player"='craig wood';
```
## Task
Generate a SQL query to answer the following question:
`What was the 2013 finish for the tournament that had a 2007 finish of A?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "singles_performance_timeline" (
  "tournament" text,
  "2007" text,
  "2008" text,
  "2009" text,
  "2010" text,
  "2011" text,
  "2012" text,
  "2013" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the 2013 finish for the tournament that had a 2007 finish of A?`:
```sql
                SELECT "2013" FROM "singles_performance_timeline" WHERE "2007"='a';
```
## Task
Generate a SQL query to answer the following question:
`What was the 2012 finish in the US Open?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "singles_performance_timeline" (
  "tournament" text,
  "2007" text,
  "2008" text,
  "2009" text,
  "2010" text,
  "2011" text,
  "2012" text,
  "2013" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the 2012 finish in the US Open?`:
```sql
                SELECT "2012" FROM "singles_performance_timeline" WHERE "tournament"='us open';
```
## Task
Generate a SQL query to answer the following question:
`Which tournament had a 2010 finish of 4R?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "singles_performance_timeline" (
  "tournament" text,
  "2007" text,
  "2008" text,
  "2009" text,
  "2010" text,
  "2011" text,
  "2012" text,
  "2013" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which tournament had a 2010 finish of 4R?`:
```sql
                SELECT "tournament" FROM "singles_performance_timeline" WHERE "2010"='4r';
```
## Task
Generate a SQL query to answer the following question:
`Name the 18th september 2007-19:45 with preston north end of watford`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "the_championship" (
  "18_september_2007_19_45" text,
  "preston_north_end" text,
  "home" text,
  "won_2_1" text,
  "5_754" real
);
### SQL
Given the database schema, here is the SQL query that answers `Name the 18th september 2007-19:45 with preston north end of watford`:
```sql
                SELECT "18_september_2007_19_45" FROM "the_championship" WHERE "preston_north_end"='watford';
```
## Task
Generate a SQL query to answer the following question:
`Name the won 2-1 for preston north end of preston`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "the_championship" (
  "18_september_2007_19_45" text,
  "preston_north_end" text,
  "home" text,
  "won_2_1" text,
  "5_754" real
);
### SQL
Given the database schema, here is the SQL query that answers `Name the won 2-1 for preston north end of preston`:
```sql
                SELECT "won_2_1" FROM "the_championship" WHERE "preston_north_end"='preston';
```
## Task
Generate a SQL query to answer the following question:
`What is the qualification for rank of 29 in 1957?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "indy_500_results" (
  "year" text,
  "start" text,
  "qual" text,
  "rank" text,
  "finish" text,
  "laps" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the qualification for rank of 29 in 1957?`:
```sql
                SELECT "qual" FROM "indy_500_results" WHERE "rank"='29' AND "year"='1957';
```
## Task
Generate a SQL query to answer the following question:
`What is the Place when the To par was +3 and Score was 74-73=147?`

### 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 Place when the To par was +3 and Score was 74-73=147?`:
```sql
                SELECT "place" FROM "second_round" WHERE "to_par"='+3' AND "score"='74-73=147';
```
## Task
Generate a SQL query to answer the following question:
`When the To par is E, what is the Score?`

### 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 `When the To par is E, what is the Score?`:
```sql
                SELECT "score" FROM "second_round" WHERE "to_par"='e';
```
## Task
Generate a SQL query to answer the following question:
`What was Lloyd Mangrum's Score?`

### 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 was Lloyd Mangrum's Score?`:
```sql
                SELECT "score" FROM "second_round" WHERE "player"='lloyd mangrum';
```
## Task
Generate a SQL query to answer the following question:
`What Dave Douglas' Place?`

### 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 Dave Douglas' Place?`:
```sql
                SELECT "place" FROM "second_round" WHERE "player"='dave douglas';
```
## Task
Generate a SQL query to answer the following question:
`What's Chick Harbert'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's Chick Harbert's To par?`:
```sql
                SELECT "to_par" FROM "second_round" WHERE "player"='chick harbert';
```
## Task
Generate a SQL query to answer the following question:
`What United States Player has a To par of +4 and a Score of 71-77=148?`

### 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 United States Player has a To par of +4 and a Score of 71-77=148?`:
```sql
                SELECT "player" FROM "second_round" WHERE "country"='united states' AND "to_par"='+4' AND "score"='71-77=148';
```
## Task
Generate a SQL query to answer the following question:
`What is South Korea's to par value?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "final_round" (
  "place" text,
  "player" text,
  "country" text,
  "score" text,
  "to_par" text,
  "money" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is South Korea's to par value?`:
```sql
                SELECT "to_par" FROM "final_round" WHERE "country"='south korea';
```
## Task
Generate a SQL query to answer the following question:
`What are Tiger Woods' average earnings?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "final_round" (
  "place" text,
  "player" text,
  "country" text,
  "score" text,
  "to_par" text,
  "money" real
);
### SQL
Given the database schema, here is the SQL query that answers `What are Tiger Woods' average earnings?`:
```sql
                SELECT AVG("money") FROM "final_round" WHERE "player"='tiger woods';
```
## Task
Generate a SQL query to answer the following question:
`What's the method for a record of 4-2 and round smaller than 3?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "mixed_martial_arts_record" (
  "res" text,
  "record" text,
  "opponent" text,
  "method" text,
  "round" real,
  "time" text,
  "location" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the method for a record of 4-2 and round smaller than 3?`:
```sql
                SELECT "method" FROM "mixed_martial_arts_record" WHERE "round"<3 AND "record"='4-2';
```
## Task
Generate a SQL query to answer the following question:
`Where's the location for the opponent James Zikic and 3 rounds?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "mixed_martial_arts_record" (
  "res" text,
  "record" text,
  "opponent" text,
  "method" text,
  "round" real,
  "time" text,
  "location" text
);
### SQL
Given the database schema, here is the SQL query that answers `Where's the location for the opponent James Zikic and 3 rounds?`:
```sql
                SELECT "location" FROM "mixed_martial_arts_record" WHERE "round"=3 AND "opponent"='james zikic';
```
## Task
Generate a SQL query to answer the following question:
`Name the spouse for louise of hesse-kassel`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "house_of_schleswig_holstein_sonderburg_g" (
  "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 `Name the spouse for louise of hesse-kassel`:
```sql
                SELECT "spouse" FROM "house_of_schleswig_holstein_sonderburg_g" WHERE "name"='louise of hesse-kassel';
```
## Task
Generate a SQL query to answer the following question:
`Name the became consort for christian ix spouse`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "house_of_schleswig_holstein_sonderburg_g" (
  "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 `Name the became consort for christian ix spouse`:
```sql
                SELECT "became_consort" FROM "house_of_schleswig_holstein_sonderburg_g" WHERE "spouse"='christian ix';
```
## Task
Generate a SQL query to answer the following question:
`Name the marriagefor ceased to be consort of 29 september 1898`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "house_of_schleswig_holstein_sonderburg_g" (
  "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 `Name the marriagefor ceased to be consort of 29 september 1898`:
```sql
                SELECT "marriage" FROM "house_of_schleswig_holstein_sonderburg_g" WHERE "ceased_to_be_consort"='29 september 1898';
```
## Task
Generate a SQL query to answer the following question:
`Tell me the name of the person married to frederick ix`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "house_of_schleswig_holstein_sonderburg_g" (
  "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 `Tell me the name of the person married to frederick ix`:
```sql
                SELECT "name" FROM "house_of_schleswig_holstein_sonderburg_g" WHERE "spouse"='frederick ix';
```
## Task
Generate a SQL query to answer the following question:
`Name the birth of the person married 24 may 1935`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "house_of_schleswig_holstein_sonderburg_g" (
  "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 `Name the birth of the person married 24 may 1935`:
```sql
                SELECT "birth" FROM "house_of_schleswig_holstein_sonderburg_g" WHERE "marriage"='24 may 1935';
```
## Task
Generate a SQL query to answer the following question:
`What was the rank of the player in lane 6?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "semifinal_2" (
  "rank" real,
  "lane" real,
  "name" text,
  "nationality" text,
  "time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the rank of the player in lane 6?`:
```sql
                SELECT AVG("rank") FROM "semifinal_2" WHERE "lane"=6;
```
## Task
Generate a SQL query to answer the following question:
`Name the average year with Laps of 6`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "complete_24_hours_of_le_mans_results" (
  "year" real,
  "class" text,
  "tyres" text,
  "team" text,
  "co_drivers" text,
  "laps" real,
  "pos" text,
  "class_pos" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the average year with Laps of 6`:
```sql
                SELECT AVG("year") FROM "complete_24_hours_of_le_mans_results" WHERE "laps"=6;
```
## Task
Generate a SQL query to answer the following question:
`Which Language has a Number of 553 633?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "language" (
  "language" text,
  "number" text,
  "percentage_pct" text,
  "males" text,
  "females" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Language has a Number of 553 633?`:
```sql
                SELECT "language" FROM "language" WHERE "number"='553 633';
```
## Task
Generate a SQL query to answer the following question:
`Which Males have a percentage of 0.42?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "language" (
  "language" text,
  "number" text,
  "percentage_pct" text,
  "males" text,
  "females" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Males have a percentage of 0.42?`:
```sql
                SELECT "males" FROM "language" WHERE "percentage_pct"='0.42';
```
## Task
Generate a SQL query to answer the following question:
`What's the Language with a percentage of 6.49?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "language" (
  "language" text,
  "number" text,
  "percentage_pct" text,
  "males" text,
  "females" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the Language with a percentage of 6.49?`:
```sql
                SELECT "language" FROM "language" WHERE "percentage_pct"='6.49';
```
## Task
Generate a SQL query to answer the following question:
`What Number has a Language listed as other?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "language" (
  "language" text,
  "number" text,
  "percentage_pct" text,
  "males" text,
  "females" text
);
### SQL
Given the database schema, here is the SQL query that answers `What Number has a Language listed as other?`:
```sql
                SELECT "number" FROM "language" WHERE "language"='other';
```
## Task
Generate a SQL query to answer the following question:
`what is the highest gold count when total is more than 3, bronze less than 3, and nation of belarus with silver count more than 2?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "medals_table" (
  "nation" text,
  "gold" real,
  "silver" real,
  "bronze" real,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `what is the highest gold count when total is more than 3, bronze less than 3, and nation of belarus with silver count more than 2?`:
```sql
                SELECT MAX("gold") FROM "medals_table" WHERE "total">3 AND "bronze"<3 AND "nation"='belarus' AND "silver">2;
```
## Task
Generate a SQL query to answer the following question:
`with silver count at 0, what is the lowest bronze count?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "medals_table" (
  "nation" text,
  "gold" real,
  "silver" real,
  "bronze" real,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `with silver count at 0, what is the lowest bronze count?`:
```sql
                SELECT MIN("bronze") FROM "medals_table" WHERE "silver"<0;
```
## Task
Generate a SQL query to answer the following question:
`what is the gold count with total less than 3 and more than 1 silver?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "medals_table" (
  "nation" text,
  "gold" real,
  "silver" real,
  "bronze" real,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `what is the gold count with total less than 3 and more than 1 silver?`:
```sql
                SELECT MIN("gold") FROM "medals_table" WHERE "total"<3 AND "silver">1;
```
## Task
Generate a SQL query to answer the following question:
`Who built the ship that is 42.8 m long and was delivered in 2007?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "jdf_coast_guard" (
  "name_of_ship" text,
  "length" text,
  "max_speed" text,
  "crew_capacity" text,
  "class" text,
  "builder" text,
  "delivery" real
);
### SQL
Given the database schema, here is the SQL query that answers `Who built the ship that is 42.8 m long and was delivered in 2007?`:
```sql
                SELECT "builder" FROM "jdf_coast_guard" WHERE "length"='42.8 m' AND "delivery"=2007;
```
## Task
Generate a SQL query to answer the following question:
`Who was the Human Resources & Operations person between 2003-2004?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "executive_commissioners" (
  "year" text,
  "human_resources_operations" text,
  "local_affairs" text,
  "academic_university_affairs" text,
  "external_affairs" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the Human Resources & Operations person between 2003-2004?`:
```sql
                SELECT "human_resources_operations" FROM "executive_commissioners" WHERE "year"='2003-2004';
```
## Task
Generate a SQL query to answer the following question:
`Who was in local affairs when the Human Resources & Operations was N. Charles Hamilton?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "executive_commissioners" (
  "year" text,
  "human_resources_operations" text,
  "local_affairs" text,
  "academic_university_affairs" text,
  "external_affairs" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was in local affairs when the Human Resources & Operations was N. Charles Hamilton?`:
```sql
                SELECT "local_affairs" FROM "executive_commissioners" WHERE "human_resources_operations"='n. charles hamilton';
```
## Task
Generate a SQL query to answer the following question:
`Who was in Human Resources & Operations when David Hornsby was in Academic & University Affairs?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "executive_commissioners" (
  "year" text,
  "human_resources_operations" text,
  "local_affairs" text,
  "academic_university_affairs" text,
  "external_affairs" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was in Human Resources & Operations when David Hornsby was in Academic & University Affairs?`:
```sql
                SELECT "human_resources_operations" FROM "executive_commissioners" WHERE "academic_university_affairs"='david hornsby';
```