output stringlengths 27 479 | instruction stringlengths 407 1.39k |
|---|---|
SELECT "conference_joined" FROM "former_members" WHERE "location"='terre haute' AND "mascot"='golden bears'; |
## Task
Generate a SQL query to answer the following question:
`Can you tell me the Conference Joined that has the Location of terre haute, and the Mascot of golden bears?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "former_members" (
"school" text,
"location" text,
"mascot" text,
"county" text,
"year_joined" real,
"year_left" text,
"conference_joined" text
);
### SQL
Given the database schema, here is the SQL query that answers `Can you tell me the Conference Joined that has the Location of terre haute, and the Mascot of golden bears?`:
```sql
|
SELECT "mascot" FROM "former_members" WHERE "school"='rosedale'; |
## Task
Generate a SQL query to answer the following question:
`Can you tell me the Mascot that has the School of rosedale?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "former_members" (
"school" text,
"location" text,
"mascot" text,
"county" text,
"year_joined" real,
"year_left" text,
"conference_joined" text
);
### SQL
Given the database schema, here is the SQL query that answers `Can you tell me the Mascot that has the School of rosedale?`:
```sql
|
SELECT "conference_joined" FROM "former_members" WHERE "mascot"='little sycamores'; |
## Task
Generate a SQL query to answer the following question:
`Can you tell me the Conference Joined that has the Mascot of little sycamores?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "former_members" (
"school" text,
"location" text,
"mascot" text,
"county" text,
"year_joined" real,
"year_left" text,
"conference_joined" text
);
### SQL
Given the database schema, here is the SQL query that answers `Can you tell me the Conference Joined that has the Mascot of little sycamores?`:
```sql
|
SELECT "location" FROM "former_members" WHERE "mascot"='lakers'; |
## Task
Generate a SQL query to answer the following question:
`Can you tell me the Location that has the Mascot of lakers?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "former_members" (
"school" text,
"location" text,
"mascot" text,
"county" text,
"year_joined" real,
"year_left" text,
"conference_joined" text
);
### SQL
Given the database schema, here is the SQL query that answers `Can you tell me the Location that has the Mascot of lakers?`:
```sql
|
SELECT "time" FROM "race_3_junior_classic_race" WHERE "team"='348cc k4 honda' AND "speed"='97.743mph'; |
## Task
Generate a SQL query to answer the following question:
`What is the time of the rider from the 348cc K4 Honda team with a speed of 97.743mph?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "race_3_junior_classic_race" (
"rank" real,
"rider" text,
"team" text,
"speed" text,
"time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the time of the rider from the 348cc K4 Honda team with a speed of 97.743mph?`:
```sql
|
SELECT "lane" FROM "heats" WHERE "time"='8:34.25'; |
## Task
Generate a SQL query to answer the following question:
`What is the Lane of the swimmer with a Time of 8:34.25?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "heats" (
"heat" real,
"lane" real,
"name" text,
"nationality" text,
"time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Lane of the swimmer with a Time of 8:34.25?`:
```sql
|
SELECT "name" FROM "heats" WHERE "heat"=2 AND "time"='9:04.86'; |
## Task
Generate a SQL query to answer the following question:
`What is the Name of the swimmer with a Time of 9:04.86 in Heat 2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "heats" (
"heat" real,
"lane" real,
"name" text,
"nationality" text,
"time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Name of the swimmer with a Time of 9:04.86 in Heat 2?`:
```sql
|
SELECT "location" FROM "mixed_martial_arts_record" WHERE "round"=1 AND "time"='1:25'; |
## Task
Generate a SQL query to answer the following question:
`What is the Location of the Event in Round 1 with a Time of 1:25?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "mixed_martial_arts_record" (
"res" text,
"record" text,
"opponent" text,
"method" text,
"event" text,
"round" real,
"time" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Location of the Event in Round 1 with a Time of 1:25?`:
```sql
|
SELECT AVG("goals") FROM "list_of_players" WHERE "last_appearance"<1984 AND "appearances">17 AND "first_appearance"<1961 AND "position"='mf'; |
## Task
Generate a SQL query to answer the following question:
`What is the average goals when the last appearance was before 1984, there were more than 17 appearances, the first appearance was before 1961 and the position was mf?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_players" (
"position" text,
"appearances" real,
"goals" real,
"first_appearance" real,
"last_appearance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average goals when the last appearance was before 1984, there were more than 17 appearances, the first appearance was before 1961 and the position was mf?`:
```sql
|
SELECT "school" FROM "former_members" WHERE "year_left"=1966; |
## Task
Generate a SQL query to answer the following question:
`what is the school that left in 1966?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "former_members" (
"school" text,
"location" text,
"mascot" text,
"county" text,
"year_joined" real,
"year_left" real,
"conference_joined" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the school that left in 1966?`:
```sql
|
SELECT "mascot" FROM "former_members" WHERE "year_joined">1952 AND "school"='moores hill'; |
## Task
Generate a SQL query to answer the following question:
`what is the mascot for moores hill that joined later than 1952?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "former_members" (
"school" text,
"location" text,
"mascot" text,
"county" text,
"year_joined" real,
"year_left" real,
"conference_joined" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the mascot for moores hill that joined later than 1952?`:
```sql
|
SELECT "conference_joined" FROM "former_members" WHERE "county"='69 ripley' AND "year_joined"=1952 AND "location"='versailles'; |
## Task
Generate a SQL query to answer the following question:
`what is the conference joined for the county 69 ripley in 1952 in versailles?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "former_members" (
"school" text,
"location" text,
"mascot" text,
"county" text,
"year_joined" real,
"year_left" real,
"conference_joined" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the conference joined for the county 69 ripley in 1952 in versailles?`:
```sql
|
SELECT "mascot" FROM "former_members" WHERE "county"='78 switzerland'; |
## Task
Generate a SQL query to answer the following question:
`who is the mascot of the county 78 switzerland?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "former_members" (
"school" text,
"location" text,
"mascot" text,
"county" text,
"year_joined" real,
"year_left" real,
"conference_joined" text
);
### SQL
Given the database schema, here is the SQL query that answers `who is the mascot of the county 78 switzerland?`:
```sql
|
SELECT COUNT("time") FROM "semifinal_1" WHERE "lane"<8 AND "nationality"='canada' AND "rank"<8; |
## Task
Generate a SQL query to answer the following question:
`What is the total time of the athlete from Canada with a lane less than 8 and a rank less than 8?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "semifinal_1" (
"rank" real,
"lane" real,
"name" text,
"nationality" text,
"react" real,
"time" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total time of the athlete from Canada with a lane less than 8 and a rank less than 8?`:
```sql
|
SELECT COUNT("react") FROM "semifinal_1" WHERE "time"<20.05 AND "lane"<6; |
## Task
Generate a SQL query to answer the following question:
`What is the total react number with a time less than 20.05 and a lane less than 6?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "semifinal_1" (
"rank" real,
"lane" real,
"name" text,
"nationality" text,
"react" real,
"time" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total react number with a time less than 20.05 and a lane less than 6?`:
```sql
|
SELECT AVG("react") FROM "semifinal_1" WHERE "name"='bryan barnett' AND "lane"<2; |
## Task
Generate a SQL query to answer the following question:
`What is the average react of bryan barnett, who has a lane less than 2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "semifinal_1" (
"rank" real,
"lane" real,
"name" text,
"nationality" text,
"react" real,
"time" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average react of bryan barnett, who has a lane less than 2?`:
```sql
|
SELECT "year_left" FROM "former_members" WHERE "team_name"='hornets'; |
## Task
Generate a SQL query to answer the following question:
`What year did the Hornets leave the conference?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "former_members" (
"school" text,
"city" text,
"team_name" text,
"county" text,
"year_joined" text,
"year_left" text
);
### SQL
Given the database schema, here is the SQL query that answers `What year did the Hornets leave the conference?`:
```sql
|
SELECT "city" FROM "former_members" WHERE "year_left"='1949'; |
## Task
Generate a SQL query to answer the following question:
`In what city was the team that left the conference in 1949 based?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "former_members" (
"school" text,
"city" text,
"team_name" text,
"county" text,
"year_joined" text,
"year_left" text
);
### SQL
Given the database schema, here is the SQL query that answers `In what city was the team that left the conference in 1949 based?`:
```sql
|
SELECT "year_joined" FROM "former_members" WHERE "city"='winamac'; |
## Task
Generate a SQL query to answer the following question:
`What year did the team based in the city of Winamac join the conference?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "former_members" (
"school" text,
"city" text,
"team_name" text,
"county" text,
"year_joined" text,
"year_left" text
);
### SQL
Given the database schema, here is the SQL query that answers `What year did the team based in the city of Winamac join the conference?`:
```sql
|
SELECT "county" FROM "former_members" WHERE "year_left"='1993'; |
## Task
Generate a SQL query to answer the following question:
`From what county was the team that left the conference in 1993?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "former_members" (
"school" text,
"city" text,
"team_name" text,
"county" text,
"year_joined" text,
"year_left" text
);
### SQL
Given the database schema, here is the SQL query that answers `From what county was the team that left the conference in 1993?`:
```sql
|
SELECT "school" FROM "former_members" WHERE "year_left"='1992'; |
## Task
Generate a SQL query to answer the following question:
`From what school was the team that left the conference in 1992?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "former_members" (
"school" text,
"city" text,
"team_name" text,
"county" text,
"year_joined" text,
"year_left" text
);
### SQL
Given the database schema, here is the SQL query that answers `From what school was the team that left the conference in 1992?`:
```sql
|
SELECT "year_joined" FROM "former_members" WHERE "school"='western'; |
## Task
Generate a SQL query to answer the following question:
`In what year did the team from the Western school join the conference?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "former_members" (
"school" text,
"city" text,
"team_name" text,
"county" text,
"year_joined" text,
"year_left" text
);
### SQL
Given the database schema, here is the SQL query that answers `In what year did the team from the Western school join the conference?`:
```sql
|
SELECT AVG("place") FROM "results" WHERE "points"<1; |
## Task
Generate a SQL query to answer the following question:
`What is the place when less than 1 point is scored?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "results" (
"draw" real,
"language" text,
"artist" text,
"song" text,
"english_translation" text,
"place" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the place when less than 1 point is scored?`:
```sql
|
SELECT MAX("draw") FROM "results" WHERE "points"=23; |
## Task
Generate a SQL query to answer the following question:
`What is the highest draw number when 23 points are scored?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "results" (
"draw" real,
"language" text,
"artist" text,
"song" text,
"english_translation" text,
"place" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest draw number when 23 points are scored?`:
```sql
|
SELECT MIN("heat") FROM "heats" WHERE "time"='1:02.85' AND "lane">7; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest heat that had a time of 1:02.85 in a lane larger than 7?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "heats" (
"heat" real,
"lane" real,
"name" text,
"nationality" text,
"time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest heat that had a time of 1:02.85 in a lane larger than 7?`:
```sql
|
SELECT SUM("lane") FROM "heats" WHERE "heat"<7 AND "name"='elizabeth simmonds'; |
## Task
Generate a SQL query to answer the following question:
`What is the sum of the lanes before heat 7 that elizabeth simmonds swam?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "heats" (
"heat" real,
"lane" real,
"name" text,
"nationality" text,
"time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the sum of the lanes before heat 7 that elizabeth simmonds swam?`:
```sql
|
SELECT "s_dbayern" FROM "1928_to_1933" WHERE "year"=1928; |
## Task
Generate a SQL query to answer the following question:
`What's the Südbayern in 1928?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1928_to_1933" (
"year" real,
"baden" text,
"w_rttemberg" text,
"nordbayern" text,
"s_dbayern" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the Südbayern in 1928?`:
```sql
|
SELECT "w_rttemberg" FROM "1928_to_1933" WHERE "baden"='karlsruher fv' AND "year">1931; |
## Task
Generate a SQL query to answer the following question:
`What's the Württemberg for Karlsruher FV happening after 1931?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1928_to_1933" (
"year" real,
"baden" text,
"w_rttemberg" text,
"nordbayern" text,
"s_dbayern" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the Württemberg for Karlsruher FV happening after 1931?`:
```sql
|
SELECT COUNT("year") FROM "1928_to_1933" WHERE "baden"='freiburger fc'; |
## Task
Generate a SQL query to answer the following question:
`What's the year that has a Baden Freiburger FC?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1928_to_1933" (
"year" real,
"baden" text,
"w_rttemberg" text,
"nordbayern" text,
"s_dbayern" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the year that has a Baden Freiburger FC?`:
```sql
|
SELECT "w_rttemberg" FROM "1928_to_1933" WHERE "year"<1929; |
## Task
Generate a SQL query to answer the following question:
`What's the Württemberg in the year before 1929?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1928_to_1933" (
"year" real,
"baden" text,
"w_rttemberg" text,
"nordbayern" text,
"s_dbayern" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the Württemberg in the year before 1929?`:
```sql
|
SELECT "nordbayern" FROM "1928_to_1933" WHERE "year"<1932 AND "w_rttemberg"='union böckingen'; |
## Task
Generate a SQL query to answer the following question:
`What's the Nordbayern with a Württemberg of Union Böckingen in the year before 1932?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1928_to_1933" (
"year" real,
"baden" text,
"w_rttemberg" text,
"nordbayern" text,
"s_dbayern" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the Nordbayern with a Württemberg of Union Böckingen in the year before 1932?`:
```sql
|
SELECT "high_rebounds" FROM "regular_season" WHERE "score"='w 76-66'; |
## Task
Generate a SQL query to answer the following question:
`What was the high rebounds for the game that had a score of w 76-66?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "regular_season" (
"game" real,
"date" text,
"opponent" 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 high rebounds for the game that had a score of w 76-66?`:
```sql
|
SELECT "location_attendance" FROM "regular_season" WHERE "record"='16-6'; |
## Task
Generate a SQL query to answer the following question:
`What was the location/attendance for the game with a record of 16-6?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "regular_season" (
"game" real,
"date" text,
"opponent" 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 location/attendance for the game with a record of 16-6?`:
```sql
|
SELECT "nationality" FROM "semifinal_1" WHERE "lane">1 AND "rank">5 AND "name"='hsu chi-chieh'; |
## Task
Generate a SQL query to answer the following question:
`What is the nationality with a lane larger than 1, and a rank larger than 5, for Hsu Chi-Chieh?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "semifinal_1" (
"rank" real,
"lane" real,
"name" text,
"nationality" text,
"time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the nationality with a lane larger than 1, and a rank larger than 5, for Hsu Chi-Chieh?`:
```sql
|
SELECT COUNT("lane") FROM "semifinal_1" WHERE "time"='1:56.64' AND "rank"<7; |
## Task
Generate a SQL query to answer the following question:
`What is the lane with a time of 1:56.64, and a tank smaller than 7?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "semifinal_1" (
"rank" real,
"lane" real,
"name" text,
"nationality" text,
"time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lane with a time of 1:56.64, and a tank smaller than 7?`:
```sql
|
SELECT "rank" FROM "semifinal_1" WHERE "nationality"='japan'; |
## Task
Generate a SQL query to answer the following question:
`What is the rank of Japan?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "semifinal_1" (
"rank" real,
"lane" real,
"name" text,
"nationality" text,
"time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the rank of Japan?`:
```sql
|
SELECT "time" FROM "semifinal_1" WHERE "nationality"='russia'; |
## Task
Generate a SQL query to answer the following question:
`What is the time for Russia?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "semifinal_1" (
"rank" real,
"lane" real,
"name" text,
"nationality" text,
"time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the time for Russia?`:
```sql
|
SELECT "nation" FROM "medals_table" WHERE "silver">0 AND "rank"='1'; |
## Task
Generate a SQL query to answer the following question:
`What nation has more than 0 silver medals and is ranked 1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medals_table" (
"rank" text,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What nation has more than 0 silver medals and is ranked 1?`:
```sql
|
SELECT "rank" FROM "medals_table" WHERE "total">3 AND "silver">6; |
## Task
Generate a SQL query to answer the following question:
`What is the rank of the country with total more than 3 and more than 6 silver?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medals_table" (
"rank" text,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the rank of the country with total more than 3 and more than 6 silver?`:
```sql
|
SELECT MAX("silver") FROM "medals_table" WHERE "gold">1 AND "bronze"=3 AND "rank"='1' AND "total"<12; |
## Task
Generate a SQL query to answer the following question:
`What is the most silver won by the country with more than 1 gold, 3 bronze, ranked 1, and less than 12 as the total?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medals_table" (
"rank" text,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the most silver won by the country with more than 1 gold, 3 bronze, ranked 1, and less than 12 as the total?`:
```sql
|
SELECT "nation" FROM "medals_table" WHERE "total"<11 AND "silver"<1 AND "bronze"<1; |
## Task
Generate a SQL query to answer the following question:
`What nation has a total less than 11, more than 1 silver and less than 1 bronze?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medals_table" (
"rank" text,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What nation has a total less than 11, more than 1 silver and less than 1 bronze?`:
```sql
|
SELECT MAX("silver") FROM "medals_table" WHERE "nation"='norway'; |
## Task
Generate a SQL query to answer the following question:
`What is the most silver won by Norway?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medals_table" (
"rank" text,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the most silver won by Norway?`:
```sql
|
SELECT "district" FROM "assembly_segments" WHERE "constituency_number"='60'; |
## Task
Generate a SQL query to answer the following question:
`What district has a constituency of 60?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "assembly_segments" (
"constituency_number" text,
"name" text,
"reserved_for_sc_st_none" text,
"district" text,
"number_of_electorates_2009" real
);
### SQL
Given the database schema, here is the SQL query that answers `What district has a constituency of 60?`:
```sql
|
SELECT "district" FROM "assembly_segments" WHERE "name"='rajnagar'; |
## Task
Generate a SQL query to answer the following question:
`What is district has a name of Rajnagar?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "assembly_segments" (
"constituency_number" text,
"name" text,
"reserved_for_sc_st_none" text,
"district" text,
"number_of_electorates_2009" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is district has a name of Rajnagar?`:
```sql
|
SELECT "score" FROM "second_round_proper" WHERE "away_team"='brentford'; |
## Task
Generate a SQL query to answer the following question:
`What was the score for the away team of Brentford?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "second_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 was the score for the away team of Brentford?`:
```sql
|
SELECT "tie_no" FROM "second_round_proper" WHERE "away_team"='crewe alexandra'; |
## Task
Generate a SQL query to answer the following question:
`What was the score of the tied game or the away team of Crewe Alexandra?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "second_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 was the score of the tied game or the away team of Crewe Alexandra?`:
```sql
|
SELECT "date" FROM "second_round_proper" WHERE "away_team"='wrexham'; |
## Task
Generate a SQL query to answer the following question:
`What was the date of the game for the Wrexham away team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "second_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 was the date of the game for the Wrexham away team?`:
```sql
|
SELECT "date" FROM "second_round_proper" WHERE "home_team"='hartlepool united'; |
## Task
Generate a SQL query to answer the following question:
`What was the date of the game for the HartlePool United team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "second_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 was the date of the game for the HartlePool United team?`:
```sql
|
SELECT "tickets_sold_available" FROM "box_office_score_data" WHERE "venue"='long beach arena'; |
## Task
Generate a SQL query to answer the following question:
`What is the number of tickets sold and available for the concert at Long Beach Arena?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "box_office_score_data" (
"date" text,
"show" text,
"venue" text,
"city" text,
"tickets_sold_available" text,
"gross_revenue" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the number of tickets sold and available for the concert at Long Beach Arena?`:
```sql
|
SELECT "city" FROM "box_office_score_data" WHERE "venue"='arco arena'; |
## Task
Generate a SQL query to answer the following question:
`Which city has a venue of the Arco Arena?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "box_office_score_data" (
"date" text,
"show" text,
"venue" text,
"city" text,
"tickets_sold_available" text,
"gross_revenue" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which city has a venue of the Arco Arena?`:
```sql
|
SELECT MIN("round") FROM "mixed_martial_arts_record" WHERE "opponent"='kazushi sakuraba'; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest round that has kazushi sakuraba as the opponent?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "mixed_martial_arts_record" (
"res" text,
"record" text,
"opponent" text,
"method" text,
"round" real,
"time" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest round that has kazushi sakuraba as the opponent?`:
```sql
|
SELECT AVG("gold") FROM "medal_table" WHERE "nation"='japan (jpn)' AND "total"<5; |
## Task
Generate a SQL query to answer the following question:
`Japan (JPN) with a total of less than 5, has what average gold medals?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medal_table" (
"rank" real,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `Japan (JPN) with a total of less than 5, has what average gold medals?`:
```sql
|
SELECT AVG("bronze") FROM "medal_table" WHERE "gold">0 AND "silver"<0; |
## Task
Generate a SQL query to answer the following question:
`What is the average bronze medal when gold is greater than 0, and there is less than 0 silver medals?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medal_table" (
"rank" real,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average bronze medal when gold is greater than 0, and there is less than 0 silver medals?`:
```sql
|
SELECT COUNT("bronze") FROM "medal_table" WHERE "rank">2 AND "total"<2 AND "silver">0; |
## Task
Generate a SQL query to answer the following question:
`What is the sum of bronze medals when the rank is greater than 2, and less than 2 total medals with silver medals being more than 0?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medal_table" (
"rank" real,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the sum of bronze medals when the rank is greater than 2, and less than 2 total medals with silver medals being more than 0?`:
```sql
|
SELECT AVG("total") FROM "medal_table" WHERE "rank">4 AND "silver">0 AND "bronze"<1; |
## Task
Generate a SQL query to answer the following question:
`With a greater than 4 rank, and the silver medal greater than 0, and the bronze medal less than 1, what is the average total?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medal_table" (
"rank" real,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `With a greater than 4 rank, and the silver medal greater than 0, and the bronze medal less than 1, what is the average total?`:
```sql
|
SELECT MIN("gold") FROM "medal_table" WHERE "bronze">5; |
## Task
Generate a SQL query to answer the following question:
`What is the fewest gold medals when the bronze medals is greater than 5?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medal_table" (
"rank" real,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the fewest gold medals when the bronze medals is greater than 5?`:
```sql
|
SELECT "player" FROM "fourth_round" WHERE "team"='oakland raiders'; |
## Task
Generate a SQL query to answer the following question:
`What is the player when the team is oakland raiders?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fourth_round" (
"pick" real,
"team" text,
"player" text,
"position" text,
"college" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the player when the team is oakland raiders?`:
```sql
|
SELECT "team" FROM "fourth_round" WHERE "college"='virginia tech'; |
## Task
Generate a SQL query to answer the following question:
`What is the team when the college is virginia tech?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fourth_round" (
"pick" real,
"team" text,
"player" text,
"position" text,
"college" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the team when the college is virginia tech?`:
```sql
|
SELECT "college" FROM "fourth_round" WHERE "team"='new york jets'; |
## Task
Generate a SQL query to answer the following question:
`What college has a team of new york jets?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fourth_round" (
"pick" real,
"team" text,
"player" text,
"position" text,
"college" text
);
### SQL
Given the database schema, here is the SQL query that answers `What college has a team of new york jets?`:
```sql
|
SELECT "team" FROM "fourth_round" WHERE "pick">30 AND "college"='saginaw valley state'; |
## Task
Generate a SQL query to answer the following question:
`What team has a pick larger than 30, when the college is saginaw valley state?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fourth_round" (
"pick" real,
"team" text,
"player" text,
"position" text,
"college" text
);
### SQL
Given the database schema, here is the SQL query that answers `What team has a pick larger than 30, when the college is saginaw valley state?`:
```sql
|
SELECT MAX("pick") FROM "fourth_round" WHERE "college"='saginaw valley state'; |
## Task
Generate a SQL query to answer the following question:
`What is the highest pick when the college is saginaw valley state?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fourth_round" (
"pick" real,
"team" text,
"player" text,
"position" text,
"college" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest pick when the college is saginaw valley state?`:
```sql
|
SELECT "record" FROM "mixed_martial_arts_record" WHERE "opponent"='akiko inoue'; |
## Task
Generate a SQL query to answer the following question:
`what is the record when the opponent is akiko inoue?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "mixed_martial_arts_record" (
"res" text,
"record" text,
"opponent" text,
"method" text,
"event" text,
"round" real,
"time" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the record when the opponent is akiko inoue?`:
```sql
|
SELECT "event" FROM "mixed_martial_arts_record" WHERE "location"='tokyo, japan' AND "record"='6-1'; |
## Task
Generate a SQL query to answer the following question:
`what is the even when the location is tokyo, japan and the record is 6-1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "mixed_martial_arts_record" (
"res" text,
"record" text,
"opponent" text,
"method" text,
"event" text,
"round" real,
"time" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the even when the location is tokyo, japan and the record is 6-1?`:
```sql
|
SELECT "range" FROM "see_also" WHERE "name"='mount fukushima' AND "rank"=38; |
## Task
Generate a SQL query to answer the following question:
`Which range includes Mount Fukushima, and is ranked 38?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "see_also" (
"rank" real,
"name" text,
"altitude_meters" real,
"range" text,
"parent_range" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which range includes Mount Fukushima, and is ranked 38?`:
```sql
|
SELECT SUM("altitude_meters") FROM "see_also" WHERE "range"='belgica mountains' AND "name"='mount launoit'; |
## Task
Generate a SQL query to answer the following question:
`What is the altitude (meters) is associated with the Name Mount Launoit, with the range as Belgica Mountains?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "see_also" (
"rank" real,
"name" text,
"altitude_meters" real,
"range" text,
"parent_range" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the altitude (meters) is associated with the Name Mount Launoit, with the range as Belgica Mountains?`:
```sql
|
SELECT COUNT("altitude_meters") FROM "see_also" WHERE "range"='mühlig-hofmann mountains' AND "rank"<10; |
## Task
Generate a SQL query to answer the following question:
`What is the Altitude (meters) associated with a rank smaller than 10, and the range Mühlig-Hofmann Mountains?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "see_also" (
"rank" real,
"name" text,
"altitude_meters" real,
"range" text,
"parent_range" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Altitude (meters) associated with a rank smaller than 10, and the range Mühlig-Hofmann Mountains?`:
```sql
|
SELECT "name" FROM "see_also" WHERE "range"='sivorgfjella' AND "rank">69 AND "altitude_meters"<2154; |
## Task
Generate a SQL query to answer the following question:
`What name is associated with a rank greater than 69, an altitude (meters) smaller than 2154, and a range of Sivorgfjella?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "see_also" (
"rank" real,
"name" text,
"altitude_meters" real,
"range" text,
"parent_range" text
);
### SQL
Given the database schema, here is the SQL query that answers `What name is associated with a rank greater than 69, an altitude (meters) smaller than 2154, and a range of Sivorgfjella?`:
```sql
|
SELECT "name" FROM "see_also" WHERE "rank"<24 AND "altitude_meters"=3085; |
## Task
Generate a SQL query to answer the following question:
`What name is associated with a rank of less than 24, and an altitude (meters) of 3085?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "see_also" (
"rank" real,
"name" text,
"altitude_meters" real,
"range" text,
"parent_range" text
);
### SQL
Given the database schema, here is the SQL query that answers `What name is associated with a rank of less than 24, and an altitude (meters) of 3085?`:
```sql
|
SELECT "primary_conference" FROM "indiana_high_school_athletics_conference" WHERE "ihsaa_football_class"='a' AND "school"='south decatur'; |
## Task
Generate a SQL query to answer the following question:
`What is the primary conference with a IHSAA Football Class of A, at South Decatur school?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indiana_high_school_athletics_conference" (
"school" text,
"location" text,
"mascot" text,
"enrollment" real,
"ihsaa_football_class" text,
"primary_conference" text,
"county" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the primary conference with a IHSAA Football Class of A, at South Decatur school?`:
```sql
|
SELECT "location" FROM "indiana_high_school_athletics_conference" WHERE "county"='30 hancock'; |
## Task
Generate a SQL query to answer the following question:
`What is the Location with a county of 30 Hancock?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indiana_high_school_athletics_conference" (
"school" text,
"location" text,
"mascot" text,
"enrollment" real,
"ihsaa_football_class" text,
"primary_conference" text,
"county" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Location with a county of 30 Hancock?`:
```sql
|
SELECT "county" FROM "indiana_high_school_athletics_conference" WHERE "ihsaa_football_class"='a' AND "mascot"='royals'; |
## Task
Generate a SQL query to answer the following question:
`What county has an IHSAA Football Class of A, and a Mascot of royals?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indiana_high_school_athletics_conference" (
"school" text,
"location" text,
"mascot" text,
"enrollment" real,
"ihsaa_football_class" text,
"primary_conference" text,
"county" text
);
### SQL
Given the database schema, here is the SQL query that answers `What county has an IHSAA Football Class of A, and a Mascot of royals?`:
```sql
|
SELECT "school" FROM "indiana_high_school_athletics_conference" WHERE "county"='69 ripley'; |
## Task
Generate a SQL query to answer the following question:
`What school has a county of 69 ripley?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indiana_high_school_athletics_conference" (
"school" text,
"location" text,
"mascot" text,
"enrollment" real,
"ihsaa_football_class" text,
"primary_conference" text,
"county" text
);
### SQL
Given the database schema, here is the SQL query that answers `What school has a county of 69 ripley?`:
```sql
|
SELECT "enrollment" FROM "indiana_high_school_athletics_conference" WHERE "mascot"='fighting ''59ers'; |
## Task
Generate a SQL query to answer the following question:
`What is the enrollment for the school with the mascot of the Fighting '59ers?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indiana_high_school_athletics_conference" (
"school" text,
"location" text,
"mascot" text,
"enrollment" real,
"ihsaa_class" text,
"ihsaa_football_class" text,
"num_county" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the enrollment for the school with the mascot of the Fighting '59ers?`:
```sql
|
SELECT "nation" FROM "medals_table" WHERE "total"<2 AND "bronze"<1 AND "silver"=1; |
## Task
Generate a SQL query to answer the following question:
`What nation has a total less than 2, silver of 1 and bronze less than 1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medals_table" (
"rank" text,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What nation has a total less than 2, silver of 1 and bronze less than 1?`:
```sql
|
SELECT SUM("total") FROM "medals_table" WHERE "bronze"=3 AND "gold"<1 AND "silver"<0; |
## Task
Generate a SQL query to answer the following question:
`What's the total with silver being less than 0, less than 1 gold, and 3 bronze?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medals_table" (
"rank" text,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What's the total with silver being less than 0, less than 1 gold, and 3 bronze?`:
```sql
|
SELECT "time" FROM "heats" WHERE "heat">4 AND "nationality"='australia'; |
## Task
Generate a SQL query to answer the following question:
`What's Australia's time in the heat more than 4?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "heats" (
"heat" real,
"lane" real,
"name" text,
"nationality" text,
"time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's Australia's time in the heat more than 4?`:
```sql
|
SELECT SUM("lane") FROM "heats" WHERE "heat"=3 AND "name"='sara isakovič'; |
## Task
Generate a SQL query to answer the following question:
`What's Sara Isakovič's lane number that had a heat of 3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "heats" (
"heat" real,
"lane" real,
"name" text,
"nationality" text,
"time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's Sara Isakovič's lane number that had a heat of 3?`:
```sql
|
SELECT COUNT("heat") FROM "heats" WHERE "time"='2:08.54'; |
## Task
Generate a SQL query to answer the following question:
`What's the heat that was timed 2:08.54?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "heats" (
"heat" real,
"lane" real,
"name" text,
"nationality" text,
"time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the heat that was timed 2:08.54?`:
```sql
|
SELECT "director" FROM "1936" WHERE "title"='fish tales'; |
## Task
Generate a SQL query to answer the following question:
`Who is the Director of Fish Tales?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1936" (
"title" text,
"series" text,
"director" text,
"production_num" text,
"release_date" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the Director of Fish Tales?`:
```sql
|
SELECT "title" FROM "1936" WHERE "release_date"='1936-08-29'; |
## Task
Generate a SQL query to answer the following question:
`What was released on 1936-08-29?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1936" (
"title" text,
"series" text,
"director" text,
"production_num" text,
"release_date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was released on 1936-08-29?`:
```sql
|
SELECT "release_date" FROM "1936" WHERE "title"='milk and money'; |
## Task
Generate a SQL query to answer the following question:
`What is the release date of Milk and Money?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1936" (
"title" text,
"series" text,
"director" text,
"production_num" text,
"release_date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the release date of Milk and Money?`:
```sql
|
SELECT "release_date" FROM "1936" WHERE "title"='i wanna play house'; |
## Task
Generate a SQL query to answer the following question:
`What is the release date of I Wanna Play House?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1936" (
"title" text,
"series" text,
"director" text,
"production_num" text,
"release_date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the release date of I Wanna Play House?`:
```sql
|
SELECT "director" FROM "1936" WHERE "title"='little beau porky'; |
## Task
Generate a SQL query to answer the following question:
`Who is the director of Little Beau Porky?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1936" (
"title" text,
"series" text,
"director" text,
"production_num" text,
"release_date" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the director of Little Beau Porky?`:
```sql
|
SELECT "release_date" FROM "1936" WHERE "title"='the blow out'; |
## Task
Generate a SQL query to answer the following question:
`What is the release date of The Blow Out?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1936" (
"title" text,
"series" text,
"director" text,
"production_num" text,
"release_date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the release date of The Blow Out?`:
```sql
|
SELECT "author" FROM "references" WHERE "company"='buzz productions theater'; |
## Task
Generate a SQL query to answer the following question:
`Who was the author for company Buzz Productions Theater?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"play" text,
"author" text,
"company" text,
"base" text,
"country" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the author for company Buzz Productions Theater?`:
```sql
|
SELECT "country" FROM "references" WHERE "play"='cyclops'; |
## Task
Generate a SQL query to answer the following question:
`What country had the play Cyclops?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"play" text,
"author" text,
"company" text,
"base" text,
"country" text
);
### SQL
Given the database schema, here is the SQL query that answers `What country had the play Cyclops?`:
```sql
|
SELECT "country" FROM "references" WHERE "play"='medea'; |
## Task
Generate a SQL query to answer the following question:
`What country had the play Medea?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"play" text,
"author" text,
"company" text,
"base" text,
"country" text
);
### SQL
Given the database schema, here is the SQL query that answers `What country had the play Medea?`:
```sql
|
SELECT "play" FROM "references" WHERE "country"='belgium'; |
## Task
Generate a SQL query to answer the following question:
`What play is from the country Belgium?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"play" text,
"author" text,
"company" text,
"base" text,
"country" text
);
### SQL
Given the database schema, here is the SQL query that answers `What play is from the country Belgium?`:
```sql
|
SELECT "play" FROM "references" WHERE "author"='aeschylus' AND "base"='athens'; |
## Task
Generate a SQL query to answer the following question:
`What play has a base of Athens and was written by Aeschylus?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"play" text,
"author" text,
"company" text,
"base" text,
"country" text
);
### SQL
Given the database schema, here is the SQL query that answers `What play has a base of Athens and was written by Aeschylus?`:
```sql
|
SELECT "company" FROM "references" WHERE "country"='greece' AND "author"='aeschylus'; |
## Task
Generate a SQL query to answer the following question:
`What is the company from Greece with author Aeschylus?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"play" text,
"author" text,
"company" text,
"base" text,
"country" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the company from Greece with author Aeschylus?`:
```sql
|
SELECT "coaster_name" FROM "examples" WHERE "year_opened"='1978' AND "track"='wooden'; |
## Task
Generate a SQL query to answer the following question:
`What is the coaster name that was opened in 1978, and have wooden track?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "examples" (
"coaster_name" text,
"park" text,
"location" text,
"track" text,
"builder" text,
"year_opened" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the coaster name that was opened in 1978, and have wooden track?`:
```sql
|
SELECT "year_opened" FROM "examples" WHERE "coaster_name"='le monstre'; |
## Task
Generate a SQL query to answer the following question:
`Which year opened has le monstre coaster?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "examples" (
"coaster_name" text,
"park" text,
"location" text,
"track" text,
"builder" text,
"year_opened" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which year opened has le monstre coaster?`:
```sql
|
SELECT "coaster_name" FROM "examples" WHERE "location"='sandusky, ohio'; |
## Task
Generate a SQL query to answer the following question:
`Which coaster is located in sandusky, Ohio?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "examples" (
"coaster_name" text,
"park" text,
"location" text,
"track" text,
"builder" text,
"year_opened" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which coaster is located in sandusky, Ohio?`:
```sql
|
SELECT "year_opened" FROM "examples" WHERE "location"='west mifflin, pennsylvania'; |
## Task
Generate a SQL query to answer the following question:
`Which year opened is located in west mifflin, pennsylvania?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "examples" (
"coaster_name" text,
"park" text,
"location" text,
"track" text,
"builder" text,
"year_opened" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which year opened is located in west mifflin, pennsylvania?`:
```sql
|
SELECT MIN("league_cup_goals") FROM "appearances_and_goals" WHERE "fa_cup_goals">0 AND "fa_cup_apps">2; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest league cup goals for the entry with fa cup goals greater than 0 and FA cup apps larger than 2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "appearances_and_goals" (
"name" text,
"position" text,
"league_apps" text,
"league_goals" real,
"fa_cup_apps" real,
"fa_cup_goals" real,
"league_cup_apps" real,
"league_cup_goals" real,
"total_apps" text,
"total_goals" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest league cup goals for the entry with fa cup goals greater than 0 and FA cup apps larger than 2?`:
```sql
|
SELECT SUM("league_cup_apps") FROM "appearances_and_goals" WHERE "fa_cup_goals">0 AND "fa_cup_apps"<2; |
## Task
Generate a SQL query to answer the following question:
`What is the sum of league cup appearances for the players with FA cup goals larger than 0 and FA cup appearances less than 2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "appearances_and_goals" (
"name" text,
"position" text,
"league_apps" text,
"league_goals" real,
"fa_cup_apps" real,
"fa_cup_goals" real,
"league_cup_apps" real,
"league_cup_goals" real,
"total_apps" text,
"total_goals" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the sum of league cup appearances for the players with FA cup goals larger than 0 and FA cup appearances less than 2?`:
```sql
|
SELECT MAX("league_cup_apps") FROM "appearances_and_goals" WHERE "league_cup_goals"=0 AND "fa_cup_apps"=2 AND "league_goals"=4; |
## Task
Generate a SQL query to answer the following question:
`What is the highest league cup appearances for the player with league cup goals of 0, and FA cup appearances of 2, and 4 league goals?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "appearances_and_goals" (
"name" text,
"position" text,
"league_apps" text,
"league_goals" real,
"fa_cup_apps" real,
"fa_cup_goals" real,
"league_cup_apps" real,
"league_cup_goals" real,
"total_apps" text,
"total_goals" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest league cup appearances for the player with league cup goals of 0, and FA cup appearances of 2, and 4 league goals?`:
```sql
|
SELECT "game" FROM "game_log" WHERE "location_attendance"='omni coliseum' AND "score"='w 105-95'; |
## Task
Generate a SQL query to answer the following question:
`What game was played at Omni Coliseum with a w 105-95 score?`
### 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 game was played at Omni Coliseum with a w 105-95 score?`:
```sql
|
SELECT "date" FROM "game_log" WHERE "record"='10-8'; |
## Task
Generate a SQL query to answer the following question:
`When did the team have a 10-8 record?`
### 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 `When did the team have a 10-8 record?`:
```sql
|
SELECT "date" FROM "game_log" WHERE "record"='11-8'; |
## Task
Generate a SQL query to answer the following question:
`When was 11-8 the record?`
### 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 `When was 11-8 the record?`:
```sql
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.