output stringlengths 27 479 | instruction stringlengths 407 1.39k |
|---|---|
SELECT AVG("caboolture") FROM "population" WHERE "redcliffe">'27,327' AND "pine_rivers">'119,236' AND "year">1971 AND "population_total">'344,878'; |
## Task
Generate a SQL query to answer the following question:
`What is the average Caboolture population with a Redcliffe population greater than 27,327, a Pine Rivers population greater than 119,236, and a total population greater than 344,878 after 1971?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "population" (
"year" real,
"population_total" real,
"caboolture" real,
"pine_rivers" real,
"redcliffe" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average Caboolture population with a Redcliffe population greater than 27,327, a Pine Rivers population greater than 119,236, and a total population greater than 344,878 after 1971?`:
```sql
|
SELECT "place" FROM "first_round" WHERE "player"='emmet french'; |
## Task
Generate a SQL query to answer the following question:
`In which place is Emmet French?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_round" (
"place" text,
"player" text,
"country" text,
"score" real,
"to_par" text
);
### SQL
Given the database schema, here is the SQL query that answers `In which place is Emmet French?`:
```sql
|
SELECT "gold_coast" FROM "1995" WHERE "melbourne"='yes' AND "perth"='no' AND "adelaide"='yes'; |
## Task
Generate a SQL query to answer the following question:
`What is the result for Gold Coast when Melbourne and Adelaide are yes, but Perth is no?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1995" (
"sydney" text,
"melbourne" text,
"perth" text,
"adelaide" text,
"gold_coast" text,
"auckland" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the result for Gold Coast when Melbourne and Adelaide are yes, but Perth is no?`:
```sql
|
SELECT "melbourne" FROM "1995" WHERE "adelaide"='yes' AND "sydney"='yes' AND "perth"='yes' AND "gold_coast"='no'; |
## Task
Generate a SQL query to answer the following question:
`What is the result for Melbourne when Adelaide, Sydney, and Perth are yes, and Gold Coast is no?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1995" (
"sydney" text,
"melbourne" text,
"perth" text,
"adelaide" text,
"gold_coast" text,
"auckland" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the result for Melbourne when Adelaide, Sydney, and Perth are yes, and Gold Coast is no?`:
```sql
|
SELECT "melbourne" FROM "1995" WHERE "gold_coast"='no' AND "perth"='no' AND "auckland"='no' AND "sydney"='no'; |
## Task
Generate a SQL query to answer the following question:
`What is the result for Melbourne when Gold Coast, Perth, Auckland, and Sydney are no?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1995" (
"sydney" text,
"melbourne" text,
"perth" text,
"adelaide" text,
"gold_coast" text,
"auckland" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the result for Melbourne when Gold Coast, Perth, Auckland, and Sydney are no?`:
```sql
|
SELECT "gold_coast" FROM "1995" WHERE "adelaide"='yes' AND "auckland"='no' AND "perth"='yes'; |
## Task
Generate a SQL query to answer the following question:
`What is the result for Gold Coast when Adelaide and Perth are yes, but Auckland is no?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1995" (
"sydney" text,
"melbourne" text,
"perth" text,
"adelaide" text,
"gold_coast" text,
"auckland" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the result for Gold Coast when Adelaide and Perth are yes, but Auckland is no?`:
```sql
|
SELECT "gold_coast" FROM "1995" WHERE "melbourne"='yes' AND "sydney"='yes' AND "auckland"='no' AND "perth"='no'; |
## Task
Generate a SQL query to answer the following question:
`What is the result for Gold Coast when Melbourne and Sydney are yes, while Auckland and Perth are no?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1995" (
"sydney" text,
"melbourne" text,
"perth" text,
"adelaide" text,
"gold_coast" text,
"auckland" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the result for Gold Coast when Melbourne and Sydney are yes, while Auckland and Perth are no?`:
```sql
|
SELECT "melbourne" FROM "1995" WHERE "adelaide"='no' AND "auckland"='yes'; |
## Task
Generate a SQL query to answer the following question:
`What is the result for Melbourne when Adelaide is no, and Auckland is yes?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1995" (
"sydney" text,
"melbourne" text,
"perth" text,
"adelaide" text,
"gold_coast" text,
"auckland" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the result for Melbourne when Adelaide is no, and Auckland is yes?`:
```sql
|
SELECT "winner" FROM "stage_results" WHERE "date"='3 june'; |
## Task
Generate a SQL query to answer the following question:
`Who won on 3 june?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "stage_results" (
"stage" text,
"date" text,
"course" text,
"distance" text,
"winner" text,
"race_leader" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who won on 3 june?`:
```sql
|
SELECT "date" FROM "stage_results" WHERE "race_leader"='hermann buse ( ger )' AND "stage"='5'; |
## Task
Generate a SQL query to answer the following question:
`Which date has a Race Leader of hermann buse ( ger ), and a Stage of 5?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "stage_results" (
"stage" text,
"date" text,
"course" text,
"distance" text,
"winner" text,
"race_leader" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which date has a Race Leader of hermann buse ( ger ), and a Stage of 5?`:
```sql
|
SELECT "race_leader" FROM "stage_results" WHERE "stage"='7'; |
## Task
Generate a SQL query to answer the following question:
`Which race Leader has a Stage of 7?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "stage_results" (
"stage" text,
"date" text,
"course" text,
"distance" text,
"winner" text,
"race_leader" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which race Leader has a Stage of 7?`:
```sql
|
SELECT "date" FROM "stage_results" WHERE "stage"='12'; |
## Task
Generate a SQL query to answer the following question:
`Which date has a Stage of 12?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "stage_results" (
"stage" text,
"date" text,
"course" text,
"distance" text,
"winner" text,
"race_leader" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which date has a Stage of 12?`:
```sql
|
SELECT "result" FROM "apra_awards" WHERE "year"=1994 AND "award"='song of the year'; |
## Task
Generate a SQL query to answer the following question:
`What was the result for song of the year award in 1994?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "apra_awards" (
"year" real,
"country" text,
"nominated_work" text,
"award" text,
"result" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the result for song of the year award in 1994?`:
```sql
|
SELECT "result" FROM "apra_awards" WHERE "nominated_work"='neil finn'; |
## Task
Generate a SQL query to answer the following question:
`What was the result for work made by Neil Finn?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "apra_awards" (
"year" real,
"country" text,
"nominated_work" text,
"award" text,
"result" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the result for work made by Neil Finn?`:
```sql
|
SELECT COUNT("money") FROM "final_round" WHERE "country"='argentina'; |
## Task
Generate a SQL query to answer the following question:
`what is the money for argentina?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "final_round" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" real
);
### SQL
Given the database schema, here is the SQL query that answers `what is the money for argentina?`:
```sql
|
SELECT "money" FROM "final_round" WHERE "player"='trevor immelman'; |
## Task
Generate a SQL query to answer the following question:
`what is the money for trevor immelman?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "final_round" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" real
);
### SQL
Given the database schema, here is the SQL query that answers `what is the money for trevor immelman?`:
```sql
|
SELECT "place" FROM "final_round" WHERE "country"='ireland'; |
## Task
Generate a SQL query to answer the following question:
`what is the place for ireland?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "final_round" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" real
);
### SQL
Given the database schema, here is the SQL query that answers `what is the place for ireland?`:
```sql
|
SELECT "result" FROM "2008_fixtures_results" WHERE "opponent"='leeds' AND "date"='20/03/2008'; |
## Task
Generate a SQL query to answer the following question:
`What result was a date of 20/03/2008 with leeds as the opponent`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2008_fixtures_results" (
"date" text,
"competition" text,
"round" text,
"opponent" text,
"result" text,
"score" text,
"home_away" text,
"venue" text,
"goals" text,
"attendance" real,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `What result was a date of 20/03/2008 with leeds as the opponent`:
```sql
|
SELECT "h_t" FROM "independent_state_of_croatia" WHERE "venue"='stadio luigi ferraris'; |
## Task
Generate a SQL query to answer the following question:
`What was the HT for the game at Stadio Luigi Ferraris?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "independent_state_of_croatia" (
"date" text,
"score" text,
"h_t" text,
"venue" text,
"competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the HT for the game at Stadio Luigi Ferraris?`:
```sql
|
SELECT "h_t" FROM "independent_state_of_croatia" WHERE "venue"='zagreb' AND "score"='0-2'; |
## Task
Generate a SQL query to answer the following question:
`What was the HT for the game at Zagreb, with a full-time score of 0-2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "independent_state_of_croatia" (
"date" text,
"score" text,
"h_t" text,
"venue" text,
"competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the HT for the game at Zagreb, with a full-time score of 0-2?`:
```sql
|
SELECT "competition" FROM "independent_state_of_croatia" WHERE "venue"='zurich'; |
## Task
Generate a SQL query to answer the following question:
`What was the competition that was played in Zurich?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "independent_state_of_croatia" (
"date" text,
"score" text,
"h_t" text,
"venue" text,
"competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the competition that was played in Zurich?`:
```sql
|
SELECT "first_game" FROM "rugby_russia_internationals_1994" WHERE "lost">4; |
## Task
Generate a SQL query to answer the following question:
`When was the first game associated with over 4 losses?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "rugby_russia_internationals_1994" (
"first_game" real,
"played" real,
"drawn" real,
"lost" real,
"percentage" text
);
### SQL
Given the database schema, here is the SQL query that answers `When was the first game associated with over 4 losses?`:
```sql
|
SELECT MIN("drawn") FROM "rugby_russia_internationals_1994" WHERE "played">39; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest number of games drawn associated with over 39 games played?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "rugby_russia_internationals_1994" (
"first_game" real,
"played" real,
"drawn" real,
"lost" real,
"percentage" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest number of games drawn associated with over 39 games played?`:
```sql
|
SELECT MAX("lost") FROM "rugby_russia_internationals_1994" WHERE "played"<1; |
## Task
Generate a SQL query to answer the following question:
`What is the highest number of losses when there are under 1 games played?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "rugby_russia_internationals_1994" (
"first_game" real,
"played" real,
"drawn" real,
"lost" real,
"percentage" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest number of losses when there are under 1 games played?`:
```sql
|
SELECT "location" FROM "summary" WHERE "game">2 AND "time"='2:56'; |
## Task
Generate a SQL query to answer the following question:
`What location has more than 2 games with 2:56?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "summary" (
"game" real,
"date" text,
"location" text,
"time" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What location has more than 2 games with 2:56?`:
```sql
|
SELECT "location" FROM "summary" WHERE "date"='october 10'; |
## Task
Generate a SQL query to answer the following question:
`What location has October 10 as date?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "summary" (
"game" real,
"date" text,
"location" text,
"time" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What location has October 10 as date?`:
```sql
|
SELECT MAX("seats_2006") FROM "community_council" WHERE "pct_2001"=39 AND "seats_2001"<12; |
## Task
Generate a SQL query to answer the following question:
`what is the seats 2006 total with %2001 of 39 and seats 2001 less than 12?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "community_council" (
"parties_and_voter_communities" text,
"pct_2006" real,
"seats_2006" real,
"pct_2001" real,
"seats_2001" real
);
### SQL
Given the database schema, here is the SQL query that answers `what is the seats 2006 total with %2001 of 39 and seats 2001 less than 12?`:
```sql
|
SELECT SUM("seats_2006") FROM "community_council" WHERE "parties_and_voter_communities"='voter turnout in %' AND "pct_2006">51.5; |
## Task
Generate a SQL query to answer the following question:
`what is the total number of seats 2006 that has parties and voter turnout in % and whose %2006 is greater than 51.5?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "community_council" (
"parties_and_voter_communities" text,
"pct_2006" real,
"seats_2006" real,
"pct_2001" real,
"seats_2001" real
);
### SQL
Given the database schema, here is the SQL query that answers `what is the total number of seats 2006 that has parties and voter turnout in % and whose %2006 is greater than 51.5?`:
```sql
|
SELECT SUM("seats_2001") FROM "community_council" WHERE "parties_and_voter_communities"='cdu' AND "seats_2006">10; |
## Task
Generate a SQL query to answer the following question:
`what is the total number of seats 2001 with seats 2006 more than 10 and voter communities of cdu?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "community_council" (
"parties_and_voter_communities" text,
"pct_2006" real,
"seats_2006" real,
"pct_2001" real,
"seats_2001" real
);
### SQL
Given the database schema, here is the SQL query that answers `what is the total number of seats 2001 with seats 2006 more than 10 and voter communities of cdu?`:
```sql
|
SELECT "loss" FROM "game_log" WHERE "record"='3β2'; |
## Task
Generate a SQL query to answer the following question:
`What was the loss of the game when the record was 3β2?`
### 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,
"stadium" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the loss of the game when the record was 3β2?`:
```sql
|
SELECT "opponent" FROM "game_log" WHERE "loss"='shields (1β1)'; |
## Task
Generate a SQL query to answer the following question:
`Who was the opponent at the game that had a loss of Shields (1β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,
"stadium" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the opponent at the game that had a loss of Shields (1β1)?`:
```sql
|
SELECT "opponent" FROM "highest_individual_score" WHERE "player"='andrew symonds' AND "season"='2004'; |
## Task
Generate a SQL query to answer the following question:
`Who is the opponent for Andrew Symonds in the 2004 season?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "highest_individual_score" (
"runs" text,
"player" text,
"opponent" text,
"venue" text,
"season" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the opponent for Andrew Symonds in the 2004 season?`:
```sql
|
SELECT "country_of_origin" FROM "75_million_to_79_million_records" WHERE "artist"='journey'; |
## Task
Generate a SQL query to answer the following question:
`Name th country of origin for journey`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "75_million_to_79_million_records" (
"artist" text,
"country_of_origin" text,
"period_active" text,
"release_year_of_first_charted_record" real,
"genre" text,
"claimed_sales" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name th country of origin for journey`:
```sql
|
SELECT "period_active" FROM "75_million_to_79_million_records" WHERE "artist"='enya'; |
## Task
Generate a SQL query to answer the following question:
`Name the period active for enya`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "75_million_to_79_million_records" (
"artist" text,
"country_of_origin" text,
"period_active" text,
"release_year_of_first_charted_record" real,
"genre" text,
"claimed_sales" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the period active for enya`:
```sql
|
SELECT "genre" FROM "75_million_to_79_million_records" WHERE "release_year_of_first_charted_record"<1980 AND "country_of_origin"='jamaica'; |
## Task
Generate a SQL query to answer the following question:
`Name the genre for release-year of firsst charted less than 1980 and origin of jamaica`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "75_million_to_79_million_records" (
"artist" text,
"country_of_origin" text,
"period_active" text,
"release_year_of_first_charted_record" real,
"genre" text,
"claimed_sales" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the genre for release-year of firsst charted less than 1980 and origin of jamaica`:
```sql
|
SELECT "election" FROM "members_of_parliament" WHERE "1st_member"='constituency abolished'; |
## Task
Generate a SQL query to answer the following question:
`In which election was the constituency abolished?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "members_of_parliament" (
"election" text,
"1st_member" text,
"1st_party" text,
"2nd_member" text,
"2nd_party" text
);
### SQL
Given the database schema, here is the SQL query that answers `In which election was the constituency abolished?`:
```sql
|
SELECT "1st_party" FROM "members_of_parliament" WHERE "1st_member"='john willis fleming'; |
## Task
Generate a SQL query to answer the following question:
`What was the 1st party with a 1st member of John Willis Fleming?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "members_of_parliament" (
"election" text,
"1st_member" text,
"1st_party" text,
"2nd_member" text,
"2nd_party" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the 1st party with a 1st member of John Willis Fleming?`:
```sql
|
SELECT "1st_party" FROM "members_of_parliament" WHERE "2nd_party"='constituency abolished'; |
## Task
Generate a SQL query to answer the following question:
`What is the 1st party when the 2nd party is constituency abolished?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "members_of_parliament" (
"election" text,
"1st_member" text,
"1st_party" text,
"2nd_member" text,
"2nd_party" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 1st party when the 2nd party is constituency abolished?`:
```sql
|
SELECT "2nd_member" FROM "members_of_parliament" WHERE "election"='1885'; |
## Task
Generate a SQL query to answer the following question:
`Who is the 2nd member during 1885 election?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "members_of_parliament" (
"election" text,
"1st_member" text,
"1st_party" text,
"2nd_member" text,
"2nd_party" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the 2nd member during 1885 election?`:
```sql
|
SELECT "1st_party" FROM "members_of_parliament" WHERE "election"='1857'; |
## Task
Generate a SQL query to answer the following question:
`What is the 1st party during the 1857 election?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "members_of_parliament" (
"election" text,
"1st_member" text,
"1st_party" text,
"2nd_member" text,
"2nd_party" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 1st party during the 1857 election?`:
```sql
|
SELECT "language" FROM "language" WHERE "percentage_pct"='2.54'; |
## Task
Generate a SQL query to answer the following question:
`Which language has the percentage of 2.54?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "language" (
"language" text,
"number" text,
"percentage_pct" text,
"males" text,
"females" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which language has the percentage of 2.54?`:
```sql
|
SELECT "females" FROM "language" WHERE "language"='polish'; |
## Task
Generate a SQL query to answer the following question:
`What is the number of females that has the Polish language?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "language" (
"language" text,
"number" text,
"percentage_pct" text,
"males" text,
"females" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the number of females that has the Polish language?`:
```sql
|
SELECT "males" FROM "language" WHERE "females"='62 331'; |
## Task
Generate a SQL query to answer the following question:
`What was the number of males that had the number females 62 331?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "language" (
"language" text,
"number" text,
"percentage_pct" text,
"males" text,
"females" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the number of males that had the number females 62 331?`:
```sql
|
SELECT "position" FROM "women" WHERE "class"='sophomore'; |
## Task
Generate a SQL query to answer the following question:
`Which position has a sophomore class?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "women" (
"season" text,
"player" text,
"school" text,
"position" text,
"class" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which position has a sophomore class?`:
```sql
|
SELECT MIN("preliminaries") FROM "final_competition_scores" WHERE "evening_gown"=8.472; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest Preliminary score of a contestant that has an Evening Gown score of 8.472?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "final_competition_scores" (
"state" text,
"preliminaries" real,
"interview" real,
"swimsuit" real,
"evening_gown" real,
"average" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest Preliminary score of a contestant that has an Evening Gown score of 8.472?`:
```sql
|
SELECT "set_3" FROM "pool_a" WHERE "set_1"='25β20'; |
## Task
Generate a SQL query to answer the following question:
`Which Set 3 has a Set 1 of 25β20?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "pool_a" (
"date" text,
"time" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Set 3 has a Set 1 of 25β20?`:
```sql
|
SELECT "set_3" FROM "pool_a" WHERE "time"='10:00' AND "set_2"='25β19'; |
## Task
Generate a SQL query to answer the following question:
`Which Set 3 has a Time of 10:00, and a Set 2 of 25β19?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "pool_a" (
"date" text,
"time" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Set 3 has a Time of 10:00, and a Set 2 of 25β19?`:
```sql
|
SELECT "set_1" FROM "pool_a" WHERE "set_3"='16β25'; |
## Task
Generate a SQL query to answer the following question:
`Which Set 1 has a Set 3 of 16β25?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "pool_a" (
"date" text,
"time" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Set 1 has a Set 3 of 16β25?`:
```sql
|
SELECT "set_3" FROM "pool_a" WHERE "score"='0β3' AND "time"='18:30' AND "date"='july 10'; |
## Task
Generate a SQL query to answer the following question:
`Which Set 3 has a Score of 0β3, a Time of 18:30, and a Date of july 10?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "pool_a" (
"date" text,
"time" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Set 3 has a Score of 0β3, a Time of 18:30, and a Date of july 10?`:
```sql
|
SELECT "score" FROM "pool_a" WHERE "set_2"='17β25' AND "total"='48β75'; |
## Task
Generate a SQL query to answer the following question:
`Which score has a Set 2 of 17β25, and a Total of 48β75?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "pool_a" (
"date" text,
"time" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which score has a Set 2 of 17β25, and a Total of 48β75?`:
```sql
|
SELECT "set_3" FROM "pool_a" WHERE "time"='10:00' AND "score"='3β2' AND "total"='113β102'; |
## Task
Generate a SQL query to answer the following question:
`Which set 3 has a Time of 10:00, and a Score of 3β2, and a Total of 113β102?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "pool_a" (
"date" text,
"time" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which set 3 has a Time of 10:00, and a Score of 3β2, and a Total of 113β102?`:
```sql
|
SELECT "live_studio" FROM "discography" WHERE "year"<1983; |
## Task
Generate a SQL query to answer the following question:
`Is it live or studio before 1983?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "discography" (
"year" real,
"title" text,
"role" text,
"cast" text,
"live_studio" text,
"label" text
);
### SQL
Given the database schema, here is the SQL query that answers `Is it live or studio before 1983?`:
```sql
|
SELECT COUNT("1st_prize") FROM "winners" WHERE "country"='united states' AND "score"<271 AND "year">1964 AND "winner"='bobby mitchell'; |
## Task
Generate a SQL query to answer the following question:
`What is the total number of 1st prize ($) that has a United States country with a score lower than 271 and in a year after 1964 with a winner of Bobby Mitchell?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "winners" (
"year" real,
"winner" text,
"country" text,
"score" real,
"to_par" text,
"1st_prize" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total number of 1st prize ($) that has a United States country with a score lower than 271 and in a year after 1964 with a winner of Bobby Mitchell?`:
```sql
|
SELECT SUM("round") FROM "indianapolis_colts_draft_history" WHERE "name"='marcus howard'; |
## Task
Generate a SQL query to answer the following question:
`What is the round for marcus howard?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indianapolis_colts_draft_history" (
"round" real,
"pick_num" real,
"overall" real,
"name" text,
"position" text,
"college" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the round for marcus howard?`:
```sql
|
SELECT MAX("laps") FROM "indy_500_results" WHERE "finish"='30'; |
## Task
Generate a SQL query to answer the following question:
`What is the highest laps with a 30 finish?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indy_500_results" (
"year" text,
"start" text,
"qual" text,
"rank" text,
"finish" text,
"laps" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest laps with a 30 finish?`:
```sql
|
SELECT "rank" FROM "indy_500_results" WHERE "qual"='150.163'; |
## Task
Generate a SQL query to answer the following question:
`What is the rank of the 150.163 qual?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indy_500_results" (
"year" text,
"start" text,
"qual" text,
"rank" text,
"finish" text,
"laps" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the rank of the 150.163 qual?`:
```sql
|
SELECT MIN("laps") FROM "indy_500_results" WHERE "qual"='142.744'; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest laps with a 142.744 qual?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indy_500_results" (
"year" text,
"start" text,
"qual" text,
"rank" text,
"finish" text,
"laps" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest laps with a 142.744 qual?`:
```sql
|
SELECT "year" FROM "indy_500_results" WHERE "laps"<160 AND "rank"='26'; |
## Task
Generate a SQL query to answer the following question:
`What year had less than 160 laps and a rank of 26?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indy_500_results" (
"year" text,
"start" text,
"qual" text,
"rank" text,
"finish" text,
"laps" real
);
### SQL
Given the database schema, here is the SQL query that answers `What year had less than 160 laps and a rank of 26?`:
```sql
|
SELECT "khmer" FROM "numbers_from_0_5" WHERE "other"='soun'; |
## Task
Generate a SQL query to answer the following question:
`for the other of soun, what's the khmer?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "numbers_from_0_5" (
"value" real,
"khmer" real,
"word_form" text,
"ungegn" text,
"ala_lc" text,
"other" text
);
### SQL
Given the database schema, here is the SQL query that answers `for the other of soun, what's the khmer?`:
```sql
|
SELECT "khmer" FROM "numbers_from_0_5" WHERE "other"='mouy'; |
## Task
Generate a SQL query to answer the following question:
`for the other of mouy, what's the khmer?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "numbers_from_0_5" (
"value" real,
"khmer" real,
"word_form" text,
"ungegn" text,
"ala_lc" text,
"other" text
);
### SQL
Given the database schema, here is the SQL query that answers `for the other of mouy, what's the khmer?`:
```sql
|
SELECT "language" FROM "references" WHERE "director"='hans kristensen'; |
## Task
Generate a SQL query to answer the following question:
`What is the language of the film directed by Hans Kristensen?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"country" text,
"film_title_used_in_nomination" text,
"language" text,
"original_title" text,
"director" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the language of the film directed by Hans Kristensen?`:
```sql
|
SELECT "original_title" FROM "references" WHERE "film_title_used_in_nomination"='dersu uzala'; |
## Task
Generate a SQL query to answer the following question:
`What is the original title of the film for which Dersu Uzala was nominated?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"country" text,
"film_title_used_in_nomination" text,
"language" text,
"original_title" text,
"director" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the original title of the film for which Dersu Uzala was nominated?`:
```sql
|
SELECT "language" FROM "references" WHERE "country"='argentina'; |
## Task
Generate a SQL query to answer the following question:
`What is Argentina's language?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"country" text,
"film_title_used_in_nomination" text,
"language" text,
"original_title" text,
"director" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is Argentina's language?`:
```sql
|
SELECT "chassis" FROM "complete_formula_one_world_championship_" WHERE "year">1985 AND "entrant"='jolly club spa'; |
## Task
Generate a SQL query to answer the following question:
`What chassis did Jolly Club Spa used after 1985?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "complete_formula_one_world_championship_" (
"year" real,
"entrant" text,
"chassis" text,
"engine" text,
"tyres" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What chassis did Jolly Club Spa used after 1985?`:
```sql
|
SELECT "engine" FROM "complete_formula_one_world_championship_" WHERE "chassis"='minardi m187'; |
## Task
Generate a SQL query to answer the following question:
`What engine was paired with Minardi m187?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "complete_formula_one_world_championship_" (
"year" real,
"entrant" text,
"chassis" text,
"engine" text,
"tyres" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What engine was paired with Minardi m187?`:
```sql
|
SELECT MAX("points") FROM "complete_formula_one_world_championship_" WHERE "tyres"='g' AND "chassis"='minardi m187'; |
## Task
Generate a SQL query to answer the following question:
`What is the highest points with g Tyres and Minardi m187?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "complete_formula_one_world_championship_" (
"year" real,
"entrant" text,
"chassis" text,
"engine" text,
"tyres" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest points with g Tyres and Minardi m187?`:
```sql
|
SELECT "chassis" FROM "complete_formula_one_world_championship_" WHERE "tyres"='g' AND "year"<1987; |
## Task
Generate a SQL query to answer the following question:
`What Chassis has g Tyres before 1987?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "complete_formula_one_world_championship_" (
"year" real,
"entrant" text,
"chassis" text,
"engine" text,
"tyres" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What Chassis has g Tyres before 1987?`:
```sql
|
SELECT AVG("year") FROM "complete_formula_one_world_championship_" WHERE "tyres"='g' AND "chassis"='minardi m187'; |
## Task
Generate a SQL query to answer the following question:
`How many years were g Tyres and Minardi m187 used?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "complete_formula_one_world_championship_" (
"year" real,
"entrant" text,
"chassis" text,
"engine" text,
"tyres" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many years were g Tyres and Minardi m187 used?`:
```sql
|
SELECT "engine" FROM "complete_american_le_mans_series_results" WHERE "rank"='1st' AND "entrant"='adt champion racing'; |
## Task
Generate a SQL query to answer the following question:
`What engine what in the vehicle when adt champion racing ranked in 1st place?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "complete_american_le_mans_series_results" (
"year" real,
"entrant" text,
"class" text,
"chassis" text,
"engine" text,
"tyres" text,
"rank" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What engine what in the vehicle when adt champion racing ranked in 1st place?`:
```sql
|
SELECT "chassis" FROM "complete_american_le_mans_series_results" WHERE "rank"='18th'; |
## Task
Generate a SQL query to answer the following question:
`What Chassis ranked 18th?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "complete_american_le_mans_series_results" (
"year" real,
"entrant" text,
"class" text,
"chassis" text,
"engine" text,
"tyres" text,
"rank" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What Chassis ranked 18th?`:
```sql
|
SELECT "class" FROM "complete_american_le_mans_series_results" WHERE "points"<206 AND "chassis"='audi r8' AND "entrant"='adt champion racing' AND "rank"='1st'; |
## Task
Generate a SQL query to answer the following question:
`What was the class when adt champion racing ranked 1st with an audi r8 chassis, and less than 206 points?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "complete_american_le_mans_series_results" (
"year" real,
"entrant" text,
"class" text,
"chassis" text,
"engine" text,
"tyres" text,
"rank" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What was the class when adt champion racing ranked 1st with an audi r8 chassis, and less than 206 points?`:
```sql
|
SELECT "winner_nominee_s" FROM "nickelodeon_movies" WHERE "year"=2001; |
## Task
Generate a SQL query to answer the following question:
`Who were the winner and nominees in 2001?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nickelodeon_movies" (
"year" real,
"category" text,
"film" text,
"winner_nominee_s" text,
"result" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who were the winner and nominees in 2001?`:
```sql
|
SELECT "winner_nominee_s" FROM "nickelodeon_movies" WHERE "result"='nominated' AND "film"='rugrats go wild'; |
## Task
Generate a SQL query to answer the following question:
`Who is nominated for the film Rugrats Go Wild?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nickelodeon_movies" (
"year" real,
"category" text,
"film" text,
"winner_nominee_s" text,
"result" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is nominated for the film Rugrats Go Wild?`:
```sql
|
SELECT COUNT("goals") FROM "statistics" WHERE "apps"<26 AND "club"='werder bremen'; |
## Task
Generate a SQL query to answer the following question:
`How many goals did he score with under 26 appearances for werder bremen?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "statistics" (
"season" text,
"club" text,
"country" text,
"competition" text,
"apps" real,
"goals" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many goals did he score with under 26 appearances for werder bremen?`:
```sql
|
SELECT AVG("goals") FROM "statistics" WHERE "competition"='bundesliga' AND "apps"<7; |
## Task
Generate a SQL query to answer the following question:
`How many goals did he have in the bundesliga with under 7 appearances?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "statistics" (
"season" text,
"club" text,
"country" text,
"competition" text,
"apps" real,
"goals" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many goals did he have in the bundesliga with under 7 appearances?`:
```sql
|
SELECT "season" FROM "statistics" WHERE "apps"=7; |
## Task
Generate a SQL query to answer the following question:
`What season did he have 7 appearances?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "statistics" (
"season" text,
"club" text,
"country" text,
"competition" text,
"apps" real,
"goals" real
);
### SQL
Given the database schema, here is the SQL query that answers `What season did he have 7 appearances?`:
```sql
|
SELECT "to_par" FROM "second_round" WHERE "score"='73-71=144'; |
## Task
Generate a SQL query to answer the following question:
`What is the to par for the score 73-71=144?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "second_round" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the to par for the score 73-71=144?`:
```sql
|
SELECT "place" FROM "second_round" WHERE "player"='julius boros'; |
## Task
Generate a SQL query to answer the following question:
`What area did Julius Boros play at?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "second_round" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text
);
### SQL
Given the database schema, here is the SQL query that answers `What area did Julius Boros play at?`:
```sql
|
SELECT "country" FROM "second_round" WHERE "score"='74-70=144'; |
## Task
Generate a SQL query to answer the following question:
`What country has a score of 74-70=144`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "second_round" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text
);
### SQL
Given the database schema, here is the SQL query that answers `What country has a score of 74-70=144`:
```sql
|
SELECT "canterbury" FROM "highest_partnerships" WHERE "central_districts"='276* m.d. crowe & p.s. briasco v (c) 1986/87'; |
## Task
Generate a SQL query to answer the following question:
`Which of the Canterbury has a Central District of 276* M.D. Crowe & P.S. Briasco V (C) 1986/87?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "highest_partnerships" (
"auckland" text,
"canterbury" text,
"central_districts" text,
"otago" text,
"wellington" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which of the Canterbury has a Central District of 276* M.D. Crowe & P.S. Briasco V (C) 1986/87?`:
```sql
|
SELECT "auckland" FROM "highest_partnerships" WHERE "otago"='184 r.c. blunt & w. hawksworth v (c) 1931/32'; |
## Task
Generate a SQL query to answer the following question:
`What is Auckland thats got Otago of 184 R.C. Blunt & W. Hawksworth V (C) 1931/32?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "highest_partnerships" (
"auckland" text,
"canterbury" text,
"central_districts" text,
"otago" text,
"wellington" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is Auckland thats got Otago of 184 R.C. Blunt & W. Hawksworth V (C) 1931/32?`:
```sql
|
SELECT "tournament" FROM "achievements" WHERE "year">2009; |
## Task
Generate a SQL query to answer the following question:
`What tournament was after 2009?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "achievements" (
"year" real,
"tournament" text,
"venue" text,
"result" text,
"event" text
);
### SQL
Given the database schema, here is the SQL query that answers `What tournament was after 2009?`:
```sql
|
SELECT "event" FROM "achievements" WHERE "venue"='chihuahua, mexico'; |
## Task
Generate a SQL query to answer the following question:
`What event was held in Chihuahua, Mexico?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "achievements" (
"year" real,
"tournament" text,
"venue" text,
"result" text,
"event" text
);
### SQL
Given the database schema, here is the SQL query that answers `What event was held in Chihuahua, Mexico?`:
```sql
|
SELECT COUNT("rank") FROM "with_population_above_1_million" WHERE "area_km_2"<'2,040' AND "population"<'1,234,596'; |
## Task
Generate a SQL query to answer the following question:
`Can you tell me the total number of Rank that has the Area (km 2) smaller than 2,040, and the Population smaller than 1,234,596?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "with_population_above_1_million" (
"rank" real,
"country_region" text,
"population" real,
"area_km_2" real,
"density_pop_per_km_2" real
);
### SQL
Given the database schema, here is the SQL query that answers `Can you tell me the total number of Rank that has the Area (km 2) smaller than 2,040, and the Population smaller than 1,234,596?`:
```sql
|
SELECT SUM("population") FROM "with_population_above_1_million" WHERE "country_region"='hong kong' AND "rank"<2; |
## Task
Generate a SQL query to answer the following question:
`Can you tell me the sun of Population that has the Country/Region of hong kong, and the Rank smaller than 2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "with_population_above_1_million" (
"rank" real,
"country_region" text,
"population" real,
"area_km_2" real,
"density_pop_per_km_2" real
);
### SQL
Given the database schema, here is the SQL query that answers `Can you tell me the sun of Population that has the Country/Region of hong kong, and the Rank smaller than 2?`:
```sql
|
SELECT "manager_1" FROM "personnel_and_kits" WHERE "shirt_sponsor"='hewlett-packard'; |
## Task
Generate a SQL query to answer the following question:
`Who is the manager with the Hewlett-Packard shirt sponsor?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "personnel_and_kits" (
"team" text,
"manager_1" text,
"captain" text,
"kit_manufacturer" text,
"shirt_sponsor" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the manager with the Hewlett-Packard shirt sponsor?`:
```sql
|
SELECT "captain" FROM "personnel_and_kits" WHERE "kit_manufacturer"='fox leisure'; |
## Task
Generate a SQL query to answer the following question:
`Who is the captain of the team that has a kit manufacturer of Fox Leisure?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "personnel_and_kits" (
"team" text,
"manager_1" text,
"captain" text,
"kit_manufacturer" text,
"shirt_sponsor" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the captain of the team that has a kit manufacturer of Fox Leisure?`:
```sql
|
SELECT "captain" FROM "personnel_and_kits" WHERE "shirt_sponsor"='one2one'; |
## Task
Generate a SQL query to answer the following question:
`One2one is the shirt sponsor for the captain of what team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "personnel_and_kits" (
"team" text,
"manager_1" text,
"captain" text,
"kit_manufacturer" text,
"shirt_sponsor" text
);
### SQL
Given the database schema, here is the SQL query that answers `One2one is the shirt sponsor for the captain of what team?`:
```sql
|
SELECT "kit_manufacturer" FROM "personnel_and_kits" WHERE "captain"='gareth southgate'; |
## Task
Generate a SQL query to answer the following question:
`What company is the kit manufacturer that Gareth Southgate belongs to?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "personnel_and_kits" (
"team" text,
"manager_1" text,
"captain" text,
"kit_manufacturer" text,
"shirt_sponsor" text
);
### SQL
Given the database schema, here is the SQL query that answers `What company is the kit manufacturer that Gareth Southgate belongs to?`:
```sql
|
SELECT "result" FROM "awards_and_honours" WHERE "year"=2010 AND "tournament"='world amateur championship'; |
## Task
Generate a SQL query to answer the following question:
`for the tournament of world amateur championship what was the result in 2010?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "awards_and_honours" (
"year" real,
"tournament" text,
"venue" text,
"result" text,
"event" text
);
### SQL
Given the database schema, here is the SQL query that answers `for the tournament of world amateur championship what was the result in 2010?`:
```sql
|
SELECT "location" FROM "junior_under_20_men" WHERE "rank">8 AND "date"='22 july 2011'; |
## Task
Generate a SQL query to answer the following question:
`Which location had a race that took place on 22 July 2011 and has a rank greater than 8?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "junior_under_20_men" (
"rank" real,
"fastest_time_s" real,
"wind_m_s" real,
"athlete" text,
"country" text,
"date" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which location had a race that took place on 22 July 2011 and has a rank greater than 8?`:
```sql
|
SELECT COUNT("gold_medals") FROM "percussion_scholastic_open_class" WHERE "total_medals"=2 AND "bronze_medals"<0; |
## Task
Generate a SQL query to answer the following question:
`How many gold medals for the school with 2 total medals and under 0 bronzes?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "percussion_scholastic_open_class" (
"ensemble" text,
"gold_medals" real,
"silver_medals" real,
"bronze_medals" real,
"total_medals" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many gold medals for the school with 2 total medals and under 0 bronzes?`:
```sql
|
SELECT COUNT("gold_medals") FROM "percussion_scholastic_open_class" WHERE "ensemble"='bellbrook hs' AND "silver_medals"<1; |
## Task
Generate a SQL query to answer the following question:
`How many gold medals for bellbrook HS with less than 1 silver?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "percussion_scholastic_open_class" (
"ensemble" text,
"gold_medals" real,
"silver_medals" real,
"bronze_medals" real,
"total_medals" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many gold medals for bellbrook HS with less than 1 silver?`:
```sql
|
SELECT "silver_medals" FROM "percussion_scholastic_open_class" WHERE "gold_medals"=2 AND "total_medals">2; |
## Task
Generate a SQL query to answer the following question:
`How many silvers for a school with 2 golds and over 2 total?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "percussion_scholastic_open_class" (
"ensemble" text,
"gold_medals" real,
"silver_medals" real,
"bronze_medals" real,
"total_medals" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many silvers for a school with 2 golds and over 2 total?`:
```sql
|
SELECT COUNT("gold_medals") FROM "percussion_scholastic_open_class" WHERE "total_medals"<1; |
## Task
Generate a SQL query to answer the following question:
`How many gold medals for the school with less than 1 total?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "percussion_scholastic_open_class" (
"ensemble" text,
"gold_medals" real,
"silver_medals" real,
"bronze_medals" real,
"total_medals" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many gold medals for the school with less than 1 total?`:
```sql
|
SELECT "entrant" FROM "formula_one_world_championship_results" WHERE "year"=1967; |
## Task
Generate a SQL query to answer the following question:
`What is the entrant for 1967?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "formula_one_world_championship_results" (
"year" real,
"entrant" text,
"chassis" text,
"engine" text,
"pts" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the entrant for 1967?`:
```sql
|
SELECT "entrant" FROM "formula_one_world_championship_results" WHERE "year">1963 AND "chassis"='eagle mk1'; |
## Task
Generate a SQL query to answer the following question:
`What ist he entrant later than 1963 with an eagle MK1 chassis?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "formula_one_world_championship_results" (
"year" real,
"entrant" text,
"chassis" text,
"engine" text,
"pts" text
);
### SQL
Given the database schema, here is the SQL query that answers `What ist he entrant later than 1963 with an eagle MK1 chassis?`:
```sql
|
SELECT "entrant" FROM "formula_one_world_championship_results" WHERE "pts"='0'; |
## Task
Generate a SQL query to answer the following question:
`What is the entrant that has 0 points?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "formula_one_world_championship_results" (
"year" real,
"entrant" text,
"chassis" text,
"engine" text,
"pts" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the entrant that has 0 points?`:
```sql
|
SELECT MIN("year") FROM "formula_one_world_championship_results" WHERE "pts"='16'; |
## Task
Generate a SQL query to answer the following question:
`What is the earliest year with 16 points?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "formula_one_world_championship_results" (
"year" real,
"entrant" text,
"chassis" text,
"engine" text,
"pts" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the earliest year with 16 points?`:
```sql
|
SELECT "venue" FROM "biggest_wins" WHERE "margin"<66 AND "opponent"='north queensland cowboys'; |
## Task
Generate a SQL query to answer the following question:
`Name the venue for margin less than 66 and opponent of north queensland cowboys`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "biggest_wins" (
"margin" real,
"score" text,
"opponent" text,
"venue" text,
"year" real
);
### SQL
Given the database schema, here is the SQL query that answers `Name the venue for margin less than 66 and opponent of north queensland cowboys`:
```sql
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.