output stringlengths 27 479 | instruction stringlengths 407 1.39k |
|---|---|
SELECT "position" FROM "nfl_draft" WHERE "pick"<152 AND "round"<3; |
## Task
Generate a SQL query to answer the following question:
`Which Position has a Pick smaller than 152, and a Round smaller than 3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nfl_draft" (
"round" real,
"pick" real,
"player" text,
"position" text,
"school_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Position has a Pick smaller than 152, and a Round smaller than 3?`:
```sql
|
SELECT COUNT("pick") FROM "nfl_draft" WHERE "position"='defensive back'; |
## Task
Generate a SQL query to answer the following question:
`How many Picks have a Position of defensive back?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nfl_draft" (
"round" real,
"pick" real,
"player" text,
"position" text,
"school_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many Picks have a Position of defensive back?`:
```sql
|
SELECT "player" FROM "nfl_draft" WHERE "round"<11 AND "pick"<152 AND "position"='guard'; |
## Task
Generate a SQL query to answer the following question:
`Which Player has a Round smaller than 11, and a Pick smaller than 152, and a Position of guard?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nfl_draft" (
"round" real,
"pick" real,
"player" text,
"position" text,
"school_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Player has a Round smaller than 11, and a Pick smaller than 152, and a Position of guard?`:
```sql
|
SELECT "name" FROM "list_of_medalists" WHERE "medal"='silver' AND "event"='men''s doubles'; |
## Task
Generate a SQL query to answer the following question:
`Which participants won the silver medal for the Men's Doubles?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_medalists" (
"medal" text,
"name" text,
"games" text,
"sport" text,
"event" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which participants won the silver medal for the Men's Doubles?`:
```sql
|
SELECT "event" FROM "list_of_medalists" WHERE "name"='rashid sidek'; |
## Task
Generate a SQL query to answer the following question:
`What event did Rashid Sidek participate in?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_medalists" (
"medal" text,
"name" text,
"games" text,
"sport" text,
"event" text
);
### SQL
Given the database schema, here is the SQL query that answers `What event did Rashid Sidek participate in?`:
```sql
|
SELECT "games" FROM "list_of_medalists" WHERE "event"='men''s singles' AND "medal"='silver'; |
## Task
Generate a SQL query to answer the following question:
`Which Olympic Games had a silver medal for the Men's Singles?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_medalists" (
"medal" text,
"name" text,
"games" text,
"sport" text,
"event" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Olympic Games had a silver medal for the Men's Singles?`:
```sql
|
SELECT "sport" FROM "list_of_medalists" WHERE "games"='1992 barcelona'; |
## Task
Generate a SQL query to answer the following question:
`Which sport was in the 1992 Barcelona games?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_medalists" (
"medal" text,
"name" text,
"games" text,
"sport" text,
"event" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which sport was in the 1992 Barcelona games?`:
```sql
|
SELECT "event" FROM "list_of_medalists" WHERE "games"='2008 beijing'; |
## Task
Generate a SQL query to answer the following question:
`What event was in the 2008 Beijing games?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_medalists" (
"medal" text,
"name" text,
"games" text,
"sport" text,
"event" text
);
### SQL
Given the database schema, here is the SQL query that answers `What event was in the 2008 Beijing games?`:
```sql
|
SELECT "round" FROM "nhl_entry_draft" WHERE "position"='defense' AND "nationality"='united states'; |
## Task
Generate a SQL query to answer the following question:
`What is the round of the defense player from the United States?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nhl_entry_draft" (
"round" real,
"player" text,
"position" text,
"nationality" text,
"college_junior_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the round of the defense player from the United States?`:
```sql
|
SELECT "position" FROM "nhl_entry_draft" WHERE "player"='dale craigwell'; |
## Task
Generate a SQL query to answer the following question:
`What is the position of Dale Craigwell?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nhl_entry_draft" (
"round" real,
"player" text,
"position" text,
"nationality" text,
"college_junior_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the position of Dale Craigwell?`:
```sql
|
SELECT "position" FROM "nhl_entry_draft" WHERE "nationality"='sweden'; |
## Task
Generate a SQL query to answer the following question:
`What is the position of the player from Sweden?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nhl_entry_draft" (
"round" real,
"player" text,
"position" text,
"nationality" text,
"college_junior_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the position of the player from Sweden?`:
```sql
|
SELECT "player" FROM "nhl_entry_draft" WHERE "round">5 AND "college_junior_club_team"='leningrad ska (russia)'; |
## Task
Generate a SQL query to answer the following question:
`Who is the player from a round larger than 5 and the college/junior/club team of Leningrad SKA (russia)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nhl_entry_draft" (
"round" real,
"player" text,
"position" text,
"nationality" text,
"college_junior_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the player from a round larger than 5 and the college/junior/club team of Leningrad SKA (russia)?`:
```sql
|
SELECT "position" FROM "nhl_entry_draft" WHERE "player"='mikhail kravets'; |
## Task
Generate a SQL query to answer the following question:
`What position does Mikhail Kravets play?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nhl_entry_draft" (
"round" real,
"player" text,
"position" text,
"nationality" text,
"college_junior_club_team" text
);
### SQL
Given the database schema, here is the SQL query that answers `What position does Mikhail Kravets play?`:
```sql
|
SELECT "date" FROM "schedule" WHERE "circuit"='laguna seca raceway' AND "class"='gtx/gto'; |
## Task
Generate a SQL query to answer the following question:
`Which date was held at Laguna Seca Raceway, in class GTX/GTO?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"race" text,
"length" text,
"class" text,
"circuit" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which date was held at Laguna Seca Raceway, in class GTX/GTO?`:
```sql
|
SELECT "circuit" FROM "schedule" WHERE "date"='may 7' AND "length"='1 hour'; |
## Task
Generate a SQL query to answer the following question:
`Which circuit was held on May 7 for 1 hour?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"race" text,
"length" text,
"class" text,
"circuit" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which circuit was held on May 7 for 1 hour?`:
```sql
|
SELECT "circuit" FROM "schedule" WHERE "length"='45 minutes' AND "date"='august 6'; |
## Task
Generate a SQL query to answer the following question:
`Which circuit has a length of 45 minutes and is held on August 6?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"race" text,
"length" text,
"class" text,
"circuit" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which circuit has a length of 45 minutes and is held on August 6?`:
```sql
|
SELECT "length" FROM "schedule" WHERE "race"='6 hours of talladega'; |
## Task
Generate a SQL query to answer the following question:
`What is the length of the 6 Hours of Talladega?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule" (
"race" text,
"length" text,
"class" text,
"circuit" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the length of the 6 Hours of Talladega?`:
```sql
|
SELECT "class_aaaa" FROM "team" WHERE "class_a"='lindsay' AND "class_aaaaa"='galena park north shore'; |
## Task
Generate a SQL query to answer the following question:
`Name the class AAAA with class A of lindsay and class AAAAA of galena park north shore`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "team" (
"school_year" text,
"class_a" text,
"class_aa" text,
"class_aaa" text,
"class_aaaa" text,
"class_aaaaa" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the class AAAA with class A of lindsay and class AAAAA of galena park north shore`:
```sql
|
SELECT "class_a" FROM "team" WHERE "class_aaaa"='longview pine tree' AND "school_year"='1995-96'; |
## Task
Generate a SQL query to answer the following question:
`Name the class A with class AAAA of longview pine tree and school year of 1995-96`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "team" (
"school_year" text,
"class_a" text,
"class_aa" text,
"class_aaa" text,
"class_aaaa" text,
"class_aaaaa" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the class A with class AAAA of longview pine tree and school year of 1995-96`:
```sql
|
SELECT "class_aa" FROM "team" WHERE "class_a"='rule' AND "school_year"='1995-96'; |
## Task
Generate a SQL query to answer the following question:
`Name the class AA with class A of rule and school year of 1995-96`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "team" (
"school_year" text,
"class_a" text,
"class_aa" text,
"class_aaa" text,
"class_aaaa" text,
"class_aaaaa" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the class AA with class A of rule and school year of 1995-96`:
```sql
|
SELECT "school_year" FROM "team" WHERE "class_aaaaa"='mcallen' AND "class_aaaa"='longview pine tree'; |
## Task
Generate a SQL query to answer the following question:
`Name the school year with class AAAAA of mcallen and class AAAA of longview pine tree`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "team" (
"school_year" text,
"class_a" text,
"class_aa" text,
"class_aaa" text,
"class_aaaa" text,
"class_aaaaa" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the school year with class AAAAA of mcallen and class AAAA of longview pine tree`:
```sql
|
SELECT "class_a" FROM "team" WHERE "school_year"='2004-05'; |
## Task
Generate a SQL query to answer the following question:
`Name the class A with school year of 2004-05`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "team" (
"school_year" text,
"class_a" text,
"class_aa" text,
"class_aaa" text,
"class_aaaa" text,
"class_aaaaa" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the class A with school year of 2004-05`:
```sql
|
SELECT "class_aaaa" FROM "team" WHERE "school_year"='2000-01'; |
## Task
Generate a SQL query to answer the following question:
`Name the clas AAAA of school year 2000-01`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "team" (
"school_year" text,
"class_a" text,
"class_aa" text,
"class_aaa" text,
"class_aaaa" text,
"class_aaaaa" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the clas AAAA of school year 2000-01`:
```sql
|
SELECT "school" FROM "indiana_high_school_athletics_conference" WHERE "county"='45 lake' AND "location"='merrillville'; |
## Task
Generate a SQL query to answer the following question:
`What school is from 45 Lake county and is located in Merrillville?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indiana_high_school_athletics_conference" (
"school" text,
"mascot" text,
"location" text,
"enrollment" real,
"ihsaa_class" text,
"ihsaa_football_class" text,
"county" text
);
### SQL
Given the database schema, here is the SQL query that answers `What school is from 45 Lake county and is located in Merrillville?`:
```sql
|
SELECT "school" FROM "indiana_high_school_athletics_conference" WHERE "location"='michigan city'; |
## Task
Generate a SQL query to answer the following question:
`What school is located in Michigan City?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indiana_high_school_athletics_conference" (
"school" text,
"mascot" text,
"location" text,
"enrollment" real,
"ihsaa_class" text,
"ihsaa_football_class" text,
"county" text
);
### SQL
Given the database schema, here is the SQL query that answers `What school is located in Michigan City?`:
```sql
|
SELECT "ihsaa_class" FROM "indiana_high_school_athletics_conference" WHERE "school"='chesterton'; |
## Task
Generate a SQL query to answer the following question:
`What is the IHSAA class for Chesterton?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indiana_high_school_athletics_conference" (
"school" text,
"mascot" text,
"location" text,
"enrollment" real,
"ihsaa_class" text,
"ihsaa_football_class" text,
"county" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the IHSAA class for Chesterton?`:
```sql
|
SELECT "ihsaa_class" FROM "indiana_high_school_athletics_conference" WHERE "school"='portage'; |
## Task
Generate a SQL query to answer the following question:
`What is the IHSAA class for Portage?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indiana_high_school_athletics_conference" (
"school" text,
"mascot" text,
"location" text,
"enrollment" real,
"ihsaa_class" text,
"ihsaa_football_class" text,
"county" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the IHSAA class for Portage?`:
```sql
|
SELECT "ihsaa_class" FROM "indiana_high_school_athletics_conference" WHERE "school"='crown point'; |
## Task
Generate a SQL query to answer the following question:
`What is the IHSAA class for Crown Point?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "indiana_high_school_athletics_conference" (
"school" text,
"mascot" text,
"location" text,
"enrollment" real,
"ihsaa_class" text,
"ihsaa_football_class" text,
"county" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the IHSAA class for Crown Point?`:
```sql
|
SELECT AVG("grid") FROM "sprint_race" WHERE "driver"='christian vietoris' AND "laps"<12; |
## Task
Generate a SQL query to answer the following question:
`What is the average grid of driver Christian Vietoris who has less than 12 laps?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "sprint_race" (
"team" text,
"driver" text,
"laps" real,
"time" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average grid of driver Christian Vietoris who has less than 12 laps?`:
```sql
|
SELECT SUM("grid") FROM "sprint_race" WHERE "driver"='joΓ£o urbano'; |
## Task
Generate a SQL query to answer the following question:
`What is the grid of driver joΓ£o urbano?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "sprint_race" (
"team" text,
"driver" text,
"laps" real,
"time" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the grid of driver joΓ£o urbano?`:
```sql
|
SELECT MIN("laps") FROM "sprint_race" WHERE "grid"<22 AND "time"='+35.268'; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest laps a grid less than 22 with a time of +35.268 has?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "sprint_race" (
"team" text,
"driver" text,
"laps" real,
"time" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest laps a grid less than 22 with a time of +35.268 has?`:
```sql
|
SELECT MIN("laps") FROM "sprint_race" WHERE "driver"='christian vietoris' AND "grid"<6; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest laps driver Christian Vietoris with a grid smaller than 6 has?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "sprint_race" (
"team" text,
"driver" text,
"laps" real,
"time" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest laps driver Christian Vietoris with a grid smaller than 6 has?`:
```sql
|
SELECT "primary_sponsor_s" FROM "teams_and_drivers" WHERE "driver_s"='mark martin'; |
## Task
Generate a SQL query to answer the following question:
`What is the primary sponsor of driver Mark Martin?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "teams_and_drivers" (
"team" text,
"car_s" text,
"driver_s" text,
"primary_sponsor_s" text,
"crew_chief" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the primary sponsor of driver Mark Martin?`:
```sql
|
SELECT "crew_chief" FROM "teams_and_drivers" WHERE "car_s"='chevrolet monte carlo' AND "team"='joe gibbs racing' AND "primary_sponsor_s"='fedex'; |
## Task
Generate a SQL query to answer the following question:
`Who is the crew chief of team Joe Gibbs Racing, which has a Chevrolet Monte Carlo and Fedex as the primary sponsor?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "teams_and_drivers" (
"team" text,
"car_s" text,
"driver_s" text,
"primary_sponsor_s" text,
"crew_chief" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the crew chief of team Joe Gibbs Racing, which has a Chevrolet Monte Carlo and Fedex as the primary sponsor?`:
```sql
|
SELECT "driver_s" FROM "teams_and_drivers" WHERE "crew_chief"='derrick finley'; |
## Task
Generate a SQL query to answer the following question:
`Who is the driver of the team with the crew chief Derrick Finley?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "teams_and_drivers" (
"team" text,
"car_s" text,
"driver_s" text,
"primary_sponsor_s" text,
"crew_chief" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the driver of the team with the crew chief Derrick Finley?`:
```sql
|
SELECT "crew_chief" FROM "teams_and_drivers" WHERE "team"='chip ganassi racing with felix sabates' AND "driver_s"='casey mears'; |
## Task
Generate a SQL query to answer the following question:
`Who is the crew chief of team Chip Ganassi Racing with Felix Sabates, which has Casey Mears as the driver?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "teams_and_drivers" (
"team" text,
"car_s" text,
"driver_s" text,
"primary_sponsor_s" text,
"crew_chief" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the crew chief of team Chip Ganassi Racing with Felix Sabates, which has Casey Mears as the driver?`:
```sql
|
SELECT "team" FROM "teams_and_drivers" WHERE "primary_sponsor_s"='peak fitness'; |
## Task
Generate a SQL query to answer the following question:
`Which team has Peak Fitness as the primary sponsor?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "teams_and_drivers" (
"team" text,
"car_s" text,
"driver_s" text,
"primary_sponsor_s" text,
"crew_chief" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which team has Peak Fitness as the primary sponsor?`:
```sql
|
SELECT "date" FROM "schedule" WHERE "result"='w 20-17' AND "record"='1-0'; |
## Task
Generate a SQL query to answer the following question:
`What date has w 20-17 as the result, and 1-0 as the record?`
### 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,
"game_site" text,
"record" text,
"attendance" text
);
### SQL
Given the database schema, here is the SQL query that answers `What date has w 20-17 as the result, and 1-0 as the record?`:
```sql
|
SELECT "game_site" FROM "schedule" WHERE "date"='december 24, 2000'; |
## Task
Generate a SQL query to answer the following question:
`What game site has december 24, 2000 as a date?`
### 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,
"game_site" text,
"record" text,
"attendance" text
);
### SQL
Given the database schema, here is the SQL query that answers `What game site has december 24, 2000 as a date?`:
```sql
|
SELECT "date" FROM "schedule" WHERE "opponent"='dallas cowboys'; |
## Task
Generate a SQL query to answer the following question:
`What date has dallas cowboys as the opponent?`
### 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,
"game_site" text,
"record" text,
"attendance" text
);
### SQL
Given the database schema, here is the SQL query that answers `What date has dallas cowboys as the opponent?`:
```sql
|
SELECT "attendance" FROM "schedule" WHERE "game_site"='fedex field' AND "week"=3; |
## Task
Generate a SQL query to answer the following question:
`What is the attendance that has fedex field as the game site with 3 as the 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,
"game_site" text,
"record" text,
"attendance" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the attendance that has fedex field as the game site with 3 as the week?`:
```sql
|
SELECT "record" FROM "free_agents" WHERE "date"='april 22'; |
## Task
Generate a SQL query to answer the following question:
`What is the record for April 22?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "free_agents" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the record for April 22?`:
```sql
|
SELECT "record" FROM "free_agents" WHERE "visitor"='quebec nordiques' AND "date"='april 22'; |
## Task
Generate a SQL query to answer the following question:
`What is the record when the visiting team was the Quebec Nordiques on April 22?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "free_agents" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the record when the visiting team was the Quebec Nordiques on April 22?`:
```sql
|
SELECT "longitude" FROM "seasons" WHERE "latin"='taurus'; |
## Task
Generate a SQL query to answer the following question:
`What is the longitude of Taurus?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "seasons" (
"longitude" text,
"sign" text,
"sanskrit" text,
"latin" text,
"ruling_planet" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the longitude of Taurus?`:
```sql
|
SELECT "location" FROM "teams_and_venues" WHERE "team"='belshina'; |
## Task
Generate a SQL query to answer the following question:
`What is the Location for Belshina?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "teams_and_venues" (
"team" text,
"location" text,
"venue" text,
"capacity" real,
"position_in_2003" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Location for Belshina?`:
```sql
|
SELECT "team" FROM "teams_and_venues" WHERE "capacity">'5,000' AND "position_in_2003"='13'; |
## Task
Generate a SQL query to answer the following question:
`What is the name of the Team with a Capacity larger than 5,000, and a Position in 2003 of 13?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "teams_and_venues" (
"team" text,
"location" text,
"venue" text,
"capacity" real,
"position_in_2003" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the name of the Team with a Capacity larger than 5,000, and a Position in 2003 of 13?`:
```sql
|
SELECT COUNT("capacity") FROM "teams_and_venues" WHERE "venue"='city stadium, borisov'; |
## Task
Generate a SQL query to answer the following question:
`What is the total number for Capacity at city stadium, borisov?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "teams_and_venues" (
"team" text,
"location" text,
"venue" text,
"capacity" real,
"position_in_2003" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total number for Capacity at city stadium, borisov?`:
```sql
|
SELECT MIN("viewers_millions") FROM "season_1_2008" WHERE "weekly_rank"='#3' AND "share"=9 AND "rating">5; |
## Task
Generate a SQL query to answer the following question:
`Which rating larger than 5 have the lowest amount of views in #3 rank with a share of 9?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "season_1_2008" (
"airdate" text,
"celebrities" text,
"rating" real,
"share" real,
"18_49" text,
"viewers_millions" real,
"weekly_rank" text,
"prod_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which rating larger than 5 have the lowest amount of views in #3 rank with a share of 9?`:
```sql
|
SELECT MAX("played") FROM "campeonato_brasileiro_s_rie_a" WHERE "drawn"<9 AND "difference"='36' AND "lost">7; |
## Task
Generate a SQL query to answer the following question:
`What is the highest played that has a drawn less than 9, 36 as the difference, with a lost greater than 7?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "campeonato_brasileiro_s_rie_a" (
"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 `What is the highest played that has a drawn less than 9, 36 as the difference, with a lost greater than 7?`:
```sql
|
SELECT COUNT("position") FROM "campeonato_brasileiro_s_rie_a" WHERE "team"='figueirense' AND "played">38; |
## Task
Generate a SQL query to answer the following question:
`How many positions have figueirense as the team, with a played greater than 38?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "campeonato_brasileiro_s_rie_a" (
"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 many positions have figueirense as the team, with a played greater than 38?`:
```sql
|
SELECT MAX("drawn") FROM "campeonato_brasileiro_s_rie_a" WHERE "played"<38; |
## Task
Generate a SQL query to answer the following question:
`What is the largest drawn that has a played less than 38?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "campeonato_brasileiro_s_rie_a" (
"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 `What is the largest drawn that has a played less than 38?`:
```sql
|
SELECT COUNT("position") FROM "campeonato_brasileiro_s_rie_a" WHERE "drawn"=9 AND "difference"='5' AND "lost"<14; |
## Task
Generate a SQL query to answer the following question:
`How many positions have 9 as a drawn, 5 as a difference, with a lost less than 14?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "campeonato_brasileiro_s_rie_a" (
"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 many positions have 9 as a drawn, 5 as a difference, with a lost less than 14?`:
```sql
|
SELECT "original_airdate" FROM "season_2_1938_1939" WHERE "episode"='2-01 (42)'; |
## Task
Generate a SQL query to answer the following question:
`What date did Episode 2-01 (42) air?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "season_2_1938_1939" (
"episode" text,
"title" text,
"writer_s" text,
"preservation" text,
"original_airdate" text
);
### SQL
Given the database schema, here is the SQL query that answers `What date did Episode 2-01 (42) air?`:
```sql
|
SELECT "writer_s" FROM "season_2_1938_1939" WHERE "episode"='2-15 (56)'; |
## Task
Generate a SQL query to answer the following question:
`Who wrote Episode 2-15 (56)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "season_2_1938_1939" (
"episode" text,
"title" text,
"writer_s" text,
"preservation" text,
"original_airdate" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who wrote Episode 2-15 (56)?`:
```sql
|
SELECT MAX("games") FROM "world_championship_group_a_finland" WHERE "lost"=1 AND "points"<18; |
## Task
Generate a SQL query to answer the following question:
`What is the highest number of games with 1 loss and points less than 18?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "world_championship_group_a_finland" (
"team" text,
"games" real,
"drawn" real,
"lost" real,
"points_difference" text,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest number of games with 1 loss and points less than 18?`:
```sql
|
SELECT "city" FROM "brazil_national_team" WHERE "result"='w' AND "competition"='international friendly (unofficial match)' AND "score"='1-0'; |
## Task
Generate a SQL query to answer the following question:
`Which City has a Result of w, and a Competition of international friendly (unofficial match), and a Score of 1-0?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "brazil_national_team" (
"date" text,
"city" text,
"result" text,
"score" text,
"competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which City has a Result of w, and a Competition of international friendly (unofficial match), and a Score of 1-0?`:
```sql
|
SELECT "date" FROM "brazil_national_team" WHERE "result"='w' AND "score"='3-0'; |
## Task
Generate a SQL query to answer the following question:
`Which Date has a Result of w, and a Score of 3-0?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "brazil_national_team" (
"date" text,
"city" text,
"result" text,
"score" text,
"competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Date has a Result of w, and a Score of 3-0?`:
```sql
|
SELECT "city" FROM "brazil_national_team" WHERE "date"='june 9, 1976'; |
## Task
Generate a SQL query to answer the following question:
`Which City has a Date of june 9, 1976?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "brazil_national_team" (
"date" text,
"city" text,
"result" text,
"score" text,
"competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which City has a Date of june 9, 1976?`:
```sql
|
SELECT "city" FROM "brazil_national_team" WHERE "date"='may 19, 1976'; |
## Task
Generate a SQL query to answer the following question:
`Which City has a Date of may 19, 1976?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "brazil_national_team" (
"date" text,
"city" text,
"result" text,
"score" text,
"competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which City has a Date of may 19, 1976?`:
```sql
|
SELECT COUNT("laps") FROM "classification" WHERE "driver"='tom bridger'; |
## Task
Generate a SQL query to answer the following question:
`What are the total number of laps for Tom Bridger?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "classification" (
"driver" text,
"constructor" text,
"laps" real,
"time_retired" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `What are the total number of laps for Tom Bridger?`:
```sql
|
SELECT MIN("laps") FROM "classification" WHERE "driver"='graham hill'; |
## Task
Generate a SQL query to answer the following question:
`What are the lowest laps of Graham Hill?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "classification" (
"driver" text,
"constructor" text,
"laps" real,
"time_retired" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `What are the lowest laps of Graham Hill?`:
```sql
|
SELECT MIN("laps") FROM "classification" WHERE "grid"=17; |
## Task
Generate a SQL query to answer the following question:
`What are the lowest laps of grid 17?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "classification" (
"driver" text,
"constructor" text,
"laps" real,
"time_retired" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `What are the lowest laps of grid 17?`:
```sql
|
SELECT SUM("avg_g") FROM "rushing" WHERE "gain"=16 AND "name"='barnes, freddie' AND "loss"<2; |
## Task
Generate a SQL query to answer the following question:
`Which Avg/G has a Gain of 16, and a Name of barnes, freddie, and a Loss smaller than 2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "rushing" (
"name" text,
"gain" real,
"loss" real,
"long" real,
"avg_g" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Avg/G has a Gain of 16, and a Name of barnes, freddie, and a Loss smaller than 2?`:
```sql
|
SELECT AVG("long") FROM "rushing" WHERE "gain"<16 AND "loss"<6; |
## Task
Generate a SQL query to answer the following question:
`Which average Long has a Gain smaller than 16, and a Loss smaller than 6?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "rushing" (
"name" text,
"gain" real,
"loss" real,
"long" real,
"avg_g" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which average Long has a Gain smaller than 16, and a Loss smaller than 6?`:
```sql
|
SELECT MIN("gain") FROM "rushing" WHERE "loss">2 AND "avg_g">-6 AND "name"='sheehan, tyler' AND "long">11; |
## Task
Generate a SQL query to answer the following question:
`Which Gain is the lowest one that has a Loss larger than 2, and an Avg/G larger than -6, and a Name of sheehan, tyler, and a Long larger than 11?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "rushing" (
"name" text,
"gain" real,
"loss" real,
"long" real,
"avg_g" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Gain is the lowest one that has a Loss larger than 2, and an Avg/G larger than -6, and a Name of sheehan, tyler, and a Long larger than 11?`:
```sql
|
SELECT MIN("avg_g") FROM "rushing" WHERE "long">8 AND "loss"<34 AND "gain">16 AND "name"='bullock, chris'; |
## Task
Generate a SQL query to answer the following question:
`Which Avg/G is the lowest one that has a Long larger than 8, and a Loss smaller than 34, and a Gain larger than 16, and a Name of bullock, chris?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "rushing" (
"name" text,
"gain" real,
"loss" real,
"long" real,
"avg_g" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Avg/G is the lowest one that has a Long larger than 8, and a Loss smaller than 34, and a Gain larger than 16, and a Name of bullock, chris?`:
```sql
|
SELECT SUM("loss") FROM "rushing" WHERE "name"='bullock, chris' AND "long"<36; |
## Task
Generate a SQL query to answer the following question:
`Which Loss has a Name of bullock, chris, and a Long smaller than 36?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "rushing" (
"name" text,
"gain" real,
"loss" real,
"long" real,
"avg_g" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Loss has a Name of bullock, chris, and a Long smaller than 36?`:
```sql
|
SELECT SUM("long") FROM "rushing" WHERE "loss">2 AND "gain"=157 AND "avg_g"<129; |
## Task
Generate a SQL query to answer the following question:
`How much Long has a Loss larger than 2, and a Gain of 157, and an Avg/G smaller than 129?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "rushing" (
"name" text,
"gain" real,
"loss" real,
"long" real,
"avg_g" real
);
### SQL
Given the database schema, here is the SQL query that answers `How much Long has a Loss larger than 2, and a Gain of 157, and an Avg/G smaller than 129?`:
```sql
|
SELECT MIN("places") FROM "ladies_singles" WHERE "nation"='norway' AND "points"<1524.9; |
## Task
Generate a SQL query to answer the following question:
`What is the fewest number of places for a skater from Norway with fewer than 1524.9 points?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ladies_singles" (
"rank" real,
"name" text,
"nation" text,
"points" real,
"places" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the fewest number of places for a skater from Norway with fewer than 1524.9 points?`:
```sql
|
SELECT "home" FROM "regular_season" WHERE "visitor"='philadelphia' AND "date"='december 4'; |
## Task
Generate a SQL query to answer the following question:
`What home has Philadelphia as the visitor, and december 4 as the date?`
### 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,
"decision" text,
"attendance" real,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What home has Philadelphia as the visitor, and december 4 as the date?`:
```sql
|
SELECT "record" FROM "regular_season" WHERE "decision"='parent' AND "home"='philadelphia' AND "date"='december 12'; |
## Task
Generate a SQL query to answer the following question:
`What record has a decision of parent, Philadelphia as the home, with december 12 as the date?`
### 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,
"decision" text,
"attendance" real,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What record has a decision of parent, Philadelphia as the home, with december 12 as the date?`:
```sql
|
SELECT "tournament" FROM "singles_titles" WHERE "score"='6β4, 6β2'; |
## Task
Generate a SQL query to answer the following question:
`Which Tournament has a Score of 6β4, 6β2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_titles" (
"date" real,
"tournament" text,
"surface" text,
"opponent_in_the_final" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Tournament has a Score of 6β4, 6β2?`:
```sql
|
SELECT "score" FROM "singles_titles" WHERE "opponent_in_the_final"='mehdi tahiri'; |
## Task
Generate a SQL query to answer the following question:
`Which Score has an Opponent in the final of mehdi tahiri?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_titles" (
"date" real,
"tournament" text,
"surface" text,
"opponent_in_the_final" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Score has an Opponent in the final of mehdi tahiri?`:
```sql
|
SELECT SUM("date") FROM "singles_titles" WHERE "score"='6β3, 7β6'; |
## Task
Generate a SQL query to answer the following question:
`Which Date has a Score of 6β3, 7β6?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_titles" (
"date" real,
"tournament" text,
"surface" text,
"opponent_in_the_final" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Date has a Score of 6β3, 7β6?`:
```sql
|
SELECT SUM("date") FROM "singles_titles" WHERE "score"='7β6(3), 4β6, 6β2'; |
## Task
Generate a SQL query to answer the following question:
`Which Date has a Score of 7β6(3), 4β6, 6β2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_titles" (
"date" real,
"tournament" text,
"surface" text,
"opponent_in_the_final" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Date has a Score of 7β6(3), 4β6, 6β2?`:
```sql
|
SELECT "surface" FROM "singles_titles" WHERE "tournament"='olbia'; |
## Task
Generate a SQL query to answer the following question:
`Which Surface has a Tournament of olbia?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_titles" (
"date" real,
"tournament" text,
"surface" text,
"opponent_in_the_final" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which Surface has a Tournament of olbia?`:
```sql
|
SELECT "attendance" FROM "schedule" WHERE "week"=7; |
## Task
Generate a SQL query to answer the following question:
`What was the attendance at the week 7 game?`
### 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,
"attendance" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the attendance at the week 7 game?`:
```sql
|
SELECT "result" FROM "schedule" WHERE "week">3 AND "opponent"='new york giants'; |
## Task
Generate a SQL query to answer the following question:
`What was the result of the game after week 3 against the New York Giants?`
### 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,
"attendance" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the result of the game after week 3 against the New York Giants?`:
```sql
|
SELECT "opponent" FROM "schedule" WHERE "week"=6; |
## Task
Generate a SQL query to answer the following question:
`Who was the opponent at the week 6 game?`
### 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,
"attendance" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the opponent at the week 6 game?`:
```sql
|
SELECT MIN("loss") FROM "rushing" WHERE "name"='jarius wright' AND "gain">1; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest loss that Jarius Wright has had where he also has had a gain bigger than 1.`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "rushing" (
"name" text,
"gp_gs" text,
"gain" real,
"loss" real,
"long" real,
"avg_g" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest loss that Jarius Wright has had where he also has had a gain bigger than 1.`:
```sql
|
SELECT "1st_prize" FROM "tournament_results" WHERE "location"='ohio' AND "tournament"='american golf classic'; |
## Task
Generate a SQL query to answer the following question:
`How much was the first place prize for the American golf classic located in Ohio?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "tournament_results" (
"date" text,
"tournament" text,
"location" text,
"winner" text,
"score" text,
"1st_prize" text
);
### SQL
Given the database schema, here is the SQL query that answers `How much was the first place prize for the American golf classic located in Ohio?`:
```sql
|
SELECT "date" FROM "tournament_results" WHERE "location"='florida' AND "tournament"='monsanto open'; |
## Task
Generate a SQL query to answer the following question:
`What date was the Monsanto open located in Florida?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "tournament_results" (
"date" text,
"tournament" text,
"location" text,
"winner" text,
"score" text,
"1st_prize" text
);
### SQL
Given the database schema, here is the SQL query that answers `What date was the Monsanto open located in Florida?`:
```sql
|
SELECT "score" FROM "tournament_results" WHERE "winner"='johnny miller (7)'; |
## Task
Generate a SQL query to answer the following question:
`What was the score of Johnny Miller (7)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "tournament_results" (
"date" text,
"tournament" text,
"location" text,
"winner" text,
"score" text,
"1st_prize" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the score of Johnny Miller (7)?`:
```sql
|
SELECT COUNT("year") FROM "year_by_year" WHERE "division">4; |
## Task
Generate a SQL query to answer the following question:
`What is the total number of years that have divisions greater than 4?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "year_by_year" (
"year" real,
"division" real,
"league" text,
"regular_season" text,
"playoffs" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total number of years that have divisions greater than 4?`:
```sql
|
SELECT MAX("division") FROM "year_by_year" WHERE "year"<2011; |
## Task
Generate a SQL query to answer the following question:
`What is the highest division for years earlier than 2011?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "year_by_year" (
"year" real,
"division" real,
"league" text,
"regular_season" text,
"playoffs" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest division for years earlier than 2011?`:
```sql
|
SELECT SUM("week") FROM "schedule" WHERE "attendance"<'30,348' AND "result"='w 37-21'; |
## Task
Generate a SQL query to answer the following question:
`In what Week were there less than 30,348 in Attendance with a Result of W 37-21?`
### 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,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `In what Week were there less than 30,348 in Attendance with a Result of W 37-21?`:
```sql
|
SELECT COUNT("week") FROM "schedule" WHERE "date"='november 30, 1958' AND "attendance">'33,240'; |
## Task
Generate a SQL query to answer the following question:
`What is the Week number on November 30, 1958 with more than 33,240 in 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,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Week number on November 30, 1958 with more than 33,240 in Attendance?`:
```sql
|
SELECT "result" FROM "schedule" WHERE "date"='november 9, 1958'; |
## Task
Generate a SQL query to answer the following question:
`What was the Result on November 9, 1958?`
### 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,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What was the Result on November 9, 1958?`:
```sql
|
SELECT AVG("attendance") FROM "schedule" WHERE "week"=8; |
## Task
Generate a SQL query to answer the following question:
`What was the Attendance on Week 8?`
### 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,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What was the Attendance on Week 8?`:
```sql
|
SELECT "season" FROM "year_by_year_performance" WHERE "against"='did not qualify for uefa competitions'; |
## Task
Generate a SQL query to answer the following question:
`Which season did not qualify for UEFA competitions?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "year_by_year_performance" (
"season" text,
"competition" text,
"round" text,
"against" text,
"played" text,
"drew" text,
"lost" text,
"goals_for" text,
"goals_against" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which season did not qualify for UEFA competitions?`:
```sql
|
SELECT "lost" FROM "year_by_year_performance" WHERE "goals_against"='5'; |
## Task
Generate a SQL query to answer the following question:
`How many games were lost that had goals against of 5?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "year_by_year_performance" (
"season" text,
"competition" text,
"round" text,
"against" text,
"played" text,
"drew" text,
"lost" text,
"goals_for" text,
"goals_against" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many games were lost that had goals against of 5?`:
```sql
|
SELECT "drew" FROM "year_by_year_performance" WHERE "goals_against"='did not qualify for uefa competitions'; |
## Task
Generate a SQL query to answer the following question:
`How many draws were there with goals against that did not qualify for UEFA competitions?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "year_by_year_performance" (
"season" text,
"competition" text,
"round" text,
"against" text,
"played" text,
"drew" text,
"lost" text,
"goals_for" text,
"goals_against" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many draws were there with goals against that did not qualify for UEFA competitions?`:
```sql
|
SELECT "competition" FROM "year_by_year_performance" WHERE "lost"='did not qualify for uefa competitions' AND "season"='1970-71'; |
## Task
Generate a SQL query to answer the following question:
`Which competition did not qualify for UEFA competitions in the 1970-71 season?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "year_by_year_performance" (
"season" text,
"competition" text,
"round" text,
"against" text,
"played" text,
"drew" text,
"lost" text,
"goals_for" text,
"goals_against" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which competition did not qualify for UEFA competitions in the 1970-71 season?`:
```sql
|
SELECT SUM("attendance") FROM "schedule" WHERE "venue"='texas stadium'; |
## Task
Generate a SQL query to answer the following question:
`What is the attendance in texas 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,
"venue" text,
"attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the attendance in texas stadium?`:
```sql
|
SELECT "home_team_score" FROM "round_22" WHERE "ground"='telstra dome'; |
## Task
Generate a SQL query to answer the following question:
`What is the home team score for the team that has a home field of the Telstra Dome?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_22" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"ground" text,
"crowd" real,
"date" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the home team score for the team that has a home field of the Telstra Dome?`:
```sql
|
SELECT "date" FROM "round_22" WHERE "home_team_score"='6.5 (41)'; |
## Task
Generate a SQL query to answer the following question:
`What is the date for the home team score of 6.5 (41)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_22" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"ground" text,
"crowd" real,
"date" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the date for the home team score of 6.5 (41)?`:
```sql
|
SELECT "home_team" FROM "round_22" WHERE "away_team"='brisbane lions'; |
## Task
Generate a SQL query to answer the following question:
`Which home team had an away team of the Brisbane Lions?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_22" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"ground" text,
"crowd" real,
"date" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which home team had an away team of the Brisbane Lions?`:
```sql
|
SELECT "report" FROM "round_22" WHERE "ground"='mcg' AND "home_team_score"='6.5 (41)'; |
## Task
Generate a SQL query to answer the following question:
`What is the report for the team with a home ground of MCG and a home team score of 6.5 (41)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_22" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"ground" text,
"crowd" real,
"date" text,
"report" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the report for the team with a home ground of MCG and a home team score of 6.5 (41)?`:
```sql
|
SELECT "sensor" FROM "comparison_of_some_cameras_compatible_wi" WHERE "sensor_resolution"='355x288' AND "camera"='naturalpoint trackir 3'; |
## Task
Generate a SQL query to answer the following question:
`What was the sensor with a resolution of 355x288 for a Naturalpoint Trackir 3?`
### 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 sensor with a resolution of 355x288 for a Naturalpoint Trackir 3?`:
```sql
|
SELECT "sensor_resolution" FROM "comparison_of_some_cameras_compatible_wi" WHERE "cpu_usage"='minimal' AND "camera"='naturalpoint trackir 3 pro'; |
## Task
Generate a SQL query to answer the following question:
`What was the sensor resolution with a minimal CPU usage for a naturalpoint trackir 3 pro?`
### 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 sensor resolution with a minimal CPU usage for a naturalpoint trackir 3 pro?`:
```sql
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.