output stringlengths 27 479 | instruction stringlengths 407 1.39k |
|---|---|
SELECT "output" FROM "comparison_of_some_cameras_compatible_wi" WHERE "ir_le_ds"='no'; |
## Task
Generate a SQL query to answer the following question:
`What was the output with no IR LEDs?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "comparison_of_some_cameras_compatible_wi" (
"camera" text,
"sensor_resolution" text,
"sensor" text,
"output" text,
"cpu_usage" text,
"ir_le_ds" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the output with no IR LEDs?`:
```sql
|
SELECT "sensor" FROM "comparison_of_some_cameras_compatible_wi" WHERE "sensor_resolution"='640x480' AND "cpu_usage"='small' AND "output"='jpeg compressed' AND "camera"='sony playstation eyetoy'; |
## Task
Generate a SQL query to answer the following question:
`What sensor has a resolution of 640x480 with small CPU usage, jpeg compressed output and a camera of sony playstation eyetoy?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "comparison_of_some_cameras_compatible_wi" (
"camera" text,
"sensor_resolution" text,
"sensor" text,
"output" text,
"cpu_usage" text,
"ir_le_ds" text
);
### SQL
Given the database schema, here is the SQL query that answers `What sensor has a resolution of 640x480 with small CPU usage, jpeg compressed output and a camera of sony playstation eyetoy?`:
```sql
|
SELECT SUM("max_speed_km_h") FROM "diesel_multiple_units" WHERE "quantity_built"='8+4' AND "year_built"<1971; |
## Task
Generate a SQL query to answer the following question:
`What is the max speed of the unit with an 8+4 quantity built before 1971?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "diesel_multiple_units" (
"type" text,
"numbers" text,
"year_built" real,
"quantity_built" text,
"power_horsepower" real,
"max_speed_km_h" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the max speed of the unit with an 8+4 quantity built before 1971?`:
```sql
|
SELECT "numbers" FROM "diesel_multiple_units" WHERE "power_horsepower">220 AND "type"='thn'; |
## Task
Generate a SQL query to answer the following question:
`What is the numbers of the thn unit with a power greater than 220?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "diesel_multiple_units" (
"type" text,
"numbers" text,
"year_built" real,
"quantity_built" text,
"power_horsepower" real,
"max_speed_km_h" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the numbers of the thn unit with a power greater than 220?`:
```sql
|
SELECT SUM("power_horsepower") FROM "diesel_multiple_units" WHERE "year_built">1995; |
## Task
Generate a SQL query to answer the following question:
`What is the power of the unit built after 1995?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "diesel_multiple_units" (
"type" text,
"numbers" text,
"year_built" real,
"quantity_built" text,
"power_horsepower" real,
"max_speed_km_h" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the power of the unit built after 1995?`:
```sql
|
SELECT "result" FROM "schedule" WHERE "week">6 AND "date"='november 22, 1959'; |
## Task
Generate a SQL query to answer the following question:
`Week larger than 6, and a Date of november 22, 1959 had what result?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"record" text,
"game_site" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `Week larger than 6, and a Date of november 22, 1959 had what result?`:
```sql
|
SELECT AVG("week") FROM "schedule" WHERE "result"='w 21β7'; |
## Task
Generate a SQL query to answer the following question:
`Result of w 21β7 had what average week?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"record" text,
"game_site" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `Result of w 21β7 had what average week?`:
```sql
|
SELECT MIN("attendance") FROM "schedule" WHERE "date"='november 29, 1959'; |
## Task
Generate a SQL query to answer the following question:
`Date of november 29, 1959 had what lowest attendance?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"record" text,
"game_site" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `Date of november 29, 1959 had what lowest attendance?`:
```sql
|
SELECT "week" FROM "schedule" WHERE "date"='december 5, 1959'; |
## Task
Generate a SQL query to answer the following question:
`Week that has a Date of december 5, 1959 had what week?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"record" text,
"game_site" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `Week that has a Date of december 5, 1959 had what week?`:
```sql
|
SELECT SUM("game") FROM "schedule_and_results" WHERE "opponent"='@ carolina hurricanes'; |
## Task
Generate a SQL query to answer the following question:
`Which Game has an Opponent of @ carolina hurricanes?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule_and_results" (
"game" real,
"november" real,
"opponent" text,
"score" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Game has an Opponent of @ carolina hurricanes?`:
```sql
|
SELECT COUNT("game") FROM "schedule_and_results" WHERE "november"=10; |
## Task
Generate a SQL query to answer the following question:
`How many games have a November of 10?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule_and_results" (
"game" real,
"november" real,
"opponent" text,
"score" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many games have a November of 10?`:
```sql
|
SELECT SUM("game") FROM "schedule_and_results" WHERE "november"=22; |
## Task
Generate a SQL query to answer the following question:
`Which Game has a November of 22?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule_and_results" (
"game" real,
"november" real,
"opponent" text,
"score" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Game has a November of 22?`:
```sql
|
SELECT AVG("year_of_marriage") FROM "chart_the_eight_wives" WHERE "her_age">19 AND "his_age"=30; |
## Task
Generate a SQL query to answer the following question:
`What is the mean year of marriage when her age was more than 19 and his age was 30?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "chart_the_eight_wives" (
"year_of_marriage" real,
"name" text,
"her_age" real,
"his_age" real,
"num_of_children" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the mean year of marriage when her age was more than 19 and his age was 30?`:
```sql
|
SELECT MIN("her_age") FROM "chart_the_eight_wives" WHERE "year_of_marriage"<1853 AND "num_of_children"<8 AND "name"='eliza maria partridge'; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest figure for her age when the year of marriage is before 1853, the number of children is less than 8, and the bride was Eliza Maria Partridge?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "chart_the_eight_wives" (
"year_of_marriage" real,
"name" text,
"her_age" real,
"his_age" real,
"num_of_children" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest figure for her age when the year of marriage is before 1853, the number of children is less than 8, and the bride was Eliza Maria Partridge?`:
```sql
|
SELECT SUM("her_age") FROM "chart_the_eight_wives" WHERE "his_age"<33 AND "name"='diontha walker' AND "num_of_children"<0; |
## Task
Generate a SQL query to answer the following question:
`What is the total number of her age figures where his age is less than 33, the bride was diontha walker, and the number of children was less than 0?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "chart_the_eight_wives" (
"year_of_marriage" real,
"name" text,
"her_age" real,
"his_age" real,
"num_of_children" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total number of her age figures where his age is less than 33, the bride was diontha walker, and the number of children was less than 0?`:
```sql
|
SELECT SUM("lost") FROM "torneio_rio_s_o_paulo" WHERE "against">19 AND "drawn"<1; |
## Task
Generate a SQL query to answer the following question:
`How much Lost has an Against larger than 19, and a Drawn smaller than 1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "torneio_rio_s_o_paulo" (
"position" real,
"team" text,
"points" real,
"played" real,
"drawn" real,
"lost" real,
"against" real,
"difference" text
);
### SQL
Given the database schema, here is the SQL query that answers `How much Lost has an Against larger than 19, and a Drawn smaller than 1?`:
```sql
|
SELECT AVG("played") FROM "torneio_rio_s_o_paulo" WHERE "lost"=3 AND "against"=23; |
## Task
Generate a SQL query to answer the following question:
`Which Played has a Lost of 3, and an Against of 23?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "torneio_rio_s_o_paulo" (
"position" real,
"team" text,
"points" real,
"played" real,
"drawn" real,
"lost" real,
"against" real,
"difference" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Played has a Lost of 3, and an Against of 23?`:
```sql
|
SELECT MAX("played") FROM "torneio_rio_s_o_paulo" WHERE "against"<18 AND "points"<10; |
## Task
Generate a SQL query to answer the following question:
`Which Played is the highest one that has an Against smaller than 18, and Points smaller than 10?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "torneio_rio_s_o_paulo" (
"position" real,
"team" text,
"points" real,
"played" real,
"drawn" real,
"lost" real,
"against" real,
"difference" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Played is the highest one that has an Against smaller than 18, and Points smaller than 10?`:
```sql
|
SELECT MAX("against") FROM "torneio_rio_s_o_paulo" WHERE "drawn">1 AND "team"='corinthians' AND "played"<7; |
## Task
Generate a SQL query to answer the following question:
`Which Against is the highest one that has a Drawn larger than 1, and a Team of corinthians, and a Played smaller than 7?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "torneio_rio_s_o_paulo" (
"position" real,
"team" text,
"points" real,
"played" real,
"drawn" real,
"lost" real,
"against" real,
"difference" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Against is the highest one that has a Drawn larger than 1, and a Team of corinthians, and a Played smaller than 7?`:
```sql
|
SELECT "opponent" FROM "regular_season" WHERE "october"<20 AND "points"=8; |
## Task
Generate a SQL query to answer the following question:
`What opponent has october less than 20, and 8 for points?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "regular_season" (
"game" real,
"october" real,
"opponent" text,
"score" text,
"record" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What opponent has october less than 20, and 8 for points?`:
```sql
|
SELECT "position" FROM "draft_picks" WHERE "player"='drew callander'; |
## Task
Generate a SQL query to answer the following question:
`What position does Drew Callander play?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "draft_picks" (
"round" real,
"player" text,
"position" text,
"nationality" text,
"college_junior_club_team_league" text
);
### SQL
Given the database schema, here is the SQL query that answers `What position does Drew Callander play?`:
```sql
|
SELECT "round" FROM "draft_picks" WHERE "player"='ray kurpis'; |
## Task
Generate a SQL query to answer the following question:
`What round did Ray Kurpis play?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "draft_picks" (
"round" real,
"player" text,
"position" text,
"nationality" text,
"college_junior_club_team_league" text
);
### SQL
Given the database schema, here is the SQL query that answers `What round did Ray Kurpis play?`:
```sql
|
SELECT "built_by" FROM "american_seafoods_company_fleet" WHERE "name"='northern jaeger'; |
## Task
Generate a SQL query to answer the following question:
`Which Built by has a Name of northern jaeger?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "american_seafoods_company_fleet" (
"name" text,
"length" text,
"tonnage" real,
"built_by" text,
"year" real,
"engines" text,
"horsepowers" real,
"former_names" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Built by has a Name of northern jaeger?`:
```sql
|
SELECT SUM("horsepowers") FROM "american_seafoods_company_fleet" WHERE "year"<1974 AND "tonnage"=4437; |
## Task
Generate a SQL query to answer the following question:
`How many Horsepowers have a Year smaller than 1974, and a Tonnage of 4437?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "american_seafoods_company_fleet" (
"name" text,
"length" text,
"tonnage" real,
"built_by" text,
"year" real,
"engines" text,
"horsepowers" real,
"former_names" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many Horsepowers have a Year smaller than 1974, and a Tonnage of 4437?`:
```sql
|
SELECT "date" FROM "international_goals" WHERE "competition"='2014 fifa world cup qualification'; |
## Task
Generate a SQL query to answer the following question:
`When was the 2014 fifa world cup qualification?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "international_goals" (
"date" text,
"venue" text,
"score" text,
"result" text,
"competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `When was the 2014 fifa world cup qualification?`:
```sql
|
SELECT "date" FROM "international_goals" WHERE "venue"='tokyo'; |
## Task
Generate a SQL query to answer the following question:
`When was the date of an event at Tokyo venue?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "international_goals" (
"date" text,
"venue" text,
"score" text,
"result" text,
"competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `When was the date of an event at Tokyo venue?`:
```sql
|
SELECT "city" FROM "1980" WHERE "opponent"='poland'; |
## Task
Generate a SQL query to answer the following question:
`What city did Yugoslavia play against Poland in?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1980" (
"date" text,
"city" text,
"opponent" text,
"results" text,
"type_of_game" text
);
### SQL
Given the database schema, here is the SQL query that answers `What city did Yugoslavia play against Poland in?`:
```sql
|
SELECT "date" FROM "1980" WHERE "opponent"='luxembourg'; |
## Task
Generate a SQL query to answer the following question:
`What day did Yugoslavia play Luxembourg?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1980" (
"date" text,
"city" text,
"opponent" text,
"results" text,
"type_of_game" text
);
### SQL
Given the database schema, here is the SQL query that answers `What day did Yugoslavia play Luxembourg?`:
```sql
|
SELECT "type_of_game" FROM "1980" WHERE "city"='ljubljana'; |
## Task
Generate a SQL query to answer the following question:
`What type of game was played in Ljubljana?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1980" (
"date" text,
"city" text,
"opponent" text,
"results" text,
"type_of_game" text
);
### SQL
Given the database schema, here is the SQL query that answers `What type of game was played in Ljubljana?`:
```sql
|
SELECT "results" FROM "1980" WHERE "city"='belgrade'; |
## Task
Generate a SQL query to answer the following question:
`What's the result of the game played in Belgrade?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1980" (
"date" text,
"city" text,
"opponent" text,
"results" text,
"type_of_game" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the result of the game played in Belgrade?`:
```sql
|
SELECT "score" FROM "regular_season" WHERE "date"='march 23'; |
## Task
Generate a SQL query to answer the following question:
`What was the score on March 23?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "regular_season" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the score on March 23?`:
```sql
|
SELECT "record" FROM "regular_season" WHERE "score"='4-2' AND "visitor"='vancouver canucks'; |
## Task
Generate a SQL query to answer the following question:
`When the Vancouver Canucks were visiting, what was the record when the score was 4-2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "regular_season" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `When the Vancouver Canucks were visiting, what was the record when the score was 4-2?`:
```sql
|
SELECT "partner" FROM "doubles_9_6_titles_3_runner_ups" WHERE "score"='6β7, 7β6, 6β7'; |
## Task
Generate a SQL query to answer the following question:
`Which Partner has a Score of 6β7, 7β6, 6β7?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "doubles_9_6_titles_3_runner_ups" (
"outcome" text,
"date" text,
"tournament" text,
"surface" text,
"partner" text,
"opponents" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Partner has a Score of 6β7, 7β6, 6β7?`:
```sql
|
SELECT "score" FROM "doubles_9_6_titles_3_runner_ups" WHERE "date"='13 april 1997'; |
## Task
Generate a SQL query to answer the following question:
`Which Score has a Date of 13 april 1997?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "doubles_9_6_titles_3_runner_ups" (
"outcome" text,
"date" text,
"tournament" text,
"surface" text,
"partner" text,
"opponents" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Score has a Date of 13 april 1997?`:
```sql
|
SELECT "partner" FROM "doubles_9_6_titles_3_runner_ups" WHERE "score"='7β6, 6β3'; |
## Task
Generate a SQL query to answer the following question:
`Which Partner has a Score of 7β6, 6β3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "doubles_9_6_titles_3_runner_ups" (
"outcome" text,
"date" text,
"tournament" text,
"surface" text,
"partner" text,
"opponents" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Partner has a Score of 7β6, 6β3?`:
```sql
|
SELECT "date" FROM "doubles_9_6_titles_3_runner_ups" WHERE "tournament"='bmw open'; |
## Task
Generate a SQL query to answer the following question:
`Which Date has a Tournament of bmw open?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "doubles_9_6_titles_3_runner_ups" (
"outcome" text,
"date" text,
"tournament" text,
"surface" text,
"partner" text,
"opponents" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Date has a Tournament of bmw open?`:
```sql
|
SELECT "partner" FROM "doubles_9_6_titles_3_runner_ups" WHERE "tournament"='catella swedish open'; |
## Task
Generate a SQL query to answer the following question:
`Which Partner has a Tournament of catella swedish open?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "doubles_9_6_titles_3_runner_ups" (
"outcome" text,
"date" text,
"tournament" text,
"surface" text,
"partner" text,
"opponents" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Partner has a Tournament of catella swedish open?`:
```sql
|
SELECT "date" FROM "doubles_9_6_titles_3_runner_ups" WHERE "surface"='clay' AND "score"='6β3, 5β7, 2β6'; |
## Task
Generate a SQL query to answer the following question:
`Which Date has a Surface of clay, and a Score of 6β3, 5β7, 2β6?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "doubles_9_6_titles_3_runner_ups" (
"outcome" text,
"date" text,
"tournament" text,
"surface" text,
"partner" text,
"opponents" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Date has a Surface of clay, and a Score of 6β3, 5β7, 2β6?`:
```sql
|
SELECT "winner" FROM "events" WHERE "race_name"='tre valli varesine'; |
## Task
Generate a SQL query to answer the following question:
`Who was the winner of the tre valli varesine race?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "events" (
"date" text,
"race_name" text,
"location" text,
"uci_rating" text,
"winner" text,
"team" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the winner of the tre valli varesine race?`:
```sql
|
SELECT "date" FROM "events" WHERE "uci_rating"='1.1' AND "race_name"='omloop van de vlaamse scheldeboorden'; |
## Task
Generate a SQL query to answer the following question:
`What is the date of the omloop van de vlaamse scheldeboorden race with a UCI rating of 1.1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "events" (
"date" text,
"race_name" text,
"location" text,
"uci_rating" text,
"winner" text,
"team" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the date of the omloop van de vlaamse scheldeboorden race with a UCI rating of 1.1?`:
```sql
|
SELECT "date" FROM "events" WHERE "race_name"='gp cittΓ di camaiore'; |
## Task
Generate a SQL query to answer the following question:
`What is the date of the gp cittΓ di camaiore race?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "events" (
"date" text,
"race_name" text,
"location" text,
"uci_rating" text,
"winner" text,
"team" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the date of the gp cittΓ di camaiore race?`:
```sql
|
SELECT "uci_rating" FROM "events" WHERE "location"='italy' AND "team"='progetto ciclismo alplast'; |
## Task
Generate a SQL query to answer the following question:
`What is the UCI rating of the race in Italy with the progetto ciclismo alplast team?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "events" (
"date" text,
"race_name" text,
"location" text,
"uci_rating" text,
"winner" text,
"team" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the UCI rating of the race in Italy with the progetto ciclismo alplast team?`:
```sql
|
SELECT "date" FROM "schedule" WHERE "game_site"='schaeffer stadium'; |
## Task
Generate a SQL query to answer the following question:
`What is the date of the game being played at Schaeffer Stadium?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"record" text,
"game_site" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the date of the game being played at Schaeffer Stadium?`:
```sql
|
SELECT AVG("points") FROM "motorcycle_grand_prix_results" WHERE "year">1966 AND "wins">1; |
## Task
Generate a SQL query to answer the following question:
`Which Points have a Year larger than 1966, and Wins larger than 1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "motorcycle_grand_prix_results" (
"year" real,
"class" text,
"team" text,
"points" real,
"wins" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Points have a Year larger than 1966, and Wins larger than 1?`:
```sql
|
SELECT MIN("year") FROM "motorcycle_grand_prix_results" WHERE "wins"<0; |
## Task
Generate a SQL query to answer the following question:
`Which Year is the lowest one that has Wins smaller than 0?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "motorcycle_grand_prix_results" (
"year" real,
"class" text,
"team" text,
"points" real,
"wins" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Year is the lowest one that has Wins smaller than 0?`:
```sql
|
SELECT AVG("points") FROM "motorcycle_grand_prix_results" WHERE "wins">1; |
## Task
Generate a SQL query to answer the following question:
`Which Points have Wins larger than 1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "motorcycle_grand_prix_results" (
"year" real,
"class" text,
"team" text,
"points" real,
"wins" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Points have Wins larger than 1?`:
```sql
|
SELECT AVG("wins") FROM "motorcycle_grand_prix_results" WHERE "year"=1963 AND "class"='50cc'; |
## Task
Generate a SQL query to answer the following question:
`Which Wins have a Year of 1963, and a Class of 50cc?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "motorcycle_grand_prix_results" (
"year" real,
"class" text,
"team" text,
"points" real,
"wins" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Wins have a Year of 1963, and a Class of 50cc?`:
```sql
|
SELECT "overall_wc_points_rank" FROM "liberec" WHERE "rank"<3 AND "name"='anders jacobsen'; |
## Task
Generate a SQL query to answer the following question:
`How many overall WC ponts (rank) did Anders Jacobsen get when his rank was smaller than 3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "liberec" (
"rank" real,
"name" text,
"nationality" text,
"1st_m" real,
"2nd_m" real,
"points" real,
"overall_wc_points_rank" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many overall WC ponts (rank) did Anders Jacobsen get when his rank was smaller than 3?`:
```sql
|
SELECT MAX("rank") FROM "liberec" WHERE "1st_m"=129 AND "points"<255.6; |
## Task
Generate a SQL query to answer the following question:
`Who had the highest rank with a 1st (m) of 129 and less than 255.6 points?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "liberec" (
"rank" real,
"name" text,
"nationality" text,
"1st_m" real,
"2nd_m" real,
"points" real,
"overall_wc_points_rank" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who had the highest rank with a 1st (m) of 129 and less than 255.6 points?`:
```sql
|
SELECT MIN("1st_m") FROM "liberec" WHERE "rank"<8 AND "overall_wc_points_rank"='369 (16)' AND "points">258.2; |
## Task
Generate a SQL query to answer the following question:
`Who had the lowest 1st (m), ranked lower than 8, with an overall WC points (rank) of 369 (16) with more than 258.2 points?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "liberec" (
"rank" real,
"name" text,
"nationality" text,
"1st_m" real,
"2nd_m" real,
"points" real,
"overall_wc_points_rank" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who had the lowest 1st (m), ranked lower than 8, with an overall WC points (rank) of 369 (16) with more than 258.2 points?`:
```sql
|
SELECT COUNT("rank") FROM "leaders" WHERE "wins">16 AND "country"='australia'; |
## Task
Generate a SQL query to answer the following question:
`What is the player from Australia's rank with more than 16 wins?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "leaders" (
"rank" real,
"player" text,
"country" text,
"earnings" real,
"wins" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the player from Australia's rank with more than 16 wins?`:
```sql
|
SELECT MIN("rank") FROM "leaders" WHERE "earnings"<'11,936,443' AND "wins">16; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest rank of a player with earnings under $11,936,443 and more than 16 wins?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "leaders" (
"rank" real,
"player" text,
"country" text,
"earnings" real,
"wins" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest rank of a player with earnings under $11,936,443 and more than 16 wins?`:
```sql
|
SELECT MAX("earnings") FROM "leaders" WHERE "wins">19; |
## Task
Generate a SQL query to answer the following question:
`What is the highest earnings of a player with more than 19 wins?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "leaders" (
"rank" real,
"player" text,
"country" text,
"earnings" real,
"wins" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest earnings of a player with more than 19 wins?`:
```sql
|
SELECT AVG("opened") FROM "roller_coasters" WHERE "manufacturer"='vekoma'; |
## Task
Generate a SQL query to answer the following question:
`Which average Opened has a Manufacturer of vekoma?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "roller_coasters" (
"name" text,
"style" text,
"opened" real,
"manufacturer" text,
"themed_area" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which average Opened has a Manufacturer of vekoma?`:
```sql
|
SELECT MAX("opened") FROM "roller_coasters" WHERE "themed_area"='aerial park' AND "manufacturer"='zamperla'; |
## Task
Generate a SQL query to answer the following question:
`Which Opened is the highest one that has a Themed Area of aerial park, and a Manufacturer of zamperla?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "roller_coasters" (
"name" text,
"style" text,
"opened" real,
"manufacturer" text,
"themed_area" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Opened is the highest one that has a Themed Area of aerial park, and a Manufacturer of zamperla?`:
```sql
|
SELECT "themed_area" FROM "roller_coasters" WHERE "name"='troublesome trucks runaway coaster'; |
## Task
Generate a SQL query to answer the following question:
`Which Themed Area has a Name of troublesome trucks runaway coaster?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "roller_coasters" (
"name" text,
"style" text,
"opened" real,
"manufacturer" text,
"themed_area" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Themed Area has a Name of troublesome trucks runaway coaster?`:
```sql
|
SELECT "manufacturer" FROM "roller_coasters" WHERE "style"='steel sit down' AND "opened">2008; |
## Task
Generate a SQL query to answer the following question:
`Which Manufacturer has a Style of steel sit down, and an Opened larger than 2008?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "roller_coasters" (
"name" text,
"style" text,
"opened" real,
"manufacturer" text,
"themed_area" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Manufacturer has a Style of steel sit down, and an Opened larger than 2008?`:
```sql
|
SELECT "position" FROM "first_round_selections" WHERE "pick"<25 AND "school"='university of california'; |
## Task
Generate a SQL query to answer the following question:
`What position has a pick less than 25 for the university of california?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_round_selections" (
"pick" real,
"player" text,
"team" text,
"position" text,
"school" text
);
### SQL
Given the database schema, here is the SQL query that answers `What position has a pick less than 25 for the university of california?`:
```sql
|
SELECT SUM("pick") FROM "first_round_selections" WHERE "school"='tulane university'; |
## Task
Generate a SQL query to answer the following question:
`What is the pick number for tulane university?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_round_selections" (
"pick" real,
"player" text,
"team" text,
"position" text,
"school" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the pick number for tulane university?`:
```sql
|
SELECT SUM("pick") FROM "first_round_selections" WHERE "team"='kansas city royals'; |
## Task
Generate a SQL query to answer the following question:
`What is the pick number for the kansas city royals?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_round_selections" (
"pick" real,
"player" text,
"team" text,
"position" text,
"school" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the pick number for the kansas city royals?`:
```sql
|
SELECT AVG("pick") FROM "first_round_selections" WHERE "school"='pasco, wa'; |
## Task
Generate a SQL query to answer the following question:
`What is the average Pick for the Pasco, Wa school?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_round_selections" (
"pick" real,
"player" text,
"team" text,
"position" text,
"school" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average Pick for the Pasco, Wa school?`:
```sql
|
SELECT "label" FROM "release_history" WHERE "format"='cd single' AND "date"='1993'; |
## Task
Generate a SQL query to answer the following question:
`What Label released a CD single in 1993?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "release_history" (
"date" text,
"label" text,
"region" text,
"format" text,
"catalog" text
);
### SQL
Given the database schema, here is the SQL query that answers `What Label released a CD single in 1993?`:
```sql
|
SELECT "home" FROM "december" WHERE "record"='7β5β2'; |
## Task
Generate a SQL query to answer the following question:
`Where was home with a record of 7β5β2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "december" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `Where was home with a record of 7β5β2?`:
```sql
|
SELECT "date" FROM "december" WHERE "record"='8β6β3'; |
## Task
Generate a SQL query to answer the following question:
`On what date was the record 8β6β3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "december" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `On what date was the record 8β6β3?`:
```sql
|
SELECT "score" FROM "december" WHERE "visitor"='pittsburgh'; |
## Task
Generate a SQL query to answer the following question:
`What was the score when Pittsburgh was the visitor?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "december" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the score when Pittsburgh was the visitor?`:
```sql
|
SELECT "date" FROM "december" WHERE "home"='ny rangers'; |
## Task
Generate a SQL query to answer the following question:
`On what date were the NY Rangers home?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "december" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `On what date were the NY Rangers home?`:
```sql
|
SELECT "visitor" FROM "december" WHERE "record"='7β5β3'; |
## Task
Generate a SQL query to answer the following question:
`Which visitor had a record of 7β5β3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "december" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which visitor had a record of 7β5β3?`:
```sql
|
SELECT "home" FROM "december" WHERE "visitor"='detroit' AND "score"='4 β 1'; |
## Task
Generate a SQL query to answer the following question:
`Who was home when Detroit was visiting with a score of 4 β 1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "december" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was home when Detroit was visiting with a score of 4 β 1?`:
```sql
|
SELECT MIN("date") FROM "release_history" WHERE "label"='great expectations' AND "format"='lp'; |
## Task
Generate a SQL query to answer the following question:
`What is the earliest date with Great Expectations label with LP format?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "release_history" (
"region" text,
"date" real,
"label" text,
"format" text,
"catalog" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the earliest date with Great Expectations label with LP format?`:
```sql
|
SELECT "format" FROM "release_history" WHERE "catalog"='mobil 1'; |
## Task
Generate a SQL query to answer the following question:
`What format was used for Mobil 1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "release_history" (
"region" text,
"date" real,
"label" text,
"format" text,
"catalog" text
);
### SQL
Given the database schema, here is the SQL query that answers `What format was used for Mobil 1?`:
```sql
|
SELECT "result" FROM "under_23" WHERE "competition"='friendly match'; |
## Task
Generate a SQL query to answer the following question:
`what team won the friendly match`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "under_23" (
"date" text,
"venue" text,
"score" text,
"result" text,
"competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `what team won the friendly match`:
```sql
|
SELECT COUNT("runner_up") FROM "wins_by_club" WHERE "last_win"<1998 AND "wins"=1 AND "rank">13; |
## Task
Generate a SQL query to answer the following question:
`Which Runner-up has a Last win smaller than 1998, and Wins of 1, and a Rank larger than 13?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "wins_by_club" (
"rank" real,
"club" text,
"wins" real,
"last_win" real,
"runner_up" real,
"last_losing_final" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Runner-up has a Last win smaller than 1998, and Wins of 1, and a Rank larger than 13?`:
```sql
|
SELECT COUNT("last_win") FROM "wins_by_club" WHERE "club"='mansfield town' AND "wins"<1; |
## Task
Generate a SQL query to answer the following question:
`How many Last wins have a Club of mansfield town, and Wins smaller than 1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "wins_by_club" (
"rank" real,
"club" text,
"wins" real,
"last_win" real,
"runner_up" real,
"last_losing_final" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many Last wins have a Club of mansfield town, and Wins smaller than 1?`:
```sql
|
SELECT "driver" FROM "formula_one_entries_for_brm_type_15" WHERE "date"='16th september 1951' AND "race"='dns'; |
## Task
Generate a SQL query to answer the following question:
`Which Driver has a Date of 16th september 1951, and a Race of dns?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "formula_one_entries_for_brm_type_15" (
"date" text,
"event" text,
"circuit" text,
"driver" text,
"race" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Driver has a Date of 16th september 1951, and a Race of dns?`:
```sql
|
SELECT "race" FROM "formula_one_entries_for_brm_type_15" WHERE "event"='goodwood trophy' AND "driver"='reg parnell'; |
## Task
Generate a SQL query to answer the following question:
`At which race did reg parnell win the goodwood trophy?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "formula_one_entries_for_brm_type_15" (
"date" text,
"event" text,
"circuit" text,
"driver" text,
"race" text
);
### SQL
Given the database schema, here is the SQL query that answers `At which race did reg parnell win the goodwood trophy?`:
```sql
|
SELECT "race" FROM "formula_one_entries_for_brm_type_15" WHERE "date"='31st may 1953' AND "event"='grand prix de l''albigeois final'; |
## Task
Generate a SQL query to answer the following question:
`Which Race has a Date of 31st may 1953, and an Event of grand prix de l'albigeois final?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "formula_one_entries_for_brm_type_15" (
"date" text,
"event" text,
"circuit" text,
"driver" text,
"race" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Race has a Date of 31st may 1953, and an Event of grand prix de l'albigeois final?`:
```sql
|
SELECT MAX("rank") FROM "2009_final_statistics" WHERE "code_iata_icao"='pvg/zspd' AND "total_cargo_metric_tonnes"<'2,543,394'; |
## Task
Generate a SQL query to answer the following question:
`What's the highest rank of a PVG/ZSPD Code (IATA/ICAO) airport with a total cargo less than 2,543,394 metric tonnes?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2009_final_statistics" (
"rank" real,
"airport" text,
"code_iata_icao" text,
"total_cargo_metric_tonnes" real,
"pct_change" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the highest rank of a PVG/ZSPD Code (IATA/ICAO) airport with a total cargo less than 2,543,394 metric tonnes?`:
```sql
|
SELECT AVG("total_cargo_metric_tonnes") FROM "2009_final_statistics" WHERE "pct_change"='11.8%'; |
## Task
Generate a SQL query to answer the following question:
`What's the average total cargo in metric tonnes that has an 11.8% Change?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2009_final_statistics" (
"rank" real,
"airport" text,
"code_iata_icao" text,
"total_cargo_metric_tonnes" real,
"pct_change" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the average total cargo in metric tonnes that has an 11.8% Change?`:
```sql
|
SELECT MAX("rank") FROM "2009_final_statistics" WHERE "airport"='tokyo international airport'; |
## Task
Generate a SQL query to answer the following question:
`What is the highest rank of Tokyo International Airport?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2009_final_statistics" (
"rank" real,
"airport" text,
"code_iata_icao" text,
"total_cargo_metric_tonnes" real,
"pct_change" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest rank of Tokyo International Airport?`:
```sql
|
SELECT AVG("lost") FROM "group_2" WHERE "points"=6 AND "games"<5; |
## Task
Generate a SQL query to answer the following question:
`Where the games are smaller than 5 and the points are 6, what is the average lost?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "group_2" (
"games" real,
"drawn" real,
"lost" real,
"points_difference" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `Where the games are smaller than 5 and the points are 6, what is the average lost?`:
```sql
|
SELECT SUM("order") FROM "roster" WHERE "built"='5/69-6/69'; |
## Task
Generate a SQL query to answer the following question:
`with build 5/69-6/69 what's the order?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "roster" (
"order" real,
"built" text,
"serial_numbers" text,
"quantity" real,
"1st_no" text
);
### SQL
Given the database schema, here is the SQL query that answers `with build 5/69-6/69 what's the order?`:
```sql
|
SELECT "outcome" FROM "singles_17_10_7" WHERE "score"='6β2, 6β2'; |
## Task
Generate a SQL query to answer the following question:
`Which Outcome has a Score of 6β2, 6β2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_17_10_7" (
"outcome" text,
"date" text,
"tournament" text,
"surface" text,
"opponent" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Outcome has a Score of 6β2, 6β2?`:
```sql
|
SELECT "date" FROM "singles_17_10_7" WHERE "outcome"='winner' AND "score"='7β5, 6β4'; |
## Task
Generate a SQL query to answer the following question:
`Which Date has an Outcome of winner, and a Score of 7β5, 6β4?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_17_10_7" (
"outcome" text,
"date" text,
"tournament" text,
"surface" text,
"opponent" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Date has an Outcome of winner, and a Score of 7β5, 6β4?`:
```sql
|
SELECT "tournament" FROM "singles_17_10_7" WHERE "outcome"='winner' AND "surface"='clay' AND "score"='6β4, 6β1'; |
## Task
Generate a SQL query to answer the following question:
`Which Tournament has an Outcome of winner, and a Surface of clay, and a Score of 6β4, 6β1?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_17_10_7" (
"outcome" text,
"date" text,
"tournament" text,
"surface" text,
"opponent" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Tournament has an Outcome of winner, and a Surface of clay, and a Score of 6β4, 6β1?`:
```sql
|
SELECT "outcome" FROM "singles_17_10_7" WHERE "opponent"='mari andersson'; |
## Task
Generate a SQL query to answer the following question:
`What was the outcome in mari andersson's tournament?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_17_10_7" (
"outcome" text,
"date" text,
"tournament" text,
"surface" text,
"opponent" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the outcome in mari andersson's tournament?`:
```sql
|
SELECT "loss" FROM "game_log" WHERE "opponent"='nationals' AND "score"='7-1'; |
## Task
Generate a SQL query to answer the following question:
`What's the loss of the game with the opponent of the Nationals with a score of 7-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,
"attendance" real,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the loss of the game with the opponent of the Nationals with a score of 7-1?`:
```sql
|
SELECT "opponent" FROM "game_log" WHERE "record"='70-52'; |
## Task
Generate a SQL query to answer the following question:
`Which opponent has a record of 70-52?`
### 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,
"attendance" real,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which opponent has a record of 70-52?`:
```sql
|
SELECT SUM("attendance") FROM "game_log" WHERE "opponent"='nationals' AND "record"='68-51'; |
## Task
Generate a SQL query to answer the following question:
`What is the attendance of the game that has the opponent of The Nationals with a record of 68-51?`
### 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,
"attendance" real,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the attendance of the game that has the opponent of The Nationals with a record of 68-51?`:
```sql
|
SELECT "attendance" FROM "game_log" WHERE "score"='5-4'; |
## Task
Generate a SQL query to answer the following question:
`What's the attendance of the game with a score of 5-4?`
### 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,
"attendance" real,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the attendance of the game with a score of 5-4?`:
```sql
|
SELECT "opponent" FROM "game_log" WHERE "record"='64-51'; |
## Task
Generate a SQL query to answer the following question:
`Who's the opponent of the game with the record 64-51?`
### 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,
"attendance" real,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who's the opponent of the game with the record 64-51?`:
```sql
|
SELECT "opponent" FROM "regular_season" WHERE "game"<54; |
## Task
Generate a SQL query to answer the following question:
`Who were the opponents in games before number 54?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "regular_season" (
"game" real,
"february" real,
"opponent" text,
"score" text,
"record" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `Who were the opponents in games before number 54?`:
```sql
|
SELECT "score" FROM "final_leaderboard" WHERE "player"='bert yancey'; |
## Task
Generate a SQL query to answer the following question:
`what was the score of bert yancey`
### 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 was the score of bert yancey`:
```sql
|
SELECT "length_fuel" FROM "current_fleet" WHERE "quantity"=30; |
## Task
Generate a SQL query to answer the following question:
`What is the Length/Fuel of the bus with a Quantity of 30?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "current_fleet" (
"length_fuel" text,
"model" text,
"year_built" text,
"quantity" real,
"floor_styling" text,
"wheelchair_access" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Length/Fuel of the bus with a Quantity of 30?`:
```sql
|
SELECT "length_fuel" FROM "current_fleet" WHERE "floor_styling"='high' AND "year_built"='2000-2003'; |
## Task
Generate a SQL query to answer the following question:
`What is the Length/Fuel of the bus built between 2000-2003 with a high Floor Styling?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "current_fleet" (
"length_fuel" text,
"model" text,
"year_built" text,
"quantity" real,
"floor_styling" text,
"wheelchair_access" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Length/Fuel of the bus built between 2000-2003 with a high Floor Styling?`:
```sql
|
SELECT "venue" FROM "thomas_buffel_international_goals" WHERE "competition"='friendly' AND "goal"=1; |
## Task
Generate a SQL query to answer the following question:
`In what Venue was the game with a Friendly Competition and 1 Goal played?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "thomas_buffel_international_goals" (
"goal" real,
"date" text,
"venue" text,
"score" text,
"result" text,
"competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `In what Venue was the game with a Friendly Competition and 1 Goal played?`:
```sql
|
SELECT COUNT("money") FROM "final_round" WHERE "to_par"='+5' AND "score"='76-69-70-70=285'; |
## Task
Generate a SQL query to answer the following question:
`What is the amount of money that a +5 to par with a score of 76-69-70-70=285?`
### 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 amount of money that a +5 to par with a score of 76-69-70-70=285?`:
```sql
|
SELECT "player" FROM "final_round" WHERE "score"='71-69-71-69=280'; |
## Task
Generate a SQL query to answer the following question:
`What is the name of the player with a 71-69-71-69=280 score?`
### 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 name of the player with a 71-69-71-69=280 score?`:
```sql
|
SELECT AVG("game_num") FROM "february" WHERE "home"='san jose' AND "points"<71; |
## Task
Generate a SQL query to answer the following question:
`Which average Game # has a Home of san jose, and Points smaller than 71?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "february" (
"game_num" real,
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which average Game # has a Home of san jose, and Points smaller than 71?`:
```sql
|
SELECT "home" FROM "february" WHERE "game_num"=59; |
## Task
Generate a SQL query to answer the following question:
`Which Home has a Game # of 59?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "february" (
"game_num" real,
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Home has a Game # of 59?`:
```sql
|
SELECT "visitor" FROM "february" WHERE "game_num">62 AND "date"='february 25'; |
## Task
Generate a SQL query to answer the following question:
`Which Visitor has a Game # larger than 62, and a Date of february 25?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "february" (
"game_num" real,
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Visitor has a Game # larger than 62, and a Date of february 25?`:
```sql
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.