text
stringlengths 310
1.28k
|
|---|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "ties" (
"tie_no" real,
"home_team" text,
"score" text,
"away_team" text,
"attendance" real
);
Question: Who was the Home team in Tie #23?
<|assistant|>
SELECT "home_team" FROM "ties" WHERE "tie_no"=23;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "ties" (
"tie_no" real,
"home_team" text,
"score" text,
"away_team" text,
"attendance" real
);
Question: What was the final score in Tie #28?
<|assistant|>
SELECT "score" FROM "ties" WHERE "tie_no"=28;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" real,
"money" real
);
Question: What score has a to par greater than 15, money ($) greater than 116, with billy burke as the player?
<|assistant|>
SELECT "score" FROM "final_leaderboard" WHERE "to_par">15 AND "money">116 AND "player"='billy burke';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" real,
"money" real
);
Question: What player has t3 as the place, with england united states as the country?
<|assistant|>
SELECT "player" FROM "final_leaderboard" WHERE "place"='t3' AND "country"='england united states';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" real,
"money" real
);
Question: What is the lowest money ($) that has t8 as the place, with a to par greater than 19?
<|assistant|>
SELECT MIN("money") FROM "final_leaderboard" WHERE "place"='t8' AND "to_par">19;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" real,
"money" real
);
Question: What score has money ($) greater than 400, with gene sarazen as the player?
<|assistant|>
SELECT "score" FROM "final_leaderboard" WHERE "money">400 AND "player"='gene sarazen';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "missed_the_cut" (
"player" text,
"country" text,
"year_s_won" text,
"total" real,
"to_par" real
);
Question: Which Country has a To par smaller than 7, and a Total of 148?
<|assistant|>
SELECT "country" FROM "missed_the_cut" WHERE "to_par"<7 AND "total"=148;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "missed_the_cut" (
"player" text,
"country" text,
"year_s_won" text,
"total" real,
"to_par" real
);
Question: Which player is from south africa?
<|assistant|>
SELECT "player" FROM "missed_the_cut" WHERE "country"='south africa';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "missed_the_cut" (
"player" text,
"country" text,
"year_s_won" text,
"total" real,
"to_par" real
);
Question: Which Year(s) won has a Total larger than 148, and a To par smaller than 17, and a Country of new zealand?
<|assistant|>
SELECT "year_s_won" FROM "missed_the_cut" WHERE "total">148 AND "to_par"<17 AND "country"='new zealand';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "list_of_medallists" (
"medal" text,
"name" text,
"games" text,
"sport" text,
"event" text
);
Question: In what Event did Dorcus Inzikuru compete?
<|assistant|>
SELECT "event" FROM "list_of_medallists" WHERE "name"='dorcus inzikuru';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "list_of_medallists" (
"medal" text,
"name" text,
"games" text,
"sport" text,
"event" text
);
Question: In what Games did Patrick Etolu compete?
<|assistant|>
SELECT "games" FROM "list_of_medallists" WHERE "name"='patrick etolu';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "list_of_medallists" (
"medal" text,
"name" text,
"games" text,
"sport" text,
"event" text
);
Question: What Medal did James Odwori receive for Boxing in the 1970 Edinburgh Games?
<|assistant|>
SELECT "medal" FROM "list_of_medallists" WHERE "sport"='boxing' AND "games"='1970 edinburgh' AND "name"='james odwori';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "list_of_medallists" (
"medal" text,
"name" text,
"games" text,
"sport" text,
"event" text
);
Question: What is the Medal for the Player in the Light Heavyweight event?
<|assistant|>
SELECT "medal" FROM "list_of_medallists" WHERE "event"='light heavyweight';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "list_of_medallists" (
"medal" text,
"name" text,
"games" text,
"sport" text,
"event" text
);
Question: At what Games did the competitor win a Silver medal in the light heavyweight event?
<|assistant|>
SELECT "games" FROM "list_of_medallists" WHERE "medal"='silver' AND "event"='light heavyweight';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "sixth_round_proper" (
"tie_no" text,
"home_team" text,
"score" text,
"away_team" text,
"date" text
);
Question: What is the Tie no for Away Team Ipswich Town?
<|assistant|>
SELECT "tie_no" FROM "sixth_round_proper" WHERE "away_team"='ipswich town';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "sixth_round_proper" (
"tie_no" text,
"home_team" text,
"score" text,
"away_team" text,
"date" text
);
Question: What is the Date of the Middlesbrough Home game?
<|assistant|>
SELECT "date" FROM "sixth_round_proper" WHERE "home_team"='middlesbrough';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "sixth_round_proper" (
"tie_no" text,
"home_team" text,
"score" text,
"away_team" text,
"date" text
);
Question: What is the Home team in the Game with a Score of 1–0?
<|assistant|>
SELECT "home_team" FROM "sixth_round_proper" WHERE "score"='1–0';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "sixth_round_proper" (
"tie_no" text,
"home_team" text,
"score" text,
"away_team" text,
"date" text
);
Question: What is the Date of the Everton Away game?
<|assistant|>
SELECT "date" FROM "sixth_round_proper" WHERE "away_team"='everton';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "made_the_cut" (
"player" text,
"country" text,
"year_s_won" text,
"total" real,
"to_par" text,
"finish" text
);
Question: When the finish was t31 what was the To par?
<|assistant|>
SELECT "to_par" FROM "made_the_cut" WHERE "finish"='t31';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "made_the_cut" (
"player" text,
"country" text,
"year_s_won" text,
"total" real,
"to_par" text,
"finish" text
);
Question: Who had a finish of t15?
<|assistant|>
SELECT "player" FROM "made_the_cut" WHERE "finish"='t15';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "made_the_cut" (
"player" text,
"country" text,
"year_s_won" text,
"total" real,
"to_par" text,
"finish" text
);
Question: When the total was 290 what was the To par?
<|assistant|>
SELECT "to_par" FROM "made_the_cut" WHERE "total"=290;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "made_the_cut" (
"player" text,
"country" text,
"year_s_won" text,
"total" real,
"to_par" text,
"finish" text
);
Question: What is the Total for Seve Ballesteros?
<|assistant|>
SELECT SUM("total") FROM "made_the_cut" WHERE "player"='seve ballesteros';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "1993_london_revival" (
"year" real,
"award_ceremony" text,
"category" text,
"nominee" text,
"result" text
);
Question: What was the result of Declan Donnellan's nomination?
<|assistant|>
SELECT "result" FROM "1993_london_revival" WHERE "nominee"='declan donnellan';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "1993_london_revival" (
"year" real,
"award_ceremony" text,
"category" text,
"nominee" text,
"result" text
);
Question: What was the result of the Best Actor in a Musical category?
<|assistant|>
SELECT "result" FROM "1993_london_revival" WHERE "category"='best actor in a musical';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "made_the_cut" (
"player" text,
"country" text,
"year_s_won" text,
"total" real,
"to_par" text,
"finish" text
);
Question: WHAT IS THE PLAYER WITH 287?
<|assistant|>
SELECT "player" FROM "made_the_cut" WHERE "total"=287;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "made_the_cut" (
"player" text,
"country" text,
"year_s_won" text,
"total" real,
"to_par" text,
"finish" text
);
Question: WHAT COUNTRY HAS A PLAYER NAMED JACK NICKLAUS?
<|assistant|>
SELECT "country" FROM "made_the_cut" WHERE "player"='jack nicklaus';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" real
);
Question: What is Player, when Country is "United States", and when Place is "6"?
<|assistant|>
SELECT "player" FROM "final_leaderboard" WHERE "country"='united states' AND "place"='6';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" real
);
Question: What is the average Money ( $ ), when Score is "69-69-76-69=283"?
<|assistant|>
SELECT AVG("money") FROM "final_leaderboard" WHERE "score"='69-69-76-69=283';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" real
);
Question: What is Country, when To par is "+1", and when Score is "72-71-70-72=285"?
<|assistant|>
SELECT "country" FROM "final_leaderboard" WHERE "to_par"='+1' AND "score"='72-71-70-72=285';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" real
);
Question: What is Place, when Score is "70-70-68-70=278"?
<|assistant|>
SELECT "place" FROM "final_leaderboard" WHERE "score"='70-70-68-70=278';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "1990s" (
"year" real,
"network" text,
"play_by_play" text,
"colour_commentator_s" text,
"pregame_host" text
);
Question: For which network was Chris Walby the color commentator after 1990?
<|assistant|>
SELECT "network" FROM "1990s" WHERE "year">1990 AND "colour_commentator_s"='chris walby';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "1990s" (
"year" real,
"network" text,
"play_by_play" text,
"colour_commentator_s" text,
"pregame_host" text
);
Question: Who was the pregame host before 1992 when there was a play by play of Bob Irving?
<|assistant|>
SELECT "pregame_host" FROM "1990s" WHERE "year"<1992 AND "play_by_play"='bob irving';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "missed_the_cut" (
"player" text,
"country" text,
"year_won" real,
"total" real,
"to_par" real
);
Question: What is the total of the player who won before 1991 and has a to par less than 14?
<|assistant|>
SELECT COUNT("total") FROM "missed_the_cut" WHERE "year_won"<1991 AND "to_par"<14;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "missed_the_cut" (
"player" text,
"country" text,
"year_won" real,
"total" real,
"to_par" real
);
Question: What is the total to par of player jeff sluman, who won before 1993 and has a total greater than 154?
<|assistant|>
SELECT COUNT("to_par") FROM "missed_the_cut" WHERE "year_won"<1993 AND "player"='jeff sluman' AND "total">154;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "missed_the_cut" (
"player" text,
"country" text,
"year_won" real,
"total" real,
"to_par" real
);
Question: What is the sum of the total of player rich beem, who has a to par greater than 17?
<|assistant|>
SELECT SUM("total") FROM "missed_the_cut" WHERE "player"='rich beem' AND "to_par">17;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "european_cup_history" (
"season" text,
"competition" text,
"round" text,
"club" text,
"home" text,
"away" text,
"aggregate" text
);
Question: Who was the away team in the semifinals?
<|assistant|>
SELECT "away" FROM "european_cup_history" WHERE "round"='semifinals';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "european_cup_history" (
"season" text,
"competition" text,
"round" text,
"club" text,
"home" text,
"away" text,
"aggregate" text
);
Question: What is the home record for the Auxerre club?
<|assistant|>
SELECT "home" FROM "european_cup_history" WHERE "club"='auxerre';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "european_cup_history" (
"season" text,
"competition" text,
"round" text,
"club" text,
"home" text,
"away" text,
"aggregate" text
);
Question: What is the home record for the Maccabi Tel-Aviv club?
<|assistant|>
SELECT "home" FROM "european_cup_history" WHERE "club"='maccabi tel-aviv';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "1996" (
"opposing_teams" text,
"against" real,
"date" text,
"venue" text,
"status" text
);
Question: What is the total number of Against, when Date is "16/03/1996"?
<|assistant|>
SELECT COUNT("against") FROM "1996" WHERE "date"='16/03/1996';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "1996" (
"opposing_teams" text,
"against" real,
"date" text,
"venue" text,
"status" text
);
Question: What is Venue, when Against is greater than 9, and when Date is "03/02/1996"?
<|assistant|>
SELECT "venue" FROM "1996" WHERE "against">9 AND "date"='03/02/1996';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "1996" (
"opposing_teams" text,
"against" real,
"date" text,
"venue" text,
"status" text
);
Question: What is Status, when Opposing Teams is "Scotland"?
<|assistant|>
SELECT "status" FROM "1996" WHERE "opposing_teams"='scotland';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "1996" (
"opposing_teams" text,
"against" real,
"date" text,
"venue" text,
"status" text
);
Question: What is Venue, when Date is "14/12/1996"?
<|assistant|>
SELECT "venue" FROM "1996" WHERE "date"='14/12/1996';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "1996" (
"opposing_teams" text,
"against" real,
"date" text,
"venue" text,
"status" text
);
Question: What is the average Against, when Status is "Five Nations", and when Date is "16/03/1996"?
<|assistant|>
SELECT AVG("against") FROM "1996" WHERE "status"='five nations' AND "date"='16/03/1996';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "24_hours_of_le_mans_results" (
"year" real,
"team" text,
"co_drivers" text,
"class" text,
"laps" real,
"pos" text,
"class_pos" text
);
Question: In what year did the team of aston martin racing have a position of 6th?
<|assistant|>
SELECT COUNT("year") FROM "24_hours_of_le_mans_results" WHERE "team"='aston martin racing' AND "pos"='6th';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "24_hours_of_le_mans_results" (
"year" real,
"team" text,
"co_drivers" text,
"class" text,
"laps" real,
"pos" text,
"class_pos" text
);
Question: Which year did the team of pescarolo sport have a Class Position of 7th?
<|assistant|>
SELECT MAX("year") FROM "24_hours_of_le_mans_results" WHERE "team"='pescarolo sport' AND "class_pos"='7th';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "24_hours_of_le_mans_results" (
"year" real,
"team" text,
"co_drivers" text,
"class" text,
"laps" real,
"pos" text,
"class_pos" text
);
Question: Who were the co-drivers of the vehicle that had both a Class position and position of 7th?
<|assistant|>
SELECT "co_drivers" FROM "24_hours_of_le_mans_results" WHERE "class_pos"='7th' AND "pos"='7th';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "slowest_progress_to_top_division" (
"name" text,
"tournaments" real,
"pro_debut" text,
"top_division_debut" text,
"highest_rank" text
);
Question: Which Rank is Highest for Yoshiazuma?
<|assistant|>
SELECT "highest_rank" FROM "slowest_progress_to_top_division" WHERE "name"='yoshiazuma';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "slowest_progress_to_top_division" (
"name" text,
"tournaments" real,
"pro_debut" text,
"top_division_debut" text,
"highest_rank" text
);
Question: Which Top Division debut for Kitazakura has Tournaments less than 88?
<|assistant|>
SELECT "top_division_debut" FROM "slowest_progress_to_top_division" WHERE "tournaments"<88 AND "name"='kitazakura';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "slowest_progress_to_top_division" (
"name" text,
"tournaments" real,
"pro_debut" text,
"top_division_debut" text,
"highest_rank" text
);
Question: What is the lowest Tournaments with Highest Rank of Maegashira 13?
<|assistant|>
SELECT MIN("tournaments") FROM "slowest_progress_to_top_division" WHERE "highest_rank"='maegashira 13';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "finals" (
"year" real,
"winner" text,
"finalist" text,
"result" text,
"city" text,
"stadium" text
);
Question: What was the city where Hallescher FC won in 2008?
<|assistant|>
SELECT "city" FROM "finals" WHERE "winner"='hallescher fc' AND "year"=2008;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "finals" (
"year" real,
"winner" text,
"finalist" text,
"result" text,
"city" text,
"stadium" text
);
Question: Who was the winner of fc grün-weiß wolfen?
<|assistant|>
SELECT "winner" FROM "finals" WHERE "finalist"='fc grün-weiß wolfen';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "finals" (
"year" real,
"winner" text,
"finalist" text,
"result" text,
"city" text,
"stadium" text
);
Question: What was the stadium past 2012?
<|assistant|>
SELECT "stadium" FROM "finals" WHERE "year">2012;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "workplace_killings" (
"perpetrator" text,
"date" text,
"year" real,
"location" text,
"country" text,
"killed" real,
"injured" text
);
Question: What is the average Year, when Country is "U.S.", and when Location is "Edmond , OK"?
<|assistant|>
SELECT AVG("year") FROM "workplace_killings" WHERE "country"='u.s.' AND "location"='edmond , ok';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "workplace_killings" (
"perpetrator" text,
"date" text,
"year" real,
"location" text,
"country" text,
"killed" real,
"injured" text
);
Question: What is the lowest Killed, when Perpetrator is "Sherrill, Patrick Henry , 44"?
<|assistant|>
SELECT MIN("killed") FROM "workplace_killings" WHERE "perpetrator"='sherrill, patrick henry , 44';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "group_i" (
"position" real,
"club" text,
"played" real,
"points" real,
"wins" real,
"draws" real,
"losses" real,
"goals_for" real,
"goals_against" real,
"goal_difference" real
);
Question: What was the highest goals with fewer than 16 losses, fewer than 11 wins, and a goal difference greater than -9?
<|assistant|>
SELECT MAX("goals_for") FROM "group_i" WHERE "losses"<16 AND "wins"<11 AND "goal_difference">-9;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "group_i" (
"position" real,
"club" text,
"played" real,
"points" real,
"wins" real,
"draws" real,
"losses" real,
"goals_for" real,
"goals_against" real,
"goal_difference" real
);
Question: What is the highest wins entry with fewer than 51 goals, more than 39 points, and a goal difference smaller than 13?
<|assistant|>
SELECT MAX("wins") FROM "group_i" WHERE "goals_against"<51 AND "points">39 AND "goal_difference"<13;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "group_i" (
"position" real,
"club" text,
"played" real,
"points" real,
"wins" real,
"draws" real,
"losses" real,
"goals_for" real,
"goals_against" real,
"goal_difference" real
);
Question: What is the lowest wins entry that has a goal difference less than 33, position higher than 13, and 42 goals?
<|assistant|>
SELECT MIN("wins") FROM "group_i" WHERE "goal_difference"<33 AND "position"<13 AND "goals_for"=42;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "group_i" (
"position" real,
"club" text,
"played" real,
"points" real,
"wins" real,
"draws" real,
"losses" real,
"goals_for" real,
"goals_against" real,
"goal_difference" real
);
Question: What is the total number of goals for entries that have more than 7 draws, 8 wins, and more than 5 losses?
<|assistant|>
SELECT COUNT("goals_for") FROM "group_i" WHERE "draws">7 AND "wins">8 AND "losses">5;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "team_summaries" (
"club" text,
"head_coach" text,
"city" text,
"stadium" text,
"2002_2003_season" text
);
Question: What city is the Stadium estádio dr. magalhães pessoa in?
<|assistant|>
SELECT "city" FROM "team_summaries" WHERE "stadium"='estádio dr. magalhães pessoa';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "team_summaries" (
"club" text,
"head_coach" text,
"city" text,
"stadium" text,
"2002_2003_season" text
);
Question: What city is the Stadium estádio cidade de barcelos in?
<|assistant|>
SELECT "city" FROM "team_summaries" WHERE "stadium"='estádio cidade de barcelos';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "team_summaries" (
"club" text,
"head_coach" text,
"city" text,
"stadium" text,
"2002_2003_season" text
);
Question: Head Coach casemiro mior is at which Club?
<|assistant|>
SELECT "club" FROM "team_summaries" WHERE "head_coach"='casemiro mior';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "team_summaries" (
"club" text,
"head_coach" text,
"city" text,
"stadium" text,
"2002_2003_season" text
);
Question: What City is the Club braga in?
<|assistant|>
SELECT "city" FROM "team_summaries" WHERE "club"='braga';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "team_summaries" (
"club" text,
"head_coach" text,
"city" text,
"stadium" text,
"2002_2003_season" text
);
Question: What place is listed in the 2002-2003 season for the City of Aveiro?
<|assistant|>
SELECT "2002_2003_season" FROM "team_summaries" WHERE "city"='aveiro';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_of_16" (
"team_1" text,
"score" text,
"team_2" text,
"1st_round" text,
"2nd_round" text
);
Question: What is the 1st round with fc nantes (d1) as team 1?
<|assistant|>
SELECT "1st_round" FROM "round_of_16" WHERE "team_1"='fc nantes (d1)';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_of_16" (
"team_1" text,
"score" text,
"team_2" text,
"1st_round" text,
"2nd_round" text
);
Question: What is the team 1 with nîmes olympique (d2) as team 2?
<|assistant|>
SELECT "team_1" FROM "round_of_16" WHERE "team_2"='nîmes olympique (d2)';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "release_history" (
"region" text,
"date" text,
"label" text,
"format" text,
"catalog_number" text,
"lyrics" text
);
Question: In what language is the Lyrics of the release on August 10, 2005 with Catalog number of TOCP-66427?
<|assistant|>
SELECT "lyrics" FROM "release_history" WHERE "date"='august 10, 2005' AND "catalog_number"='tocp-66427';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "release_history" (
"region" text,
"date" text,
"label" text,
"format" text,
"catalog_number" text,
"lyrics" text
);
Question: What is the Label of the CD released in Germany on June 6, 2005?
<|assistant|>
SELECT "label" FROM "release_history" WHERE "date"='june 6, 2005' AND "region"='germany' AND "format"='cd';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "release_history" (
"region" text,
"date" text,
"label" text,
"format" text,
"catalog_number" text,
"lyrics" text
);
Question: What is the Region of the EMI 4 x vinyl release bearing Catalog number 560 6111?
<|assistant|>
SELECT "region" FROM "release_history" WHERE "label"='emi' AND "format"='4 x vinyl' AND "catalog_number"='560 6111';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "release_history" (
"region" text,
"date" text,
"label" text,
"format" text,
"catalog_number" text,
"lyrics" text
);
Question: What language is the Lyrics of the release with Catalog number 560 6111?
<|assistant|>
SELECT "lyrics" FROM "release_history" WHERE "catalog_number"='560 6111';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "release_history" (
"region" text,
"date" text,
"label" text,
"format" text,
"catalog_number" text,
"lyrics" text
);
Question: What is the Region of the release with Catalog number 3 12046 2?
<|assistant|>
SELECT "region" FROM "release_history" WHERE "catalog_number"='3 12046 2';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "release_history" (
"region" text,
"date" text,
"format_s" text,
"edition_s" text,
"label" text
);
Question: What is the Label of the September 19, 2008 release in Germany?
<|assistant|>
SELECT "label" FROM "release_history" WHERE "date"='september 19, 2008' AND "region"='germany';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "release_history" (
"region" text,
"date" text,
"format_s" text,
"edition_s" text,
"label" text
);
Question: What is the Edition of the release in Germany?
<|assistant|>
SELECT "edition_s" FROM "release_history" WHERE "region"='germany';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "release_history" (
"region" text,
"date" text,
"format_s" text,
"edition_s" text,
"label" text
);
Question: What is the Format(s) of the release on September 23, 2008?
<|assistant|>
SELECT "format_s" FROM "release_history" WHERE "date"='september 23, 2008';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "release_history" (
"region" text,
"date" text,
"format_s" text,
"edition_s" text,
"label" text
);
Question: What is the Label of the release on April 24, 2009 in Germany?
<|assistant|>
SELECT "label" FROM "release_history" WHERE "region"='germany' AND "date"='april 24, 2009';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "ultra_low_voltage_processors" (
"model_number" text,
"clock_speed" text,
"l1_cache" text,
"l2_cache" text,
"fsb_speed" text,
"clock_multiplier" text,
"idle_power" text,
"socket" text,
"cores" real,
"release_date" text
);
Question: What is the L2 Cache for Model Number nano u3400 with an Idle Power of 100mw?
<|assistant|>
SELECT "l2_cache" FROM "ultra_low_voltage_processors" WHERE "idle_power"='100mw' AND "model_number"='nano u3400';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "ultra_low_voltage_processors" (
"model_number" text,
"clock_speed" text,
"l1_cache" text,
"l2_cache" text,
"fsb_speed" text,
"clock_multiplier" text,
"idle_power" text,
"socket" text,
"cores" real,
"release_date" text
);
Question: What is the total Cores with a Clock Speed of 1.3ghz?
<|assistant|>
SELECT COUNT("cores") FROM "ultra_low_voltage_processors" WHERE "clock_speed"='1.3ghz';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" text
);
Question: What's the to par for the score of 68-74-71-77=290?
<|assistant|>
SELECT "to_par" FROM "final_leaderboard" WHERE "score"='68-74-71-77=290';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" text
);
Question: What's the money ($) for the t3 place and the score of 74-74-71-69=288?
<|assistant|>
SELECT "money" FROM "final_leaderboard" WHERE "place"='t3' AND "score"='74-74-71-69=288';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" text
);
Question: What's the score for $22,500?
<|assistant|>
SELECT "score" FROM "final_leaderboard" WHERE "money"='22,500';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_leaderboard" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" text
);
Question: What's the to par for the t1 place with a score of 70-72-73-72=287?
<|assistant|>
SELECT "to_par" FROM "final_leaderboard" WHERE "place"='t1' AND "score"='70-72-73-72=287';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "references" (
"rank" real,
"railway_station" text,
"annual_entry_exit_millions_2011_12" real,
"annual_interchanges_millions_2011_12" real,
"total_passengers_millions_2011_12" real,
"location" text,
"number_of_platforms" real
);
Question: What's the average annual interchange for a rank over 26 in liverpool with an annual entry/exit less than 14.209 and more than 10 platforms?
<|assistant|>
SELECT AVG("annual_interchanges_millions_2011_12") FROM "references" WHERE "rank">26 AND "location"='liverpool' AND "annual_entry_exit_millions_2011_12"<14.209 AND "number_of_platforms">10;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "references" (
"rank" real,
"railway_station" text,
"annual_entry_exit_millions_2011_12" real,
"annual_interchanges_millions_2011_12" real,
"total_passengers_millions_2011_12" real,
"location" text,
"number_of_platforms" real
);
Question: What's the highest annual interchange for wimbledon railway station?
<|assistant|>
SELECT MAX("annual_interchanges_millions_2011_12") FROM "references" WHERE "railway_station"='wimbledon';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "references" (
"rank" real,
"railway_station" text,
"annual_entry_exit_millions_2011_12" real,
"annual_interchanges_millions_2011_12" real,
"total_passengers_millions_2011_12" real,
"location" text,
"number_of_platforms" real
);
Question: What's the lowest number of total passengers (millions) for an annual entry/exit of 36.609?
<|assistant|>
SELECT MIN("total_passengers_millions_2011_12") FROM "references" WHERE "annual_entry_exit_millions_2011_12"=36.609;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "references" (
"rank" real,
"railway_station" text,
"annual_entry_exit_millions_2011_12" real,
"annual_interchanges_millions_2011_12" real,
"total_passengers_millions_2011_12" real,
"location" text,
"number_of_platforms" real
);
Question: What rank has an annual interchange less than 1.99 million, an annual entry/exit less than 13.835 million, and more than 13.772 million total passengers?
<|assistant|>
SELECT "rank" FROM "references" WHERE "annual_interchanges_millions_2011_12"<1.99 AND "annual_entry_exit_millions_2011_12"<13.835 AND "total_passengers_millions_2011_12">13.772;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "references" (
"rank" real,
"railway_station" text,
"annual_entry_exit_millions_2011_12" real,
"annual_interchanges_millions_2011_12" real,
"total_passengers_millions_2011_12" real,
"location" text,
"number_of_platforms" real
);
Question: How many ranks are in liverpool with more than 3 platforms and an annual interchange less than 0.778 million?
<|assistant|>
SELECT COUNT("rank") FROM "references" WHERE "location"='liverpool' AND "number_of_platforms">3 AND "annual_interchanges_millions_2011_12"<0.778;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "minnesota_counties_ranked_by_per_capita_" (
"county" text,
"per_capita_income" text,
"median_household_income" text,
"median_family_income" text,
"population" real,
"number_of_households" real
);
Question: Which Number of households has Per capita income of $21,571, and a Population smaller than 9,783?
<|assistant|>
SELECT AVG("number_of_households") FROM "minnesota_counties_ranked_by_per_capita_" WHERE "per_capita_income"='$21,571' AND "population"<'9,783';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "minnesota_counties_ranked_by_per_capita_" (
"county" text,
"per_capita_income" text,
"median_household_income" text,
"median_family_income" text,
"population" real,
"number_of_households" real
);
Question: Which Number of households has a County of cook, and Population smaller than 5,176?
<|assistant|>
SELECT AVG("number_of_households") FROM "minnesota_counties_ranked_by_per_capita_" WHERE "county"='cook' AND "population"<'5,176';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "minnesota_counties_ranked_by_per_capita_" (
"county" text,
"per_capita_income" text,
"median_household_income" text,
"median_family_income" text,
"population" real,
"number_of_households" real
);
Question: What Per capita income has a Median family income of $50,755?
<|assistant|>
SELECT "per_capita_income" FROM "minnesota_counties_ranked_by_per_capita_" WHERE "median_family_income"='$50,755';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "minnesota_counties_ranked_by_per_capita_" (
"county" text,
"per_capita_income" text,
"median_household_income" text,
"median_family_income" text,
"population" real,
"number_of_households" real
);
Question: What Number of households have a Median family income of $58,491?
<|assistant|>
SELECT "number_of_households" FROM "minnesota_counties_ranked_by_per_capita_" WHERE "median_family_income"='$58,491';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "second_round" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text
);
Question: What was the score of the golfer representing Scotland?
<|assistant|>
SELECT "score" FROM "second_round" WHERE "country"='scotland';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "second_round" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text
);
Question: What was the to par score of the golfer that had a score of 68-70=138?
<|assistant|>
SELECT "to_par" FROM "second_round" WHERE "score"='68-70=138';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "second_round" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text
);
Question: Which golfer had a score of 69-71=140?
<|assistant|>
SELECT "player" FROM "second_round" WHERE "score"='69-71=140';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_round" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" real
);
Question: Which country is t3 finisher billy mayfair from?
<|assistant|>
SELECT "country" FROM "final_round" WHERE "place"='t3' AND "player"='billy mayfair';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_round" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" real
);
Question: Which Country has a Player of jodie mudd?
<|assistant|>
SELECT "country" FROM "final_round" WHERE "player"='jodie mudd';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_round" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" real
);
Question: Which Money (£) has a Player of jodie mudd?
<|assistant|>
SELECT COUNT("money") FROM "final_round" WHERE "player"='jodie mudd';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_round" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" real
);
Question: What is the total Money (£) of Player of nick faldo?
<|assistant|>
SELECT SUM("money") FROM "final_round" WHERE "player"='nick faldo';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_round" (
"place" text,
"player" text,
"country" text,
"score" text,
"to_par" text,
"money" real
);
Question: What is the total Money (£) with a Place of t6, and a Player of ian baker-finch?
<|assistant|>
SELECT COUNT("money") FROM "final_round" WHERE "place"='t6' AND "player"='ian baker-finch';<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "first_division_final_table" (
"position" real,
"team" text,
"played" real,
"drawn" real,
"lost" real,
"goals_for" real,
"goals_against" real,
"goal_difference" text,
"points_1" text
);
Question: What position was the team who had less then 63 goals against and less than 6 losses?
<|assistant|>
SELECT AVG("position") FROM "first_division_final_table" WHERE "goals_against"<63 AND "lost"<6;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "first_division_final_table" (
"position" real,
"team" text,
"played" real,
"drawn" real,
"lost" real,
"goals_for" real,
"goals_against" real,
"goal_difference" text,
"points_1" text
);
Question: How many times did the team lose who had 1 of 37 points and less than 60 goals against?
<|assistant|>
SELECT MIN("lost") FROM "first_division_final_table" WHERE "points_1"='37' AND "goals_against"<60;<|endoftext|>
|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "first_division_final_table" (
"position" real,
"team" text,
"played" real,
"drawn" real,
"lost" real,
"goals_for" real,
"goals_against" real,
"goal_difference" text,
"points_1" text
);
Question: How many times did the team lose who had a goal difference of +2, 52 goals for, and less than 9 draws?
<|assistant|>
SELECT MIN("lost") FROM "first_division_final_table" WHERE "goal_difference"='+2' AND "goals_for"=52 AND "drawn"<9;<|endoftext|>
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.