text stringlengths 310 1.28k |
|---|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season" (
"game" real,
"october" real,
"opponent" text,
"score" text,
"record" text,
"points" real
);
Question: What was the score of the game that had more than 8 points?
<|assistant|>
SELECT "score" FROM "regular_season" WHERE "points">8;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "results" (
"event" text,
"round" text,
"result" text,
"opponent" text,
"score" text
);
Question: The round that had the final, what was the result?
<|assistant|>
SELECT "result" FROM "results" WHERE "round"='final';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "results" (
"event" text,
"round" text,
"result" text,
"opponent" text,
"score" text
);
Question: Opponent of andry laffita had what score?
<|assistant|>
SELECT "score" FROM "results" WHERE "opponent"='andry laffita';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "results" (
"event" text,
"round" text,
"result" text,
"opponent" text,
"score" text
);
Question: Opponent of igor samoilenco had what result?
<|assistant|>
SELECT "result" FROM "results" WHERE "opponent"='igor samoilenco';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "results" (
"event" text,
"round" text,
"result" text,
"opponent" text,
"score" text
);
Question: Score of 33-22 had what round?
<|assistant|>
SELECT "round" FROM "results" WHERE "score"='33-22';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "results" (
"event" text,
"round" text,
"result" text,
"opponent" text,
"score" text
);
Question: Round of first had what opponent?
<|assistant|>
SELECT "opponent" FROM "results" WHERE "round"='first';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "results" (
"event" text,
"round" text,
"result" text,
"opponent" text,
"score" text
);
Question: Result of win, and a Score of 33-22 involved what event?
<|assistant|>
SELECT "event" FROM "results" WHERE "result"='win' AND "score"='33-22';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season" (
"game" real,
"february" real,
"opponent" text,
"score" text,
"record" text,
"points" real
);
Question: What were the lowest points of game 60?
<|assistant|>
SELECT MIN("points") FROM "regular_season" WHERE "game"=60;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "singles_5_2_3" (
"outcome" text,
"date" text,
"championship" text,
"surface" text,
"opponent_in_the_final" text,
"score_in_the_final" text
);
Question: What championship had Francesca Schiavone in the finals?
<|assistant|>
SELECT "championship" FROM "singles_5_2_3" WHERE "opponent_in_the_final"='francesca schiavone';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "college_sports" (
"school" text,
"mascot" text,
"conference" text,
"national_titles" real,
"founded" real
);
Question: What is the total number of national titles for the team with doane tigers as the mascot?
<|assistant|>
SELECT COUNT("national_titles") FROM "college_sports" WHERE "mascot"='doane tigers';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "season_by_season_results" (
"year" text,
"coach" text,
"crew" text,
"record" text,
"win_pct" real
);
Question: Which year's crew is varsity 8+ when the record is 7-3?
<|assistant|>
SELECT "year" FROM "season_by_season_results" WHERE "crew"='varsity 8+' AND "record"='7-3';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "season_by_season_results" (
"year" text,
"coach" text,
"crew" text,
"record" text,
"win_pct" real
);
Question: What is the total number of win % when John Gartin is coach, the crew is varsity 8+, and the year is 2005?
<|assistant|>
SELECT SUM("win_pct") FROM "season_by_season_results" WHERE "coach"='john gartin' AND "crew"='varsity 8+' AND "year"='2005';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "season_by_season_results" (
"year" text,
"coach" text,
"crew" text,
"record" text,
"win_pct" real
);
Question: What is the largest win percentage when John Gartin is coach, the record is 11-0, and the year is 2009?
<|assistant|>
SELECT MAX("win_pct") FROM "season_by_season_results" WHERE "coach"='john gartin' AND "record"='11-0' AND "year"='2009';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "season_by_season_results" (
"year" text,
"coach" text,
"crew" text,
"record" text,
"win_pct" real
);
Question: What is the total of win percentages when the year is 2008 and the crew is varsity 8+?
<|assistant|>
SELECT SUM("win_pct") FROM "season_by_season_results" WHERE "year"='2008' AND "crew"='varsity 8+';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "nfl_draft" (
"round" real,
"pick" real,
"player" text,
"position" text,
"school" text
);
Question: What is the pick number for the tight end who was picked after round 6?
<|assistant|>
SELECT COUNT("pick") FROM "nfl_draft" WHERE "round">6 AND "position"='tight end';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "nfl_draft" (
"round" real,
"pick" real,
"player" text,
"position" text,
"school" text
);
Question: What is the lowest round for the player whose position is guard and had a pick number smaller than 144?
<|assistant|>
SELECT MIN("round") FROM "nfl_draft" WHERE "position"='guard' AND "pick"<144;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "nfl_draft" (
"round" real,
"pick" real,
"player" text,
"position" text,
"school" text
);
Question: What was the position of terry jones whose pick number was after 256?
<|assistant|>
SELECT "position" FROM "nfl_draft" WHERE "pick">256 AND "player"='terry jones';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "game_log" (
"date" text,
"opponent" text,
"score" text,
"loss" text,
"attendance" real,
"record" text
);
Question: Which Loss has a Record of 30-32?
<|assistant|>
SELECT "loss" FROM "game_log" WHERE "record"='30-32';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "game_log" (
"date" text,
"opponent" text,
"score" text,
"loss" text,
"attendance" real,
"record" text
);
Question: Which Attendance is the highest one that has a Record of 37-38?
<|assistant|>
SELECT MAX("attendance") FROM "game_log" WHERE "record"='37-38';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "game_log" (
"date" text,
"opponent" text,
"score" text,
"loss" text,
"attendance" real,
"record" text
);
Question: Which Score has a Loss of buehrle (7-2)?
<|assistant|>
SELECT "score" FROM "game_log" WHERE "loss"='buehrle (7-2)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "atlanta_falcons_draft_history" (
"round" real,
"pick_num" real,
"overall" real,
"name" text,
"position" text,
"college" text
);
Question: Which Overall is the average one that has a Pick # larger than 7, and a Round larger than 4, and a Name of glen howe?
<|assistant|>
SELECT AVG("overall") FROM "atlanta_falcons_draft_history" WHERE "pick_num">7 AND "round">4 AND "name"='glen howe';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "atlanta_falcons_draft_history" (
"round" real,
"pick_num" real,
"overall" real,
"name" text,
"position" text,
"college" text
);
Question: Which Round is the lowest one that has a Pick # larger than 10, and a Position of tight end, and an Overall smaller than 132?
<|assistant|>
SELECT MIN("round") FROM "atlanta_falcons_draft_history" WHERE "pick_num">10 AND "position"='tight end' AND "overall"<132;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "atlanta_falcons_draft_history" (
"round" real,
"pick_num" real,
"overall" real,
"name" text,
"position" text,
"college" text
);
Question: Which Round is the highest one that has an Overall of 32, and a Pick # smaller than 4?
<|assistant|>
SELECT MAX("round") FROM "atlanta_falcons_draft_history" WHERE "overall"=32 AND "pick_num"<4;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "atlanta_falcons_draft_history" (
"round" real,
"pick_num" real,
"overall" real,
"name" text,
"position" text,
"college" text
);
Question: How many Picks have a Round larger than 8, and a College of fresno state?
<|assistant|>
SELECT COUNT("pick_num") FROM "atlanta_falcons_draft_history" WHERE "round">8 AND "college"='fresno state';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "atlanta_falcons_draft_history" (
"round" real,
"pick_num" real,
"overall" real,
"name" text,
"position" text,
"college" text
);
Question: Which Overall is the highest one that has a College of oklahoma, and a Pick # smaller than 4?
<|assistant|>
SELECT MAX("overall") FROM "atlanta_falcons_draft_history" WHERE "college"='oklahoma' AND "pick_num"<4;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "under_23" (
"date" text,
"venue" text,
"score" text,
"result" text,
"competition" text
);
Question: What is the result of the match on 30 July 2004?
<|assistant|>
SELECT "result" FROM "under_23" WHERE "date"='30 july 2004';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "under_23" (
"date" text,
"venue" text,
"score" text,
"result" text,
"competition" text
);
Question: What is the result of the match on 3 March 2004?
<|assistant|>
SELECT "result" FROM "under_23" WHERE "date"='3 march 2004';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "under_23" (
"date" text,
"venue" text,
"score" text,
"result" text,
"competition" text
);
Question: What is the score of the friendly match?
<|assistant|>
SELECT "score" FROM "under_23" WHERE "competition"='friendly match';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"attendance" real
);
Question: Which Week had a Result of w 10-0, and an Attendance smaller than 58,571?
<|assistant|>
SELECT COUNT("week") FROM "schedule" WHERE "result"='w 10-0' AND "attendance"<'58,571';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"attendance" real
);
Question: Which Week had a Result of w 23-17?
<|assistant|>
SELECT SUM("week") FROM "schedule" WHERE "result"='w 23-17';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"attendance" real
);
Question: What was the Attendance on october 2, 1977?
<|assistant|>
SELECT "attendance" FROM "schedule" WHERE "date"='october 2, 1977';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "medal_table" (
"rank" text,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
Question: Bronze of 2, and a Silver smaller than 0 then what is the sum of the gold?
<|assistant|>
SELECT SUM("gold") FROM "medal_table" WHERE "bronze"=2 AND "silver"<0;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "medal_table" (
"rank" text,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
Question: Smaller than 4, and a Silver larger than 0, and a Rank of 3, and a Bronze smaller than 6 then what is the sum of the gold?
<|assistant|>
SELECT SUM("total") FROM "medal_table" WHERE "gold"<4 AND "silver">0 AND "rank"='3' AND "bronze"<6;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "medal_table" (
"rank" text,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
Question: Total larger than 3, and a Rank of 4, and a Silver larger than 0 has what average gold?
<|assistant|>
SELECT AVG("gold") FROM "medal_table" WHERE "total">3 AND "rank"='4' AND "silver">0;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "medal_table" (
"rank" text,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
Question: Total smaller than 10, and a Gold larger than 1 then what is the lowest silver?
<|assistant|>
SELECT MIN("silver") FROM "medal_table" WHERE "total"<10 AND "gold">1;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "season_schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"game_site" text,
"attendance" real
);
Question: What was the date of the week 9 game?
<|assistant|>
SELECT "date" FROM "season_schedule" WHERE "week"=9;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "grand_prix_motorcycle_racing_results" (
"year" real,
"class" text,
"team" text,
"points" real,
"rank" text,
"wins" real
);
Question: What class has over 0 wins and 42 points?
<|assistant|>
SELECT "class" FROM "grand_prix_motorcycle_racing_results" WHERE "wins">0 AND "points"=42;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "grand_prix_motorcycle_racing_results" (
"year" real,
"class" text,
"team" text,
"points" real,
"rank" text,
"wins" real
);
Question: What team was the bike with a 350cc class, over 2 points, and 1 win?
<|assistant|>
SELECT "team" FROM "grand_prix_motorcycle_racing_results" WHERE "class"='350cc' AND "points">2 AND "wins"=1;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "grand_prix_motorcycle_racing_results" (
"year" real,
"class" text,
"team" text,
"points" real,
"rank" text,
"wins" real
);
Question: What is the earliest year associated with 0 wins and 42 points?
<|assistant|>
SELECT MIN("year") FROM "grand_prix_motorcycle_racing_results" WHERE "wins">0 AND "points"=42;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "player_of_the_year" (
"season" text,
"player" text,
"position" text,
"nationality" text,
"team" text
);
Question: What Nationality has the Player of Marcus Walker?
<|assistant|>
SELECT "nationality" FROM "player_of_the_year" WHERE "player"='marcus walker';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "player_of_the_year" (
"season" text,
"player" text,
"position" text,
"nationality" text,
"team" text
);
Question: What Season is listed for the Player of Jon Stefansson?
<|assistant|>
SELECT "season" FROM "player_of_the_year" WHERE "player"='jon stefansson';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "player_of_the_year" (
"season" text,
"player" text,
"position" text,
"nationality" text,
"team" text
);
Question: Which Team has the Player of A.J. Moye?
<|assistant|>
SELECT "team" FROM "player_of_the_year" WHERE "player"='a.j. moye';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "player_of_the_year" (
"season" text,
"player" text,
"position" text,
"nationality" text,
"team" text
);
Question: What Position does the Team of KR and the Player of Marcus Walker have listed?
<|assistant|>
SELECT "position" FROM "player_of_the_year" WHERE "team"='kr' AND "player"='marcus walker';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "tallest_proposed" (
"rank" real,
"name" text,
"location" text,
"height_feet_metres" text,
"floors" text,
"year_proposed" text
);
Question: What building is in ljubljana, proposed in 2010, and has 15 floors?
<|assistant|>
SELECT "name" FROM "tallest_proposed" WHERE "location"='ljubljana' AND "year_proposed"='2010' AND "floors"='15';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "table_of_federal_taxation_and_spending_b" (
"state" text,
"revenue_millions" text,
"population" real,
"revenue_per_capita" text,
"spending_millions" text,
"spending_per_capita" text,
"net_contribution_per_capita" text
);
Question: What is the Revenue of the population of more than 1,499,402, with Spending (millions) of $13,986?
<|assistant|>
SELECT "revenue_millions" FROM "table_of_federal_taxation_and_spending_b" WHERE "population">'1,499,402' AND "spending_millions"='$13,986';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "table_of_federal_taxation_and_spending_b" (
"state" text,
"revenue_millions" text,
"population" real,
"revenue_per_capita" text,
"spending_millions" text,
"spending_per_capita" text,
"net_contribution_per_capita" text
);
Question: What is the Revenue per capita for Vermont?
<|assistant|>
SELECT "revenue_per_capita" FROM "table_of_federal_taxation_and_spending_b" WHERE "state"='vermont';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "table_of_federal_taxation_and_spending_b" (
"state" text,
"revenue_millions" text,
"population" real,
"revenue_per_capita" text,
"spending_millions" text,
"spending_per_capita" text,
"net_contribution_per_capita" text
);
Question: What state has a Net contribution per capita of $-171?
<|assistant|>
SELECT "state" FROM "table_of_federal_taxation_and_spending_b" WHERE "net_contribution_per_capita"='$-171';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_2" (
"pick" real,
"player" text,
"country_of_origin" text,
"pba_team" text,
"college" text
);
Question: Who is the PBA team with Mlqu college?
<|assistant|>
SELECT "pba_team" FROM "round_2" WHERE "college"='mlqu';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_2" (
"pick" real,
"player" text,
"country_of_origin" text,
"pba_team" text,
"college" text
);
Question: Which country of origin corresponds to Far Eastern college?
<|assistant|>
SELECT "country_of_origin" FROM "round_2" WHERE "college"='far eastern';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_2" (
"pick" real,
"player" text,
"country_of_origin" text,
"pba_team" text,
"college" text
);
Question: Who is the player with the PBA team of Barangay Ginebra Kings?
<|assistant|>
SELECT "player" FROM "round_2" WHERE "pba_team"='barangay ginebra kings';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "game_log" (
"date" text,
"opponent" text,
"score" text,
"loss" text,
"stadium" text,
"attendance" real,
"record" text
);
Question: Who was the opponent on April 28?
<|assistant|>
SELECT "opponent" FROM "game_log" WHERE "date"='april 28';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "top_10_albums" (
"issue_date" real,
"album_title" text,
"artist" text,
"sales" real,
"highest_position" real
);
Question: What is the highest position the album Where we belong, which had an issue date higher than 9, had?
<|assistant|>
SELECT COUNT("highest_position") FROM "top_10_albums" WHERE "issue_date"<9 AND "album_title"='where we belong';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "top_10_albums" (
"issue_date" real,
"album_title" text,
"artist" text,
"sales" real,
"highest_position" real
);
Question: What is the biggest issue date Madonna, who had less than 1,060,000 sales, had?
<|assistant|>
SELECT MAX("issue_date") FROM "top_10_albums" WHERE "artist"='madonna' AND "sales"<'1,060,000';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "top_10_albums" (
"issue_date" real,
"album_title" text,
"artist" text,
"sales" real,
"highest_position" real
);
Question: What is the highest position Talk on Corners, which had an issue date greater than 1, had?
<|assistant|>
SELECT COUNT("highest_position") FROM "top_10_albums" WHERE "album_title"='talk on corners' AND "issue_date">1;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "top_10_albums" (
"issue_date" real,
"album_title" text,
"artist" text,
"sales" real,
"highest_position" real
);
Question: What is the highest sales All Saints had?
<|assistant|>
SELECT MAX("sales") FROM "top_10_albums" WHERE "album_title"='all saints';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "teams_and_drivers" (
"team" text,
"manufacturer" text,
"car_model" text,
"engine" text,
"driver" text
);
Question: Who is the Driver that has Car Model Commodore VS?
<|assistant|>
SELECT "driver" FROM "teams_and_drivers" WHERE "car_model"='commodore vs';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "teams_and_drivers" (
"team" text,
"manufacturer" text,
"car_model" text,
"engine" text,
"driver" text
);
Question: What Car Model has the Manufacturer of Saab, and Driver Dean Randle?
<|assistant|>
SELECT "car_model" FROM "teams_and_drivers" WHERE "manufacturer"='saab' AND "driver"='dean randle';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "teams_and_drivers" (
"team" text,
"manufacturer" text,
"car_model" text,
"engine" text,
"driver" text
);
Question: Who is the Driver with the Team of P & L Mechanical Services?
<|assistant|>
SELECT "driver" FROM "teams_and_drivers" WHERE "team"='p & l mechanical services';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "teams_and_drivers" (
"team" text,
"manufacturer" text,
"car_model" text,
"engine" text,
"driver" text
);
Question: What Car Model has the Engine of Ford 6.0 V8?
<|assistant|>
SELECT "car_model" FROM "teams_and_drivers" WHERE "engine"='ford 6.0 v8';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "teams_and_drivers" (
"team" text,
"manufacturer" text,
"car_model" text,
"engine" text,
"driver" text
);
Question: What Team has the Engine of Chevrolet 6.0 V8, the Manufacturer of Opel, and the Driver Chris Jackson?
<|assistant|>
SELECT "team" FROM "teams_and_drivers" WHERE "engine"='chevrolet 6.0 v8' AND "manufacturer"='opel' AND "driver"='chris jackson';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "season_21_2013" (
"series_ep" text,
"episode" real,
"segment_a" text,
"segment_b" text,
"segment_c" text,
"segment_d" text
);
Question: What is the Segment A entry for the episode that has an entry of Diesel filters for Segment D?
<|assistant|>
SELECT "segment_a" FROM "season_21_2013" WHERE "segment_d"='diesel filters';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "season_21_2013" (
"series_ep" text,
"episode" real,
"segment_a" text,
"segment_b" text,
"segment_c" text,
"segment_d" text
);
Question: What is the series episode number that is larger than 262 and has a Segment A entry of Aluminium s canoe?
<|assistant|>
SELECT "series_ep" FROM "season_21_2013" WHERE "episode">262 AND "segment_a"='aluminium s canoe';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "south_carolina" (
"district" text,
"incumbent" text,
"party" text,
"first_elected" real,
"result" text
);
Question: Which First elected has a District of south carolina 2?
<|assistant|>
SELECT MIN("first_elected") FROM "south_carolina" WHERE "district"='south carolina 2';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "south_carolina" (
"district" text,
"incumbent" text,
"party" text,
"first_elected" real,
"result" text
);
Question: Which Incumbent has a First elected larger than 1884?
<|assistant|>
SELECT "incumbent" FROM "south_carolina" WHERE "first_elected">1884;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "2000s" (
"year" real,
"english_title" text,
"original_title" text,
"country" text,
"director" text
);
Question: What is the English title with a Director named ang lee?
<|assistant|>
SELECT "english_title" FROM "2000s" WHERE "director"='ang lee';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "2000s" (
"year" real,
"english_title" text,
"original_title" text,
"country" text,
"director" text
);
Question: What is the Original title with a Country that is canada?
<|assistant|>
SELECT "original_title" FROM "2000s" WHERE "country"='canada';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "editions_feature_grid" (
"product" text,
"extensions" text,
"projects_templates" text,
"msdn_integration" text,
"debugging" text,
"profiling" text,
"intelli_trace" text,
"unit_test" text,
"code_coverage" text,
"test_impact_analysis" text,
"load_testing" text,
"lab_management" text,
"architecture_and_modelling" text,
"windows_phone_development" text
);
Question: Which Architecture and modelling has a Unit test of no, and a Projects templates of limited?
<|assistant|>
SELECT "architecture_and_modelling" FROM "editions_feature_grid" WHERE "unit_test"='no' AND "projects_templates"='limited';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "editions_feature_grid" (
"product" text,
"extensions" text,
"projects_templates" text,
"msdn_integration" text,
"debugging" text,
"profiling" text,
"intelli_trace" text,
"unit_test" text,
"code_coverage" text,
"test_impact_analysis" text,
"load_testing" text,
"lab_management" text,
"architecture_and_modelling" text,
"windows_phone_development" text
);
Question: which MSDN integration has a Load testing of no, and a Test impact analysis of no?
<|assistant|>
SELECT "msdn_integration" FROM "editions_feature_grid" WHERE "load_testing"='no' AND "test_impact_analysis"='no';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "editions_feature_grid" (
"product" text,
"extensions" text,
"projects_templates" text,
"msdn_integration" text,
"debugging" text,
"profiling" text,
"intelli_trace" text,
"unit_test" text,
"code_coverage" text,
"test_impact_analysis" text,
"load_testing" text,
"lab_management" text,
"architecture_and_modelling" text,
"windows_phone_development" text
);
Question: Which Unit test has a MSDN integration of full, and a Projects templates of yes?
<|assistant|>
SELECT "unit_test" FROM "editions_feature_grid" WHERE "msdn_integration"='full' AND "projects_templates"='yes';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "editions_feature_grid" (
"product" text,
"extensions" text,
"projects_templates" text,
"msdn_integration" text,
"debugging" text,
"profiling" text,
"intelli_trace" text,
"unit_test" text,
"code_coverage" text,
"test_impact_analysis" text,
"load_testing" text,
"lab_management" text,
"architecture_and_modelling" text,
"windows_phone_development" text
);
Question: Which Intelli Trace has a No Extension and Windows Phone development of no?
<|assistant|>
SELECT "intelli_trace" FROM "editions_feature_grid" WHERE "extensions"='no' AND "windows_phone_development"='no';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "editions_feature_grid" (
"product" text,
"extensions" text,
"projects_templates" text,
"msdn_integration" text,
"debugging" text,
"profiling" text,
"intelli_trace" text,
"unit_test" text,
"code_coverage" text,
"test_impact_analysis" text,
"load_testing" text,
"lab_management" text,
"architecture_and_modelling" text,
"windows_phone_development" text
);
Question: Which Projects template has an IntelliTrace of no, and a Windows Phone development of yes, and a Test impact analysis of no?
<|assistant|>
SELECT "projects_templates" FROM "editions_feature_grid" WHERE "intelli_trace"='no' AND "windows_phone_development"='yes' AND "test_impact_analysis"='no';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "editions_feature_grid" (
"product" text,
"extensions" text,
"projects_templates" text,
"msdn_integration" text,
"debugging" text,
"profiling" text,
"intelli_trace" text,
"unit_test" text,
"code_coverage" text,
"test_impact_analysis" text,
"load_testing" text,
"lab_management" text,
"architecture_and_modelling" text,
"windows_phone_development" text
);
Question: Which MSDN integration has a IntelliTrace of yes?
<|assistant|>
SELECT "msdn_integration" FROM "editions_feature_grid" WHERE "intelli_trace"='yes';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "historical_list_of_princeton_eating_club" (
"name" text,
"years_of_operation" text,
"location" text,
"historical_photos" text,
"year_clubhouse_constructed" text,
"sign_in_bicker" text,
"year_co_ed" text
);
Question: During what Years of Operation was the location prospect 33 prospect ave?
<|assistant|>
SELECT "years_of_operation" FROM "historical_list_of_princeton_eating_club" WHERE "location"='prospect 33 prospect ave';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "historical_list_of_princeton_eating_club" (
"name" text,
"years_of_operation" text,
"location" text,
"historical_photos" text,
"year_clubhouse_constructed" text,
"sign_in_bicker" text,
"year_co_ed" text
);
Question: What is the location of the ivy club?
<|assistant|>
SELECT "location" FROM "historical_list_of_princeton_eating_club" WHERE "name"='the ivy club';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "historical_list_of_princeton_eating_club" (
"name" text,
"years_of_operation" text,
"location" text,
"historical_photos" text,
"year_clubhouse_constructed" text,
"sign_in_bicker" text,
"year_co_ed" text
);
Question: What is the Sign-in/Bicker at wash50 on washington rd?
<|assistant|>
SELECT "sign_in_bicker" FROM "historical_list_of_princeton_eating_club" WHERE "location"='wash50 on washington rd';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "historical_list_of_princeton_eating_club" (
"name" text,
"years_of_operation" text,
"location" text,
"historical_photos" text,
"year_clubhouse_constructed" text,
"sign_in_bicker" text,
"year_co_ed" text
);
Question: When was the Clubhouse built with a Sign-in/Bicker of bicker, and Named cannon club?
<|assistant|>
SELECT "year_clubhouse_constructed" FROM "historical_list_of_princeton_eating_club" WHERE "sign_in_bicker"='bicker' AND "name"='cannon club';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "historical_list_of_princeton_eating_club" (
"name" text,
"years_of_operation" text,
"location" text,
"historical_photos" text,
"year_clubhouse_constructed" text,
"sign_in_bicker" text,
"year_co_ed" text
);
Question: Which Sign-in/Bicker is at of wash50 on washington rd?
<|assistant|>
SELECT "sign_in_bicker" FROM "historical_list_of_princeton_eating_club" WHERE "location"='wash50 on washington rd';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "historical_list_of_princeton_eating_club" (
"name" text,
"years_of_operation" text,
"location" text,
"historical_photos" text,
"year_clubhouse_constructed" text,
"sign_in_bicker" text,
"year_co_ed" text
);
Question: Which Historical Photos were taken at prospect 43 prospect ave?
<|assistant|>
SELECT "historical_photos" FROM "historical_list_of_princeton_eating_club" WHERE "location"='prospect 43 prospect ave';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "first_knockout_round" (
"team_1" text,
"agg" text,
"team_2" text,
"1st_leg" text,
"2nd_leg" text
);
Question: What is the 1st leg of team 1 Lyon?
<|assistant|>
SELECT "1st_leg" FROM "first_knockout_round" WHERE "team_1"='lyon';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "first_knockout_round" (
"team_1" text,
"agg" text,
"team_2" text,
"1st_leg" text,
"2nd_leg" text
);
Question: What is the 1st leg of team 1 Liverpool?
<|assistant|>
SELECT "1st_leg" FROM "first_knockout_round" WHERE "team_1"='liverpool';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "summary" (
"tournament" text,
"wins" real,
"top_5" real,
"top_10" real,
"top_25" real,
"events" real,
"cuts_made" real
);
Question: How many events resulted in a top-25 less than 2?
<|assistant|>
SELECT COUNT("events") FROM "summary" WHERE "top_25"<2;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "summary" (
"tournament" text,
"wins" real,
"top_5" real,
"top_10" real,
"top_25" real,
"events" real,
"cuts_made" real
);
Question: What is the smallest number of wins for a top-25 value greater than 5 and more than 38 cuts?
<|assistant|>
SELECT MIN("wins") FROM "summary" WHERE "top_25">5 AND "cuts_made">38;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "medal_table" (
"rank" real,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
Question: How many bronze medals did Chinese Taipei win with less than 0 gold?
<|assistant|>
SELECT COUNT("bronze") FROM "medal_table" WHERE "nation"='chinese taipei' AND "gold"<0;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "medal_table" (
"rank" real,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
Question: How many silver medals had a rank of 3 with bronze larger than 0?
<|assistant|>
SELECT COUNT("silver") FROM "medal_table" WHERE "rank"=3 AND "bronze">0;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "medal_table" (
"rank" real,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
Question: How many silver medals does China have?
<|assistant|>
SELECT COUNT("silver") FROM "medal_table" WHERE "nation"='china';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "torneo_apertura" (
"position" real,
"team" text,
"played" real,
"wins" real,
"draws" real,
"losses" real,
"scored" real,
"conceded" real,
"points" real
);
Question: Which Position has Losses of 11, and a Played larger than 22?
<|assistant|>
SELECT SUM("position") FROM "torneo_apertura" WHERE "losses"=11 AND "played">22;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "torneo_apertura" (
"position" real,
"team" text,
"played" real,
"wins" real,
"draws" real,
"losses" real,
"scored" real,
"conceded" real,
"points" real
);
Question: How many Wins have a Scored smaller than 24, and a Conceded larger than 25, and Draws larger than 5, and a Position smaller than 9?
<|assistant|>
SELECT COUNT("wins") FROM "torneo_apertura" WHERE "scored"<24 AND "conceded">25 AND "draws">5 AND "position"<9;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "torneo_apertura" (
"position" real,
"team" text,
"played" real,
"wins" real,
"draws" real,
"losses" real,
"scored" real,
"conceded" real,
"points" real
);
Question: How many Points has a Position of 8?
<|assistant|>
SELECT AVG("points") FROM "torneo_apertura" WHERE "position"=8;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "torneo_apertura" (
"position" real,
"team" text,
"played" real,
"wins" real,
"draws" real,
"losses" real,
"scored" real,
"conceded" real,
"points" real
);
Question: How many Wins has a Scored of 27 and Draws smaller than 5?
<|assistant|>
SELECT COUNT("wins") FROM "torneo_apertura" WHERE "scored"=27 AND "draws"<5;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "torneo_apertura" (
"position" real,
"team" text,
"played" real,
"wins" real,
"draws" real,
"losses" real,
"scored" real,
"conceded" real,
"points" real
);
Question: Which Position has Draws smaller than 7 and a Played larger than 22?
<|assistant|>
SELECT AVG("position") FROM "torneo_apertura" WHERE "draws"<7 AND "played">22;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "torneo_apertura" (
"position" real,
"team" text,
"played" real,
"wins" real,
"draws" real,
"losses" real,
"scored" real,
"conceded" real,
"points" real
);
Question: Which Played has a Scored larger than 25 and a Position of 1, and Draws smaller than 5?
<|assistant|>
SELECT MAX("played") FROM "torneo_apertura" WHERE "scored">25 AND "position"=1 AND "draws"<5;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "2008_six_nations_championship_squads" (
"player" text,
"position" text,
"date_of_birth_age" text,
"caps" real,
"club_province" text
);
Question: When was the player with 51 caps from a Club/province of clermont born?
<|assistant|>
SELECT "date_of_birth_age" FROM "2008_six_nations_championship_squads" WHERE "caps"=51 AND "club_province"='clermont';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "overview_of_main_characters" (
"character" text,
"actor" text,
"years" text,
"series" text,
"episode_count" real
);
Question: How many Episode Counts have an Actor of liz carr?
<|assistant|>
SELECT COUNT("episode_count") FROM "overview_of_main_characters" WHERE "actor"='liz carr';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "overview_of_main_characters" (
"character" text,
"actor" text,
"years" text,
"series" text,
"episode_count" real
);
Question: Which Years have a Character of dr trevor stewart?
<|assistant|>
SELECT "years" FROM "overview_of_main_characters" WHERE "character"='dr trevor stewart';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "overview_of_main_characters" (
"character" text,
"actor" text,
"years" text,
"series" text,
"episode_count" real
);
Question: Which Series has an Actor of tom ward?
<|assistant|>
SELECT "series" FROM "overview_of_main_characters" WHERE "actor"='tom ward';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_two" (
"pick_num" real,
"mls_team" text,
"player" text,
"position" text,
"affiliation" text
);
Question: How many picks involved the player Joe Germanese?
<|assistant|>
SELECT SUM("pick_num") FROM "round_two" WHERE "player"='joe germanese';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_two" (
"pick_num" real,
"mls_team" text,
"player" text,
"position" text,
"affiliation" text
);
Question: Which player's pick number was 25?
<|assistant|>
SELECT "player" FROM "round_two" WHERE "pick_num"=25;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "montreal_canadiens_4_chicago_black_hawks" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: What team did the Montreal Canadiens visit when the record was 0-3?
<|assistant|>
SELECT "home" FROM "montreal_canadiens_4_chicago_black_hawks" WHERE "visitor"='montreal canadiens' AND "record"='0-3';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "montreal_canadiens_4_chicago_black_hawks" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: What was the score on April 23?
<|assistant|>
SELECT "score" FROM "montreal_canadiens_4_chicago_black_hawks" WHERE "date"='april 23';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "montreal_canadiens_4_chicago_black_hawks" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: What team did the Chicago Black Hawks visit on April 20?
<|assistant|>
SELECT "home" FROM "montreal_canadiens_4_chicago_black_hawks" WHERE "visitor"='chicago black hawks' AND "date"='april 20';<|endoftext|> |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.