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