output stringlengths 27 479 | instruction stringlengths 407 1.39k |
|---|---|
SELECT MIN("highest_position") FROM "top_40_albums_of_2004" WHERE "album_title"='10 years of hits' AND "sales">'870,000'; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest high position for 10 years of hits, and over 870,000 sales?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "top_40_albums_of_2004" (
"position" real,
"album_title" text,
"artist" text,
"highest_position" real,
"sales" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest high position for 10 years of hits, and over 870,000 sales?`:
```sql
|
SELECT AVG("highest_position") FROM "top_40_albums_of_2004" WHERE "album_title"='unwritten'; |
## Task
Generate a SQL query to answer the following question:
`What is the average high position for the album unwritten?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "top_40_albums_of_2004" (
"position" real,
"album_title" text,
"artist" text,
"highest_position" real,
"sales" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average high position for the album unwritten?`:
```sql
|
SELECT "date" FROM "formula_one_2004_race_schedule" WHERE "race_title"='grand prix de monaco'; |
## Task
Generate a SQL query to answer the following question:
`When did the Grand Prix de Monaco race?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "formula_one_2004_race_schedule" (
"round" real,
"race_title" text,
"grand_prix" text,
"circuit" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `When did the Grand Prix de Monaco race?`:
```sql
|
SELECT "circuit" FROM "formula_one_2004_race_schedule" WHERE "round"=16; |
## Task
Generate a SQL query to answer the following question:
`What circuit had 16 rounds?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "formula_one_2004_race_schedule" (
"round" real,
"race_title" text,
"grand_prix" text,
"circuit" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What circuit had 16 rounds?`:
```sql
|
SELECT "grand_prix" FROM "formula_one_2004_race_schedule" WHERE "round"=9; |
## Task
Generate a SQL query to answer the following question:
`Which Grand Prix had 9 rounds?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "formula_one_2004_race_schedule" (
"round" real,
"race_title" text,
"grand_prix" text,
"circuit" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Grand Prix had 9 rounds?`:
```sql
|
SELECT "base_fares" FROM "fares" WHERE "fare_categories"='senior/disabled'; |
## Task
Generate a SQL query to answer the following question:
`What is the Base Fare in the senior/disabled category?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fares" (
"fare_categories" text,
"base_fares" text,
"day_pass" text,
"7_day_pass" text,
"30_day_pass" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Base Fare in the senior/disabled category?`:
```sql
|
SELECT "30_day_pass" FROM "fares" WHERE "base_fares"='$3'; |
## Task
Generate a SQL query to answer the following question:
`Which 30-day Pass has a Base Fare of $3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fares" (
"fare_categories" text,
"base_fares" text,
"day_pass" text,
"7_day_pass" text,
"30_day_pass" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which 30-day Pass has a Base Fare of $3?`:
```sql
|
SELECT "length" FROM "bus_fleet" WHERE "year"='2012-2013'; |
## Task
Generate a SQL query to answer the following question:
`What is the length for years 2012-2013?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "bus_fleet" (
"year" text,
"make_model" text,
"length" text,
"engine_type" text,
"numbers" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the length for years 2012-2013?`:
```sql
|
SELECT "engine_type" FROM "bus_fleet" WHERE "length"='ft (m)' AND "year"='2003' AND "numbers"='6600-6684 (84 buses)'; |
## Task
Generate a SQL query to answer the following question:
`If length is ft (m) with numbers of 6600-6684 (84 buses) for 2003, what is the engine type?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "bus_fleet" (
"year" text,
"make_model" text,
"length" text,
"engine_type" text,
"numbers" text
);
### SQL
Given the database schema, here is the SQL query that answers `If length is ft (m) with numbers of 6600-6684 (84 buses) for 2003, what is the engine type?`:
```sql
|
SELECT "length" FROM "bus_fleet" WHERE "numbers"='2600-2825 (223 buses)'; |
## Task
Generate a SQL query to answer the following question:
`For numbers of 2600-2825 (223 buses), what is the length?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "bus_fleet" (
"year" text,
"make_model" text,
"length" text,
"engine_type" text,
"numbers" text
);
### SQL
Given the database schema, here is the SQL query that answers `For numbers of 2600-2825 (223 buses), what is the length?`:
```sql
|
SELECT "length" FROM "bus_fleet" WHERE "year"='2003' AND "make_model"='nabi 35-lfw'; |
## Task
Generate a SQL query to answer the following question:
`What is the lenth of a 2003 Make & Model of nabi 35-lfw?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "bus_fleet" (
"year" text,
"make_model" text,
"length" text,
"engine_type" text,
"numbers" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lenth of a 2003 Make & Model of nabi 35-lfw?`:
```sql
|
SELECT "length" FROM "bus_fleet" WHERE "engine_type"='diesel' AND "numbers"='tbd (13 buses)'; |
## Task
Generate a SQL query to answer the following question:
`What is the length for a diesel engine with numbers of tbd (13 buses)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "bus_fleet" (
"year" text,
"make_model" text,
"length" text,
"engine_type" text,
"numbers" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the length for a diesel engine with numbers of tbd (13 buses)?`:
```sql
|
SELECT "year" FROM "bus_fleet" WHERE "make_model"='mci d4000n'; |
## Task
Generate a SQL query to answer the following question:
`What year has a make & model of mci d4000n?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "bus_fleet" (
"year" text,
"make_model" text,
"length" text,
"engine_type" text,
"numbers" text
);
### SQL
Given the database schema, here is the SQL query that answers `What year has a make & model of mci d4000n?`:
```sql
|
SELECT "type" FROM "ships_sunk_or_captured_by_moewe_on_her_s" WHERE "date"='8 dec 16' AND "ship"='duchess of cornwall'; |
## Task
Generate a SQL query to answer the following question:
`What type has a Date of 8 dec 16, and a Ship of duchess of cornwall?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ships_sunk_or_captured_by_moewe_on_her_s" (
"date" text,
"ship" text,
"type" text,
"nationality" text,
"tonnage_grt" real
);
### SQL
Given the database schema, here is the SQL query that answers `What type has a Date of 8 dec 16, and a Ship of duchess of cornwall?`:
```sql
|
SELECT "nationality" FROM "ships_sunk_or_captured_by_moewe_on_her_s" WHERE "tonnage_grt">'2,890' AND "ship"='mount temple'; |
## Task
Generate a SQL query to answer the following question:
`Which Nationality has a Tonnage GRT larger than 2,890, and a Ship of mount temple?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ships_sunk_or_captured_by_moewe_on_her_s" (
"date" text,
"ship" text,
"type" text,
"nationality" text,
"tonnage_grt" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Nationality has a Tonnage GRT larger than 2,890, and a Ship of mount temple?`:
```sql
|
SELECT "nationality" FROM "ships_sunk_or_captured_by_moewe_on_her_s" WHERE "ship"='minteh'; |
## Task
Generate a SQL query to answer the following question:
`Which nationality has a Ship of minteh?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ships_sunk_or_captured_by_moewe_on_her_s" (
"date" text,
"ship" text,
"type" text,
"nationality" text,
"tonnage_grt" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which nationality has a Ship of minteh?`:
```sql
|
SELECT SUM("tonnage_grt") FROM "ships_sunk_or_captured_by_moewe_on_her_s" WHERE "type"='cargo ship' AND "nationality"='norway'; |
## Task
Generate a SQL query to answer the following question:
`What is the total Tonnage GRT with a Type of cargo ship, and a Nationality of norway?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ships_sunk_or_captured_by_moewe_on_her_s" (
"date" text,
"ship" text,
"type" text,
"nationality" text,
"tonnage_grt" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total Tonnage GRT with a Type of cargo ship, and a Nationality of norway?`:
```sql
|
SELECT "date" FROM "ships_sunk_or_captured_by_moewe_on_her_s" WHERE "ship"='hallbjorg'; |
## Task
Generate a SQL query to answer the following question:
`Which Date has a Ship of hallbjorg?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ships_sunk_or_captured_by_moewe_on_her_s" (
"date" text,
"ship" text,
"type" text,
"nationality" text,
"tonnage_grt" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Date has a Ship of hallbjorg?`:
```sql
|
SELECT "set_3" FROM "pool_e" WHERE "total"='45β31'; |
## Task
Generate a SQL query to answer the following question:
`What is the score of set 3 when the total is 45β31?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "pool_e" (
"date" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the score of set 3 when the total is 45β31?`:
```sql
|
SELECT "set_2" FROM "pool_e" WHERE "set_3"='15β6'; |
## Task
Generate a SQL query to answer the following question:
`What is the score for set 2 when set 3 was 15β6?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "pool_e" (
"date" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the score for set 2 when set 3 was 15β6?`:
```sql
|
SELECT "total" FROM "pool_e" WHERE "set_1"='15β11'; |
## Task
Generate a SQL query to answer the following question:
`What is the total when the score of set 1 was 15β11?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "pool_e" (
"date" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total when the score of set 1 was 15β11?`:
```sql
|
SELECT "total" FROM "pool_e" WHERE "set_1"='15β11'; |
## Task
Generate a SQL query to answer the following question:
`What is the total when the score of set 1 is 15β11?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "pool_e" (
"date" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total when the score of set 1 is 15β11?`:
```sql
|
SELECT "date" FROM "pool_e" WHERE "total"='25β45'; |
## Task
Generate a SQL query to answer the following question:
`On what date was the total 25β45?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "pool_e" (
"date" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text
);
### SQL
Given the database schema, here is the SQL query that answers `On what date was the total 25β45?`:
```sql
|
SELECT "away_team_score" FROM "round_7" WHERE "home_team_score"='13.14 (92)'; |
## Task
Generate a SQL query to answer the following question:
`What was the score of the Away team when the score of the Home team was 13.14 (92)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_7" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the score of the Away team when the score of the Home team was 13.14 (92)?`:
```sql
|
SELECT "away_team_score" FROM "round_7" WHERE "away_team"='st kilda'; |
## Task
Generate a SQL query to answer the following question:
`What was St Kilda's score as the Away team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_7" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was St Kilda's score as the Away team?`:
```sql
|
SELECT "venue" FROM "round_7" WHERE "home_team_score"='17.19 (121)'; |
## Task
Generate a SQL query to answer the following question:
`At what Venue was the Home team score 17.19 (121)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_7" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `At what Venue was the Home team score 17.19 (121)?`:
```sql
|
SELECT "home_team_score" FROM "round_7" WHERE "venue"='vfl park'; |
## Task
Generate a SQL query to answer the following question:
`At the venue Vfl Park, what was the Home team score?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_7" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `At the venue Vfl Park, what was the Home team score?`:
```sql
|
SELECT COUNT("reg_gp") FROM "list_of_vancouver_canucks_draft_picks" WHERE "player"='daniel rahimi' AND "rd_num">3; |
## Task
Generate a SQL query to answer the following question:
`How many Reg GP does daniel rahimi have with a rd # greater than 3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_vancouver_canucks_draft_picks" (
"rd_num" real,
"pick_num" real,
"player" text,
"team_league" text,
"reg_gp" real,
"pl_gp" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many Reg GP does daniel rahimi have with a rd # greater than 3?`:
```sql
|
SELECT MIN("pick_num") FROM "list_of_vancouver_canucks_draft_picks" WHERE "player"='michael grabner' AND "reg_gp"<20; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest Pick # with michael grabner and less than 20 Reg GP?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_vancouver_canucks_draft_picks" (
"rd_num" real,
"pick_num" real,
"player" text,
"team_league" text,
"reg_gp" real,
"pl_gp" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest Pick # with michael grabner and less than 20 Reg GP?`:
```sql
|
SELECT "class" FROM "southern_fells" WHERE "peak"='fountains fell south top'; |
## Task
Generate a SQL query to answer the following question:
`Which class has a peak named fountains fell south top?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "southern_fells" (
"peak" text,
"height_m" real,
"prom_m" real,
"class" text,
"parent" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which class has a peak named fountains fell south top?`:
```sql
|
SELECT SUM("prom_m") FROM "southern_fells" WHERE "peak"='great knoutberry hill'; |
## Task
Generate a SQL query to answer the following question:
`What is the total of Prom in M for Peak great knoutberry hill?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "southern_fells" (
"peak" text,
"height_m" real,
"prom_m" real,
"class" text,
"parent" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total of Prom in M for Peak great knoutberry hill?`:
```sql
|
SELECT AVG("height_m") FROM "southern_fells" WHERE "class"='hewitt' AND "prom_m"<86 AND "peak"='gragareth'; |
## Task
Generate a SQL query to answer the following question:
`What is the average height for hewitt class, with prom less than 86, and a Peak of gragareth?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "southern_fells" (
"peak" text,
"height_m" real,
"prom_m" real,
"class" text,
"parent" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average height for hewitt class, with prom less than 86, and a Peak of gragareth?`:
```sql
|
SELECT "movie" FROM "tamil_songs" WHERE "co_singers"='selva nambi'; |
## Task
Generate a SQL query to answer the following question:
`In which movie is Selva Nambi a co-singer?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "tamil_songs" (
"year" real,
"song_title" text,
"movie" text,
"music_director" text,
"co_singers" text
);
### SQL
Given the database schema, here is the SQL query that answers `In which movie is Selva Nambi a co-singer?`:
```sql
|
SELECT "music_director" FROM "tamil_songs" WHERE "year"=1994; |
## Task
Generate a SQL query to answer the following question:
`Who was the music director in 1994?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "tamil_songs" (
"year" real,
"song_title" text,
"movie" text,
"music_director" text,
"co_singers" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the music director in 1994?`:
```sql
|
SELECT COUNT("year") FROM "2008_london_revival" WHERE "nominee"='denis lawson'; |
## Task
Generate a SQL query to answer the following question:
`What years was Denis Lawson nominated for an award?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2008_london_revival" (
"year" real,
"award" text,
"category" text,
"nominee" text,
"result" text
);
### SQL
Given the database schema, here is the SQL query that answers `What years was Denis Lawson nominated for an award?`:
```sql
|
SELECT "result" FROM "2008_london_revival" WHERE "nominee"='jason pennycooke'; |
## Task
Generate a SQL query to answer the following question:
`Did Jason Pennycooke win the award he was nominated for?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2008_london_revival" (
"year" real,
"award" text,
"category" text,
"nominee" text,
"result" text
);
### SQL
Given the database schema, here is the SQL query that answers `Did Jason Pennycooke win the award he was nominated for?`:
```sql
|
SELECT COUNT("year") FROM "2008_london_revival" WHERE "nominee"='best musical revival'; |
## Task
Generate a SQL query to answer the following question:
`How many years was Best Musical Revival nominated?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2008_london_revival" (
"year" real,
"award" text,
"category" text,
"nominee" text,
"result" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many years was Best Musical Revival nominated?`:
```sql
|
SELECT "award" FROM "2008_london_revival" WHERE "category"='best actor in a musical' AND "nominee"='denis lawson'; |
## Task
Generate a SQL query to answer the following question:
`What award was Denis Lawson nominated for in the Best Actor in a Musical category?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2008_london_revival" (
"year" real,
"award" text,
"category" text,
"nominee" text,
"result" text
);
### SQL
Given the database schema, here is the SQL query that answers `What award was Denis Lawson nominated for in the Best Actor in a Musical category?`:
```sql
|
SELECT "opponent" FROM "singles_6_4_titles_2_runners_up" WHERE "outcome"='winner' AND "date"='5 november 2011'; |
## Task
Generate a SQL query to answer the following question:
`Which opponent has an Outcome of winner, and a Date of 5 november 2011?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_6_4_titles_2_runners_up" (
"outcome" text,
"date" text,
"surface" text,
"opponent" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which opponent has an Outcome of winner, and a Date of 5 november 2011?`:
```sql
|
SELECT "date" FROM "singles_6_4_titles_2_runners_up" WHERE "score"='4β6, 2β6'; |
## Task
Generate a SQL query to answer the following question:
`Which date has a Score of 4β6, 2β6?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_6_4_titles_2_runners_up" (
"outcome" text,
"date" text,
"surface" text,
"opponent" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which date has a Score of 4β6, 2β6?`:
```sql
|
SELECT "date" FROM "singles_6_4_titles_2_runners_up" WHERE "opponent"='juan mΓ³naco' AND "score"='6β2, 4β6, 7β6 (7β3)'; |
## Task
Generate a SQL query to answer the following question:
`Which date has a Opponent of juan mΓ³naco, and a Score of 6β2, 4β6, 7β6 (7β3)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_6_4_titles_2_runners_up" (
"outcome" text,
"date" text,
"surface" text,
"opponent" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which date has a Opponent of juan mΓ³naco, and a Score of 6β2, 4β6, 7β6 (7β3)?`:
```sql
|
SELECT "outcome" FROM "singles_6_4_titles_2_runners_up" WHERE "opponent"='fernando verdasco'; |
## Task
Generate a SQL query to answer the following question:
`Which outcome has a Opponent of fernando verdasco?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_6_4_titles_2_runners_up" (
"outcome" text,
"date" text,
"surface" text,
"opponent" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which outcome has a Opponent of fernando verdasco?`:
```sql
|
SELECT "surface" FROM "singles_6_4_titles_2_runners_up" WHERE "opponent"='fernando verdasco'; |
## Task
Generate a SQL query to answer the following question:
`Which surface has an Opponent of fernando verdasco?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_6_4_titles_2_runners_up" (
"outcome" text,
"date" text,
"surface" text,
"opponent" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which surface has an Opponent of fernando verdasco?`:
```sql
|
SELECT "surface" FROM "singles_6_4_titles_2_runners_up" WHERE "date"='5 november 2011'; |
## Task
Generate a SQL query to answer the following question:
`Which surface has a Date of 5 november 2011?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_6_4_titles_2_runners_up" (
"outcome" text,
"date" text,
"surface" text,
"opponent" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which surface has a Date of 5 november 2011?`:
```sql
|
SELECT SUM("crowd") FROM "round_16" WHERE "venue"='mcg'; |
## Task
Generate a SQL query to answer the following question:
`When the Venue was mcg what was the sum of all Crowds for that venue?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_16" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `When the Venue was mcg what was the sum of all Crowds for that venue?`:
```sql
|
SELECT "date" FROM "round_16" WHERE "away_team"='essendon'; |
## Task
Generate a SQL query to answer the following question:
`If the Away team is essendon, what was the Date they played?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_16" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `If the Away team is essendon, what was the Date they played?`:
```sql
|
SELECT "date" FROM "round_16" WHERE "away_team"='essendon'; |
## Task
Generate a SQL query to answer the following question:
`On what Date did the Away team essendon play?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_16" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `On what Date did the Away team essendon play?`:
```sql
|
SELECT "date" FROM "round_16" WHERE "home_team"='north melbourne'; |
## Task
Generate a SQL query to answer the following question:
`When the Home team was north melbourne what was the Date of the game?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_16" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `When the Home team was north melbourne what was the Date of the game?`:
```sql
|
SELECT "record" FROM "game_log" WHERE "date"='september 1'; |
## Task
Generate a SQL query to answer the following question:
`What was the record as of September 1?`
### 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,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the record as of September 1?`:
```sql
|
SELECT "loss" FROM "game_log" WHERE "date"='september 1'; |
## Task
Generate a SQL query to answer the following question:
`What was the losing score on September 1?`
### 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,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the losing score on September 1?`:
```sql
|
SELECT "1988" FROM "grand_slam_singles_tournament_timeline" WHERE "1987"='1r'; |
## Task
Generate a SQL query to answer the following question:
`What is the 1988 value when the 1987 value was 1r?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "grand_slam_singles_tournament_timeline" (
"tournament" text,
"1980" text,
"1981" text,
"1982" text,
"1983" text,
"1984" text,
"1985" text,
"1986" text,
"1987" text,
"1988" text,
"1989" text,
"1990" text,
"1991" text,
"1992" text,
"1993" text,
"1994" text,
"1995" text,
"1996" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 1988 value when the 1987 value was 1r?`:
```sql
|
SELECT "1981" FROM "grand_slam_singles_tournament_timeline" WHERE "tournament"='wimbledon'; |
## Task
Generate a SQL query to answer the following question:
`What is the 1981 value at the Tournament of Wimbledon?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "grand_slam_singles_tournament_timeline" (
"tournament" text,
"1980" text,
"1981" text,
"1982" text,
"1983" text,
"1984" text,
"1985" text,
"1986" text,
"1987" text,
"1988" text,
"1989" text,
"1990" text,
"1991" text,
"1992" text,
"1993" text,
"1994" text,
"1995" text,
"1996" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 1981 value at the Tournament of Wimbledon?`:
```sql
|
SELECT "name" FROM "roller_coasters" WHERE "opened"='2004' AND "park"='bobbejaanland'; |
## Task
Generate a SQL query to answer the following question:
`What is the name of the rollercoaster that opened in 2004 in bobbejaanland?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "roller_coasters" (
"name" text,
"model" text,
"park" text,
"opened" text,
"status" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the name of the rollercoaster that opened in 2004 in bobbejaanland?`:
```sql
|
SELECT "status" FROM "roller_coasters" WHERE "opened"='2008' AND "model"='junior coaster'; |
## Task
Generate a SQL query to answer the following question:
`What is the status of the junior coaster model that opened in 2008?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "roller_coasters" (
"name" text,
"model" text,
"park" text,
"opened" text,
"status" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the status of the junior coaster model that opened in 2008?`:
```sql
|
SELECT "model" FROM "roller_coasters" WHERE "status"='operating' AND "name"='thor''s hammer'; |
## Task
Generate a SQL query to answer the following question:
`What is the model for Thor's Hammer which is listed as operating?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "roller_coasters" (
"name" text,
"model" text,
"park" text,
"opened" text,
"status" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the model for Thor's Hammer which is listed as operating?`:
```sql
|
SELECT "name" FROM "roller_coasters" WHERE "model"='euro-fighter' AND "opened"='2011'; |
## Task
Generate a SQL query to answer the following question:
`What is the name of the coaster that opened in 2011 and is a euro-fighter model?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "roller_coasters" (
"name" text,
"model" text,
"park" text,
"opened" text,
"status" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the name of the coaster that opened in 2011 and is a euro-fighter model?`:
```sql
|
SELECT "winning_driver" FROM "non_championship_race_results" WHERE "race_name"='iv j.c.c. jersey road race'; |
## Task
Generate a SQL query to answer the following question:
`Which driver won the iv j.c.c. jersey road race?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "non_championship_race_results" (
"race_name" text,
"circuit" text,
"date" text,
"winning_driver" text,
"constructor" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which driver won the iv j.c.c. jersey road race?`:
```sql
|
SELECT COUNT("games") FROM "all_time_record" WHERE "points"=34 AND "losses"=3; |
## Task
Generate a SQL query to answer the following question:
`What's the total number of games that had more than 34 points and exactly 3 losses?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "all_time_record" (
"season" text,
"team_name" text,
"games" real,
"losses" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What's the total number of games that had more than 34 points and exactly 3 losses?`:
```sql
|
SELECT COUNT("losses") FROM "all_time_record" WHERE "points"<19 AND "games">36; |
## Task
Generate a SQL query to answer the following question:
`What's the total number of losses with less than 19 points and more than 36 games?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "all_time_record" (
"season" text,
"team_name" text,
"games" real,
"losses" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What's the total number of losses with less than 19 points and more than 36 games?`:
```sql
|
SELECT "season" FROM "all_time_record" WHERE "points"<26 AND "games">18 AND "losses"=13; |
## Task
Generate a SQL query to answer the following question:
`Which season has less than 26 points, more than 18 games, and exactly 13 losses?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "all_time_record" (
"season" text,
"team_name" text,
"games" real,
"losses" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which season has less than 26 points, more than 18 games, and exactly 13 losses?`:
```sql
|
SELECT MAX("crowd") FROM "round_3" WHERE "away_team"='south melbourne'; |
## Task
Generate a SQL query to answer the following question:
`What is the highest crowd number of the game where the away team was south melbourne?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_3" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest crowd number of the game where the away team was south melbourne?`:
```sql
|
SELECT "home_team_score" FROM "round_3" WHERE "away_team"='north melbourne'; |
## Task
Generate a SQL query to answer the following question:
`What is the home team score that played the away team of north melbourne?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_3" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the home team score that played the away team of north melbourne?`:
```sql
|
SELECT "away_team_score" FROM "round_3" WHERE "venue"='princes park'; |
## Task
Generate a SQL query to answer the following question:
`What is the away team score of the game that was played at princes park?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_3" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the away team score of the game that was played at princes park?`:
```sql
|
SELECT SUM("crowd") FROM "round_8" WHERE "home_team_score"='21.22 (148)'; |
## Task
Generate a SQL query to answer the following question:
`If the Home team had a score of 21.22 (148), what is the sum of all Crowds?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_8" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `If the Home team had a score of 21.22 (148), what is the sum of all Crowds?`:
```sql
|
SELECT MIN("crowd") FROM "round_8" WHERE "home_team"='carlton'; |
## Task
Generate a SQL query to answer the following question:
`If the Home team is carlton, what's the lowest Crowd found?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_8" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `If the Home team is carlton, what's the lowest Crowd found?`:
```sql
|
SELECT AVG("crowd") FROM "round_19" WHERE "away_team_score"='12.10 (82)'; |
## Task
Generate a SQL query to answer the following question:
`What is the average amount of attenders when away team score is 12.10 (82)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_19" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average amount of attenders when away team score is 12.10 (82)?`:
```sql
|
SELECT "away_team_score" FROM "round_19" WHERE "home_team_score"='11.11 (77)'; |
## Task
Generate a SQL query to answer the following question:
`What is the away team score when the home team scored 11.11 (77)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_19" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the away team score when the home team scored 11.11 (77)?`:
```sql
|
SELECT "venue" FROM "round_19" WHERE "away_team_score"='15.11 (101)'; |
## Task
Generate a SQL query to answer the following question:
`Where did the game take place when the away team score is 15.11 (101)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_19" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `Where did the game take place when the away team score is 15.11 (101)?`:
```sql
|
SELECT "block_a" FROM "2007" WHERE "el_nosawa_mendoza"='kondo (7:08)'; |
## Task
Generate a SQL query to answer the following question:
`What is the Block A value for an El NOSAWA Mendoza value of kondo (7:08)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2007" (
"block_a" text,
"ryuji_hijikata" text,
"shuji_kondo" text,
"el_nosawa_mendoza" text,
"pepe_michinoku" text,
"katsuhiko_nakajima" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Block A value for an El NOSAWA Mendoza value of kondo (7:08)?`:
```sql
|
SELECT "pepe_michinoku" FROM "2007" WHERE "ryuji_hijikata"='sabin (12:33)'; |
## Task
Generate a SQL query to answer the following question:
`What is the PEPE Michinoku value for a Ryuji Hijikata value of sabin (12:33)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2007" (
"block_a" text,
"ryuji_hijikata" text,
"shuji_kondo" text,
"el_nosawa_mendoza" text,
"pepe_michinoku" text,
"katsuhiko_nakajima" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the PEPE Michinoku value for a Ryuji Hijikata value of sabin (12:33)?`:
```sql
|
SELECT "shuji_kondo" FROM "2007" WHERE "pepe_michinoku"='sabin (14:43)'; |
## Task
Generate a SQL query to answer the following question:
`What is the Shuji Kondo value related to a PEPE Michinoku value of sabin (14:43)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2007" (
"block_a" text,
"ryuji_hijikata" text,
"shuji_kondo" text,
"el_nosawa_mendoza" text,
"pepe_michinoku" text,
"katsuhiko_nakajima" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Shuji Kondo value related to a PEPE Michinoku value of sabin (14:43)?`:
```sql
|
SELECT "from" FROM "b" WHERE "asts"=0; |
## Task
Generate a SQL query to answer the following question:
`when did asts reach 0?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "b" (
"player" text,
"pos" text,
"from" real,
"school_country" text,
"rebs" real,
"asts" real
);
### SQL
Given the database schema, here is the SQL query that answers `when did asts reach 0?`:
```sql
|
SELECT MIN("asts") FROM "b" WHERE "pos"='sf' AND "from">2001; |
## Task
Generate a SQL query to answer the following question:
`beyond 2001, what is the lowest asts from a pos of sf?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "b" (
"player" text,
"pos" text,
"from" real,
"school_country" text,
"rebs" real,
"asts" real
);
### SQL
Given the database schema, here is the SQL query that answers `beyond 2001, what is the lowest asts from a pos of sf?`:
```sql
|
SELECT "declination_j2000" FROM "5701_5800" WHERE "ngc_number">5750; |
## Task
Generate a SQL query to answer the following question:
`Tell me the declination with NGC number larger than 5750`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "5701_5800" (
"ngc_number" real,
"object_type" text,
"constellation" text,
"right_ascension_j2000" text,
"declination_j2000" text,
"apparent_magnitude" real
);
### SQL
Given the database schema, here is the SQL query that answers `Tell me the declination with NGC number larger than 5750`:
```sql
|
SELECT "final_position_round" FROM "competition_overall" WHERE "competition"='fa community shield'; |
## Task
Generate a SQL query to answer the following question:
`Tell me the final position for fa community shield`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "competition_overall" (
"competition" text,
"current_position_round" text,
"final_position_round" text,
"first_match" text,
"last_match" text
);
### SQL
Given the database schema, here is the SQL query that answers `Tell me the final position for fa community shield`:
```sql
|
SELECT "first_match" FROM "competition_overall" WHERE "last_match"='11 may 2008'; |
## Task
Generate a SQL query to answer the following question:
`Name the first match for 11 may 2008`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "competition_overall" (
"competition" text,
"current_position_round" text,
"final_position_round" text,
"first_match" text,
"last_match" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the first match for 11 may 2008`:
```sql
|
SELECT COUNT("lifetime_india_distributor_share") FROM "lifetime_distributor_share" WHERE "year"<2009; |
## Task
Generate a SQL query to answer the following question:
`What is the total number of Lifetime India Distributor share earlier than 2009?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "lifetime_distributor_share" (
"rank" real,
"movie" text,
"year" real,
"studio_s" text,
"lifetime_india_distributor_share" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total number of Lifetime India Distributor share earlier than 2009?`:
```sql
|
SELECT "date" FROM "round_17" WHERE "home_team"='south melbourne'; |
## Task
Generate a SQL query to answer the following question:
`When did South Melbourne play as the home team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_17" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `When did South Melbourne play as the home team?`:
```sql
|
SELECT MAX("crowd") FROM "round_17" WHERE "away_team"='st kilda'; |
## Task
Generate a SQL query to answer the following question:
`What was the largest amount of spectators when St Kilda was the away team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_17" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the largest amount of spectators when St Kilda was the away team?`:
```sql
|
SELECT "away_team_score" FROM "round_17" WHERE "away_team"='richmond'; |
## Task
Generate a SQL query to answer the following question:
`What was Richmond's score when it was the away team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_17" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was Richmond's score when it was the away team?`:
```sql
|
SELECT "declination_j2000" FROM "3301_3400" WHERE "constellation"='hydra' AND "right_ascension_j2000"='10h46m44.9s'; |
## Task
Generate a SQL query to answer the following question:
`what is the declination (j2000) that has a constellation of hydra and a right ascension (j2000) of 10h46m44.9s?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "3301_3400" (
"ngc_number" real,
"object_type" text,
"constellation" text,
"right_ascension_j2000" text,
"declination_j2000" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the declination (j2000) that has a constellation of hydra and a right ascension (j2000) of 10h46m44.9s?`:
```sql
|
SELECT MAX("ngc_number") FROM "3301_3400" WHERE "object_type"='lenticular galaxy' AND "constellation"='hydra'; |
## Task
Generate a SQL query to answer the following question:
`What is the ngc number when the object type is lenticular galaxy and the constellation is hydra?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "3301_3400" (
"ngc_number" real,
"object_type" text,
"constellation" text,
"right_ascension_j2000" text,
"declination_j2000" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the ngc number when the object type is lenticular galaxy and the constellation is hydra?`:
```sql
|
SELECT "object_type" FROM "3301_3400" WHERE "ngc_number"=3314; |
## Task
Generate a SQL query to answer the following question:
`what is the object type when the ngc number is 3314?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "3301_3400" (
"ngc_number" real,
"object_type" text,
"constellation" text,
"right_ascension_j2000" text,
"declination_j2000" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the object type when the ngc number is 3314?`:
```sql
|
SELECT AVG("ngc_number") FROM "3301_3400" WHERE "constellation"='leo' AND "declination_j2000"='Β°42β²13β³'; |
## Task
Generate a SQL query to answer the following question:
`what is the ngc number when the constellation is leo and the declination (j2000) is Β°42β²13β³?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "3301_3400" (
"ngc_number" real,
"object_type" text,
"constellation" text,
"right_ascension_j2000" text,
"declination_j2000" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the ngc number when the constellation is leo and the declination (j2000) is Β°42β²13β³?`:
```sql
|
SELECT "right_ascension_j2000" FROM "3301_3400" WHERE "ngc_number"<3384 AND "constellation"='hydra' AND "object_type"='spiral galaxy'; |
## Task
Generate a SQL query to answer the following question:
`what is the right ascension (j2000) with the ngc number less than 3384, the constellation is hydra and the object type is spiral galaxy?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "3301_3400" (
"ngc_number" real,
"object_type" text,
"constellation" text,
"right_ascension_j2000" text,
"declination_j2000" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the right ascension (j2000) with the ngc number less than 3384, the constellation is hydra and the object type is spiral galaxy?`:
```sql
|
SELECT "competition" FROM "international_goals" WHERE "date"='october 7, 2011'; |
## Task
Generate a SQL query to answer the following question:
`What competition was played on October 7, 2011?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "international_goals" (
"date" text,
"venue" text,
"score" text,
"result" text,
"competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `What competition was played on October 7, 2011?`:
```sql
|
SELECT "score" FROM "1990s" WHERE "year"=1992 AND "result"='loss'; |
## Task
Generate a SQL query to answer the following question:
`What's the score for 1992, with the result of a loss?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1990s" (
"year" real,
"date" text,
"location" text,
"score" text,
"result" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the score for 1992, with the result of a loss?`:
```sql
|
SELECT "national_league" FROM "third_and_fourth_tiers" WHERE "club"='limoges csp' AND "national_cup"='french basketball cup'; |
## Task
Generate a SQL query to answer the following question:
`What national league has limoges csp, and french basketball cup?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "third_and_fourth_tiers" (
"season" text,
"club" text,
"national_league" text,
"national_cup" text,
"european_cup" text
);
### SQL
Given the database schema, here is the SQL query that answers `What national league has limoges csp, and french basketball cup?`:
```sql
|
SELECT "club" FROM "third_and_fourth_tiers" WHERE "national_cup"='turkish basketball cup' AND "european_cup"='fiba eurochallenge (3rd tier)'; |
## Task
Generate a SQL query to answer the following question:
`What is the club that has the turkish basketball cup and fiba eurochallenge (3rd tier)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "third_and_fourth_tiers" (
"season" text,
"club" text,
"national_league" text,
"national_cup" text,
"european_cup" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the club that has the turkish basketball cup and fiba eurochallenge (3rd tier)?`:
```sql
|
SELECT "national_cup" FROM "third_and_fourth_tiers" WHERE "club"='fc barcelona'; |
## Task
Generate a SQL query to answer the following question:
`What national cup has fc barcelona?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "third_and_fourth_tiers" (
"season" text,
"club" text,
"national_league" text,
"national_cup" text,
"european_cup" text
);
### SQL
Given the database schema, here is the SQL query that answers `What national cup has fc barcelona?`:
```sql
|
SELECT "series" FROM "available_processors" WHERE "cpu_clock_m_hz"='1500' AND "model"='t-52r'; |
## Task
Generate a SQL query to answer the following question:
`Name the series ^ when the CPU clock is 1500 and the model is t-52r`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "available_processors" (
"series" text,
"model" text,
"cpu_clock_m_hz" text,
"cpu_cores" real,
"tdp_w" text,
"l2_cache_ki_b" text,
"radeon_cores" real,
"ddr3_speed" real
);
### SQL
Given the database schema, here is the SQL query that answers `Name the series ^ when the CPU clock is 1500 and the model is t-52r`:
```sql
|
SELECT AVG("ddr3_speed") FROM "available_processors" WHERE "model"='e-350'; |
## Task
Generate a SQL query to answer the following question:
`Name the average DDR3 speed for model e-350`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "available_processors" (
"series" text,
"model" text,
"cpu_clock_m_hz" text,
"cpu_cores" real,
"tdp_w" text,
"l2_cache_ki_b" text,
"radeon_cores" real,
"ddr3_speed" real
);
### SQL
Given the database schema, here is the SQL query that answers `Name the average DDR3 speed for model e-350`:
```sql
|
SELECT "cpu_clock_m_hz" FROM "available_processors" WHERE "l2_cache_ki_b"='2*512' AND "series"='e-series' AND "ddr3_speed"=1066; |
## Task
Generate a SQL query to answer the following question:
`Name the CPU clock for L2 cache of 2*512 and series ^ of e-series and DDR3 speed of 1066`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "available_processors" (
"series" text,
"model" text,
"cpu_clock_m_hz" text,
"cpu_cores" real,
"tdp_w" text,
"l2_cache_ki_b" text,
"radeon_cores" real,
"ddr3_speed" real
);
### SQL
Given the database schema, here is the SQL query that answers `Name the CPU clock for L2 cache of 2*512 and series ^ of e-series and DDR3 speed of 1066`:
```sql
|
SELECT "loss" FROM "game_log" WHERE "date"='august 21'; |
## Task
Generate a SQL query to answer the following question:
`who lost on august 21?`
### 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,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `who lost on august 21?`:
```sql
|
SELECT "record" FROM "game_log" WHERE "opponent"='expos' AND "date"='august 10'; |
## Task
Generate a SQL query to answer the following question:
`On August 10, what was the record against the Expos?`
### 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,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `On August 10, what was the record against the Expos?`:
```sql
|
SELECT AVG("laps") FROM "classification" WHERE "driver"='lorenzo bandini' AND "grid"<3; |
## Task
Generate a SQL query to answer the following question:
`What is the average laps for lorenzo bandini with a grid under 3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "classification" (
"driver" text,
"constructor" text,
"laps" real,
"time_retired" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average laps for lorenzo bandini with a grid under 3?`:
```sql
|
SELECT "driver" FROM "classification" WHERE "laps"<53 AND "grid"<14 AND "time_retired"='differential'; |
## Task
Generate a SQL query to answer the following question:
`What driver has under 53 laps, a grid smaller than 14, and a time/retired of differential?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "classification" (
"driver" text,
"constructor" text,
"laps" real,
"time_retired" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `What driver has under 53 laps, a grid smaller than 14, and a time/retired of differential?`:
```sql
|
SELECT "music" FROM "jacopetti_and_prosperi" WHERE "uncut_run_time"='95 minutes'; |
## Task
Generate a SQL query to answer the following question:
`What music is in the film with an Uncut run time of 95 minutes?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "jacopetti_and_prosperi" (
"title" text,
"year" real,
"country" text,
"music" text,
"uncut_run_time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What music is in the film with an Uncut run time of 95 minutes?`:
```sql
|
SELECT "country" FROM "jacopetti_and_prosperi" WHERE "music"='nino oliviero'; |
## Task
Generate a SQL query to answer the following question:
`What country is the film that has music of nino oliviero?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "jacopetti_and_prosperi" (
"title" text,
"year" real,
"country" text,
"music" text,
"uncut_run_time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What country is the film that has music of nino oliviero?`:
```sql
|
SELECT "music" FROM "jacopetti_and_prosperi" WHERE "year"<1963; |
## Task
Generate a SQL query to answer the following question:
`What music is in the film before 1963?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "jacopetti_and_prosperi" (
"title" text,
"year" real,
"country" text,
"music" text,
"uncut_run_time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What music is in the film before 1963?`:
```sql
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.