output stringlengths 27 479 | instruction stringlengths 407 1.39k |
|---|---|
SELECT "round" FROM "mixed_martial_arts_record" WHERE "record"='6-6'; |
## Task
Generate a SQL query to answer the following question:
`How many rounds did the match last when his record was 6-6?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "mixed_martial_arts_record" (
"res" text,
"record" text,
"opponent" text,
... |
SELECT "method" FROM "mixed_martial_arts_record" WHERE "record"='15-11'; |
## Task
Generate a SQL query to answer the following question:
`How did the match end when his record was 15-11?`
### 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" t... |
SELECT COUNT("laps") FROM "moto_gp_classification" WHERE "grid"<7 AND "rider"='ben spies'; |
## Task
Generate a SQL query to answer the following question:
`How many laps did ben spies do on the grid less than 7?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moto_gp_classification" (
"rider" text,
"manufacturer" text,
"laps" real,
"t... |
SELECT MIN("grid") FROM "moto_gp_classification" WHERE "time"='+58.353' AND "laps"<20; |
## Task
Generate a SQL query to answer the following question:
`which grid did less than 20 laps in a time of +58.353?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moto_gp_classification" (
"rider" text,
"manufacturer" text,
"laps" real,
"ti... |
SELECT "time" FROM "moto_gp_classification" WHERE "rider"='valentino rossi'; |
## Task
Generate a SQL query to answer the following question:
`what was valentino rossi's rider time?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moto_gp_classification" (
"rider" text,
"manufacturer" text,
"laps" real,
"time" text,
"gri... |
SELECT "manufacturer" FROM "moto_gp_classification" WHERE "rider"='makoto tamada'; |
## Task
Generate a SQL query to answer the following question:
`Who manufactures Makoto Tamada's vehicle?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moto_gp_classification" (
"rider" text,
"manufacturer" text,
"laps" real,
"time_retired" t... |
SELECT "time_retired" FROM "moto_gp_classification" WHERE "grid"=16; |
## Task
Generate a SQL query to answer the following question:
`What is the time/retired of the one with grid of 16?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moto_gp_classification" (
"rider" text,
"manufacturer" text,
"laps" real,
"time... |
SELECT "team" FROM "managerial_changes" WHERE "outgoing_manager"='gonzalo arconada'; |
## Task
Generate a SQL query to answer the following question:
`What team did gonzalo arconada manage?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "managerial_changes" (
"team" text,
"outgoing_manager" text,
"manner_of_departure" text,
"date... |
SELECT "team" FROM "managerial_changes" WHERE "date_of_vacancy"='9 december 2008'; |
## Task
Generate a SQL query to answer the following question:
`What team replaced their manager on 9 December 2008?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "managerial_changes" (
"team" text,
"outgoing_manager" text,
"manner_of_departure"... |
SELECT "date_of_appointment" FROM "managerial_changes" WHERE "outgoing_manager"='paco chaparro'; |
## Task
Generate a SQL query to answer the following question:
`What was the date of appointment for paco chaparro's replacement?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "managerial_changes" (
"team" text,
"outgoing_manager" text,
"manner_... |
SELECT "date_of_appointment" FROM "managerial_changes" WHERE "outgoing_manager"='javier aguirre'; |
## Task
Generate a SQL query to answer the following question:
`What was the date of appointment for javier aguirre's replacement?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "managerial_changes" (
"team" text,
"outgoing_manager" text,
"manner... |
SELECT "date" FROM "singles_14_5_9" WHERE "opponent_in_the_final"='wen-hsin hsu'; |
## Task
Generate a SQL query to answer the following question:
`What date did Namigata play against Wen-Hsin Hsu in the finals?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_14_5_9" (
"outcome" text,
"date" text,
"tournament" text,
"s... |
SELECT "result" FROM "performances_on" WHERE "week_num"='top 8'; |
## Task
Generate a SQL query to answer the following question:
`What was the result during the week # of top 8?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "performances_on" (
"week_num" text,
"theme" text,
"song_choice" text,
"original_arti... |
SELECT "theme" FROM "performances_on" WHERE "week_num"='top 24 (12 men)'; |
## Task
Generate a SQL query to answer the following question:
`What was the theme during the week # of top 24 (12 men)`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "performances_on" (
"week_num" text,
"theme" text,
"song_choice" text,
"origi... |
SELECT "result" FROM "performances_on" WHERE "week_num"='top 11'; |
## Task
Generate a SQL query to answer the following question:
`What was the result after the week # top 11?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "performances_on" (
"week_num" text,
"theme" text,
"song_choice" text,
"original_artist"... |
SELECT "league" FROM "draft_picks" WHERE "player"='ian schultz'; |
## Task
Generate a SQL query to answer the following question:
`What is the league of player ian schultz?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "draft_picks" (
"round" text,
"pick" real,
"player" text,
"position" text,
"shoots" text,... |
SELECT "birthplace_date" FROM "draft_picks" WHERE "pick"=4; |
## Task
Generate a SQL query to answer the following question:
`What is the birthplace and date of pick 4?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "draft_picks" (
"round" text,
"pick" real,
"player" text,
"position" text,
"shoots" text... |
SELECT "pick" FROM "draft_picks" WHERE "nationality"='canada' AND "player"='ian schultz'; |
## Task
Generate a SQL query to answer the following question:
`What is the pick of player ian schultz from Canada?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "draft_picks" (
"round" text,
"pick" real,
"player" text,
"position" text,
"sho... |
SELECT "opponent" FROM "january" WHERE "date"='january 7'; |
## Task
Generate a SQL query to answer the following question:
`Who is the Opponent on January 7?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "january" (
"date" text,
"h_a_n" text,
"opponent" text,
"score" text,
"record" text
);
### SQL
Gi... |
SELECT "opponent" FROM "january" WHERE "date"='january 16'; |
## Task
Generate a SQL query to answer the following question:
`Who is the Opponent on January 16?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "january" (
"date" text,
"h_a_n" text,
"opponent" text,
"score" text,
"record" text
);
### SQL
G... |
SELECT "score" FROM "january" WHERE "opponent"='philadelphia 76ers'; |
## Task
Generate a SQL query to answer the following question:
`What is the Score of the game against Philadelphia 76ers?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "january" (
"date" text,
"h_a_n" text,
"opponent" text,
"score" text,
"re... |
SELECT "date" FROM "january" WHERE "record"='15-27'; |
## Task
Generate a SQL query to answer the following question:
`What is the Date of the game where the Cavaliers have a Record of 15-27?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "january" (
"date" text,
"h_a_n" text,
"opponent" text,
"sco... |
SELECT "opponent" FROM "january" WHERE "score"='102-125'; |
## Task
Generate a SQL query to answer the following question:
`What was the Opponent in the game with a Score of 102-125?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "january" (
"date" text,
"h_a_n" text,
"opponent" text,
"score" text,
"r... |
SELECT "record" FROM "january" WHERE "score"='98-99'; |
## Task
Generate a SQL query to answer the following question:
`What is the Cavaliers Record in the game with a Score of 98-99?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "january" (
"date" text,
"h_a_n" text,
"opponent" text,
"score" text,... |
SELECT "player" FROM "player_selections" WHERE "position"='no pick' AND "year"=1976; |
## Task
Generate a SQL query to answer the following question:
`What player has a no pick position in 1976?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "player_selections" (
"year" real,
"pick" text,
"player" text,
"position" text,
"colleg... |
SELECT "pick" FROM "player_selections" WHERE "college"='baylor'; |
## Task
Generate a SQL query to answer the following question:
`What pick number was the player that went to baylor college?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "player_selections" (
"year" real,
"pick" text,
"player" text,
"position... |
SELECT "year" FROM "player_selections" WHERE "pick"='15'; |
## Task
Generate a SQL query to answer the following question:
`What year was the player pick number 15 picked?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "player_selections" (
"year" real,
"pick" text,
"player" text,
"position" text,
"co... |
SELECT "record" FROM "regular_season" WHERE "date"='september 2'; |
## Task
Generate a SQL query to answer the following question:
`What was the record on september 2?`
### 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,
"high_points" text,... |
SELECT "high_points" FROM "regular_season" WHERE "opponent"='phoenix'; |
## Task
Generate a SQL query to answer the following question:
`What were phoenix's high points?`
### 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,
"high_points" text,
... |
SELECT "date" FROM "regular_season" WHERE "record"='17-17'; |
## Task
Generate a SQL query to answer the following question:
`When was the record 17-17?`
### 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,
"high_points" text,
"high_... |
SELECT "high_points" FROM "regular_season" WHERE "date"='september 9'; |
## Task
Generate a SQL query to answer the following question:
`What were the high points on september 9?`
### 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,
"high_points"... |
SELECT COUNT("game") FROM "regular_season" WHERE "record"='16-17'; |
## Task
Generate a SQL query to answer the following question:
`How many games had a record of 16-17?`
### 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,
"high_points" tex... |
SELECT "leader" FROM "leaders_in_the_northern_ireland_assembel" WHERE "leader_since"='2007'; |
## Task
Generate a SQL query to answer the following question:
`Which leader has been a leader since 2007?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "leaders_in_the_northern_ireland_assembel" (
"leader" text,
"party" text,
"leader_s_seat" te... |
SELECT SUM("number_of_seats") FROM "leaders_in_the_northern_ireland_assembel" WHERE "leader"='raymond mccartney'; |
## Task
Generate a SQL query to answer the following question:
`How many seats does leader Raymond McCartney have?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "leaders_in_the_northern_ireland_assembel" (
"leader" text,
"party" text,
"leader_s_... |
SELECT "leader" FROM "leaders_in_the_northern_ireland_assembel" WHERE "number_of_seats">8 AND "party"='democratic unionist party'; |
## Task
Generate a SQL query to answer the following question:
`Which leader of the Democratic Unionist party has more than 8 seats?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "leaders_in_the_northern_ireland_assembel" (
"leader" text,
"party" ... |
SELECT "award" FROM "accolades" WHERE "outcome"='nominated' AND "name"='anuya bhagvath'; |
## Task
Generate a SQL query to answer the following question:
`Anuya Bhagvath was nominated for what award?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "accolades" (
"ceremony" text,
"award" text,
"category" text,
"name" text,
"outcome" t... |
SELECT "award" FROM "accolades" WHERE "category"='film lyricist'; |
## Task
Generate a SQL query to answer the following question:
`Which award has film lyricist in the category?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "accolades" (
"ceremony" text,
"award" text,
"category" text,
"name" text,
"outcome"... |
SELECT "ceremony" FROM "accolades" WHERE "award"='vijay award' AND "outcome"='nominated' AND "name"='anuya bhagvath'; |
## Task
Generate a SQL query to answer the following question:
`What is the category Anuya Bhagvath was nominated for at vijay award?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "accolades" (
"ceremony" text,
"award" text,
"category" text,
"... |
SELECT "ceremony" FROM "accolades" WHERE "category"='best lyricist'; |
## Task
Generate a SQL query to answer the following question:
`Which ceremony has the best lyricist category?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "accolades" (
"ceremony" text,
"award" text,
"category" text,
"name" text,
"outcome"... |
SELECT "best_3_year_period" FROM "moves_played_compared_with_computer_choi" WHERE "best_15_year_period"='smyslov; kasparov' AND "position"=5; |
## Task
Generate a SQL query to answer the following question:
`Which best 3-year period has a best 15-year period of smyslov; kasparov, and a Position of 5?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moves_played_compared_with_computer_choi" (
... |
SELECT "best_5_year_period" FROM "moves_played_compared_with_computer_choi" WHERE "best_15_year_period"='alekhine; lasker'; |
## Task
Generate a SQL query to answer the following question:
`Which best 5-year period has a best 15-year period of alekhine; lasker?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moves_played_compared_with_computer_choi" (
"position" real,
"be... |
SELECT "best_10_year_period" FROM "moves_played_compared_with_computer_choi" WHERE "best_2_year_period"='petrosian'; |
## Task
Generate a SQL query to answer the following question:
`Which best 10-year period has a best 2-year period of petrosian?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moves_played_compared_with_computer_choi" (
"position" real,
"best_year... |
SELECT MAX("position") FROM "moves_played_compared_with_computer_choi" WHERE "best_3_year_period"='petrosian'; |
## Task
Generate a SQL query to answer the following question:
`Which Position has a best 3-year period of petrosian?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moves_played_compared_with_computer_choi" (
"position" real,
"best_year" text,
"... |
SELECT "high_rebounds" FROM "regular_season" WHERE "score"='61-59'; |
## Task
Generate a SQL query to answer the following question:
`What is High Rebounds, when Score is 61-59?`
### 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,
"high_point... |
SELECT "score" FROM "regular_season" WHERE "high_rebounds"='nolan (10)'; |
## Task
Generate a SQL query to answer the following question:
`What is Score, when High Rebounds is "Nolan (10)"?`
### 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,
"hig... |
SELECT "opponent" FROM "regular_season" WHERE "high_rebounds"='pierson (6)'; |
## Task
Generate a SQL query to answer the following question:
`What is Opponent, when High Rebounds is "Pierson (6)"?`
### 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,
... |
SELECT SUM("game") FROM "regular_season" WHERE "high_rebounds"='pierson (6)'; |
## Task
Generate a SQL query to answer the following question:
`What is the sum of Game(s), when High Rebounds is "Pierson (6)"?`
### 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... |
SELECT AVG("laps") FROM "race_1" WHERE "driver"='bob wollek'; |
## Task
Generate a SQL query to answer the following question:
`How many Laps did Bob Wollek have?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "race_1" (
"class" text,
"team" text,
"driver" text,
"chassis_engine" text,
"laps" real
);
### S... |
SELECT "laps" FROM "race_1" WHERE "team"='primagaz competition'; |
## Task
Generate a SQL query to answer the following question:
`How many Laps did Team Primagaz Competition have?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "race_1" (
"class" text,
"team" text,
"driver" text,
"chassis_engine" text,
"laps... |
SELECT "team" FROM "race_1" WHERE "class"='c1' AND "laps"=40; |
## Task
Generate a SQL query to answer the following question:
`What Team had 40 Laps in C1 Class?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "race_1" (
"class" text,
"team" text,
"driver" text,
"chassis_engine" text,
"laps" real
);
### S... |
SELECT "team" FROM "race_1" WHERE "class"='c1' AND "laps"=76 AND "driver"='bob wollek'; |
## Task
Generate a SQL query to answer the following question:
`What Team has Bob Wollek as a Driver with 76 Laps in C1 Class?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "race_1" (
"class" text,
"team" text,
"driver" text,
"chassis_engine" ... |
SELECT SUM("laps") FROM "race_1" WHERE "team"='gp motorsport'; |
## Task
Generate a SQL query to answer the following question:
`How many Laps does GP Motorsport Team have?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "race_1" (
"class" text,
"team" text,
"driver" text,
"chassis_engine" text,
"laps" real... |
SELECT "location" FROM "game_log" WHERE "score"='w 105-99'; |
## Task
Generate a SQL query to answer the following question:
`what is the location when the score is w 105-99?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "game_log" (
"game" real,
"date" text,
"opponent" text,
"score" text,
"location" t... |
SELECT "location" FROM "game_log" WHERE "date"='november 23'; |
## Task
Generate a SQL query to answer the following question:
`what is the location on november 23?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "game_log" (
"game" real,
"date" text,
"opponent" text,
"score" text,
"location" text,
"reco... |
SELECT MAX("ends_lost") FROM "round_robin" WHERE "shot_pct">78 AND "ends_won"<38; |
## Task
Generate a SQL query to answer the following question:
`Name the highest Ends Lost which has an Shot % larger than 78, and a Ends Won smaller than 38?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_robin" (
"country" text,
"skip" tex... |
SELECT "country" FROM "round_robin" WHERE "stolen_ends">7 AND "skip"='david murdoch'; |
## Task
Generate a SQL query to answer the following question:
`Name the Country which has Stolen Ends larger than 7, and a Skip of david murdoch?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_robin" (
"country" text,
"skip" text,
"ends_w... |
SELECT AVG("stolen_ends") FROM "round_robin" WHERE "ends_lost"<35; |
## Task
Generate a SQL query to answer the following question:
`Name the average Stolen Ends which has an Ends Lost smaller than 35?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_robin" (
"country" text,
"skip" text,
"ends_won" real,
"e... |
SELECT AVG("blank_ends") FROM "round_robin" WHERE "shot_pct"<78 AND "ends_won">43; |
## Task
Generate a SQL query to answer the following question:
`Name the average Blank Ends which has a Shot % smaller than 78, and a Ends Won larger than 43?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "round_robin" (
"country" text,
"skip" te... |
SELECT "rank" FROM "highest_grossing_films_of_2012" WHERE "title"='skyfall'; |
## Task
Generate a SQL query to answer the following question:
`What rank has skyfall as the title?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "highest_grossing_films_of_2012" (
"rank" real,
"title" text,
"studio" text,
"director_s" text,
... |
SELECT "director_s" FROM "highest_grossing_films_of_2012" WHERE "title"='the intouchables'; |
## Task
Generate a SQL query to answer the following question:
`What director(s) have the intouchables as the title?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "highest_grossing_films_of_2012" (
"rank" real,
"title" text,
"studio" text,
"di... |
SELECT "studio" FROM "highest_grossing_films_of_2012" WHERE "rank"=6; |
## Task
Generate a SQL query to answer the following question:
`What studio has 6 as the rank?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "highest_grossing_films_of_2012" (
"rank" real,
"title" text,
"studio" text,
"director_s" text,
"wor... |
SELECT SUM("rank") FROM "highest_grossing_films_of_2012" WHERE "worldwide_gross"='$1,084,439,099'; |
## Task
Generate a SQL query to answer the following question:
`How many ranks have $1,084,439,099 as the worldwide gross?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "highest_grossing_films_of_2012" (
"rank" real,
"title" text,
"studio" text,... |
SELECT "1981" FROM "distribution" WHERE "number_1971">192 AND "1991"=1748; |
## Task
Generate a SQL query to answer the following question:
`What is the 1981 value of the Macedonian population with a 1971 number greater than 192 and a 1991 of 1748?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "distribution" (
"macedonian_po... |
SELECT MIN("number_1971") FROM "distribution" WHERE "2002">133 AND "1991"<171; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest 1971 number of the Macedonian population with a 2002 value greater than 133 and a 1991 value less than 171?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "distribution"... |
SELECT COUNT("1961") FROM "distribution" WHERE "macedonian_population_in_vojvodina"='plandište' AND "1981">1027; |
## Task
Generate a SQL query to answer the following question:
`What is the total 1961 number of the plandište Macedonian population with a 1981 value greater than 1027?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "distribution" (
"macedonian_popu... |
SELECT COUNT("1961") FROM "distribution" WHERE "number_1971"=3325 AND "1991">3177; |
## Task
Generate a SQL query to answer the following question:
`What is the 1961 total of the Macedonian population with a 1971 number of 3325 and a 1991 value greater than 3177?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "distribution" (
"macedo... |
SELECT "airport" FROM "references" WHERE "city"='muscat'; |
## Task
Generate a SQL query to answer the following question:
`What airport is in Muscat?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"city" text,
"country" text,
"iata" text,
"icao" text,
"airport" text
);
### SQL
Given th... |
SELECT "country" FROM "references" WHERE "city"='bandar abbas'; |
## Task
Generate a SQL query to answer the following question:
`What country is Bandar Abbas in?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"city" text,
"country" text,
"iata" text,
"icao" text,
"airport" text
);
### SQL
Gi... |
SELECT "city" FROM "references" WHERE "country"='india' AND "airport"='sardar vallabhbhai patel international airport'; |
## Task
Generate a SQL query to answer the following question:
`What is the city in India with an airport named Sardar Vallabhbhai Patel International Airport?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"city" text,
"country" tex... |
SELECT "airport" FROM "references" WHERE "country"='china' AND "icao"='zbaa'; |
## Task
Generate a SQL query to answer the following question:
`What airport is in China with an ICAO of zbaa?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"city" text,
"country" text,
"iata" text,
"icao" text,
"airport" text... |
SELECT "airport" FROM "references" WHERE "city"='toronto'; |
## Task
Generate a SQL query to answer the following question:
`What airport is in Toronto?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"city" text,
"country" text,
"iata" text,
"icao" text,
"airport" text
);
### SQL
Given t... |
SELECT "country" FROM "references" WHERE "icao"='ypph'; |
## Task
Generate a SQL query to answer the following question:
`What country has an ICAO of ypph?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "references" (
"city" text,
"country" text,
"iata" text,
"icao" text,
"airport" text
);
### SQL
G... |
SELECT MAX("points") FROM "60_metres_hurdles" WHERE "mark"='8.54' AND "react">0.23800000000000002; |
## Task
Generate a SQL query to answer the following question:
`When the mark is 8.54, the reaction time was over 0.23800000000000002 seconds, what's the highest amount of points recorded?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "60_metres_hurdl... |
SELECT "country" FROM "60_metres_hurdles" WHERE "react"<0.242 AND "points">1041; |
## Task
Generate a SQL query to answer the following question:
`Which country has a reaction time of under 0.242 seconds and over 1041 points?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "60_metres_hurdles" (
"lane" real,
"name" text,
"country... |
SELECT MAX("react") FROM "60_metres_hurdles" WHERE "points"=1008; |
## Task
Generate a SQL query to answer the following question:
`If a country has 1008 points what's their reaction time?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "60_metres_hurdles" (
"lane" real,
"name" text,
"country" text,
"mark" text,... |
SELECT "wicket" FROM "first_class_record_partnerships_by_wicke" WHERE "runs"='580'; |
## Task
Generate a SQL query to answer the following question:
`Which wicket had 580 runs?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_class_record_partnerships_by_wicke" (
"wicket" text,
"runs" text,
"batting_partners" text,
"batting... |
SELECT "fielding_team" FROM "first_class_record_partnerships_by_wicke" WHERE "wicket"='8th'; |
## Task
Generate a SQL query to answer the following question:
`Who fielded against the 8th wicket?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_class_record_partnerships_by_wicke" (
"wicket" text,
"runs" text,
"batting_partners" text,
... |
SELECT "runs" FROM "first_class_record_partnerships_by_wicke" WHERE "batting_partners"='vijay hazare and gul mohammad'; |
## Task
Generate a SQL query to answer the following question:
`How many runs did Vijay Hazare and Gul Mohammad score?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_class_record_partnerships_by_wicke" (
"wicket" text,
"runs" text,
"battin... |
SELECT "batting_partners" FROM "first_class_record_partnerships_by_wicke" WHERE "venue"='colombo'; |
## Task
Generate a SQL query to answer the following question:
`Who were the batting partners in Colombo?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_class_record_partnerships_by_wicke" (
"wicket" text,
"runs" text,
"batting_partners" t... |
SELECT "batting_team" FROM "first_class_record_partnerships_by_wicke" WHERE "season"='2006'; |
## Task
Generate a SQL query to answer the following question:
`Who was the batting team in the 2006 season?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_class_record_partnerships_by_wicke" (
"wicket" text,
"runs" text,
"batting_partners... |
SELECT "season" FROM "first_class_record_partnerships_by_wicke" WHERE "runs"='577'; |
## Task
Generate a SQL query to answer the following question:
`In what season was 577 runs scored?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "first_class_record_partnerships_by_wicke" (
"wicket" text,
"runs" text,
"batting_partners" text,
... |
SELECT "opposing_team" FROM "matches" WHERE "against"=20; |
## Task
Generate a SQL query to answer the following question:
`What opposing team has 20 against?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "matches" (
"opposing_team" text,
"against" real,
"date" text,
"venue" text,
"status" text
);
##... |
SELECT "venue" FROM "matches" WHERE "opposing_team"='hawke''s bay'; |
## Task
Generate a SQL query to answer the following question:
`Venue for Hawke's bay?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "matches" (
"opposing_team" text,
"against" real,
"date" text,
"venue" text,
"status" text
);
### SQL
Given ... |
SELECT AVG("december") FROM "schedule_and_results" WHERE "game"=36; |
## Task
Generate a SQL query to answer the following question:
`What is the average December, when Game is "36"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule_and_results" (
"game" real,
"december" real,
"opponent" text,
"score" text... |
SELECT MIN("game") FROM "schedule_and_results" WHERE "december">13 AND "score"='5 - 0'; |
## Task
Generate a SQL query to answer the following question:
`What is the lowest Game, when December is greater than 13, and when Score is "5 - 0"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule_and_results" (
"game" real,
"december" re... |
SELECT SUM("december") FROM "schedule_and_results" WHERE "game">31 AND "score"='5 - 2'; |
## Task
Generate a SQL query to answer the following question:
`What is the sum of December, when Game is greater than 31, and when Score is "5 - 2"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule_and_results" (
"game" real,
"december" re... |
SELECT "record" FROM "schedule_and_results" WHERE "game"=36; |
## Task
Generate a SQL query to answer the following question:
`What is Record, when Game is "36"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "schedule_and_results" (
"game" real,
"december" real,
"opponent" text,
"score" text,
"record" t... |
SELECT "away_team" FROM "fourth_round_proper" WHERE "home_team"='leatherhead'; |
## Task
Generate a SQL query to answer the following question:
`What was the away team that played against home team Leatherhead?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fourth_round_proper" (
"tie_no" text,
"home_team" text,
"score" text... |
SELECT "score" FROM "fourth_round_proper" WHERE "away_team"='arsenal'; |
## Task
Generate a SQL query to answer the following question:
`What was the score of the match played against away team Arsenal?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "fourth_round_proper" (
"tie_no" text,
"home_team" text,
"score" text... |
SELECT MAX("total_votes") FROM "election_results" WHERE "pct_of_popular_vote"='0.86%' AND "num_of_seats_won">0; |
## Task
Generate a SQL query to answer the following question:
`Can you tell me the highest Total votes that has the % of popular vote of 0.86%, and the # of seats won larger than 0?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "election_results" (
... |
SELECT AVG("total_votes") FROM "election_results" WHERE "num_of_seats_won"<0; |
## Task
Generate a SQL query to answer the following question:
`Can you tell me the average Total votes that has the # of seats won smaller than 0?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "election_results" (
"election" real,
"candidates_fie... |
SELECT COUNT("total_votes") FROM "election_results" WHERE "election">2009 AND "candidates_fielded">61; |
## Task
Generate a SQL query to answer the following question:
`Can you tell me the total number of Total votes that has the Election larger than 2009, and the Candidates fielded larger than 61?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "election_... |
SELECT "tournament" FROM "singles_titles" WHERE "opponent"='guillermo carry'; |
## Task
Generate a SQL query to answer the following question:
`Which tournament did the opponent Guillermo Carry play?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_titles" (
"date" text,
"tournament" text,
"surface" text,
"opponent"... |
SELECT "opponent" FROM "singles_titles" WHERE "date"='april 21, 2008'; |
## Task
Generate a SQL query to answer the following question:
`Who was the opponent on April 21, 2008?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_titles" (
"date" text,
"tournament" text,
"surface" text,
"opponent" text,
"score"... |
SELECT "opponent" FROM "singles_titles" WHERE "surface"='clay' AND "date"='november 22, 2009'; |
## Task
Generate a SQL query to answer the following question:
`Who is the opponent on November 22, 2009, clay surface?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "singles_titles" (
"date" text,
"tournament" text,
"surface" text,
"opponent"... |
SELECT MAX("laps") FROM "moto_gp_classification" WHERE "grid">8 AND "rider"='anthony west'; |
## Task
Generate a SQL query to answer the following question:
`Which Laps have a Grid larger than 8, and a Rider of anthony west?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moto_gp_classification" (
"rider" text,
"manufacturer" text,
"laps"... |
SELECT "time" FROM "moto_gp_classification" WHERE "rider"='anthony west'; |
## Task
Generate a SQL query to answer the following question:
`Which time has a Rider of anthony west?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moto_gp_classification" (
"rider" text,
"manufacturer" text,
"laps" real,
"time" text,
"gr... |
SELECT MAX("grid") FROM "moto_gp_classification" WHERE "rider"='colin edwards' AND "laps"<28; |
## Task
Generate a SQL query to answer the following question:
`Which Grid is the highest one that has a Rider of colin edwards, and Laps smaller than 28?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moto_gp_classification" (
"rider" text,
"manu... |
SELECT MIN("laps") FROM "moto_gp_classification" WHERE "rider"='andrea dovizioso'; |
## Task
Generate a SQL query to answer the following question:
`Which Laps have a Rider of andrea dovizioso?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "moto_gp_classification" (
"rider" text,
"manufacturer" text,
"laps" real,
"time" text,
... |
SELECT "college_junior_club_team_league" FROM "draft_picks" WHERE "round"=6; |
## Task
Generate a SQL query to answer the following question:
`What college/junior/club team had a player selected in round 6?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "draft_picks" (
"round" real,
"player" text,
"position" text,
"nation... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.