text stringlengths 310 1.28k |
|---|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_13" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: When were both the crowd larger than 15,000 and the Away team score of 9.11 (65)?
<|assistant|>
SELECT "date" FROM "round_13" WHERE "crowd">'15,000' AND "away_team_score"='9.11 (65)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"game_site" text,
"attendance" text
);
Question: What was the attendance at the Meadowlands against the New England Patriots?
<|assistant|>
SELECT "attendance" FROM "regular_season" WHERE "game_site"='the meadowlands' AND "opponent"='new england patriots';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"game_site" text,
"attendance" text
);
Question: What game did Jets have an attendance of 78,722?
<|assistant|>
SELECT "game_site" FROM "regular_season" WHERE "attendance"='78,722';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_16" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: Which home team corresponds to an away team score of 5.10 (40)?
<|assistant|>
SELECT "home_team" FROM "round_16" WHERE "away_team_score"='5.10 (40)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_16" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What is the largest crowd for an away team score of 8.7 (55)?
<|assistant|>
SELECT MAX("crowd") FROM "round_16" WHERE "away_team_score"='8.7 (55)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_16" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: Which venue hosted a home team with a score of 11.16 (82)?
<|assistant|>
SELECT "venue" FROM "round_16" WHERE "home_team_score"='11.16 (82)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_16" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: Which away team has a team score of 12.11 (83)?
<|assistant|>
SELECT "away_team" FROM "round_16" WHERE "away_team_score"='12.11 (83)';<|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" text
);
Question: Who played the Rams on October 2, 2005?
<|assistant|>
SELECT "opponent" FROM "schedule" WHERE "date"='october 2, 2005';<|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" text
);
Question: What was the attendance of the game on December 11, 2005?
<|assistant|>
SELECT "attendance" FROM "schedule" WHERE "date"='december 11, 2005';<|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" text
);
Question: What was the result of the game played in front of 65,473?
<|assistant|>
SELECT "result" FROM "schedule" WHERE "attendance"='65,473';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_11" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: How large was the crowd at Carlton's home game?
<|assistant|>
SELECT COUNT("crowd") FROM "round_11" WHERE "home_team"='carlton';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_11" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: On what date did the away team score 12.9 (81)?
<|assistant|>
SELECT "date" FROM "round_11" WHERE "away_team_score"='12.9 (81)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_14" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the score when St Kilda played as the home team?
<|assistant|>
SELECT "home_team_score" FROM "round_14" WHERE "home_team"='st kilda';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_14" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the crowd when the VFL played Windy Hill?
<|assistant|>
SELECT SUM("crowd") FROM "round_14" WHERE "venue"='windy hill';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_6" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was Carlton's score when they were the away team?
<|assistant|>
SELECT "away_team_score" FROM "round_6" WHERE "away_team"='carlton';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_6" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the sum of the crowds in the matches where the away team scored 11.8 (74)?
<|assistant|>
SELECT SUM("crowd") FROM "round_6" WHERE "away_team_score"='11.8 (74)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_6" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the away team that played at Corio Oval?
<|assistant|>
SELECT "away_team" FROM "round_6" WHERE "venue"='corio oval';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_12" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: Which Home team faced the Away team, Hawthorn?
<|assistant|>
SELECT "home_team" FROM "round_12" WHERE "away_team"='hawthorn';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_12" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: Which Away team scored 12.17 (89) when the crowd was larger than 17,000?
<|assistant|>
SELECT "away_team" FROM "round_12" WHERE "crowd">'17,000' AND "away_team_score"='12.17 (89)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_12" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the Home team's score when the Away team scored 12.6 (78)?
<|assistant|>
SELECT "home_team_score" FROM "round_12" WHERE "away_team_score"='12.6 (78)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_12" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the Home team's score when the Venue was mcg?
<|assistant|>
SELECT "home_team_score" FROM "round_12" WHERE "venue"='mcg';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "records" (
"season" real,
"division" real,
"tms" real,
"pos" real,
"fa_cup" text
);
Question: What is the division in the season more recent than 2012 when the round of 16 was reached in the FA Cup?
<|assistant|>
SELECT COUNT("division") FROM "records" WHERE "fa_cup"='round of 16' AND "season">2012;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "records" (
"season" real,
"division" real,
"tms" real,
"pos" real,
"fa_cup" text
);
Question: What is the division in the season with 13 tms and pos smaller than 8?
<|assistant|>
SELECT COUNT("division") FROM "records" WHERE "tms"=13 AND "pos"<8;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "by_density" (
"rank" text,
"county" text,
"population_2011" real,
"area_km" real,
"density_2011" real
);
Question: What is the population of the county with an area of 9,378 km² and a population density larger than 46.7?
<|assistant|>
SELECT MIN("population_2011") FROM "by_density" WHERE "area_km"='9,378' AND "density_2011">46.7;<|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: Of the games before week 3 which had attendance great than 65,904?
<|assistant|>
SELECT "date" FROM "schedule" WHERE "week"<3 AND "attendance">'65,904';<|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 first week to have attendance of 65,866?
<|assistant|>
SELECT MIN("week") FROM "schedule" WHERE "attendance"='65,866';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "former_members" (
"institution" text,
"location" text,
"men_s_nickname" text,
"women_s_nickname" text,
"founded" real,
"type" text,
"enrollment" real,
"joined" text,
"left" text,
"current_conference" text,
"classification" text
);
Question: Where is the Belhaven College SSAC conference location?
<|assistant|>
SELECT "location" FROM "former_members" WHERE "current_conference"='ssac' AND "institution"='belhaven college';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "former_members" (
"institution" text,
"location" text,
"men_s_nickname" text,
"women_s_nickname" text,
"founded" real,
"type" text,
"enrollment" real,
"joined" text,
"left" text,
"current_conference" text,
"classification" text
);
Question: What American Southwest Conference school was founded in 1883?
<|assistant|>
SELECT "institution" FROM "former_members" WHERE "founded">1883 AND "current_conference"='american southwest';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "year_by_year" (
"year" text,
"league" text,
"reg_season" text,
"playoffs" text,
"attendance_average" text
);
Question: Which League showed 7,975 for an average attendance?
<|assistant|>
SELECT "league" FROM "year_by_year" WHERE "attendance_average"='7,975';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "year_by_year" (
"year" text,
"league" text,
"reg_season" text,
"playoffs" text,
"attendance_average" text
);
Question: What is the average attendance of the team that had a regular season result of 2nd aisa, 24-16?
<|assistant|>
SELECT "attendance_average" FROM "year_by_year" WHERE "reg_season"='2nd aisa, 24-16';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "champions" (
"season" text,
"group_i" text,
"group_ii" text,
"group_iii" text,
"group_iv" text,
"group_v" text,
"group_vi" text
);
Question: Who won Group VI, when Group 1 was won by deportivo, group IV by sevilla, and group III by Valencia?
<|assistant|>
SELECT "group_vi" FROM "champions" WHERE "group_i"='deportivo' AND "group_iv"='sevilla' AND "group_iii"='valencia';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "champions" (
"season" text,
"group_i" text,
"group_ii" text,
"group_iii" text,
"group_iv" text,
"group_v" text,
"group_vi" text
);
Question: Who won group III when group 1 was of the racing club?
<|assistant|>
SELECT "group_iii" FROM "champions" WHERE "group_i"='racing club';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "champions" (
"season" text,
"group_i" text,
"group_ii" text,
"group_iii" text,
"group_iv" text,
"group_v" text,
"group_vi" text
);
Question: What season has Group IV Sevilla, Group VI las palmas, group III barcelona, and group 1 sporting?
<|assistant|>
SELECT "season" FROM "champions" WHERE "group_iv"='sevilla' AND "group_vi"='las palmas' AND "group_iii"='barcelona' AND "group_i"='sporting';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "1971_isle_of_man_production_500_cc_tt_fi" (
"rank" real,
"rider" text,
"team" text,
"speed" text,
"time" text
);
Question: Which team is John Williams a rider for?
<|assistant|>
SELECT "team" FROM "1971_isle_of_man_production_500_cc_tt_fi" WHERE "rider"='john williams';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_1" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: How big was the crowd when Geelong was the home team?
<|assistant|>
SELECT COUNT("crowd") FROM "round_1" WHERE "home_team"='geelong';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_1" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: Where was the game when the away team scored 11.6 (72)?
<|assistant|>
SELECT "venue" FROM "round_1" WHERE "away_team_score"='11.6 (72)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_1" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: Who was the away team when Hawthorn was the home team?
<|assistant|>
SELECT "away_team_score" FROM "round_1" WHERE "home_team"='hawthorn';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_1" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: Who was the away team when the home team scored 9.16 (70)?
<|assistant|>
SELECT "away_team" FROM "round_1" WHERE "home_team_score"='9.16 (70)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "ntua_academic_staff_per_school" (
"lecturers" real,
"associate_professors" real,
"assistant_professors" real,
"professors" real,
"total" real
);
Question: What is the total in the case where theere are 6 lecturers and fewer than 48 professors?
<|assistant|>
SELECT AVG("total") FROM "ntua_academic_staff_per_school" WHERE "lecturers"=6 AND "professors"<48;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "ntua_academic_staff_per_school" (
"lecturers" real,
"associate_professors" real,
"assistant_professors" real,
"professors" real,
"total" real
);
Question: What is the total in the case when there are more than 4 associate professors, 5 lecturers and fewer professors than 40?
<|assistant|>
SELECT COUNT("total") FROM "ntua_academic_staff_per_school" WHERE "associate_professors">4 AND "lecturers"=5 AND "professors"<40;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "ntua_academic_staff_per_school" (
"lecturers" real,
"associate_professors" real,
"assistant_professors" real,
"professors" real,
"total" real
);
Question: How may lecturers are there in the case when there are more than 8 assistant professors, fewer than 35 associate professors, more than 14 professors and total of more than 81?
<|assistant|>
SELECT COUNT("lecturers") FROM "ntua_academic_staff_per_school" WHERE "assistant_professors">8 AND "professors">14 AND "associate_professors"<35 AND "total">81;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "ntua_academic_staff_per_school" (
"lecturers" real,
"associate_professors" real,
"assistant_professors" real,
"professors" real,
"total" real
);
Question: What is the maximum number of associate professors when there are more than 5 assistant professors and fewer than 14 professors?
<|assistant|>
SELECT MAX("associate_professors") FROM "ntua_academic_staff_per_school" WHERE "assistant_professors">5 AND "professors"<14;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "malaysia" (
"network" text,
"origin_of_programming" text,
"language" text,
"genre" text,
"service" text
);
Question: Which country has the banglavision Network?
<|assistant|>
SELECT "origin_of_programming" FROM "malaysia" WHERE "network"='banglavision';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "malaysia" (
"network" text,
"origin_of_programming" text,
"language" text,
"genre" text,
"service" text
);
Question: Which general service in India is a part of the zee variasi network?
<|assistant|>
SELECT "service" FROM "malaysia" WHERE "origin_of_programming"='india' AND "genre"='general' AND "network"='zee variasi';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "allowable_tackle_types" (
"sliding_tackle" text,
"spear_tackle" text,
"dump_tackle" text,
"body_tackle" text,
"ankle_tap" text,
"diving_tackle" text,
"bumping_blocking" text,
"shoulder_charge" text,
"steal_intercept_ball" text,
"chicken_wing" text
);
Question: Which sliding tackle has no dump tackle and a restricted shoulder charge?
<|assistant|>
SELECT "sliding_tackle" FROM "allowable_tackle_types" WHERE "dump_tackle"='no' AND "shoulder_charge"='restricted';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "allowable_tackle_types" (
"sliding_tackle" text,
"spear_tackle" text,
"dump_tackle" text,
"body_tackle" text,
"ankle_tap" text,
"diving_tackle" text,
"bumping_blocking" text,
"shoulder_charge" text,
"steal_intercept_ball" text,
"chicken_wing" text
);
Question: Which bumping/blocking has a yes for both the ankle tap and steal/intercept ball?
<|assistant|>
SELECT "bumping_blocking" FROM "allowable_tackle_types" WHERE "ankle_tap"='yes' AND "steal_intercept_ball"='yes';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "allowable_tackle_types" (
"sliding_tackle" text,
"spear_tackle" text,
"dump_tackle" text,
"body_tackle" text,
"ankle_tap" text,
"diving_tackle" text,
"bumping_blocking" text,
"shoulder_charge" text,
"steal_intercept_ball" text,
"chicken_wing" text
);
Question: Which body tackle has yes for the diving tackle and the sliding tackle classified as a trip?
<|assistant|>
SELECT "body_tackle" FROM "allowable_tackle_types" WHERE "diving_tackle"='yes' AND "sliding_tackle"='classified as a trip';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "allowable_tackle_types" (
"sliding_tackle" text,
"spear_tackle" text,
"dump_tackle" text,
"body_tackle" text,
"ankle_tap" text,
"diving_tackle" text,
"bumping_blocking" text,
"shoulder_charge" text,
"steal_intercept_ball" text,
"chicken_wing" text
);
Question: Which Chicken wing has no steal/intercept ball?
<|assistant|>
SELECT "chicken_wing" FROM "allowable_tackle_types" WHERE "steal_intercept_ball"='no';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "allowable_tackle_types" (
"sliding_tackle" text,
"spear_tackle" text,
"dump_tackle" text,
"body_tackle" text,
"ankle_tap" text,
"diving_tackle" text,
"bumping_blocking" text,
"shoulder_charge" text,
"steal_intercept_ball" text,
"chicken_wing" text
);
Question: Which steal/intercept ball has no for both the sliding tackle and dump tackle?
<|assistant|>
SELECT "steal_intercept_ball" FROM "allowable_tackle_types" WHERE "sliding_tackle"='no' AND "dump_tackle"='no';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "allowable_tackle_types" (
"sliding_tackle" text,
"spear_tackle" text,
"dump_tackle" text,
"body_tackle" text,
"ankle_tap" text,
"diving_tackle" text,
"bumping_blocking" text,
"shoulder_charge" text,
"steal_intercept_ball" text,
"chicken_wing" text
);
Question: Which shoulder charge has restricted as the body tackle?
<|assistant|>
SELECT "shoulder_charge" FROM "allowable_tackle_types" WHERE "body_tackle"='restricted';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "e" (
"player" text,
"nationality" text,
"position" text,
"from" text,
"school_country" text
);
Question: Which player has West Virginia listed as their school/country?
<|assistant|>
SELECT "player" FROM "e" WHERE "school_country"='west virginia';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "e" (
"player" text,
"nationality" text,
"position" text,
"from" text,
"school_country" text
);
Question: Which player played the guard position from 1968?
<|assistant|>
SELECT "player" FROM "e" WHERE "position"='guard' AND "from"='1968';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_2" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What is the total crowd size when the away team scores 14.6 (90)?
<|assistant|>
SELECT SUM("crowd") FROM "round_2" WHERE "away_team_score"='14.6 (90)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_2" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What is the average crowd size when fitzroy plays at home?
<|assistant|>
SELECT AVG("crowd") FROM "round_2" WHERE "home_team"='fitzroy';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "mayors" (
"election" text,
"date_of_election" text,
"candidates" text,
"results" text,
"total_votes" real
);
Question: What is the result of the election with 3,871 total votes?
<|assistant|>
SELECT "results" FROM "mayors" WHERE "total_votes">'3,871';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "record_by_conference" (
"conference" text,
"num_of_bids" real,
"record" text,
"win_pct" real,
"round_of_32" real,
"sweet_sixteen" real,
"elite_eight" real,
"final_four" real,
"championship_game" real
);
Question: What is the lowest number of bids in the Missouri Valley conference?
<|assistant|>
SELECT MIN("num_of_bids") FROM "record_by_conference" WHERE "conference"='missouri valley';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "game_by_game_results" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"attendance" text
);
Question: What was the attendance on the bye week?
<|assistant|>
SELECT "attendance" FROM "game_by_game_results" WHERE "date"='bye';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "game_by_game_results" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"attendance" text
);
Question: What was the last week when the team had a bye week?
<|assistant|>
SELECT MAX("week") FROM "game_by_game_results" WHERE "result"='bye';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_9" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: Where was the game held where North Melbourne was the away team?
<|assistant|>
SELECT "venue" FROM "round_9" WHERE "away_team"='north melbourne';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_9" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: Who was the away team who scored 9.7 (61)?
<|assistant|>
SELECT "away_team" FROM "round_9" WHERE "away_team_score"='9.7 (61)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_9" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the smallest crowd for a game where the home team scored 11.18 (84)?
<|assistant|>
SELECT MIN("crowd") FROM "round_9" WHERE "home_team_score"='11.18 (84)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_9" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the smallest crowd size for a home game for Richmond?
<|assistant|>
SELECT MIN("crowd") FROM "round_9" WHERE "home_team"='richmond';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season_schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"attendance" text
);
Question: When did the 1966 Cleveland Browns play the Green Bay Packers?
<|assistant|>
SELECT "date" FROM "regular_season_schedule" WHERE "opponent"='green bay packers';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_8" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the away team score for the game where the home team scored 11.13 (79)?
<|assistant|>
SELECT "away_team_score" FROM "round_8" WHERE "home_team_score"='11.13 (79)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_8" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: Who was the home team that scored 19.15 (129) on 15 June 1959?
<|assistant|>
SELECT "home_team" FROM "round_8" WHERE "date"='15 june 1959' AND "home_team_score"='19.15 (129)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_8" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: How many points did South Melbourne score as the home team?
<|assistant|>
SELECT "home_team_score" FROM "round_8" WHERE "home_team"='south melbourne';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_4" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the home team's score when the away team scored 9.12 (66)?
<|assistant|>
SELECT "home_team_score" FROM "round_4" WHERE "away_team_score"='9.12 (66)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_4" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: On what date was the home team Footscray?
<|assistant|>
SELECT "date" FROM "round_4" WHERE "home_team"='footscray';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_4" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the average crowd size when the home team scored 9.8 (62)?
<|assistant|>
SELECT AVG("crowd") FROM "round_4" WHERE "home_team_score"='9.8 (62)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_4" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the home team when the away team scored 7.16 (58)?
<|assistant|>
SELECT "home_team" FROM "round_4" WHERE "away_team_score"='7.16 (58)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_table" (
"position" real,
"club" text,
"played" real,
"wins" real,
"draws" real,
"losses" real,
"goals_for" real,
"goals_against" real,
"points" real,
"goal_difference" real
);
Question: What is the average amount of goals that have a goal difference or 8 and the losses are smaller than 12?
<|assistant|>
SELECT AVG("goals_for") FROM "final_table" WHERE "goal_difference"=8 AND "losses"<12;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_table" (
"position" real,
"club" text,
"played" real,
"wins" real,
"draws" real,
"losses" real,
"goals_for" real,
"goals_against" real,
"points" real,
"goal_difference" real
);
Question: How many goals have a Lokomotiv Plovdiv club and goals against larger than 58?
<|assistant|>
SELECT COUNT("goals_for") FROM "final_table" WHERE "club"='lokomotiv plovdiv' AND "goals_against">58;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_table" (
"position" real,
"club" text,
"played" real,
"wins" real,
"draws" real,
"losses" real,
"goals_for" real,
"goals_against" real,
"points" real,
"goal_difference" real
);
Question: What is the average goal difference using slavia sofia club?
<|assistant|>
SELECT AVG("goal_difference") FROM "final_table" WHERE "club"='slavia sofia';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "final_table" (
"position" real,
"club" text,
"played" real,
"wins" real,
"draws" real,
"losses" real,
"goals_for" real,
"goals_against" real,
"points" real,
"goal_difference" real
);
Question: What is the played average that has botev plovdiv as the club and wins larger than 11?
<|assistant|>
SELECT AVG("played") FROM "final_table" WHERE "club"='botev plovdiv' AND "wins">11;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season" (
"week" real,
"kickoff" text,
"date" text,
"opponent" text,
"result" text,
"record" text,
"game_site" text,
"nfl_com_recap" text
);
Question: Where did they play on their bye week?
<|assistant|>
SELECT "game_site" FROM "regular_season" WHERE "record"='bye';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season" (
"week" real,
"kickoff" text,
"date" text,
"opponent" text,
"result" text,
"record" text,
"game_site" text,
"nfl_com_recap" text
);
Question: What is the kickoff that has a NFL.com recap, is played before week 17, and is played at arrowhead stadium?
<|assistant|>
SELECT "kickoff" FROM "regular_season" WHERE "nfl_com_recap"='recap' AND "week"<17 AND "game_site"='arrowhead stadium';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_1" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: Who is the home team at brunswick street oval?
<|assistant|>
SELECT "home_team" FROM "round_1" WHERE "venue"='brunswick street oval';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_1" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What is the home team's score at brunswick street oval?
<|assistant|>
SELECT "home_team_score" FROM "round_1" WHERE "venue"='brunswick street oval';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_1" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What is the away side's score when the home team's score is 15.14 (104)?
<|assistant|>
SELECT "away_team_score" FROM "round_1" WHERE "home_team_score"='15.14 (104)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_10" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: When did the match take place that had an away team score of 12.12 (84)?
<|assistant|>
SELECT "date" FROM "round_10" WHERE "away_team_score"='12.12 (84)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_10" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the crowd size of the match where the home team scored 7.7 (49) against Geelong?
<|assistant|>
SELECT SUM("crowd") FROM "round_10" WHERE "home_team_score"='7.7 (49)' AND "away_team"='geelong';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_10" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: Which match had the largest crowd size where the away team was North Melbourne?
<|assistant|>
SELECT MAX("crowd") FROM "round_10" WHERE "away_team"='north melbourne';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_13" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What away team scored 6.12 (48)?
<|assistant|>
SELECT "away_team" FROM "round_13" WHERE "away_team_score"='6.12 (48)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_13" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was North Melbourne's score as an away team?
<|assistant|>
SELECT "away_team_score" FROM "round_13" WHERE "away_team"='north melbourne';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_13" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the crowd size when the away team scored 10.9 (69)?
<|assistant|>
SELECT COUNT("crowd") FROM "round_13" WHERE "away_team_score"='10.9 (69)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_13" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the away team's score against Hawthorn?
<|assistant|>
SELECT "away_team_score" FROM "round_13" WHERE "home_team"='hawthorn';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_13" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What was the away team that played the home team of Geelong?
<|assistant|>
SELECT "away_team" FROM "round_13" WHERE "home_team"='geelong';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season_schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"attendance" real
);
Question: What week has an attended smaller than 62,723 on October 22, 1961?
<|assistant|>
SELECT AVG("week") FROM "regular_season_schedule" WHERE "attendance"<'62,723' AND "date"='october 22, 1961';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season_schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"attendance" real
);
Question: Which week with Green Bay Packers as an opponent is the highest?
<|assistant|>
SELECT MAX("week") FROM "regular_season_schedule" WHERE "opponent"='green bay packers';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "most_caps" (
"player" text,
"span" text,
"start" real,
"tries" real,
"conv" real,
"pens" real,
"drop" real,
"lost" real,
"draw" real
);
Question: What is the number of starts for the player who lost fewer than 22 and has more than 4 tries?
<|assistant|>
SELECT AVG("start") FROM "most_caps" WHERE "lost"<22 AND "tries">4;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "most_caps" (
"player" text,
"span" text,
"start" real,
"tries" real,
"conv" real,
"pens" real,
"drop" real,
"lost" real,
"draw" real
);
Question: What is the total losses for the player with fewer than 51 pens, 3 tries and 45 starts?
<|assistant|>
SELECT COUNT("lost") FROM "most_caps" WHERE "pens"<51 AND "tries"=3 AND "start"=45;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_12" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What is the average crowd size at glenferrie oval?
<|assistant|>
SELECT AVG("crowd") FROM "round_12" WHERE "venue"='glenferrie oval';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_12" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What is the away team's score when the away team is geelong?
<|assistant|>
SELECT "away_team_score" FROM "round_12" WHERE "away_team"='geelong';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_12" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What is the away team's score when geelong is the away side playing in front of a crowd of larger than 10,500, and the home team scoring 13.10 (88)?
<|assistant|>
SELECT "away_team_score" FROM "round_12" WHERE "crowd">'10,500' AND "home_team_score"='13.10 (88)' AND "away_team"='geelong';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "round_12" (
"home_team" text,
"home_team_score" text,
"away_team" text,
"away_team_score" text,
"venue" text,
"crowd" real,
"date" text
);
Question: What is the largest crowd when melbourne plays at home?
<|assistant|>
SELECT MAX("crowd") FROM "round_12" WHERE "home_team"='melbourne';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "record_by_conference" (
"conference" text,
"num_of_bids" real,
"record" text,
"win_pct" real,
"round_of_32" real,
"sweet_sixteen" text,
"elite_eight" text,
"final_four" text,
"championship_game" text
);
Question: What was the championship game for the Southwest conference?
<|assistant|>
SELECT "championship_game" FROM "record_by_conference" WHERE "conference"='southwest';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "personnel_and_kits" (
"team" text,
"manager" text,
"captain" text,
"kit_maker" text,
"shirt_sponsor" text
);
Question: Which manager has Sol Campbell as captain?
<|assistant|>
SELECT "manager" FROM "personnel_and_kits" WHERE "captain"='sol campbell';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "personnel_and_kits" (
"team" text,
"manager" text,
"captain" text,
"kit_maker" text,
"shirt_sponsor" text
);
Question: What team does Carlsberg sponsor?
<|assistant|>
SELECT "team" FROM "personnel_and_kits" WHERE "shirt_sponsor"='carlsberg';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "personnel_and_kits" (
"team" text,
"manager" text,
"captain" text,
"kit_maker" text,
"shirt_sponsor" text
);
Question: Who sponsors Middlesbrough?
<|assistant|>
SELECT "shirt_sponsor" FROM "personnel_and_kits" WHERE "team"='middlesbrough';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "personnel_and_kits" (
"team" text,
"manager" text,
"captain" text,
"kit_maker" text,
"shirt_sponsor" text
);
Question: Which sponsor has Mark Hughes as manager?
<|assistant|>
SELECT "shirt_sponsor" FROM "personnel_and_kits" WHERE "manager"='mark hughes';<|endoftext|> |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.