output stringlengths 27 479 | instruction stringlengths 407 1.39k |
|---|---|
SELECT "rank" FROM "tallest_buildings_and_structures" WHERE "floors"='01.0 87'; |
## Task
Generate a SQL query to answer the following question:
`What ranking is the structure with 01.0 87 floors?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "tallest_buildings_and_structures" (
"rank" text,
"name" text,
"height_metres_ft" text,
"floors" text,
"year" real
);
### SQL
Given the database schema, here is the SQL query that answers `What ranking is the structure with 01.0 87 floors?`:
```sql
|
SELECT MAX("attendance") FROM "schedule" WHERE "date"='oct. 26'; |
## Task
Generate a SQL query to answer the following question:
`What is the highest Attendance, when Date is "Oct. 26"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"game" real,
"date" text,
"opponent" text,
"result" text,
"raiders_points" real,
"opponents" real,
"raiders_first_downs" real,
"record" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest Attendance, when Date is "Oct. 26"?`:
```sql
|
SELECT MIN("opponents") FROM "schedule" WHERE "raiders_points">38 AND "attendance">'51,267'; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest Opponents, when Raiders Poinsts is greater than 38, and when Attendance is greater than 51,267?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"game" real,
"date" text,
"opponent" text,
"result" text,
"raiders_points" real,
"opponents" real,
"raiders_first_downs" real,
"record" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest Opponents, when Raiders Poinsts is greater than 38, and when Attendance is greater than 51,267?`:
```sql
|
SELECT COUNT("opponents") FROM "schedule" WHERE "raiders_points"=42 AND "attendance"<'52,505'; |
## Task
Generate a SQL query to answer the following question:
`What is the total number of Opponents, when Raiders Points is "42", when Attendance is less than 52,505?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"game" real,
"date" text,
"opponent" text,
"result" text,
"raiders_points" real,
"opponents" real,
"raiders_first_downs" real,
"record" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total number of Opponents, when Raiders Points is "42", when Attendance is less than 52,505?`:
```sql
|
SELECT COUNT("raiders_first_downs") FROM "schedule" WHERE "date"='nov. 2' AND "raiders_points">42; |
## Task
Generate a SQL query to answer the following question:
`What is the total number of Raiders First Downs, when Date is "Nov. 2", and when Raiders Points is greater than 42?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"game" real,
"date" text,
"opponent" text,
"result" text,
"raiders_points" real,
"opponents" real,
"raiders_first_downs" real,
"record" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total number of Raiders First Downs, when Date is "Nov. 2", and when Raiders Points is greater than 42?`:
```sql
|
SELECT AVG("tournaments") FROM "fastest_progress_to_top_division" WHERE "highest_rank"='maegashira 1'; |
## Task
Generate a SQL query to answer the following question:
`What is the average Tournaments, when Highest Rank is "Maegashira 1"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fastest_progress_to_top_division" (
"name" text,
"tournaments" real,
"pro_debut" text,
"top_division_debut" text,
"highest_rank" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average Tournaments, when Highest Rank is "Maegashira 1"?`:
```sql
|
SELECT "top_division_debut" FROM "fastest_progress_to_top_division" WHERE "tournaments"=12 AND "name"='yamamotoyama'; |
## Task
Generate a SQL query to answer the following question:
`What is Top Division Debut, when Tournaments is "12", and when Name is "Yamamotoyama"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fastest_progress_to_top_division" (
"name" text,
"tournaments" real,
"pro_debut" text,
"top_division_debut" text,
"highest_rank" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is Top Division Debut, when Tournaments is "12", and when Name is "Yamamotoyama"?`:
```sql
|
SELECT MIN("tournaments") FROM "fastest_progress_to_top_division" WHERE "name"='baruto'; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest Tournaments, when Name is "Baruto"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fastest_progress_to_top_division" (
"name" text,
"tournaments" real,
"pro_debut" text,
"top_division_debut" text,
"highest_rank" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest Tournaments, when Name is "Baruto"?`:
```sql
|
SELECT MAX("tournaments") FROM "fastest_progress_to_top_division" WHERE "pro_debut"='july 2002'; |
## Task
Generate a SQL query to answer the following question:
`What is the highest Tournaments, when Pro Debut is "July 2002"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fastest_progress_to_top_division" (
"name" text,
"tournaments" real,
"pro_debut" text,
"top_division_debut" text,
"highest_rank" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest Tournaments, when Pro Debut is "July 2002"?`:
```sql
|
SELECT "pro_debut" FROM "fastest_progress_to_top_division" WHERE "tournaments">11 AND "highest_rank"='maegashira 1'; |
## Task
Generate a SQL query to answer the following question:
`What is Pro Debut, when Tournament is greater than 11, and when Highest Rank is "Maegashira 1"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fastest_progress_to_top_division" (
"name" text,
"tournaments" real,
"pro_debut" text,
"top_division_debut" text,
"highest_rank" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is Pro Debut, when Tournament is greater than 11, and when Highest Rank is "Maegashira 1"?`:
```sql
|
SELECT COUNT("league_cup_goals") FROM "appearances_and_goals" WHERE "total_goals"=0 AND "name"='delroy facey'; |
## Task
Generate a SQL query to answer the following question:
`How many League Cup Goals have 0 as the total goals, with delroy facey as the name?`
### 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" text,
"fa_cup_goals" real,
"league_cup_apps" text,
"league_cup_goals" real,
"total_apps" text,
"total_goals" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many League Cup Goals have 0 as the total goals, with delroy facey as the name?`:
```sql
|
SELECT COUNT("total_goals") FROM "appearances_and_goals" WHERE "total_apps"='0 (3)' AND "league_goals"<0; |
## Task
Generate a SQL query to answer the following question:
`How many total goals have 0 (3) as total apps, with league goals less than 0?`
### 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" text,
"fa_cup_goals" real,
"league_cup_apps" text,
"league_cup_goals" real,
"total_apps" text,
"total_goals" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many total goals have 0 (3) as total apps, with league goals less than 0?`:
```sql
|
SELECT MIN("league_goals") FROM "appearances_and_goals" WHERE "fa_cup_apps"='0' AND "total_apps"='1 (3)'; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest league goals that have 0 as the FA Cup Apps, with 1 (3) as totals apps?`
### 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" text,
"fa_cup_goals" real,
"league_cup_apps" text,
"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 goals that have 0 as the FA Cup Apps, with 1 (3) as totals apps?`:
```sql
|
SELECT "stockholm" FROM "juries" WHERE "malm"='2'; |
## Task
Generate a SQL query to answer the following question:
`What was Stockholm's score when Malmo scored 2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "juries" (
"song" text,
"international_jury" text,
"lule" text,
"ume" text,
"sundsvall" text,
"falun" text,
"karlstad" text,
"rebro" text,
"norrk_ping" text,
"g_teborg" text,
"v_xj" text,
"malm" text,
"stockholm" text,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What was Stockholm's score when Malmo scored 2?`:
```sql
|
SELECT "v_xj" FROM "juries" WHERE "karlstad"='1'; |
## Task
Generate a SQL query to answer the following question:
`What did Vaxjo score when Karlstad scored 1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "juries" (
"song" text,
"international_jury" text,
"lule" text,
"ume" text,
"sundsvall" text,
"falun" text,
"karlstad" text,
"rebro" text,
"norrk_ping" text,
"g_teborg" text,
"v_xj" text,
"malm" text,
"stockholm" text,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What did Vaxjo score when Karlstad scored 1?`:
```sql
|
SELECT "sundsvall" FROM "juries" WHERE "falun"='2'; |
## Task
Generate a SQL query to answer the following question:
`What did Sundsvall score when Falun scored 2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "juries" (
"song" text,
"international_jury" text,
"lule" text,
"ume" text,
"sundsvall" text,
"falun" text,
"karlstad" text,
"rebro" text,
"norrk_ping" text,
"g_teborg" text,
"v_xj" text,
"malm" text,
"stockholm" text,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What did Sundsvall score when Falun scored 2?`:
```sql
|
SELECT MAX("total") FROM "juries" WHERE "norrk_ping"='12'; |
## Task
Generate a SQL query to answer the following question:
`What was the highest total when Norrkoping scored 12?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "juries" (
"song" text,
"international_jury" text,
"lule" text,
"ume" text,
"sundsvall" text,
"falun" text,
"karlstad" text,
"rebro" text,
"norrk_ping" text,
"g_teborg" text,
"v_xj" text,
"malm" text,
"stockholm" text,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What was the highest total when Norrkoping scored 12?`:
```sql
|
SELECT "rebro" FROM "juries" WHERE "ume"='2'; |
## Task
Generate a SQL query to answer the following question:
`What did Orebro score when Umea scored 2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "juries" (
"song" text,
"international_jury" text,
"lule" text,
"ume" text,
"sundsvall" text,
"falun" text,
"karlstad" text,
"rebro" text,
"norrk_ping" text,
"g_teborg" text,
"v_xj" text,
"malm" text,
"stockholm" text,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What did Orebro score when Umea scored 2?`:
```sql
|
SELECT "result" FROM "schedule" WHERE "attendance"='80,886'; |
## Task
Generate a SQL query to answer the following question:
`What was the result of the game that was attended by 80,886 people?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"date" text,
"opponentnum" text,
"site" text,
"result" text,
"attendance" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the result of the game that was attended by 80,886 people?`:
```sql
|
SELECT "result" FROM "schedule" WHERE "attendance"='72,703'; |
## Task
Generate a SQL query to answer the following question:
`What was the result of the game that was attended by 72,703 people?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"date" text,
"opponentnum" text,
"site" text,
"result" text,
"attendance" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the result of the game that was attended by 72,703 people?`:
```sql
|
SELECT "result" FROM "schedule" WHERE "attendance"='41,650'; |
## Task
Generate a SQL query to answer the following question:
`What was the result of the game that was attended by 41,650 people?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"date" text,
"opponentnum" text,
"site" text,
"result" text,
"attendance" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the result of the game that was attended by 41,650 people?`:
```sql
|
SELECT "date" FROM "schedule" WHERE "opponentnum"='indiana'; |
## Task
Generate a SQL query to answer the following question:
`When was the game against Indiana?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"date" text,
"opponentnum" text,
"site" text,
"result" text,
"attendance" text
);
### SQL
Given the database schema, here is the SQL query that answers `When was the game against Indiana?`:
```sql
|
SELECT "country" FROM "first_round" WHERE "score">69 AND "player"='brian henninger'; |
## Task
Generate a SQL query to answer the following question:
`Which country is Brian Henninger from, who had a score larger than 69?`
### 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 `Which country is Brian Henninger from, who had a score larger than 69?`:
```sql
|
SELECT COUNT("score") FROM "first_round" WHERE "player"='darren clarke'; |
## Task
Generate a SQL query to answer the following question:
`What is Darren Clarke's total score?`
### 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 `What is Darren Clarke's total score?`:
```sql
|
SELECT "away_team" FROM "fourth_round_proper" WHERE "date"='9 february 1988'; |
## Task
Generate a SQL query to answer the following question:
`Who was the away team on 9 February 1988?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fourth_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 `Who was the away team on 9 February 1988?`:
```sql
|
SELECT "away_team" FROM "fourth_round_proper" WHERE "home_team"='everton' AND "date"='30 january 1988'; |
## Task
Generate a SQL query to answer the following question:
`Who was the away team on 30 January 1988, when the home team was Everton?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fourth_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 `Who was the away team on 30 January 1988, when the home team was Everton?`:
```sql
|
SELECT "date" FROM "fourth_round_proper" WHERE "tie_no"='2'; |
## Task
Generate a SQL query to answer the following question:
`On which date was the Tie no 2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fourth_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 `On which date was the Tie no 2?`:
```sql
|
SELECT "tie_no" FROM "fourth_round_proper" WHERE "home_team"='manchester united'; |
## Task
Generate a SQL query to answer the following question:
`What was the Tie no when Manchester United was the home team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fourth_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 Tie no when Manchester United was the home team?`:
```sql
|
SELECT "score" FROM "fourth_round_proper" WHERE "tie_no"='9'; |
## Task
Generate a SQL query to answer the following question:
`What was the score when the Tie no was 9?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fourth_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 when the Tie no was 9?`:
```sql
|
SELECT "away_team" FROM "upcoming_fixtures_and_results" WHERE "home_team"='mauritius'; |
## Task
Generate a SQL query to answer the following question:
`Which away team goes against the home team Mauritius?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "upcoming_fixtures_and_results" (
"date" text,
"tournament" text,
"location" text,
"home_team" text,
"away_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which away team goes against the home team Mauritius?`:
```sql
|
SELECT "away_team" FROM "upcoming_fixtures_and_results" WHERE "home_team"='zambia'; |
## Task
Generate a SQL query to answer the following question:
`Who is the away team that goes against Team Zambia?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "upcoming_fixtures_and_results" (
"date" text,
"tournament" text,
"location" text,
"home_team" text,
"away_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the away team that goes against Team Zambia?`:
```sql
|
SELECT "away_team" FROM "fifth_round_proper" WHERE "tie_no"='3'; |
## Task
Generate a SQL query to answer the following question:
`Which away team has Tie no 3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fifth_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 `Which away team has Tie no 3?`:
```sql
|
SELECT "away_team" FROM "fifth_round_proper" WHERE "home_team"='everton'; |
## Task
Generate a SQL query to answer the following question:
`What is the away team playing at Everton?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fifth_round_proper" (
"tie_no" text,
"home_team" text,
"score" text,
"away_team" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the away team playing at Everton?`:
```sql
|
SELECT "home_team" FROM "fifth_round_proper" WHERE "away_team"='bradford city'; |
## Task
Generate a SQL query to answer the following question:
`What is the home team that Bradford City is playing against?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fifth_round_proper" (
"tie_no" text,
"home_team" text,
"score" text,
"away_team" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the home team that Bradford City is playing against?`:
```sql
|
SELECT "location" FROM "mixed_martial_arts_record" WHERE "method"='decision (unanimous)' AND "res"='win x'; |
## Task
Generate a SQL query to answer the following question:
`Which Location has a Method of decision (unanimous), and Res of win x?`
### 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 `Which Location has a Method of decision (unanimous), and Res of win x?`:
```sql
|
SELECT "round" FROM "mixed_martial_arts_record" WHERE "time"='0:37'; |
## Task
Generate a SQL query to answer the following question:
`Which Round has a Time of 0:37?`
### 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 `Which Round has a Time of 0:37?`:
```sql
|
SELECT "res" FROM "mixed_martial_arts_record" WHERE "record"='16-6'; |
## Task
Generate a SQL query to answer the following question:
`Which result has a Record of 16-6?`
### 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 `Which result has a Record of 16-6?`:
```sql
|
SELECT "champion" FROM "1972_to_1982" WHERE "score"='9–1'; |
## Task
Generate a SQL query to answer the following question:
`What Champion had a Score of 9–1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1972_to_1982" (
"champion" text,
"score" text,
"runner_up" text,
"additional_participants" text,
"host_location_s" text
);
### SQL
Given the database schema, here is the SQL query that answers `What Champion had a Score of 9–1?`:
```sql
|
SELECT "score" FROM "final_leaderboard" WHERE "place"='3'; |
## Task
Generate a SQL query to answer the following question:
`What score has 3 as the place?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "final_leaderboard" (
"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 score has 3 as the place?`:
```sql
|
SELECT "player" FROM "final_leaderboard" WHERE "place"='t7' AND "country"='united states'; |
## Task
Generate a SQL query to answer the following question:
`What player has t7 as the place, with tje United States as the country?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "final_leaderboard" (
"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 player has t7 as the place, with tje United States as the country?`:
```sql
|
SELECT "score" FROM "final_leaderboard" WHERE "player"='hal sutton'; |
## Task
Generate a SQL query to answer the following question:
`What score has hal sutton as the player?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "final_leaderboard" (
"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 score has hal sutton as the player?`:
```sql
|
SELECT "artist" FROM "releases" WHERE "year"<2010 AND "format"='promotional 7\"'; |
## Task
Generate a SQL query to answer the following question:
`Who was the artist before 2010 with a Promotional 7" as a format?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "releases" (
"year" real,
"artist" text,
"title" text,
"format" text,
"type" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the artist before 2010 with a Promotional 7" as a format?`:
```sql
|
SELECT "artist" FROM "releases" WHERE "year">2012 AND "format"='cd, lp'; |
## Task
Generate a SQL query to answer the following question:
`Who was the artist after 2012 with CD, LP as the format?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "releases" (
"year" real,
"artist" text,
"title" text,
"format" text,
"type" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the artist after 2012 with CD, LP as the format?`:
```sql
|
SELECT AVG("year") FROM "releases" WHERE "type"='ep' AND "title"='die shaolin affen ep'; |
## Task
Generate a SQL query to answer the following question:
`What year had a title of Die Shaolin Affen EP and EP as the type?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "releases" (
"year" real,
"artist" text,
"title" text,
"format" text,
"type" text
);
### SQL
Given the database schema, here is the SQL query that answers `What year had a title of Die Shaolin Affen EP and EP as the type?`:
```sql
|
SELECT "title" FROM "releases" WHERE "format"='cd' AND "artist"='misfits'; |
## Task
Generate a SQL query to answer the following question:
`What is the title of the Misfits with a CD format?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "releases" (
"year" real,
"artist" text,
"title" text,
"format" text,
"type" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the title of the Misfits with a CD format?`:
```sql
|
SELECT MAX("bronze") FROM "medal_table" WHERE "rank"='2' AND "silver"<3; |
## Task
Generate a SQL query to answer the following question:
`What was the highest number of bronze medals for the entry with rank 2 and fewer than 3 silver medals?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medal_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 was the highest number of bronze medals for the entry with rank 2 and fewer than 3 silver medals?`:
```sql
|
SELECT AVG("gold") FROM "medal_table" WHERE "total"<4 AND "nation"='brazil' AND "bronze">1; |
## Task
Generate a SQL query to answer the following question:
`What is the average number of gold medals won by Brazil for entries with more than 1 bronze medal but a total smaller than 4?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medal_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 average number of gold medals won by Brazil for entries with more than 1 bronze medal but a total smaller than 4?`:
```sql
|
SELECT SUM("silver") FROM "medal_table" WHERE "total"=4 AND "rank"='3'; |
## Task
Generate a SQL query to answer the following question:
`What is the sum of silver medals for the entry with rank 3 and a total of 4 medals?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "medal_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 sum of silver medals for the entry with rank 3 and a total of 4 medals?`:
```sql
|
SELECT "3_30_pm" FROM "fall_2001" WHERE "1_00_pm"='all my children'; |
## Task
Generate a SQL query to answer the following question:
`What shows for 3:30 pm when 1:00 is All My Children?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fall_2001" (
"7_00_am" text,
"9_00_am" text,
"10_00_am" text,
"11_00_am" text,
"noon" text,
"12_30_pm" text,
"1_00_pm" text,
"1_30_pm" text,
"2_00_pm" text,
"2_30_pm" text,
"3_30_pm" text,
"4_30_pm" text,
"5_00_pm" text,
"6_30_pm" text
);
### SQL
Given the database schema, here is the SQL query that answers `What shows for 3:30 pm when 1:00 is All My Children?`:
```sql
|
SELECT "6_30_pm" FROM "fall_2001" WHERE "2_00_pm"='local programs'; |
## Task
Generate a SQL query to answer the following question:
`What shows for 3:30 pm when 2:00 pm is local programs?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fall_2001" (
"7_00_am" text,
"9_00_am" text,
"10_00_am" text,
"11_00_am" text,
"noon" text,
"12_30_pm" text,
"1_00_pm" text,
"1_30_pm" text,
"2_00_pm" text,
"2_30_pm" text,
"3_30_pm" text,
"4_30_pm" text,
"5_00_pm" text,
"6_30_pm" text
);
### SQL
Given the database schema, here is the SQL query that answers `What shows for 3:30 pm when 2:00 pm is local programs?`:
```sql
|
SELECT "3_30_pm" FROM "fall_2001" WHERE "1_30_pm"='the bold and the beautiful'; |
## Task
Generate a SQL query to answer the following question:
`What shows for 3:30 pm when 1:30 pm is the bold and the beautiful?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fall_2001" (
"7_00_am" text,
"9_00_am" text,
"10_00_am" text,
"11_00_am" text,
"noon" text,
"12_30_pm" text,
"1_00_pm" text,
"1_30_pm" text,
"2_00_pm" text,
"2_30_pm" text,
"3_30_pm" text,
"4_30_pm" text,
"5_00_pm" text,
"6_30_pm" text
);
### SQL
Given the database schema, here is the SQL query that answers `What shows for 3:30 pm when 1:30 pm is the bold and the beautiful?`:
```sql
|
SELECT "11_00_am" FROM "fall_2001" WHERE "1_30_pm"='local programs' AND "7_00_am"='local programs'; |
## Task
Generate a SQL query to answer the following question:
`What shows for 3:30 pm when 1:30 pm is local programs, and a 7:00 am is local programs?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fall_2001" (
"7_00_am" text,
"9_00_am" text,
"10_00_am" text,
"11_00_am" text,
"noon" text,
"12_30_pm" text,
"1_00_pm" text,
"1_30_pm" text,
"2_00_pm" text,
"2_30_pm" text,
"3_30_pm" text,
"4_30_pm" text,
"5_00_pm" text,
"6_30_pm" text
);
### SQL
Given the database schema, here is the SQL query that answers `What shows for 3:30 pm when 1:30 pm is local programs, and a 7:00 am is local programs?`:
```sql
|
SELECT "noon" FROM "fall_2001" WHERE "12_30_pm"='the young and the restless'; |
## Task
Generate a SQL query to answer the following question:
`What shows for 3:30 pm when 12:30 pm is the young and the restless?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fall_2001" (
"7_00_am" text,
"9_00_am" text,
"10_00_am" text,
"11_00_am" text,
"noon" text,
"12_30_pm" text,
"1_00_pm" text,
"1_30_pm" text,
"2_00_pm" text,
"2_30_pm" text,
"3_30_pm" text,
"4_30_pm" text,
"5_00_pm" text,
"6_30_pm" text
);
### SQL
Given the database schema, here is the SQL query that answers `What shows for 3:30 pm when 12:30 pm is the young and the restless?`:
```sql
|
SELECT "5_00_pm" FROM "fall_2001" WHERE "2_30_pm"='local programs'; |
## Task
Generate a SQL query to answer the following question:
`What shows for 3:30 pm when 2:30 pm is local programs?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fall_2001" (
"7_00_am" text,
"9_00_am" text,
"10_00_am" text,
"11_00_am" text,
"noon" text,
"12_30_pm" text,
"1_00_pm" text,
"1_30_pm" text,
"2_00_pm" text,
"2_30_pm" text,
"3_30_pm" text,
"4_30_pm" text,
"5_00_pm" text,
"6_30_pm" text
);
### SQL
Given the database schema, here is the SQL query that answers `What shows for 3:30 pm when 2:30 pm is local programs?`:
```sql
|
SELECT "season" FROM "statistics" WHERE "goals"='1'; |
## Task
Generate a SQL query to answer the following question:
`What season had a goal of 1?`
### 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,
"apps" text,
"goals" text
);
### SQL
Given the database schema, here is the SQL query that answers `What season had a goal of 1?`:
```sql
|
SELECT "club" FROM "statistics" WHERE "country"='netherlands' AND "goals"='22'; |
## Task
Generate a SQL query to answer the following question:
`What club was in Netherlands and had 22 goals?`
### 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,
"apps" text,
"goals" text
);
### SQL
Given the database schema, here is the SQL query that answers `What club was in Netherlands and had 22 goals?`:
```sql
|
SELECT "season" FROM "statistics" WHERE "country"='belgium' AND "goals"='1'; |
## Task
Generate a SQL query to answer the following question:
`What season had Belgium and 1 goal?`
### 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,
"apps" text,
"goals" text
);
### SQL
Given the database schema, here is the SQL query that answers `What season had Belgium and 1 goal?`:
```sql
|
SELECT MAX("year") FROM "awards" WHERE "category"='best film'; |
## Task
Generate a SQL query to answer the following question:
`Which Year has a Category of best film?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "awards" (
"year" real,
"nominated_work" text,
"award_s" text,
"category" text,
"result" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Year has a Category of best film?`:
```sql
|
SELECT "incumbent" FROM "washington" WHERE "party"='democratic' AND "district"='washington 7'; |
## Task
Generate a SQL query to answer the following question:
`Who is the incumbent from the democratic party in the washington 7 district?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "washington" (
"district" text,
"incumbent" text,
"party" text,
"first_elected" real,
"results" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the incumbent from the democratic party in the washington 7 district?`:
```sql
|
SELECT MIN("first_elected") FROM "washington" WHERE "incumbent"='dave reichert'; |
## Task
Generate a SQL query to answer the following question:
`When was the earliest incumbent dave reichert was first elected?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "washington" (
"district" text,
"incumbent" text,
"party" text,
"first_elected" real,
"results" text
);
### SQL
Given the database schema, here is the SQL query that answers `When was the earliest incumbent dave reichert was first elected?`:
```sql
|
SELECT COUNT("first_elected") FROM "washington" WHERE "incumbent"='norm dicks'; |
## Task
Generate a SQL query to answer the following question:
`What is the total of the first elected year of incumbent norm dicks?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "washington" (
"district" text,
"incumbent" text,
"party" text,
"first_elected" real,
"results" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total of the first elected year of incumbent norm dicks?`:
```sql
|
SELECT COUNT("first_elected") FROM "washington" WHERE "district"='washington 8'; |
## Task
Generate a SQL query to answer the following question:
`What is the total of the first elected year of the incumbent from the washington 8 district?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "washington" (
"district" text,
"incumbent" text,
"party" text,
"first_elected" real,
"results" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total of the first elected year of the incumbent from the washington 8 district?`:
```sql
|
SELECT MAX("start") FROM "daytona_500_results" WHERE "finish">3 AND "manufacturer"='ford' AND "year">1969; |
## Task
Generate a SQL query to answer the following question:
`WHAT IS THE START THAT HAS A FINISH BIGGER THAN 3, FROM FORD, AFTER 1969?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "daytona_500_results" (
"year" real,
"manufacturer" text,
"start" real,
"finish" real,
"team" text
);
### SQL
Given the database schema, here is the SQL query that answers `WHAT IS THE START THAT HAS A FINISH BIGGER THAN 3, FROM FORD, AFTER 1969?`:
```sql
|
SELECT "manufacturer" FROM "daytona_500_results" WHERE "year">1966 AND "start"<5 AND "team"='wood' AND "finish"=35; |
## Task
Generate a SQL query to answer the following question:
`WHAT MANUFACTURER AFTER 1966 HAD A START SMALLER THAN 5, A WOOD TEAM AND FINISHED 35?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "daytona_500_results" (
"year" real,
"manufacturer" text,
"start" real,
"finish" real,
"team" text
);
### SQL
Given the database schema, here is the SQL query that answers `WHAT MANUFACTURER AFTER 1966 HAD A START SMALLER THAN 5, A WOOD TEAM AND FINISHED 35?`:
```sql
|
SELECT COUNT("finish") FROM "daytona_500_results" WHERE "start"<20 AND "year"=1969; |
## Task
Generate a SQL query to answer the following question:
`WHAT WAS THE FINISH NUMBER WITH A START SMALLER THAN 20 IN 1969?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "daytona_500_results" (
"year" real,
"manufacturer" text,
"start" real,
"finish" real,
"team" text
);
### SQL
Given the database schema, here is the SQL query that answers `WHAT WAS THE FINISH NUMBER WITH A START SMALLER THAN 20 IN 1969?`:
```sql
|
SELECT COUNT("pleasure") FROM "addictive_potential" WHERE "psychological_dependence">1.9 AND "drug"='benzodiazepines'; |
## Task
Generate a SQL query to answer the following question:
`What is the total number of Pleasure(s), when Psychological Dependence is greater than 1.9, and when Drug is "Benzodiazepines"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "addictive_potential" (
"drug" text,
"mean" real,
"pleasure" real,
"psychological_dependence" real,
"physical_dependence" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total number of Pleasure(s), when Psychological Dependence is greater than 1.9, and when Drug is "Benzodiazepines"?`:
```sql
|
SELECT MAX("psychological_dependence") FROM "addictive_potential" WHERE "pleasure"<2.3 AND "drug"='cannabis' AND "physical_dependence"<0.8; |
## Task
Generate a SQL query to answer the following question:
`What is the highest Psychological Dependence, when Pleasure is less than 2.3, when Drug is "Cannabis", and when Physical Dependence is less than 0.8?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "addictive_potential" (
"drug" text,
"mean" real,
"pleasure" real,
"psychological_dependence" real,
"physical_dependence" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest Psychological Dependence, when Pleasure is less than 2.3, when Drug is "Cannabis", and when Physical Dependence is less than 0.8?`:
```sql
|
SELECT AVG("mean") FROM "addictive_potential" WHERE "drug"='alcohol' AND "psychological_dependence">1.9; |
## Task
Generate a SQL query to answer the following question:
`What is the average Mean, when Drug is "Alcohol", and when Psychological Dependence is greater than 1.9?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "addictive_potential" (
"drug" text,
"mean" real,
"pleasure" real,
"psychological_dependence" real,
"physical_dependence" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average Mean, when Drug is "Alcohol", and when Psychological Dependence is greater than 1.9?`:
```sql
|
SELECT COUNT("psychological_dependence") FROM "addictive_potential" WHERE "pleasure"=2.3 AND "mean"<1.9300000000000002; |
## Task
Generate a SQL query to answer the following question:
`What is the total number of Psychological Dependence, when Pleasure is "2.3", and when Mean is less than 1.9300000000000002?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "addictive_potential" (
"drug" text,
"mean" real,
"pleasure" real,
"psychological_dependence" real,
"physical_dependence" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total number of Psychological Dependence, when Pleasure is "2.3", and when Mean is less than 1.9300000000000002?`:
```sql
|
SELECT SUM("pleasure") FROM "addictive_potential" WHERE "drug"='lsd' AND "psychological_dependence">1.1; |
## Task
Generate a SQL query to answer the following question:
`What is the sum of Pleasure, when Drug is "LSD", and when Psychological Dependence is greater than 1.1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "addictive_potential" (
"drug" text,
"mean" real,
"pleasure" real,
"psychological_dependence" real,
"physical_dependence" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the sum of Pleasure, when Drug is "LSD", and when Psychological Dependence is greater than 1.1?`:
```sql
|
SELECT "country" FROM "qualified_teams" WHERE "domestic_tournament"='2008 indian premier league' AND "team"='rajasthan royals'; |
## Task
Generate a SQL query to answer the following question:
`What Country's team is Rajasthan Royals at the 2008 Indian Premier League?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "qualified_teams" (
"team" text,
"country" text,
"domestic_tournament" text,
"position" text,
"group" text
);
### SQL
Given the database schema, here is the SQL query that answers `What Country's team is Rajasthan Royals at the 2008 Indian Premier League?`:
```sql
|
SELECT "domestic_tournament" FROM "qualified_teams" WHERE "team"='chennai super kings'; |
## Task
Generate a SQL query to answer the following question:
`What is the Domestic Tournament with Chennai Super Kings Team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "qualified_teams" (
"team" text,
"country" text,
"domestic_tournament" text,
"position" text,
"group" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Domestic Tournament with Chennai Super Kings Team?`:
```sql
|
SELECT "group" FROM "qualified_teams" WHERE "team"='dolphins'; |
## Task
Generate a SQL query to answer the following question:
`What is the Dolphins Group?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "qualified_teams" (
"team" text,
"country" text,
"domestic_tournament" text,
"position" text,
"group" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Dolphins Group?`:
```sql
|
SELECT "player" FROM "missed_the_cut" WHERE "year_s_won"='1978'; |
## Task
Generate a SQL query to answer the following question:
`Who is the player that won in the year 1978?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "missed_the_cut" (
"player" text,
"country" text,
"year_s_won" text,
"total" real,
"to_par" real
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the player that won in the year 1978?`:
```sql
|
SELECT "country" FROM "final_leaderboard" WHERE "score"='73-71-76-70=290'; |
## Task
Generate a SQL query to answer the following question:
`What is the Country of the Player with a Score of 73-71-76-70=290?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Country of the Player with a Score of 73-71-76-70=290?`:
```sql
|
SELECT "money" FROM "final_leaderboard" WHERE "player"='lawson little'; |
## Task
Generate a SQL query to answer the following question:
`What is Lawson Little's Money ($) amount?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is Lawson Little's Money ($) amount?`:
```sql
|
SELECT "money" FROM "final_leaderboard" WHERE "to_par"='e'; |
## Task
Generate a SQL query to answer the following question:
`What is the Money ($) amount of the Player with a To par of e?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Money ($) amount of the Player with a To par of e?`:
```sql
|
SELECT "country" FROM "final_leaderboard" WHERE "money"='playoff' AND "score"='72-69-73-73=287'; |
## Task
Generate a SQL query to answer the following question:
`What Country has a Player with Playoff Money with a Score of 72-69-73-73=287?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" text
);
### SQL
Given the database schema, here is the SQL query that answers `What Country has a Player with Playoff Money with a Score of 72-69-73-73=287?`:
```sql
|
SELECT "place" FROM "final_leaderboard" WHERE "player"='ben hogan'; |
## Task
Generate a SQL query to answer the following question:
`What is Ben Hogan's Place?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is Ben Hogan's Place?`:
```sql
|
SELECT "place" FROM "final_leaderboard" WHERE "score"='73-75-71-73=292'; |
## Task
Generate a SQL query to answer the following question:
`What is the Place of the Player with a Score of 73-75-71-73=292?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Place of the Player with a Score of 73-75-71-73=292?`:
```sql
|
SELECT SUM("byes") FROM "2012_ladder" WHERE "wins"=11 AND "losses"<5; |
## Task
Generate a SQL query to answer the following question:
`How many byes when there are 11 wins and fewer than 5 losses?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2012_ladder" (
"central_murray" text,
"wins" real,
"byes" real,
"losses" real,
"draws" real,
"against" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many byes when there are 11 wins and fewer than 5 losses?`:
```sql
|
SELECT COUNT("losses") FROM "2012_ladder" WHERE "wins"<0; |
## Task
Generate a SQL query to answer the following question:
`How many losses when there are less than 0 wins?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2012_ladder" (
"central_murray" text,
"wins" real,
"byes" real,
"losses" real,
"draws" real,
"against" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many losses when there are less than 0 wins?`:
```sql
|
SELECT MAX("against") FROM "2012_ladder" WHERE "central_murray"='nyah nyah west utd' AND "losses">11; |
## Task
Generate a SQL query to answer the following question:
`What are the most againsts with more than 11 losses and central murray is Nyah Nyah West Utd?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2012_ladder" (
"central_murray" text,
"wins" real,
"byes" real,
"losses" real,
"draws" real,
"against" real
);
### SQL
Given the database schema, here is the SQL query that answers `What are the most againsts with more than 11 losses and central murray is Nyah Nyah West Utd?`:
```sql
|
SELECT "to_par" FROM "final_round" WHERE "money">'7,750'; |
## Task
Generate a SQL query to answer the following question:
`What is the To par of the player with Money of 7,750 or more?`
### 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 To par of the player with Money of 7,750 or more?`:
```sql
|
SELECT "provider" FROM "germany" WHERE "up_up_to_kbit_s"=1180; |
## Task
Generate a SQL query to answer the following question:
`who is the provider when up (up to kbit/s) is 1180?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "germany" (
"dsl_type" text,
"provider" text,
"resale" text,
"down_up_to_kbit_s" real,
"up_up_to_kbit_s" real
);
### SQL
Given the database schema, here is the SQL query that answers `who is the provider when up (up to kbit/s) is 1180?`:
```sql
|
SELECT MAX("down_up_to_kbit_s") FROM "germany" WHERE "resale"='yes' AND "up_up_to_kbit_s"=1180 AND "provider"='1&1'; |
## Task
Generate a SQL query to answer the following question:
`what is the highest down (up to kbits/s) when resale is yes, up ( up to kbit/s) is 1180 and provider is 1&1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "germany" (
"dsl_type" text,
"provider" text,
"resale" text,
"down_up_to_kbit_s" real,
"up_up_to_kbit_s" real
);
### SQL
Given the database schema, here is the SQL query that answers `what is the highest down (up to kbits/s) when resale is yes, up ( up to kbit/s) is 1180 and provider is 1&1?`:
```sql
|
SELECT "resale" FROM "germany" WHERE "down_up_to_kbit_s"=24000; |
## Task
Generate a SQL query to answer the following question:
`what is the resale when the down (up to kbit/s) is 24000?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "germany" (
"dsl_type" text,
"provider" text,
"resale" text,
"down_up_to_kbit_s" real,
"up_up_to_kbit_s" real
);
### SQL
Given the database schema, here is the SQL query that answers `what is the resale when the down (up to kbit/s) is 24000?`:
```sql
|
SELECT AVG("down_up_to_kbit_s") FROM "germany" WHERE "provider"='willy.tel' AND "up_up_to_kbit_s">1984; |
## Task
Generate a SQL query to answer the following question:
`What is the average down (up to kbit/s) when the provider is willy.tel and the up (kbit/s) is more than 1984?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "germany" (
"dsl_type" text,
"provider" text,
"resale" text,
"down_up_to_kbit_s" real,
"up_up_to_kbit_s" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average down (up to kbit/s) when the provider is willy.tel and the up (kbit/s) is more than 1984?`:
```sql
|
SELECT COUNT("total") FROM "medal_table" WHERE "gold">0 AND "bronze"<0; |
## Task
Generate a SQL query to answer the following question:
`How many totals have a Gold larger than 0, and a Bronze smaller 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 `How many totals have a Gold larger than 0, and a Bronze smaller than 0?`:
```sql
|
SELECT MAX("total") FROM "medal_table" WHERE "bronze">1 AND "gold">0; |
## Task
Generate a SQL query to answer the following question:
`Which Total has a Bronze larger than 1, and a Gold larger 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 `Which Total has a Bronze larger than 1, and a Gold larger than 0?`:
```sql
|
SELECT "nationality" FROM "draft_picks" WHERE "player"='eugene mcdowell'; |
## Task
Generate a SQL query to answer the following question:
`What country is Eugene McDowell from?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "draft_picks" (
"round" real,
"pick" real,
"player" text,
"nationality" text,
"school_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `What country is Eugene McDowell from?`:
```sql
|
SELECT MAX("pick") FROM "draft_picks" WHERE "player"='mario elie' AND "round"<7; |
## Task
Generate a SQL query to answer the following question:
`When was Mario Elie picked in a round before 7?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "draft_picks" (
"round" real,
"pick" real,
"player" text,
"nationality" text,
"school_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `When was Mario Elie picked in a round before 7?`:
```sql
|
SELECT COUNT("round") FROM "draft_picks" WHERE "school_club_team"='north carolina state' AND "pick">91; |
## Task
Generate a SQL query to answer the following question:
`In what round did someone from North Carolina State get picked larger than 91?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "draft_picks" (
"round" real,
"pick" real,
"player" text,
"nationality" text,
"school_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `In what round did someone from North Carolina State get picked larger than 91?`:
```sql
|
SELECT "results" FROM "awards" WHERE "category"='best new actor in lead role(female)'; |
## Task
Generate a SQL query to answer the following question:
`Which Results have a Category of the best new actor in lead role(female)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "awards" (
"year" real,
"award" text,
"category" text,
"show" text,
"character" text,
"results" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Results have a Category of the best new actor in lead role(female)?`:
```sql
|
SELECT "category" FROM "awards" WHERE "year"=2008; |
## Task
Generate a SQL query to answer the following question:
`What was the category in 2008?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "awards" (
"year" real,
"award" text,
"category" text,
"show" text,
"character" text,
"results" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the category in 2008?`:
```sql
|
SELECT "character" FROM "awards" WHERE "category"='favourite naya sadasya'; |
## Task
Generate a SQL query to answer the following question:
`Which Character has a Category of favourite naya sadasya?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "awards" (
"year" real,
"award" text,
"category" text,
"show" text,
"character" text,
"results" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Character has a Category of favourite naya sadasya?`:
```sql
|
SELECT "show" FROM "awards" WHERE "award"='indian television academy awards'; |
## Task
Generate a SQL query to answer the following question:
`Which Show has an Award of indian television academy awards?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "awards" (
"year" real,
"award" text,
"category" text,
"show" text,
"character" text,
"results" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Show has an Award of indian television academy awards?`:
```sql
|
SELECT "award" FROM "awards" WHERE "year">2008; |
## Task
Generate a SQL query to answer the following question:
`What award was won after 2008?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "awards" (
"year" real,
"award" text,
"category" text,
"show" text,
"character" text,
"results" text
);
### SQL
Given the database schema, here is the SQL query that answers `What award was won after 2008?`:
```sql
|
SELECT "date" FROM "school_massacres" WHERE "injured"='21'; |
## Task
Generate a SQL query to answer the following question:
`On what Date did the massacre result with 21 Injured?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "school_massacres" (
"perpetrator" text,
"date" text,
"year" real,
"location" text,
"country" text,
"killed" real,
"injured" text,
"additional_notes" text
);
### SQL
Given the database schema, here is the SQL query that answers `On what Date did the massacre result with 21 Injured?`:
```sql
|
SELECT "city_state" FROM "race_calendar" WHERE "winner"='rohan onslow' AND "circuit"='oran park raceway'; |
## Task
Generate a SQL query to answer the following question:
`What is City / State, when Winner is "Rohan Onslow", and when Circuit is "Oran Park Raceway"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "race_calendar" (
"circuit" text,
"city_state" text,
"date" text,
"winner" text,
"team" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is City / State, when Winner is "Rohan Onslow", and when Circuit is "Oran Park Raceway"?`:
```sql
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.