output stringlengths 27 479 | instruction stringlengths 407 1.39k |
|---|---|
SELECT "engine_code" FROM "petrol_engines" WHERE "model"='xdrive25i'; |
## Task
Generate a SQL query to answer the following question:
`What is the engine code for the Xdrive25i?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "petrol_engines" (
"model" text,
"years" text,
"engine_code" text,
"power" text,
"torque" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the engine code for the Xdrive25i?`:
```sql
|
SELECT "torque" FROM "petrol_engines" WHERE "power"='hp (kw; ps)@5800'; |
## Task
Generate a SQL query to answer the following question:
`What is the torque on the model with power of hp (kw; ps)@5800?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "petrol_engines" (
"model" text,
"years" text,
"engine_code" text,
"power" text,
"torque" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the torque on the model with power of hp (kw; ps)@5800?`:
```sql
|
SELECT "torque" FROM "petrol_engines" WHERE "engine_code"='n46b20' AND "power"='ps (kw; hp)@6400'; |
## Task
Generate a SQL query to answer the following question:
`What is the torque when engine code is N46B20 and power is ps (kw; hp)@6400?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "petrol_engines" (
"model" text,
"years" text,
"engine_code" text,
"power" text,
"torque" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the torque when engine code is N46B20 and power is ps (kw; hp)@6400?`:
```sql
|
SELECT "power" FROM "petrol_engines" WHERE "model"='xdrive28i sdrive28i'; |
## Task
Generate a SQL query to answer the following question:
`What is the power for the model xdrive28i sdrive28i?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "petrol_engines" (
"model" text,
"years" text,
"engine_code" text,
"power" text,
"torque" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the power for the model xdrive28i sdrive28i?`:
```sql
|
SELECT "model" FROM "petrol_engines" WHERE "years"='2011 2012-'; |
## Task
Generate a SQL query to answer the following question:
`What is the model that was made in the years 2011 2012-?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "petrol_engines" (
"model" text,
"years" text,
"engine_code" text,
"power" text,
"torque" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the model that was made in the years 2011 2012-?`:
```sql
|
SELECT "engine_code" FROM "petrol_engines" WHERE "model"='xdrive35i'; |
## Task
Generate a SQL query to answer the following question:
`What is the engine code for the model xdrive35i?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "petrol_engines" (
"model" text,
"years" text,
"engine_code" text,
"power" text,
"torque" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the engine code for the model xdrive35i?`:
```sql
|
SELECT "athlete" FROM "high_school_boys" WHERE "school"='burbank high school'; |
## Task
Generate a SQL query to answer the following question:
`What is the Athlete from Burbank High School?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "high_school_boys" (
"time" text,
"athlete" text,
"school" text,
"city" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Athlete from Burbank High School?`:
```sql
|
SELECT "date" FROM "high_school_boys" WHERE "school"='ferris high school'; |
## Task
Generate a SQL query to answer the following question:
`What is the Date of the Athlete from Ferris High School?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "high_school_boys" (
"time" text,
"athlete" text,
"school" text,
"city" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Date of the Athlete from Ferris High School?`:
```sql
|
SELECT "athlete" FROM "high_school_boys" WHERE "city"='riverbank, california'; |
## Task
Generate a SQL query to answer the following question:
`What is the Athlete from Riverbank, California?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "high_school_boys" (
"time" text,
"athlete" text,
"school" text,
"city" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Athlete from Riverbank, California?`:
```sql
|
SELECT "date" FROM "high_school_boys" WHERE "school"='marshfield high school'; |
## Task
Generate a SQL query to answer the following question:
`What is the Date of the Player from Marshfield High School?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "high_school_boys" (
"time" text,
"athlete" text,
"school" text,
"city" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Date of the Player from Marshfield High School?`:
```sql
|
SELECT "school" FROM "high_school_boys" WHERE "date"='june 4, 2011'; |
## Task
Generate a SQL query to answer the following question:
`What is the School of the Player with a Date of June 4, 2011?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "high_school_boys" (
"time" text,
"athlete" text,
"school" text,
"city" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the School of the Player with a Date of June 4, 2011?`:
```sql
|
SELECT "episodes" FROM "2006_spring_season" WHERE "tv_station"='tbs' AND "japanese_title"='クロサギ'; |
## Task
Generate a SQL query to answer the following question:
`What episodes was the show クロサギ shown on TBS?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2006_spring_season" (
"japanese_title" text,
"romaji_title" text,
"tv_station" text,
"episodes" real,
"average_ratings" text
);
### SQL
Given the database schema, here is the SQL query that answers `What episodes was the show クロサギ shown on TBS?`:
```sql
|
SELECT "romaji_title" FROM "2006_spring_season" WHERE "tv_station"='tbs' AND "episodes"<11; |
## Task
Generate a SQL query to answer the following question:
`What is the Romanji Title of a show on TBS with less than 11 episodes?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2006_spring_season" (
"japanese_title" text,
"romaji_title" text,
"tv_station" text,
"episodes" real,
"average_ratings" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Romanji Title of a show on TBS with less than 11 episodes?`:
```sql
|
SELECT COUNT("episodes") FROM "2006_spring_season" WHERE "japanese_title"='クロサギ'; |
## Task
Generate a SQL query to answer the following question:
`What is the total number of episodes for クロサギ?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2006_spring_season" (
"japanese_title" text,
"romaji_title" text,
"tv_station" text,
"episodes" real,
"average_ratings" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total number of episodes for クロサギ?`:
```sql
|
SELECT "average_ratings" FROM "2006_spring_season" WHERE "japanese_title"='プリマダム'; |
## Task
Generate a SQL query to answer the following question:
`What are the average ratings for プリマダム?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "2006_spring_season" (
"japanese_title" text,
"romaji_title" text,
"tv_station" text,
"episodes" real,
"average_ratings" text
);
### SQL
Given the database schema, here is the SQL query that answers `What are the average ratings for プリマダム?`:
```sql
|
SELECT SUM("score_final") FROM "senior_career" WHERE "rank_final"=2 AND "year"<2008; |
## Task
Generate a SQL query to answer the following question:
`Which Score-Final has a Rank-Final of 2, and a Year smaller than 2008?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "senior_career" (
"year" real,
"competition_description" text,
"location" text,
"apparatus" text,
"rank_final" real,
"score_final" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Score-Final has a Rank-Final of 2, and a Year smaller than 2008?`:
```sql
|
SELECT SUM("year") FROM "senior_career" WHERE "rank_final"<7 AND "competition_description"='olympic games' AND "score_final"<186.525; |
## Task
Generate a SQL query to answer the following question:
`How many years have a Rank-Final smaller than 7, and a Competition Description of olympic games, and a Score-Final smaller than 186.525?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "senior_career" (
"year" real,
"competition_description" text,
"location" text,
"apparatus" text,
"rank_final" real,
"score_final" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many years have a Rank-Final smaller than 7, and a Competition Description of olympic games, and a Score-Final smaller than 186.525?`:
```sql
|
SELECT MAX("score_final") FROM "senior_career" WHERE "apparatus"='floor exercise'; |
## Task
Generate a SQL query to answer the following question:
`Which Score-Final has an Apparatus of floor exercise?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "senior_career" (
"year" real,
"competition_description" text,
"location" text,
"apparatus" text,
"rank_final" real,
"score_final" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Score-Final has an Apparatus of floor exercise?`:
```sql
|
SELECT MIN("year") FROM "senior_career" WHERE "apparatus"='uneven bars' AND "rank_final"<3; |
## Task
Generate a SQL query to answer the following question:
`Which Year is the first one that has an Apparatus of uneven bars, and a Rank-Final smaller than 3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "senior_career" (
"year" real,
"competition_description" text,
"location" text,
"apparatus" text,
"rank_final" real,
"score_final" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Year is the first one that has an Apparatus of uneven bars, and a Rank-Final smaller than 3?`:
```sql
|
SELECT "district" FROM "assembly_segments" WHERE "number_of_electorates_2009">'169,359' AND "constituency_number"='84'; |
## Task
Generate a SQL query to answer the following question:
`Which district has more than 169,359 2009 electorates and a constituency of 84?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "assembly_segments" (
"constituency_number" text,
"name" text,
"reserved_for_sc_st_none" text,
"district" text,
"number_of_electorates_2009" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which district has more than 169,359 2009 electorates and a constituency of 84?`:
```sql
|
SELECT "name" FROM "assembly_segments" WHERE "constituency_number"='84'; |
## Task
Generate a SQL query to answer the following question:
`Who has a constituency of 84?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "assembly_segments" (
"constituency_number" text,
"name" text,
"reserved_for_sc_st_none" text,
"district" text,
"number_of_electorates_2009" real
);
### SQL
Given the database schema, here is the SQL query that answers `Who has a constituency of 84?`:
```sql
|
SELECT AVG("round") FROM "mixed_martial_arts_record" WHERE "time"='1:15'; |
## Task
Generate a SQL query to answer the following question:
`What the round with the time 1:15?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "mixed_martial_arts_record" (
"res" text,
"record" text,
"opponent" text,
"method" text,
"event" text,
"round" real,
"time" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `What the round with the time 1:15?`:
```sql
|
SELECT "location" FROM "mixed_martial_arts_record" WHERE "opponent"='lyoto machida'; |
## Task
Generate a SQL query to answer the following question:
`What's the location when the opponent was Lyoto Machida?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "mixed_martial_arts_record" (
"res" text,
"record" text,
"opponent" text,
"method" text,
"event" text,
"round" real,
"time" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the location when the opponent was Lyoto Machida?`:
```sql
|
SELECT "2007" FROM "grand_slam_women_s_doubles_performance_t" WHERE "2010"='2r' AND "tournament"='us open'; |
## Task
Generate a SQL query to answer the following question:
`What is the 2007 result when the 2010 result was 2r, at the US Open?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "grand_slam_women_s_doubles_performance_t" (
"tournament" text,
"2007" text,
"2010" text,
"2011" text,
"2012" text,
"2013" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2007 result when the 2010 result was 2r, at the US Open?`:
```sql
|
SELECT MAX("a_score") FROM "uneven_bars_ef_qualifiers" WHERE "total"<15.95 AND "position"<7 AND "b_score">8.225; |
## Task
Generate a SQL query to answer the following question:
`What is the A score for the person with a total less than 15.95, position less than 7, and B score more than 8.225?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "uneven_bars_ef_qualifiers" (
"position" real,
"gymnast" text,
"a_score" real,
"b_score" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the A score for the person with a total less than 15.95, position less than 7, and B score more than 8.225?`:
```sql
|
SELECT AVG("b_score") FROM "uneven_bars_ef_qualifiers" WHERE "total"=16.325 AND "a_score">7.3; |
## Task
Generate a SQL query to answer the following question:
`What is the B score for the person with a total of 16.325 and an A score of more than 7.3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "uneven_bars_ef_qualifiers" (
"position" real,
"gymnast" text,
"a_score" real,
"b_score" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the B score for the person with a total of 16.325 and an A score of more than 7.3?`:
```sql
|
SELECT MIN("position") FROM "uneven_bars_ef_qualifiers" WHERE "total"<16.65 AND "a_score"=7.4; |
## Task
Generate a SQL query to answer the following question:
`What is the Position of the person with a total less than 16.65 and an A score of 7.4?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "uneven_bars_ef_qualifiers" (
"position" real,
"gymnast" text,
"a_score" real,
"b_score" real,
"total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Position of the person with a total less than 16.65 and an A score of 7.4?`:
```sql
|
SELECT "network" FROM "station_repeaters" WHERE "city_of_license"='pachuca, hidalgo'; |
## Task
Generate a SQL query to answer the following question:
`What's the network in Pachuca, Hidalgo?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "station_repeaters" (
"callsign" text,
"network" text,
"city_of_license" text,
"d_erp" text,
"owner_operator" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the network in Pachuca, Hidalgo?`:
```sql
|
SELECT "network" FROM "station_repeaters" WHERE "d_erp"='•' AND "callsign"='xhtm'; |
## Task
Generate a SQL query to answer the following question:
`What's the network that has a callsign of XHTM and a D ERP of •?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "station_repeaters" (
"callsign" text,
"network" text,
"city_of_license" text,
"d_erp" text,
"owner_operator" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the network that has a callsign of XHTM and a D ERP of •?`:
```sql
|
SELECT "city_of_license" FROM "station_repeaters" WHERE "d_erp"='100kw'; |
## Task
Generate a SQL query to answer the following question:
`What's the city of license having a D ERP of 100kw?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "station_repeaters" (
"callsign" text,
"network" text,
"city_of_license" text,
"d_erp" text,
"owner_operator" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the city of license having a D ERP of 100kw?`:
```sql
|
SELECT "d_erp" FROM "station_repeaters" WHERE "city_of_license"='san martin texmelucan, puebla'; |
## Task
Generate a SQL query to answer the following question:
`What's the D ERP in San Martin Texmelucan, Puebla?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "station_repeaters" (
"callsign" text,
"network" text,
"city_of_license" text,
"d_erp" text,
"owner_operator" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the D ERP in San Martin Texmelucan, Puebla?`:
```sql
|
SELECT "district" FROM "assembly_segments" WHERE "constituency_number"='98'; |
## Task
Generate a SQL query to answer the following question:
`What district has 98 constituencies?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "assembly_segments" (
"constituency_number" text,
"name" text,
"reserved_for_sc_st_none" text,
"district" text,
"number_of_electorates_2009" real
);
### SQL
Given the database schema, here is the SQL query that answers `What district has 98 constituencies?`:
```sql
|
SELECT MAX("points") FROM "canterbury_bankstown_bulldogs" WHERE "year"='2012'; |
## Task
Generate a SQL query to answer the following question:
`What are the highest points with 2012 as the year?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "canterbury_bankstown_bulldogs" (
"year" text,
"matches" real,
"tries" real,
"goals" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What are the highest points with 2012 as the year?`:
```sql
|
SELECT MAX("matches") FROM "canterbury_bankstown_bulldogs" WHERE "points"<88 AND "goals"<0; |
## Task
Generate a SQL query to answer the following question:
`What are the highest matches that have points less than 88, and goals less than 0?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "canterbury_bankstown_bulldogs" (
"year" text,
"matches" real,
"tries" real,
"goals" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What are the highest matches that have points less than 88, and goals less than 0?`:
```sql
|
SELECT SUM("tries") FROM "canterbury_bankstown_bulldogs" WHERE "goals">0; |
## Task
Generate a SQL query to answer the following question:
`How many tries have goals greater than 0?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "canterbury_bankstown_bulldogs" (
"year" text,
"matches" real,
"tries" real,
"goals" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many tries have goals greater than 0?`:
```sql
|
SELECT MIN("points") FROM "canterbury_bankstown_bulldogs" WHERE "year"='2013' AND "goals"<0; |
## Task
Generate a SQL query to answer the following question:
`What are the lowest points with 2013 as the year, and goals less than 0?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "canterbury_bankstown_bulldogs" (
"year" text,
"matches" real,
"tries" real,
"goals" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What are the lowest points with 2013 as the year, and goals less than 0?`:
```sql
|
SELECT COUNT("goals") FROM "canterbury_bankstown_bulldogs" WHERE "points"=28 AND "matches">11; |
## Task
Generate a SQL query to answer the following question:
`How many goals have 28 as the points, and matches greater than 11?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "canterbury_bankstown_bulldogs" (
"year" text,
"matches" real,
"tries" real,
"goals" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many goals have 28 as the points, and matches greater than 11?`:
```sql
|
SELECT MAX("laps") FROM "supersport_race_classification" WHERE "rider"='russell holland' AND "grid"<10; |
## Task
Generate a SQL query to answer the following question:
`Which Laps have a Rider of russell holland, and a Grid smaller than 10?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "supersport_race_classification" (
"rider" text,
"bike" text,
"laps" real,
"time" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Laps have a Rider of russell holland, and a Grid smaller than 10?`:
```sql
|
SELECT MIN("laps") FROM "supersport_race_classification" WHERE "bike"='kawasaki zx-6r' AND "time"='+26.891'; |
## Task
Generate a SQL query to answer the following question:
`Which Laps have a Bike of kawasaki zx-6r, and a Time of +26.891?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "supersport_race_classification" (
"rider" text,
"bike" text,
"laps" real,
"time" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Laps have a Bike of kawasaki zx-6r, and a Time of +26.891?`:
```sql
|
SELECT "rider" FROM "supersport_race_classification" WHERE "time"='retirement' AND "grid">5; |
## Task
Generate a SQL query to answer the following question:
`Which Rider has a Time of retirement, and a Grid larger than 5?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "supersport_race_classification" (
"rider" text,
"bike" text,
"laps" real,
"time" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Rider has a Time of retirement, and a Grid larger than 5?`:
```sql
|
SELECT "rider" FROM "supersport_race_classification" WHERE "laps"<18 AND "grid"=24; |
## Task
Generate a SQL query to answer the following question:
`Which Rider has less than 18 laps, and a Grid of 24?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "supersport_race_classification" (
"rider" text,
"bike" text,
"laps" real,
"time" text,
"grid" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Rider has less than 18 laps, and a Grid of 24?`:
```sql
|
SELECT "date" FROM "league_cup" WHERE "round"='2nd round 2nd leg'; |
## Task
Generate a SQL query to answer the following question:
`What is the date of the 2nd round 2nd leg?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "league_cup" (
"opposing_team" text,
"against" real,
"date" text,
"venue" text,
"round" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the date of the 2nd round 2nd leg?`:
```sql
|
SELECT "round" FROM "league_cup" WHERE "opposing_team"='gillingham' AND "against"<3; |
## Task
Generate a SQL query to answer the following question:
`What is the Round against Gillingham with an Against smaller than 3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "league_cup" (
"opposing_team" text,
"against" real,
"date" text,
"venue" text,
"round" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Round against Gillingham with an Against smaller than 3?`:
```sql
|
SELECT AVG("draw") FROM "relegation_table" WHERE "points"=42 AND "played"<36; |
## Task
Generate a SQL query to answer the following question:
`What's the draw that's played less than 36 and has 42 points?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "relegation_table" (
"place" real,
"team" text,
"played" real,
"draw" real,
"lost" real,
"goals_scored" real,
"goals_conceded" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What's the draw that's played less than 36 and has 42 points?`:
```sql
|
SELECT SUM("lost") FROM "relegation_table" WHERE "goals_scored"<38 AND "points"<10; |
## Task
Generate a SQL query to answer the following question:
`What the lost that has less than 10 points and less than 38 goals scored?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "relegation_table" (
"place" real,
"team" text,
"played" real,
"draw" real,
"lost" real,
"goals_scored" real,
"goals_conceded" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What the lost that has less than 10 points and less than 38 goals scored?`:
```sql
|
SELECT MAX("lost") FROM "relegation_table" WHERE "team"='alianza' AND "draw"<6; |
## Task
Generate a SQL query to answer the following question:
`what the most lost for Alianza with a draw less than 6?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "relegation_table" (
"place" real,
"team" text,
"played" real,
"draw" real,
"lost" real,
"goals_scored" real,
"goals_conceded" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `what the most lost for Alianza with a draw less than 6?`:
```sql
|
SELECT SUM("lost") FROM "relegation_table" WHERE "goals_scored">63 AND "place"<3; |
## Task
Generate a SQL query to answer the following question:
`What the lost in place less than 3 and having more than 63 goals scored?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "relegation_table" (
"place" real,
"team" text,
"played" real,
"draw" real,
"lost" real,
"goals_scored" real,
"goals_conceded" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `What the lost in place less than 3 and having more than 63 goals scored?`:
```sql
|
SELECT "state" FROM "member_states" WHERE "adopted"='1999-01-01' AND "gdp_per_capita_world_bank_2009_nominal_usd"<34849 AND "nominal_gdp_world_bank_2009_million_usd"<1460250; |
## Task
Generate a SQL query to answer the following question:
`What State has an Adopted of 1999-01-01, a GDP per capita World Bank, 2009 nominal (USD) that's smaller than 34849, along with a Nominal GDP World Bank, 2009 (million USD) that's smaller than 1460250?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "member_states" (
"state" text,
"adopted" text,
"population_2011_01_01" text,
"nominal_gdp_world_bank_2009_million_usd" real,
"relative_gdp_of_total_nominal" text,
"gdp_per_capita_world_bank_2009_nominal_usd" real
);
### SQL
Given the database schema, here is the SQL query that answers `What State has an Adopted of 1999-01-01, a GDP per capita World Bank, 2009 nominal (USD) that's smaller than 34849, along with a Nominal GDP World Bank, 2009 (million USD) that's smaller than 1460250?`:
```sql
|
SELECT MAX("nominal_gdp_world_bank_2009_million_usd") FROM "member_states" WHERE "gdp_per_capita_world_bank_2009_nominal_usd"=14267; |
## Task
Generate a SQL query to answer the following question:
`What is listed as the highest Nominal GDP World Bank, 2009 (million USD) that has a GDP per capita World Bank, 2009 nominal (USD) of 14267?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "member_states" (
"state" text,
"adopted" text,
"population_2011_01_01" text,
"nominal_gdp_world_bank_2009_million_usd" real,
"relative_gdp_of_total_nominal" text,
"gdp_per_capita_world_bank_2009_nominal_usd" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is listed as the highest Nominal GDP World Bank, 2009 (million USD) that has a GDP per capita World Bank, 2009 nominal (USD) of 14267?`:
```sql
|
SELECT "adopted" FROM "member_states" WHERE "nominal_gdp_world_bank_2009_million_usd"=48477; |
## Task
Generate a SQL query to answer the following question:
`What is listed for the Adopted that has a Nominal GDP World Bank, 2009 (million USD) of 48477?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "member_states" (
"state" text,
"adopted" text,
"population_2011_01_01" text,
"nominal_gdp_world_bank_2009_million_usd" real,
"relative_gdp_of_total_nominal" text,
"gdp_per_capita_world_bank_2009_nominal_usd" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is listed for the Adopted that has a Nominal GDP World Bank, 2009 (million USD) of 48477?`:
```sql
|
SELECT "adopted" FROM "member_states" WHERE "nominal_gdp_world_bank_2009_million_usd"=12460362; |
## Task
Generate a SQL query to answer the following question:
`What is listed for the Adopted that has a Niminal GDP World Bank 2009 (million USD) of 12460362?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "member_states" (
"state" text,
"adopted" text,
"population_2011_01_01" text,
"nominal_gdp_world_bank_2009_million_usd" real,
"relative_gdp_of_total_nominal" text,
"gdp_per_capita_world_bank_2009_nominal_usd" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is listed for the Adopted that has a Niminal GDP World Bank 2009 (million USD) of 12460362?`:
```sql
|
SELECT SUM("rank") FROM "all_time_top_scorers" WHERE "apps">39 AND "player"='ümit karan' AND "rate">0.58; |
## Task
Generate a SQL query to answer the following question:
`What is the total Rank for ümit karan when Apps is more than 39 and Rate is more than 0.58?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "all_time_top_scorers" (
"rank" real,
"player" text,
"goals" real,
"apps" real,
"rate" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total Rank for ümit karan when Apps is more than 39 and Rate is more than 0.58?`:
```sql
|
SELECT SUM("rate") FROM "all_time_top_scorers" WHERE "rank">10; |
## Task
Generate a SQL query to answer the following question:
`When rank is more than 10, what is the total rate?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "all_time_top_scorers" (
"rank" real,
"player" text,
"goals" real,
"apps" real,
"rate" real
);
### SQL
Given the database schema, here is the SQL query that answers `When rank is more than 10, what is the total rate?`:
```sql
|
SELECT "winning_amount" FROM "season_2" WHERE "contestant_name"='himesh reshammiya'; |
## Task
Generate a SQL query to answer the following question:
`What winning amount has himesh reshammiya as the contestant name?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "season_2" (
"contestant_name" text,
"episode_num" text,
"date_premiered_2009" text,
"winning_amount" text,
"eliminated_contestant" text
);
### SQL
Given the database schema, here is the SQL query that answers `What winning amount has himesh reshammiya as the contestant name?`:
```sql
|
SELECT "eliminated_contestant" FROM "season_2" WHERE "date_premiered_2009"='october 10'; |
## Task
Generate a SQL query to answer the following question:
`What eliminated contestant has October 10, 2009 as the date premiered?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "season_2" (
"contestant_name" text,
"episode_num" text,
"date_premiered_2009" text,
"winning_amount" text,
"eliminated_contestant" text
);
### SQL
Given the database schema, here is the SQL query that answers `What eliminated contestant has October 10, 2009 as the date premiered?`:
```sql
|
SELECT "date_premiered_2009" FROM "season_2" WHERE "contestant_name"='kareena kapoor'; |
## Task
Generate a SQL query to answer the following question:
`What date premiered (2009) has kareena kapoor as the contestant name?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "season_2" (
"contestant_name" text,
"episode_num" text,
"date_premiered_2009" text,
"winning_amount" text,
"eliminated_contestant" text
);
### SQL
Given the database schema, here is the SQL query that answers `What date premiered (2009) has kareena kapoor as the contestant name?`:
```sql
|
SELECT "episode_num" FROM "season_2" WHERE "eliminated_contestant"='govinda & david dhawan'; |
## Task
Generate a SQL query to answer the following question:
`What episode # has govinda & david dhawan as the eliminated contestant?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "season_2" (
"contestant_name" text,
"episode_num" text,
"date_premiered_2009" text,
"winning_amount" text,
"eliminated_contestant" text
);
### SQL
Given the database schema, here is the SQL query that answers `What episode # has govinda & david dhawan as the eliminated contestant?`:
```sql
|
SELECT "winning_amount" FROM "season_2" WHERE "date_premiered_2009"='may 30'; |
## Task
Generate a SQL query to answer the following question:
`What is the winning amount that has May 30, 2009 as the date premiered?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "season_2" (
"contestant_name" text,
"episode_num" text,
"date_premiered_2009" text,
"winning_amount" text,
"eliminated_contestant" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the winning amount that has May 30, 2009 as the date premiered?`:
```sql
|
SELECT "reserved_for_sc_st_none" FROM "assembly_segments" WHERE "name"='lahar'; |
## Task
Generate a SQL query to answer the following question:
`What is the Reserved For of Lahar?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "assembly_segments" (
"constituency_number" text,
"name" text,
"reserved_for_sc_st_none" text,
"district" text,
"number_of_electorates_2009" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Reserved For of Lahar?`:
```sql
|
SELECT MIN("clock_speed_m_hz") FROM "list_of_macintosh_models_grouped_by_cpu_" WHERE "introduced"='january 1986'; |
## Task
Generate a SQL query to answer the following question:
`What is the least clock speed (MHz) with January 1986 as introduced?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_macintosh_models_grouped_by_cpu_" (
"processor" text,
"model" text,
"clock_speed_m_hz" real,
"l1_cache_bytes" text,
"introduced" text,
"discontinued" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the least clock speed (MHz) with January 1986 as introduced?`:
```sql
|
SELECT MIN("clock_speed_m_hz") FROM "list_of_macintosh_models_grouped_by_cpu_" WHERE "introduced"='april 1986'; |
## Task
Generate a SQL query to answer the following question:
`With April 1986 as the introduced, what is the least clock speed (MHz)?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_macintosh_models_grouped_by_cpu_" (
"processor" text,
"model" text,
"clock_speed_m_hz" real,
"l1_cache_bytes" text,
"introduced" text,
"discontinued" text
);
### SQL
Given the database schema, here is the SQL query that answers `With April 1986 as the introduced, what is the least clock speed (MHz)?`:
```sql
|
SELECT "processor" FROM "list_of_macintosh_models_grouped_by_cpu_" WHERE "model"='powerbook 100'; |
## Task
Generate a SQL query to answer the following question:
`The Powerbook 100 model has what processor?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_macintosh_models_grouped_by_cpu_" (
"processor" text,
"model" text,
"clock_speed_m_hz" real,
"l1_cache_bytes" text,
"introduced" text,
"discontinued" text
);
### SQL
Given the database schema, here is the SQL query that answers `The Powerbook 100 model has what processor?`:
```sql
|
SELECT "discontinued" FROM "list_of_macintosh_models_grouped_by_cpu_" WHERE "model"='lisa 2'; |
## Task
Generate a SQL query to answer the following question:
`When was the Lisa 2 model discontinued?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_macintosh_models_grouped_by_cpu_" (
"processor" text,
"model" text,
"clock_speed_m_hz" real,
"l1_cache_bytes" text,
"introduced" text,
"discontinued" text
);
### SQL
Given the database schema, here is the SQL query that answers `When was the Lisa 2 model discontinued?`:
```sql
|
SELECT "rowers" FROM "repechage" WHERE "notes"='fa' AND "time"='6:41.45'; |
## Task
Generate a SQL query to answer the following question:
`Who are the rowers with a time of 6:41.45 and notes of FA?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "repechage" (
"rank" real,
"rowers" text,
"country" text,
"time" text,
"notes" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who are the rowers with a time of 6:41.45 and notes of FA?`:
```sql
|
SELECT "rowers" FROM "repechage" WHERE "country"='united states'; |
## Task
Generate a SQL query to answer the following question:
`Who are the rowers from the United States?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "repechage" (
"rank" real,
"rowers" text,
"country" text,
"time" text,
"notes" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who are the rowers from the United States?`:
```sql
|
SELECT "time" FROM "repechage" WHERE "country"='ukraine'; |
## Task
Generate a SQL query to answer the following question:
`What time did the team from Ukraine have?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "repechage" (
"rank" real,
"rowers" text,
"country" text,
"time" text,
"notes" text
);
### SQL
Given the database schema, here is the SQL query that answers `What time did the team from Ukraine have?`:
```sql
|
SELECT SUM("rank") FROM "repechage" WHERE "notes"='fa' AND "time"='6:41.45'; |
## Task
Generate a SQL query to answer the following question:
`What is the rank for the team that had a time of 6:41.45 and note FA?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "repechage" (
"rank" real,
"rowers" text,
"country" text,
"time" text,
"notes" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the rank for the team that had a time of 6:41.45 and note FA?`:
```sql
|
SELECT COUNT("rank") FROM "repechage" WHERE "country"='australia'; |
## Task
Generate a SQL query to answer the following question:
`What rank was the team from Australia?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "repechage" (
"rank" real,
"rowers" text,
"country" text,
"time" text,
"notes" text
);
### SQL
Given the database schema, here is the SQL query that answers `What rank was the team from Australia?`:
```sql
|
SELECT MAX("game") FROM "regular_season" WHERE "date"='july 31'; |
## Task
Generate a SQL query to answer the following question:
`What is the highest game that has July 31 as the date?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "regular_season" (
"game" real,
"date" text,
"opponent" text,
"score" text,
"location" text,
"record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest game that has July 31 as the date?`:
```sql
|
SELECT SUM("river_mile") FROM "downstream_pittsburgh_to_olmsted" WHERE "location_l"='greenup, kentucky'; |
## Task
Generate a SQL query to answer the following question:
`What is the total of the River Mile in Greenup, Kentucky?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "downstream_pittsburgh_to_olmsted" (
"locks_dam" text,
"location_l" text,
"river_mile" real,
"lock_side" text,
"lock_lift_drop_in_feet" text,
"pool_length_miles" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total of the River Mile in Greenup, Kentucky?`:
```sql
|
SELECT "river_mile" FROM "downstream_pittsburgh_to_olmsted" WHERE "lock_side"='rdb' AND "pool_length_miles"='55.4'; |
## Task
Generate a SQL query to answer the following question:
`What is the River Mile with a RDB lock side and a pool length of 55.4?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "downstream_pittsburgh_to_olmsted" (
"locks_dam" text,
"location_l" text,
"river_mile" real,
"lock_side" text,
"lock_lift_drop_in_feet" text,
"pool_length_miles" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the River Mile with a RDB lock side and a pool length of 55.4?`:
```sql
|
SELECT MAX("river_mile") FROM "downstream_pittsburgh_to_olmsted" WHERE "pool_length_miles"='42.2' AND "lock_lift_drop_in_feet"='21'; |
## Task
Generate a SQL query to answer the following question:
`What is the highest River Mile that has a pool length of 42.2 miles or a lock/lift drop of 21 feet?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "downstream_pittsburgh_to_olmsted" (
"locks_dam" text,
"location_l" text,
"river_mile" real,
"lock_side" text,
"lock_lift_drop_in_feet" text,
"pool_length_miles" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest River Mile that has a pool length of 42.2 miles or a lock/lift drop of 21 feet?`:
```sql
|
SELECT "location_l" FROM "downstream_pittsburgh_to_olmsted" WHERE "river_mile">938.9 AND "locks_dam"='olmsted locks and dam'; |
## Task
Generate a SQL query to answer the following question:
`What is the location of the river mile that is larger than 938.9, and Olmsted Locks and Dam?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "downstream_pittsburgh_to_olmsted" (
"locks_dam" text,
"location_l" text,
"river_mile" real,
"lock_side" text,
"lock_lift_drop_in_feet" text,
"pool_length_miles" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the location of the river mile that is larger than 938.9, and Olmsted Locks and Dam?`:
```sql
|
SELECT MIN("rank") FROM "semifinal_c_d_2" WHERE "time"='8:13.67'; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest ranking for 8:13.67?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "semifinal_c_d_2" (
"rank" real,
"athlete" text,
"country" text,
"time" text,
"notes" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest ranking for 8:13.67?`:
```sql
|
SELECT "time" FROM "semifinal_c_d_2" WHERE "country"='kazakhstan'; |
## Task
Generate a SQL query to answer the following question:
`What is the time for Kazakhstan?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "semifinal_c_d_2" (
"rank" real,
"athlete" text,
"country" text,
"time" text,
"notes" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the time for Kazakhstan?`:
```sql
|
SELECT "notes" FROM "semifinal_c_d_2" WHERE "country"='south africa'; |
## Task
Generate a SQL query to answer the following question:
`What are the notes for South Africa?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "semifinal_c_d_2" (
"rank" real,
"athlete" text,
"country" text,
"time" text,
"notes" text
);
### SQL
Given the database schema, here is the SQL query that answers `What are the notes for South Africa?`:
```sql
|
SELECT "country" FROM "semifinal_c_d_2" WHERE "rank">5; |
## Task
Generate a SQL query to answer the following question:
`What country is ranked higher than 5?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "semifinal_c_d_2" (
"rank" real,
"athlete" text,
"country" text,
"time" text,
"notes" text
);
### SQL
Given the database schema, here is the SQL query that answers `What country is ranked higher than 5?`:
```sql
|
SELECT COUNT("rank") FROM "semifinal_c_d_2" WHERE "notes"='fc' AND "country"='south africa'; |
## Task
Generate a SQL query to answer the following question:
`What is the total rank and fc notes from South Africa?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "semifinal_c_d_2" (
"rank" real,
"athlete" text,
"country" text,
"time" text,
"notes" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total rank and fc notes from South Africa?`:
```sql
|
SELECT "series" FROM "1963" WHERE "director"='friz freleng' AND "production_number"=1614; |
## Task
Generate a SQL query to answer the following question:
`From what series was the title with a production number of 1614 that was directed by Friz Freleng?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "1963" (
"title" text,
"series" text,
"director" text,
"production_number" real,
"release_date" text
);
### SQL
Given the database schema, here is the SQL query that answers `From what series was the title with a production number of 1614 that was directed by Friz Freleng?`:
```sql
|
SELECT "result" FROM "kickboxing_record" WHERE "record"='1-3'; |
## Task
Generate a SQL query to answer the following question:
`What is the Result of the event with a Record of 1-3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "kickboxing_record" (
"result" text,
"record" text,
"method" text,
"event" text,
"round" real,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Result of the event with a Record of 1-3?`:
```sql
|
SELECT "round" FROM "kickboxing_record" WHERE "record"='5-4'; |
## Task
Generate a SQL query to answer the following question:
`What is the Round of the event with a Record of 5-4?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "kickboxing_record" (
"result" text,
"record" text,
"method" text,
"event" text,
"round" real,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Round of the event with a Record of 5-4?`:
```sql
|
SELECT COUNT("latitude") FROM "v" WHERE "land_sqmi">35.747 AND "water_sqmi"=0 AND "geo_id"<3809981860 AND "township"='van meter'; |
## Task
Generate a SQL query to answer the following question:
`What was the latitude for van meter who had a land(sqmi) larger than 35.747, Water(sqmi) of 0 and a GEO ID smaller than 3809981860?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "v" (
"township" text,
"county" text,
"pop_2010" real,
"land_sqmi" real,
"water_sqmi" real,
"latitude" real,
"longitude" real,
"geo_id" real,
"ansi_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `What was the latitude for van meter who had a land(sqmi) larger than 35.747, Water(sqmi) of 0 and a GEO ID smaller than 3809981860?`:
```sql
|
SELECT MAX("pop_2010") FROM "v" WHERE "latitude"=48.853051 AND "water_sqmi"<0.9590000000000001; |
## Task
Generate a SQL query to answer the following question:
`What was the population fo the township with a Latitude of 48.853051, and a Water (sqmi) smaller than 0.9590000000000001?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "v" (
"township" text,
"county" text,
"pop_2010" real,
"land_sqmi" real,
"water_sqmi" real,
"latitude" real,
"longitude" real,
"geo_id" real,
"ansi_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `What was the population fo the township with a Latitude of 48.853051, and a Water (sqmi) smaller than 0.9590000000000001?`:
```sql
|
SELECT MAX("ansi_code") FROM "v" WHERE "water_sqmi"=0 AND "township"='van meter' AND "longitude">-98.444062; |
## Task
Generate a SQL query to answer the following question:
`Van Meter has a water(sqmi) of 0 and a longitude larger than -98.444062, what was their highest ANSI code?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "v" (
"township" text,
"county" text,
"pop_2010" real,
"land_sqmi" real,
"water_sqmi" real,
"latitude" real,
"longitude" real,
"geo_id" real,
"ansi_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `Van Meter has a water(sqmi) of 0 and a longitude larger than -98.444062, what was their highest ANSI code?`:
```sql
|
SELECT MIN("water_sqmi") FROM "v" WHERE "county"='dickey' AND "longitude"<-98.444062; |
## Task
Generate a SQL query to answer the following question:
`What was the lowest water(sqmi) in the county of dickey where the longitude was smaller than -98.444062?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "v" (
"township" text,
"county" text,
"pop_2010" real,
"land_sqmi" real,
"water_sqmi" real,
"latitude" real,
"longitude" real,
"geo_id" real,
"ansi_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `What was the lowest water(sqmi) in the county of dickey where the longitude was smaller than -98.444062?`:
```sql
|
SELECT "coach" FROM "teams" WHERE "team"='northamptonshire steelbacks'; |
## Task
Generate a SQL query to answer the following question:
`Who is the coach for the Northamptonshire Steelbacks?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "teams" (
"team" text,
"location" text,
"county" text,
"division" text,
"home_ground" text,
"coach" text,
"captain" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the coach for the Northamptonshire Steelbacks?`:
```sql
|
SELECT "team" FROM "teams" WHERE "location"='leicester'; |
## Task
Generate a SQL query to answer the following question:
`Which team is located in Leicester?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "teams" (
"team" text,
"location" text,
"county" text,
"division" text,
"home_ground" text,
"coach" text,
"captain" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which team is located in Leicester?`:
```sql
|
SELECT "team" FROM "teams" WHERE "county"='sussex'; |
## Task
Generate a SQL query to answer the following question:
`Which team is in Sussex county?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "teams" (
"team" text,
"location" text,
"county" text,
"division" text,
"home_ground" text,
"coach" text,
"captain" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which team is in Sussex county?`:
```sql
|
SELECT "home_ground" FROM "teams" WHERE "location"='canterbury'; |
## Task
Generate a SQL query to answer the following question:
`What is the home ground for the team located in Canterbury?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "teams" (
"team" text,
"location" text,
"county" text,
"division" text,
"home_ground" text,
"coach" text,
"captain" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the home ground for the team located in Canterbury?`:
```sql
|
SELECT "captain" FROM "teams" WHERE "coach"='giles white'; |
## Task
Generate a SQL query to answer the following question:
`Who is the captain of the team coached by Giles White?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "teams" (
"team" text,
"location" text,
"county" text,
"division" text,
"home_ground" text,
"coach" text,
"captain" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the captain of the team coached by Giles White?`:
```sql
|
SELECT "division" FROM "teams" WHERE "team"='derbyshire falcons'; |
## Task
Generate a SQL query to answer the following question:
`Which division is the Derbyshire Falcons in?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "teams" (
"team" text,
"location" text,
"county" text,
"division" text,
"home_ground" text,
"coach" text,
"captain" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which division is the Derbyshire Falcons in?`:
```sql
|
SELECT "tie_no" FROM "fifth_round_proper" WHERE "home_team"='derby county'; |
## Task
Generate a SQL query to answer the following question:
`Which tie number had a home team of Derby County?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fifth_round_proper" (
"tie_no" text,
"home_team" text,
"score" text,
"away_team" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which tie number had a home team of Derby County?`:
```sql
|
SELECT "score" FROM "fifth_round_proper" WHERE "away_team"='stoke city'; |
## Task
Generate a SQL query to answer the following question:
`What was the score of the tie with an away team of Stoke City?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fifth_round_proper" (
"tie_no" text,
"home_team" text,
"score" text,
"away_team" text,
"date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the score of the tie with an away team of Stoke City?`:
```sql
|
SELECT "artist" FROM "results" WHERE "draw"<14 AND "points"<73 AND "language"='turkish'; |
## Task
Generate a SQL query to answer the following question:
`Which Artist has a Draw smaller than 14, and Points less than 73, and a Language of turkish?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "results" (
"draw" real,
"language" text,
"artist" text,
"english_translation" text,
"place" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Artist has a Draw smaller than 14, and Points less than 73, and a Language of turkish?`:
```sql
|
SELECT COUNT("points") FROM "results" WHERE "artist"='mia martini'; |
## Task
Generate a SQL query to answer the following question:
`How many points does mia martini have?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "results" (
"draw" real,
"language" text,
"artist" text,
"english_translation" text,
"place" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many points does mia martini have?`:
```sql
|
SELECT "artist" FROM "results" WHERE "english_translation"='all this is music'; |
## Task
Generate a SQL query to answer the following question:
`Which Artist has an English translation of all this is music?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "results" (
"draw" real,
"language" text,
"artist" text,
"english_translation" text,
"place" real,
"points" real
);
### SQL
Given the database schema, here is the SQL query that answers `Which Artist has an English translation of all this is music?`:
```sql
|
SELECT "athlete" FROM "top_all_time_athletes_50_metres_women" WHERE "place"='grenoble'; |
## Task
Generate a SQL query to answer the following question:
`What athlete has a Grenoble place?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "top_all_time_athletes_50_metres_women" (
"rank" real,
"time" text,
"athlete" text,
"date" text,
"place" text
);
### SQL
Given the database schema, here is the SQL query that answers `What athlete has a Grenoble place?`:
```sql
|
SELECT "pick" FROM "sixth_round" WHERE "college"='syracuse'; |
## Task
Generate a SQL query to answer the following question:
`What is the Pick number of the Player from Syracuse?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "sixth_round" (
"pick" real,
"team" text,
"player" text,
"position" text,
"college" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Pick number of the Player from Syracuse?`:
```sql
|
SELECT "player" FROM "sixth_round" WHERE "pick">44 AND "position"='offensive guard' AND "college"='mississippi state'; |
## Task
Generate a SQL query to answer the following question:
`What is the Offensive Guard Player from Mississippi State College with a Pick number larter than 44?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "sixth_round" (
"pick" real,
"team" text,
"player" text,
"position" text,
"college" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the Offensive Guard Player from Mississippi State College with a Pick number larter than 44?`:
```sql
|
SELECT "college" FROM "sixth_round" WHERE "team"='denver broncos'; |
## Task
Generate a SQL query to answer the following question:
`What is the College of the Pick from Denver Broncos?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "sixth_round" (
"pick" real,
"team" text,
"player" text,
"position" text,
"college" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the College of the Pick from Denver Broncos?`:
```sql
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.