output stringlengths 27 479 | instruction stringlengths 407 1.39k |
|---|---|
SELECT "model" FROM "airbus_jetliners_1972_1994" WHERE "a310"='1983'; |
## Task
Generate a SQL query to answer the following question:
`What model is the A310 of 1983?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "airbus_jetliners_1972_1994" (
"model" text,
"a300" text,
"a310" text,
"a320" text,
"a330" text,
"a340" text
);
### SQL
Given the database schema, here is the SQL query that answers `What model is the A310 of 1983?`:
```sql
|
SELECT "no_2" FROM "male_names" WHERE "no_6"='ethan' AND "no_3"='mason'; |
## Task
Generate a SQL query to answer the following question:
`What name is in the number 2 spot when Ethan is in the number 6 spot and Mason is in the number 3 spot?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "male_names" (
"region_year" text,
"no_1" text,
"no_2" text,
"no_3" text,
"no_4" text,
"no_5" text,
"no_6" text,
"no_7" text,
"no_8" text,
"no_9" text,
"no_10" text
);
### SQL
Given the database schema, here is the SQL query that answers `What name is in the number 2 spot when Ethan is in the number 6 spot and Mason is in the number 3 spot?`:
```sql
|
SELECT "region_year" FROM "male_names" WHERE "no_2"='jacob' AND "no_10"='ryan'; |
## Task
Generate a SQL query to answer the following question:
`In what region and year was Jacob the number 2 name and Ryan the number 10 name?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "male_names" (
"region_year" text,
"no_1" text,
"no_2" text,
"no_3" text,
"no_4" text,
"no_5" text,
"no_6" text,
"no_7" text,
"no_8" text,
"no_9" text,
"no_10" text
);
### SQL
Given the database schema, here is the SQL query that answers `In what region and year was Jacob the number 2 name and Ryan the number 10 name?`:
```sql
|
SELECT "no_7" FROM "male_names" WHERE "no_1"='mason' AND "no_9"='jackson' AND "no_10"='logan' AND "no_6"='owen'; |
## Task
Generate a SQL query to answer the following question:
`What name was number 7 when Mason was number 1, Owen was number 6, Jackson was number 9, and Logan was number 10?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "male_names" (
"region_year" text,
"no_1" text,
"no_2" text,
"no_3" text,
"no_4" text,
"no_5" text,
"no_6" text,
"no_7" text,
"no_8" text,
"no_9" text,
"no_10" text
);
### SQL
Given the database schema, here is the SQL query that answers `What name was number 7 when Mason was number 1, Owen was number 6, Jackson was number 9, and Logan was number 10?`:
```sql
|
SELECT "no_4" FROM "male_names" WHERE "no_7"='aiden' AND "no_3"='james'; |
## Task
Generate a SQL query to answer the following question:
`What name was in the number 4 spot when Aiden was number 7 and James was number 3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "male_names" (
"region_year" text,
"no_1" text,
"no_2" text,
"no_3" text,
"no_4" text,
"no_5" text,
"no_6" text,
"no_7" text,
"no_8" text,
"no_9" text,
"no_10" text
);
### SQL
Given the database schema, here is the SQL query that answers `What name was in the number 4 spot when Aiden was number 7 and James was number 3?`:
```sql
|
SELECT "position" FROM "j" WHERE "player"='damon jones'; |
## Task
Generate a SQL query to answer the following question:
`What is the positions of Damon Jones?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "j" (
"player" text,
"nationality" text,
"position" text,
"years_for_grizzlies" text,
"school_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the positions of Damon Jones?`:
```sql
|
SELECT "years_for_grizzlies" FROM "j" WHERE "school_club_team"='stanford'; |
## Task
Generate a SQL query to answer the following question:
`for how many years did the player who graduated from stanford play for Grizzlies?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "j" (
"player" text,
"nationality" text,
"position" text,
"years_for_grizzlies" text,
"school_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `for how many years did the player who graduated from stanford play for Grizzlies?`:
```sql
|
SELECT "school_club_team" FROM "j" WHERE "player"='dahntay jones'; |
## Task
Generate a SQL query to answer the following question:
`Which school did Dahntay Jones graduate from?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "j" (
"player" text,
"nationality" text,
"position" text,
"years_for_grizzlies" text,
"school_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which school did Dahntay Jones graduate from?`:
```sql
|
SELECT "player" FROM "j" WHERE "school_club_team"='florida state'; |
## Task
Generate a SQL query to answer the following question:
`Which player gradyated from Florida State?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "j" (
"player" text,
"nationality" text,
"position" text,
"years_for_grizzlies" text,
"school_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which player gradyated from Florida State?`:
```sql
|
SELECT "playoffs_mvp" FROM "finals" WHERE "result"='4β1' AND "champions"='daejeon hyundai dynat'; |
## Task
Generate a SQL query to answer the following question:
`What is the Playoffs MVP of the game with a Result of 4β1 with Champions Daejeon Hyundai Dynat?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "finals" (
"year" text,
"champions" text,
"result" text,
"runners_up" text,
"playoffs_mvp" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Playoffs MVP of the game with a Result of 4β1 with Champions Daejeon Hyundai Dynat?`:
```sql
|
SELECT "year" FROM "finals" WHERE "result"='4β3' AND "champions"='daegu tongyang orions'; |
## Task
Generate a SQL query to answer the following question:
`What is the Year of the game with Result of 4β3 and Champions of Daegu Tongyang Orions?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "finals" (
"year" text,
"champions" text,
"result" text,
"runners_up" text,
"playoffs_mvp" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Year of the game with Result of 4β3 and Champions of Daegu Tongyang Orions?`:
```sql
|
SELECT "runners_up" FROM "finals" WHERE "result"='4β1' AND "champions"='wonju dongbu promy'; |
## Task
Generate a SQL query to answer the following question:
`What is the Runners-up of the game with a Result of 4β1 and Champions of Wonju Dongbu Promy?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "finals" (
"year" text,
"champions" text,
"result" text,
"runners_up" text,
"playoffs_mvp" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Runners-up of the game with a Result of 4β1 and Champions of Wonju Dongbu Promy?`:
```sql
|
SELECT "venue" FROM "friendlies" WHERE "opponent"='linfield'; |
## Task
Generate a SQL query to answer the following question:
`Where was the venue that Linfield was the opponent?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "friendlies" (
"date" text,
"opponent" text,
"venue" text,
"result" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `Where was the venue that Linfield was the opponent?`:
```sql
|
SELECT "scorer" FROM "fourth_division" WHERE "club"='aldershot' AND "league_goals"='19'; |
## Task
Generate a SQL query to answer the following question:
`Which scorer plays for Aldershot and has scored a total of 19 League goals?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fourth_division" (
"scorer" text,
"club" text,
"league_goals" text,
"fa_cup_goals" real,
"league_cup_goals" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which scorer plays for Aldershot and has scored a total of 19 League goals?`:
```sql
|
SELECT MAX("league_cup_goals") FROM "fourth_division" WHERE "club"='hartlepool'; |
## Task
Generate a SQL query to answer the following question:
`What is the highest number of League Cup goals that were scored by Hartlepool?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fourth_division" (
"scorer" text,
"club" text,
"league_goals" text,
"fa_cup_goals" real,
"league_cup_goals" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest number of League Cup goals that were scored by Hartlepool?`:
```sql
|
SELECT "date" FROM "round_12" WHERE "venue"='north shore events centre'; |
## Task
Generate a SQL query to answer the following question:
`When was the game at the North Shore Events Centre?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_12" (
"date" text,
"home_team" text,
"score" text,
"away_team" text,
"venue" text,
"box_score" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `When was the game at the North Shore Events Centre?`:
```sql
|
SELECT "report" FROM "round_12" WHERE "home_team"='townsville crocodiles'; |
## Task
Generate a SQL query to answer the following question:
`What is the report corresponding to the game that had the Townsville Crocodiles as home team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_12" (
"date" text,
"home_team" text,
"score" text,
"away_team" text,
"venue" text,
"box_score" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the report corresponding to the game that had the Townsville Crocodiles as home team?`:
```sql
|
SELECT "date" FROM "round_12" WHERE "away_team"='sydney spirit'; |
## Task
Generate a SQL query to answer the following question:
`When was the game that had Sydney Spirit as the away team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_12" (
"date" text,
"home_team" text,
"score" text,
"away_team" text,
"venue" text,
"box_score" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `When was the game that had Sydney Spirit as the away team?`:
```sql
|
SELECT "box_score" FROM "round_12" WHERE "home_team"='townsville crocodiles'; |
## Task
Generate a SQL query to answer the following question:
`What was the box score for the game that had the Townsville Crocodiles as home team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_12" (
"date" text,
"home_team" text,
"score" text,
"away_team" text,
"venue" text,
"box_score" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the box score for the game that had the Townsville Crocodiles as home team?`:
```sql
|
SELECT "box_score" FROM "round_12" WHERE "home_team"='cairns taipans'; |
## Task
Generate a SQL query to answer the following question:
`What was the box score for the game that had the Cairns Taipans as home team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_12" (
"date" text,
"home_team" text,
"score" text,
"away_team" text,
"venue" text,
"box_score" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the box score for the game that had the Cairns Taipans as home team?`:
```sql
|
SELECT COUNT("laps") FROM "moto_gp_classification" WHERE "time_retired"='+33.912'; |
## Task
Generate a SQL query to answer the following question:
`What's the lap number for time/retired of +33.912?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moto_gp_classification" (
"rider" text,
"manufacturer" text,
"laps" real,
"time_retired" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `What's the lap number for time/retired of +33.912?`:
```sql
|
SELECT COUNT("laps") FROM "moto_gp_classification" WHERE "rider"='shinya nakano' AND "grid"<10; |
## Task
Generate a SQL query to answer the following question:
`Total laps for Shinya Nakano at smaller than 10 grids.`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moto_gp_classification" (
"rider" text,
"manufacturer" text,
"laps" real,
"time_retired" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `Total laps for Shinya Nakano at smaller than 10 grids.`:
```sql
|
SELECT "years" FROM "a" WHERE "from"='connecticut'; |
## Task
Generate a SQL query to answer the following question:
`What years were from Connecticut?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "a" (
"player" text,
"nationality" text,
"jersey_number_s" text,
"position" text,
"years" text,
"from" text
);
### SQL
Given the database schema, here is the SQL query that answers `What years were from Connecticut?`:
```sql
|
SELECT "from" FROM "a" WHERE "position"='sg'; |
## Task
Generate a SQL query to answer the following question:
`Where is the position of sG from?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "a" (
"player" text,
"nationality" text,
"jersey_number_s" text,
"position" text,
"years" text,
"from" text
);
### SQL
Given the database schema, here is the SQL query that answers `Where is the position of sG from?`:
```sql
|
SELECT "player" FROM "a" WHERE "jersey_number_s"='2'; |
## Task
Generate a SQL query to answer the following question:
`Which player wears the number 2 on his jersey?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "a" (
"player" text,
"nationality" text,
"jersey_number_s" text,
"position" text,
"years" text,
"from" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which player wears the number 2 on his jersey?`:
```sql
|
SELECT "position" FROM "a" WHERE "from"='georgia tech'; |
## Task
Generate a SQL query to answer the following question:
`What position is from Georgia Tech?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "a" (
"player" text,
"nationality" text,
"jersey_number_s" text,
"position" text,
"years" text,
"from" text
);
### SQL
Given the database schema, here is the SQL query that answers `What position is from Georgia Tech?`:
```sql
|
SELECT "high_rebounds" FROM "game_log" WHERE "team"='san antonio spurs'; |
## Task
Generate a SQL query to answer the following question:
`What is the highest number of rebounds of the san antonio spurs?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "game_log" (
"game" real,
"date" text,
"team" text,
"score" text,
"high_points" text,
"high_rebounds" text,
"high_assists" text,
"location_attendance" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest number of rebounds of the san antonio spurs?`:
```sql
|
SELECT "score" FROM "game_log" WHERE "game"=4; |
## Task
Generate a SQL query to answer the following question:
`What was the score of game 4?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "game_log" (
"game" real,
"date" text,
"team" text,
"score" text,
"high_points" text,
"high_rebounds" text,
"high_assists" text,
"location_attendance" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the score of game 4?`:
```sql
|
SELECT "date" FROM "game_log" WHERE "score"='w 105-88'; |
## Task
Generate a SQL query to answer the following question:
`What is the date of the game with a w 105-88 score?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "game_log" (
"game" real,
"date" text,
"team" text,
"score" text,
"high_points" text,
"high_rebounds" text,
"high_assists" text,
"location_attendance" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the date of the game with a w 105-88 score?`:
```sql
|
SELECT "game" FROM "game_log" WHERE "team"='golden state warriors'; |
## Task
Generate a SQL query to answer the following question:
`What is the game with the golden state warriors?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "game_log" (
"game" real,
"date" text,
"team" text,
"score" text,
"high_points" text,
"high_rebounds" text,
"high_assists" text,
"location_attendance" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the game with the golden state warriors?`:
```sql
|
SELECT COUNT("pick") FROM "nfl_draft" WHERE "school"='southern mississippi'; |
## Task
Generate a SQL query to answer the following question:
`What is the Pick # of the Player from Southern MIssissippi?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nfl_draft" (
"round" real,
"pick" real,
"player" text,
"position" text,
"school" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Pick # of the Player from Southern MIssissippi?`:
```sql
|
SELECT "round" FROM "nfl_draft" WHERE "player"='derrick franklin'; |
## Task
Generate a SQL query to answer the following question:
`In what Round was Derrick Franklin picked?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nfl_draft" (
"round" real,
"pick" real,
"player" text,
"position" text,
"school" text
);
### SQL
Given the database schema, here is the SQL query that answers `In what Round was Derrick Franklin picked?`:
```sql
|
SELECT COUNT("round") FROM "nfl_draft" WHERE "pick">9 AND "school"='duke'; |
## Task
Generate a SQL query to answer the following question:
`In what Round does Duke have a Pick larger than 9?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nfl_draft" (
"round" real,
"pick" real,
"player" text,
"position" text,
"school" text
);
### SQL
Given the database schema, here is the SQL query that answers `In what Round does Duke have a Pick larger than 9?`:
```sql
|
SELECT MAX("round") FROM "nfl_draft" WHERE "player"='tommy norman'; |
## Task
Generate a SQL query to answer the following question:
`In what Round was Tommy Norman picked?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nfl_draft" (
"round" real,
"pick" real,
"player" text,
"position" text,
"school" text
);
### SQL
Given the database schema, here is the SQL query that answers `In what Round was Tommy Norman picked?`:
```sql
|
SELECT "2000" FROM "performance_indicators_for_nwsc_1998_201" WHERE "1998"='1.5'; |
## Task
Generate a SQL query to answer the following question:
`What is the 2000 value if the 1998 value is 1.5?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "performance_indicators_for_nwsc_1998_201" (
"1998" text,
"2000" text,
"2004" text,
"2007" text,
"2011" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2000 value if the 1998 value is 1.5?`:
```sql
|
SELECT "2004" FROM "performance_indicators_for_nwsc_1998_201" WHERE "1998"='35'; |
## Task
Generate a SQL query to answer the following question:
`What is the 2004 value if the 1998 value is 35?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "performance_indicators_for_nwsc_1998_201" (
"1998" text,
"2000" text,
"2004" text,
"2007" text,
"2011" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2004 value if the 1998 value is 35?`:
```sql
|
SELECT "1998" FROM "performance_indicators_for_nwsc_1998_201" WHERE "2000"='25'; |
## Task
Generate a SQL query to answer the following question:
`What is the 1998 value if the 2000 value is 25?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "performance_indicators_for_nwsc_1998_201" (
"1998" text,
"2000" text,
"2004" text,
"2007" text,
"2011" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 1998 value if the 2000 value is 25?`:
```sql
|
SELECT "1998" FROM "performance_indicators_for_nwsc_1998_201" WHERE "2007"='8'; |
## Task
Generate a SQL query to answer the following question:
`What is the 1998 value if the 2007 value is 8?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "performance_indicators_for_nwsc_1998_201" (
"1998" text,
"2000" text,
"2004" text,
"2007" text,
"2011" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 1998 value if the 2007 value is 8?`:
```sql
|
SELECT "2000" FROM "performance_indicators_for_nwsc_1998_201" WHERE "1998"='1.5'; |
## Task
Generate a SQL query to answer the following question:
`What is the 2000 value if the 1998 value is 1.5?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "performance_indicators_for_nwsc_1998_201" (
"1998" text,
"2000" text,
"2004" text,
"2007" text,
"2011" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2000 value if the 1998 value is 1.5?`:
```sql
|
SELECT "1998" FROM "performance_indicators_for_nwsc_1998_201" WHERE "2011"='30.4'; |
## Task
Generate a SQL query to answer the following question:
`What is the 1998 value if the 2011 value is 30.4?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "performance_indicators_for_nwsc_1998_201" (
"1998" text,
"2000" text,
"2004" text,
"2007" text,
"2011" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 1998 value if the 2011 value is 30.4?`:
```sql
|
SELECT "interface" FROM "typical_duplex_scanners" WHERE "product"='xerox travel scanner 100'; |
## Task
Generate a SQL query to answer the following question:
`What is the interface of the product xerox travel scanner 100?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "typical_duplex_scanners" (
"product" text,
"dimensions_mm" text,
"pages_per_minute_color" real,
"max_page_size" text,
"interface" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the interface of the product xerox travel scanner 100?`:
```sql
|
SELECT "pages_per_minute_color" FROM "typical_duplex_scanners" WHERE "max_page_size"='a4' AND "dimensions_mm"='303 x 94 x 60'; |
## Task
Generate a SQL query to answer the following question:
`What is the pages per minute (color) of the machine that has a max page size of a4 and dimensions (mm) of 303 x 94 x 60?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "typical_duplex_scanners" (
"product" text,
"dimensions_mm" text,
"pages_per_minute_color" real,
"max_page_size" text,
"interface" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the pages per minute (color) of the machine that has a max page size of a4 and dimensions (mm) of 303 x 94 x 60?`:
```sql
|
SELECT "club" FROM "end_of_season_managerial_changes" WHERE "name"='guus hiddink'; |
## Task
Generate a SQL query to answer the following question:
`What club had Guus Hiddink as outgoing manager?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "end_of_season_managerial_changes" (
"name" text,
"club" text,
"date_of_departure" text,
"replacement" text,
"date_of_appointment" text
);
### SQL
Given the database schema, here is the SQL query that answers `What club had Guus Hiddink as outgoing manager?`:
```sql
|
SELECT "date_of_departure" FROM "end_of_season_managerial_changes" WHERE "name"='brendan rodgers'; |
## Task
Generate a SQL query to answer the following question:
`When did Brendan Rodgers depart his position?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "end_of_season_managerial_changes" (
"name" text,
"club" text,
"date_of_departure" text,
"replacement" text,
"date_of_appointment" text
);
### SQL
Given the database schema, here is the SQL query that answers `When did Brendan Rodgers depart his position?`:
```sql
|
SELECT "date_of_appointment" FROM "end_of_season_managerial_changes" WHERE "replacement"='paulo sousa'; |
## Task
Generate a SQL query to answer the following question:
`On what date was Paulo Sousa appointed?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "end_of_season_managerial_changes" (
"name" text,
"club" text,
"date_of_departure" text,
"replacement" text,
"date_of_appointment" text
);
### SQL
Given the database schema, here is the SQL query that answers `On what date was Paulo Sousa appointed?`:
```sql
|
SELECT "high_rebounds" FROM "game_log" WHERE "date"='april 9'; |
## Task
Generate a SQL query to answer the following question:
`Who had the high rebounds, and how many did he have, for the game played on April 9?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "game_log" (
"game" real,
"date" text,
"team" text,
"score" text,
"high_points" text,
"high_rebounds" text,
"high_assists" text,
"location_attendance" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who had the high rebounds, and how many did he have, for the game played on April 9?`:
```sql
|
SELECT "date" FROM "philadelphia_phillies_vs_los_angeles_dod" WHERE "time"='3:44'; |
## Task
Generate a SQL query to answer the following question:
`What date did a game have a time of 3:44?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "philadelphia_phillies_vs_los_angeles_dod" (
"game" real,
"date" text,
"score" text,
"location" text,
"time" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What date did a game have a time of 3:44?`:
```sql
|
SELECT "attendance" FROM "philadelphia_phillies_vs_los_angeles_dod" WHERE "game">4; |
## Task
Generate a SQL query to answer the following question:
`What was the attendance for the game after game 4?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "philadelphia_phillies_vs_los_angeles_dod" (
"game" real,
"date" text,
"score" text,
"location" text,
"time" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What was the attendance for the game after game 4?`:
```sql
|
SELECT "geographic_character" FROM "barangays" WHERE "population_2010">2539 AND "urban_rural"='rural' AND "population_2007"=2572; |
## Task
Generate a SQL query to answer the following question:
`WHAT IS THE TYPE OF LAND WITH A 2010 POPULATION GREATER THAN 2539, A RURAL AREA, AND A 2007 POPULATION OF 2572?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "barangays" (
"barangay" text,
"urban_rural" text,
"geographic_character" text,
"population_2007" real,
"population_2010" real
);
### SQL
Given the database schema, here is the SQL query that answers `WHAT IS THE TYPE OF LAND WITH A 2010 POPULATION GREATER THAN 2539, A RURAL AREA, AND A 2007 POPULATION OF 2572?`:
```sql
|
SELECT "geographic_character" FROM "barangays" WHERE "population_2007"<4346 AND "population_2010">3385 AND "barangay"='manalongon'; |
## Task
Generate a SQL query to answer the following question:
`WHAT IS THE TYPE OF LAND WITH A 2007 POPULATION SMALLER THAN 4346, 2010 POPULATION LARGER THAN 3385, FROM BARANGAY OF MANALONGON?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "barangays" (
"barangay" text,
"urban_rural" text,
"geographic_character" text,
"population_2007" real,
"population_2010" real
);
### SQL
Given the database schema, here is the SQL query that answers `WHAT IS THE TYPE OF LAND WITH A 2007 POPULATION SMALLER THAN 4346, 2010 POPULATION LARGER THAN 3385, FROM BARANGAY OF MANALONGON?`:
```sql
|
SELECT COUNT("population_2007") FROM "barangays" WHERE "population_2010"<1282; |
## Task
Generate a SQL query to answer the following question:
`WHAT IS THE POPULATION OF 2007 WHEN 2010 POPULATION WAS SMALLER THAN 1282?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "barangays" (
"barangay" text,
"urban_rural" text,
"geographic_character" text,
"population_2007" real,
"population_2010" real
);
### SQL
Given the database schema, here is the SQL query that answers `WHAT IS THE POPULATION OF 2007 WHEN 2010 POPULATION WAS SMALLER THAN 1282?`:
```sql
|
SELECT COUNT("points") FROM "group_i" WHERE "played"<30; |
## Task
Generate a SQL query to answer the following question:
`What is the number of points when the played is less than 30?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "group_i" (
"position" real,
"club" text,
"played" real,
"points" real,
"wins" real,
"draws" real,
"losses" real,
"goals_for" real,
"goals_against" real,
"goal_difference" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the number of points when the played is less than 30?`:
```sql
|
SELECT SUM("goals_for") FROM "group_i" WHERE "goal_difference"<43 AND "position"<3; |
## Task
Generate a SQL query to answer the following question:
`What is the number of goals when the goal difference was less than 43, and the position less than 3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "group_i" (
"position" real,
"club" text,
"played" real,
"points" real,
"wins" real,
"draws" real,
"losses" real,
"goals_for" real,
"goals_against" real,
"goal_difference" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the number of goals when the goal difference was less than 43, and the position less than 3?`:
```sql
|
SELECT AVG("position") FROM "group_i" WHERE "points"<34 AND "draws"=7 AND "club"='sd eibar'; |
## Task
Generate a SQL query to answer the following question:
`What is the position when the points were less than 34, draws of 7, and a Club of sd eibar?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "group_i" (
"position" real,
"club" text,
"played" real,
"points" real,
"wins" real,
"draws" real,
"losses" real,
"goals_for" real,
"goals_against" real,
"goal_difference" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the position when the points were less than 34, draws of 7, and a Club of sd eibar?`:
```sql
|
SELECT "goals_against" FROM "group_i" WHERE "goal_difference"<43 AND "wins"<13 AND "losses">14; |
## Task
Generate a SQL query to answer the following question:
`What is the number of goals against when the goal difference was less than 43, the Wins less than 13, and losses more than 14?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "group_i" (
"position" real,
"club" text,
"played" real,
"points" real,
"wins" real,
"draws" real,
"losses" real,
"goals_for" real,
"goals_against" real,
"goal_difference" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the number of goals against when the goal difference was less than 43, the Wins less than 13, and losses more than 14?`:
```sql
|
SELECT MAX("goal_difference") FROM "group_i" WHERE "goals_against"<76 AND "position">5 AND "played">30; |
## Task
Generate a SQL query to answer the following question:
`What is the highest Goal Difference when the goals against were less than 76, and the position larger than 5, and a Played larger than 30?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "group_i" (
"position" real,
"club" text,
"played" real,
"points" real,
"wins" real,
"draws" real,
"losses" real,
"goals_for" real,
"goals_against" real,
"goal_difference" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest Goal Difference when the goals against were less than 76, and the position larger than 5, and a Played larger than 30?`:
```sql
|
SELECT "producer" FROM "production" WHERE "director"='richard clark'; |
## Task
Generate a SQL query to answer the following question:
`Who is the producer for the director Richard Clark?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "production" (
"block" real,
"director" text,
"writers" text,
"producer" text,
"code" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the producer for the director Richard Clark?`:
```sql
|
SELECT MIN("block") FROM "production" WHERE "director"='graeme harper'; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest block for director Graeme Harper?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "production" (
"block" real,
"director" text,
"writers" text,
"producer" text,
"code" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest block for director Graeme Harper?`:
```sql
|
SELECT "skip" FROM "standings" WHERE "country"='finland'; |
## Task
Generate a SQL query to answer the following question:
`What is the skip when the country is finland?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "standings" (
"country" text,
"skip" text,
"ends_won" real,
"ends_lost" real,
"blank_ends_f_a" text,
"stolen_ends_for" real,
"stolen_ends_against" real,
"shot_pct" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the skip when the country is finland?`:
```sql
|
SELECT MIN("ends_lost") FROM "standings" WHERE "stolen_ends_for"<13 AND "stolen_ends_against"=6; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest ends lost when the stolen ends for is less than 13, and stolten ends against is 6?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "standings" (
"country" text,
"skip" text,
"ends_won" real,
"ends_lost" real,
"blank_ends_f_a" text,
"stolen_ends_for" real,
"stolen_ends_against" real,
"shot_pct" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest ends lost when the stolen ends for is less than 13, and stolten ends against is 6?`:
```sql
|
SELECT SUM("shot_pct") FROM "standings" WHERE "country"='finland' AND "ends_lost">49; |
## Task
Generate a SQL query to answer the following question:
`What is the sum shot % when the country is finland, and an ends lost is larger than 49?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "standings" (
"country" text,
"skip" text,
"ends_won" real,
"ends_lost" real,
"blank_ends_f_a" text,
"stolen_ends_for" real,
"stolen_ends_against" real,
"shot_pct" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the sum shot % when the country is finland, and an ends lost is larger than 49?`:
```sql
|
SELECT "stolen_ends_against" FROM "standings" WHERE "blank_ends_f_a"='4/7' AND "country"='china'; |
## Task
Generate a SQL query to answer the following question:
`What is the stolen ends against for a bank ends f/a of 4/7, and a country of china?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "standings" (
"country" text,
"skip" text,
"ends_won" real,
"ends_lost" real,
"blank_ends_f_a" text,
"stolen_ends_for" real,
"stolen_ends_against" real,
"shot_pct" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the stolen ends against for a bank ends f/a of 4/7, and a country of china?`:
```sql
|
SELECT "location" FROM "1970s_eagles_15_4_1" WHERE "year">1974 AND "date"='september 19'; |
## Task
Generate a SQL query to answer the following question:
`what is the location when the year is after 1974 and the date is september 19?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1970s_eagles_15_4_1" (
"year" real,
"date" text,
"winner" text,
"result" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the location when the year is after 1974 and the date is september 19?`:
```sql
|
SELECT "location" FROM "1970s_eagles_15_4_1" WHERE "year"<1979 AND "result"='19-17'; |
## Task
Generate a SQL query to answer the following question:
`what is the location when the year is before 1979 and the result is 19-17?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1970s_eagles_15_4_1" (
"year" real,
"date" text,
"winner" text,
"result" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the location when the year is before 1979 and the result is 19-17?`:
```sql
|
SELECT "result" FROM "1970s_eagles_15_4_1" WHERE "year"=1970 AND "location"='yankee stadium'; |
## Task
Generate a SQL query to answer the following question:
`what is the result for 1970 at yankee stadium?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1970s_eagles_15_4_1" (
"year" real,
"date" text,
"winner" text,
"result" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the result for 1970 at yankee stadium?`:
```sql
|
SELECT AVG("year") FROM "1970s_eagles_15_4_1" WHERE "location"='yankee stadium' AND "result"='23-23'; |
## Task
Generate a SQL query to answer the following question:
`what is the year when the location is yankee stadium and the result is 23-23`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1970s_eagles_15_4_1" (
"year" real,
"date" text,
"winner" text,
"result" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the year when the location is yankee stadium and the result is 23-23`:
```sql
|
SELECT MIN("scottish_cup") FROM "appearances" WHERE "league_cup"=95 AND "europe">23; |
## Task
Generate a SQL query to answer the following question:
`Which Scottish Cup has a League Cup of 95, and a Europe larger than 23?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "appearances" (
"name" text,
"years" text,
"league" real,
"scottish_cup" real,
"league_cup" real,
"europe" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Scottish Cup has a League Cup of 95, and a Europe larger than 23?`:
```sql
|
SELECT MIN("total") FROM "appearances" WHERE "name"='eoin jess category:articles with hcards' AND "scottish_cup">23; |
## Task
Generate a SQL query to answer the following question:
`Which Total has a Name of eoin jess category:articles with hcards, and a Scottish Cup larger than 23?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "appearances" (
"name" text,
"years" text,
"league" real,
"scottish_cup" real,
"league_cup" real,
"europe" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Total has a Name of eoin jess category:articles with hcards, and a Scottish Cup larger than 23?`:
```sql
|
SELECT AVG("total") FROM "appearances" WHERE "name"='alex mcleish category:articles with hcards' AND "league"<494; |
## Task
Generate a SQL query to answer the following question:
`Which Total has a Name of alex mcleish category:articles with hcards, and a League smaller than 494?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "appearances" (
"name" text,
"years" text,
"league" real,
"scottish_cup" real,
"league_cup" real,
"europe" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Total has a Name of alex mcleish category:articles with hcards, and a League smaller than 494?`:
```sql
|
SELECT SUM("league_cup") FROM "appearances" WHERE "scottish_cup">69; |
## Task
Generate a SQL query to answer the following question:
`Which League Cup has a Scottish Cup larger than 69?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "appearances" (
"name" text,
"years" text,
"league" real,
"scottish_cup" real,
"league_cup" real,
"europe" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which League Cup has a Scottish Cup larger than 69?`:
```sql
|
SELECT COUNT("scottish_cup") FROM "appearances" WHERE "league"<561 AND "years"='1989β1995 1997β2001' AND "europe"<11; |
## Task
Generate a SQL query to answer the following question:
`Which Scottish Cup has a League smaller than 561, Years of 1989β1995 1997β2001, and Europe smaller than 11?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "appearances" (
"name" text,
"years" text,
"league" real,
"scottish_cup" real,
"league_cup" real,
"europe" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Scottish Cup has a League smaller than 561, Years of 1989β1995 1997β2001, and Europe smaller than 11?`:
```sql
|
SELECT MAX("pick") FROM "team_players_drafted_into_the_nfl" WHERE "nfl_club"='houston oilers' AND "round">10; |
## Task
Generate a SQL query to answer the following question:
`What is the highest pick of the houston oilers NFL club, which has a round greater than 10?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "team_players_drafted_into_the_nfl" (
"player" text,
"position" text,
"round" real,
"pick" real,
"nfl_club" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest pick of the houston oilers NFL club, which has a round greater than 10?`:
```sql
|
SELECT "round" FROM "team_players_drafted_into_the_nfl" WHERE "nfl_club"='new york jets'; |
## Task
Generate a SQL query to answer the following question:
`What is the round of the new york jets NFL club?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "team_players_drafted_into_the_nfl" (
"player" text,
"position" text,
"round" real,
"pick" real,
"nfl_club" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the round of the new york jets NFL club?`:
```sql
|
SELECT SUM("round") FROM "team_players_drafted_into_the_nfl" WHERE "nfl_club"='new york jets' AND "pick"<166; |
## Task
Generate a SQL query to answer the following question:
`What is the sum of the round of the new york jets NFL club, which has a pick less than 166?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "team_players_drafted_into_the_nfl" (
"player" text,
"position" text,
"round" real,
"pick" real,
"nfl_club" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the sum of the round of the new york jets NFL club, which has a pick less than 166?`:
```sql
|
SELECT "2012" FROM "singles_performance_timeline" WHERE "tournament"='madrid masters'; |
## Task
Generate a SQL query to answer the following question:
`WHAT IS THE 2012 PERFORMANCE FOR THE MADRID MASTERS?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_performance_timeline" (
"tournament" text,
"2008" text,
"2009" text,
"2010" text,
"2011" text,
"2012" text
);
### SQL
Given the database schema, here is the SQL query that answers `WHAT IS THE 2012 PERFORMANCE FOR THE MADRID MASTERS?`:
```sql
|
SELECT "2011" FROM "singles_performance_timeline" WHERE "tournament"='tournaments played'; |
## Task
Generate a SQL query to answer the following question:
`WHAT IS THE 2011 PERFORMANCE FOR TOURNAMENTS PLAYED?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_performance_timeline" (
"tournament" text,
"2008" text,
"2009" text,
"2010" text,
"2011" text,
"2012" text
);
### SQL
Given the database schema, here is the SQL query that answers `WHAT IS THE 2011 PERFORMANCE FOR TOURNAMENTS PLAYED?`:
```sql
|
SELECT "2010" FROM "singles_performance_timeline" WHERE "2009"='0' AND "tournament"='finals'; |
## Task
Generate a SQL query to answer the following question:
`WHAT IS THE 2010 PERFORMANCE THAT HAD 2009 0F 0, AND FINALS TOURNAMENT?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_performance_timeline" (
"tournament" text,
"2008" text,
"2009" text,
"2010" text,
"2011" text,
"2012" text
);
### SQL
Given the database schema, here is the SQL query that answers `WHAT IS THE 2010 PERFORMANCE THAT HAD 2009 0F 0, AND FINALS TOURNAMENT?`:
```sql
|
SELECT "2009" FROM "singles_performance_timeline" WHERE "tournament"='tournaments played'; |
## Task
Generate a SQL query to answer the following question:
`WHAT IS THE 2009 PERFORMANCE FOR TOURNAMENTS PLAYED?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_performance_timeline" (
"tournament" text,
"2008" text,
"2009" text,
"2010" text,
"2011" text,
"2012" text
);
### SQL
Given the database schema, here is the SQL query that answers `WHAT IS THE 2009 PERFORMANCE FOR TOURNAMENTS PLAYED?`:
```sql
|
SELECT "scorers" FROM "fa_cup" WHERE "round"='round 3'; |
## Task
Generate a SQL query to answer the following question:
`Who were the scorers in round 3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fa_cup" (
"date" text,
"round" text,
"opponents" text,
"h_a" text,
"result_f_a" text,
"scorers" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `Who were the scorers in round 3?`:
```sql
|
SELECT "h_a" FROM "fa_cup" WHERE "opponents"='oldham athletic' AND "round"='semi-final'; |
## Task
Generate a SQL query to answer the following question:
`What is the H/A in the semi-final round where oldham athletic were the opponents?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fa_cup" (
"date" text,
"round" text,
"opponents" text,
"h_a" text,
"result_f_a" text,
"scorers" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the H/A in the semi-final round where oldham athletic were the opponents?`:
```sql
|
SELECT "scorers" FROM "fa_cup" WHERE "opponents"='oldham athletic' AND "round"='semi-final'; |
## Task
Generate a SQL query to answer the following question:
`Who were the scorers in the semi-final round where oldham athletic were the opponents?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fa_cup" (
"date" text,
"round" text,
"opponents" text,
"h_a" text,
"result_f_a" text,
"scorers" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `Who were the scorers in the semi-final round where oldham athletic were the opponents?`:
```sql
|
SELECT "tournament" FROM "singles_11_8_3" WHERE "score"='1β6, 6β3, 3β6'; |
## Task
Generate a SQL query to answer the following question:
`Where was the tournament where the score was 1β6, 6β3, 3β6?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_11_8_3" (
"outcome" text,
"date" text,
"tournament" text,
"surface" text,
"opponent" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Where was the tournament where the score was 1β6, 6β3, 3β6?`:
```sql
|
SELECT "opponent" FROM "singles_11_8_3" WHERE "score"='4β6, 6β4, 6β2'; |
## Task
Generate a SQL query to answer the following question:
`Who did thomaz bellucci play against when the score was 4β6, 6β4, 6β2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_11_8_3" (
"outcome" text,
"date" text,
"tournament" text,
"surface" text,
"opponent" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who did thomaz bellucci play against when the score was 4β6, 6β4, 6β2?`:
```sql
|
SELECT "outcome" FROM "doubles_25_12_13" WHERE "surface"='hard' AND "partner"='akiko yonemura'; |
## Task
Generate a SQL query to answer the following question:
`What was the outcome of the tournament with Akiko Yonemura as a partner on a hard surface?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "doubles_25_12_13" (
"outcome" text,
"date" text,
"tournament" text,
"surface" text,
"partner" text,
"opponents_in_the_final" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the outcome of the tournament with Akiko Yonemura as a partner on a hard surface?`:
```sql
|
SELECT "tournament" FROM "singles_performance_timeline" WHERE "2011"='1r' AND "2012"='1r' AND "2005"='a' AND "2010"='1r'; |
## Task
Generate a SQL query to answer the following question:
`Which tournament has 1r in 2011, 1r in 2012, A in 2005, and 1r in 2010?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_performance_timeline" (
"tournament" text,
"2005" text,
"2006" text,
"2007" text,
"2008" text,
"2009" text,
"2010" text,
"2011" text,
"2012" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which tournament has 1r in 2011, 1r in 2012, A in 2005, and 1r in 2010?`:
```sql
|
SELECT "2010" FROM "singles_performance_timeline" WHERE "2012"='1r' AND "2005"='a'; |
## Task
Generate a SQL query to answer the following question:
`What is the 2010 value with a 1r in 2012 and an A in 2005?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_performance_timeline" (
"tournament" text,
"2005" text,
"2006" text,
"2007" text,
"2008" text,
"2009" text,
"2010" text,
"2011" text,
"2012" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2010 value with a 1r in 2012 and an A in 2005?`:
```sql
|
SELECT "tournament" FROM "singles_performance_timeline" WHERE "2009"='2r' AND "2010"='2r'; |
## Task
Generate a SQL query to answer the following question:
`What is the tournament with a 2r in 2009 and a 2r in 2010?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_performance_timeline" (
"tournament" text,
"2005" text,
"2006" text,
"2007" text,
"2008" text,
"2009" text,
"2010" text,
"2011" text,
"2012" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the tournament with a 2r in 2009 and a 2r in 2010?`:
```sql
|
SELECT "2011" FROM "singles_performance_timeline" WHERE "2012"='grand slam tournaments'; |
## Task
Generate a SQL query to answer the following question:
`What is the 2011 value of the 2012 grand slam tournaments?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_performance_timeline" (
"tournament" text,
"2005" text,
"2006" text,
"2007" text,
"2008" text,
"2009" text,
"2010" text,
"2011" text,
"2012" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2011 value of the 2012 grand slam tournaments?`:
```sql
|
SELECT "record" FROM "game_log" WHERE "game"='45'; |
## Task
Generate a SQL query to answer the following question:
`What was the record after game 45?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "game_log" (
"game" text,
"date" text,
"opponent" text,
"score" text,
"location_attendance" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the record after game 45?`:
```sql
|
SELECT "date" FROM "game_log" WHERE "location_attendance"='delta center' AND "record"='35-14'; |
## Task
Generate a SQL query to answer the following question:
`What was the date of the game at the delta center when the record was 35-14?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "game_log" (
"game" text,
"date" text,
"opponent" text,
"score" text,
"location_attendance" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the date of the game at the delta center when the record was 35-14?`:
```sql
|
SELECT "opponent" FROM "game_log" WHERE "location_attendance"='keyarena at seattle center'; |
## Task
Generate a SQL query to answer the following question:
`Who was the opponent, during the game at the location of keyarena at seattle center?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "game_log" (
"game" text,
"date" text,
"opponent" text,
"score" text,
"location_attendance" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the opponent, during the game at the location of keyarena at seattle center?`:
```sql
|
SELECT "label" FROM "selected_discography" WHERE "format"='cd' AND "release"='we are the rage'; |
## Task
Generate a SQL query to answer the following question:
`What is the label of release we are the rage with a cd format?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "selected_discography" (
"artist" text,
"inst" text,
"release" text,
"format" text,
"label" text,
"year" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the label of release we are the rage with a cd format?`:
```sql
|
SELECT "winner" FROM "1950s_giants_13_7" WHERE "year"<1956 AND "date"='october 21'; |
## Task
Generate a SQL query to answer the following question:
`Who was the winning team before 1956 on October 21?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1950s_giants_13_7" (
"year" real,
"date" text,
"winner" text,
"result" text,
"loser" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the winning team before 1956 on October 21?`:
```sql
|
SELECT "loser" FROM "1950s_giants_13_7" WHERE "winner"='new york giants' AND "date"='november 14'; |
## Task
Generate a SQL query to answer the following question:
`Who was the loser when the New York Giants were the winners on November 14?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1950s_giants_13_7" (
"year" real,
"date" text,
"winner" text,
"result" text,
"loser" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the loser when the New York Giants were the winners on November 14?`:
```sql
|
SELECT "winner" FROM "1950s_giants_13_7" WHERE "loser"='philadelphia eagles' AND "location"='yankee stadium' AND "year">1958; |
## Task
Generate a SQL query to answer the following question:
`Who was the winner when the Philadelphia eagles were the losers after 1958 at Yankee Stadium?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1950s_giants_13_7" (
"year" real,
"date" text,
"winner" text,
"result" text,
"loser" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the winner when the Philadelphia eagles were the losers after 1958 at Yankee Stadium?`:
```sql
|
SELECT "location" FROM "1950s_giants_13_7" WHERE "result"='29-14'; |
## Task
Generate a SQL query to answer the following question:
`What location was the game with the result of 29-14?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1950s_giants_13_7" (
"year" real,
"date" text,
"winner" text,
"result" text,
"loser" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `What location was the game with the result of 29-14?`:
```sql
|
SELECT "score" FROM "first_round_proper" WHERE "home_team"='wigan athletic'; |
## Task
Generate a SQL query to answer the following question:
`What is the score of the wigan athletic home team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_round_proper" (
"tie_no" text,
"home_team" text,
"score" text,
"away_team" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the score of the wigan athletic home team?`:
```sql
|
SELECT "away_team" FROM "first_round_proper" WHERE "tie_no"='2'; |
## Task
Generate a SQL query to answer the following question:
`What is the away team with a 2 tie no.?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_round_proper" (
"tie_no" text,
"home_team" text,
"score" text,
"away_team" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the away team with a 2 tie no.?`:
```sql
|
SELECT "away_team" FROM "first_round_proper" WHERE "home_team"='wigan athletic'; |
## Task
Generate a SQL query to answer the following question:
`What is the away team for the home team wigan athletic?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_round_proper" (
"tie_no" text,
"home_team" text,
"score" text,
"away_team" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the away team for the home team wigan athletic?`:
```sql
|
SELECT "score" FROM "first_round_proper" WHERE "date"='23 november 1983' AND "away_team"='exeter city'; |
## Task
Generate a SQL query to answer the following question:
`What is the score on 23 November 1983 with exeter city as the away team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_round_proper" (
"tie_no" text,
"home_team" text,
"score" text,
"away_team" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the score on 23 November 1983 with exeter city as the away team?`:
```sql
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.