output
stringlengths
27
479
instruction
stringlengths
407
1.39k
SELECT "hometown" FROM "2010_team" WHERE "player"='tre madden';
## Task Generate a SQL query to answer the following question: `What is the hometown for tre madden?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2010_team" ( "player" text, "position" text, "school" text, "hometown" text, "college" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the hometown for tre madden?`: ```sql
SELECT "hometown" FROM "2010_team" WHERE "position"='defensive back' AND "college"='alabama';
## Task Generate a SQL query to answer the following question: `What is the hometown for the player that is defensive back and went to alabama?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2010_team" ( "player" text, "position" text, "school" text, "hometown" text, "college" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the hometown for the player that is defensive back and went to alabama?`: ```sql
SELECT "college" FROM "2010_team" WHERE "position"='defensive back' AND "school"='ridge community high school';
## Task Generate a SQL query to answer the following question: `What is the college for the player that went to ridge community high school and is defensive back?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2010_team" ( "player" text, "position" text, "school" text, "hometown" text, "college" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the college for the player that went to ridge community high school and is defensive back?`: ```sql
SELECT SUM("year") FROM "2010_present" WHERE "type"='informal' AND "location"='justus lipsius building, brussels' AND "date"='23 may';
## Task Generate a SQL query to answer the following question: `What is the sum of Year with a Type of informal, and a Location with justus lipsius building, brussels, and a Date with 23 may?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2010_present" ( "year" real, "date" text, "type" text, "president" text, "location" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the sum of Year with a Type of informal, and a Location with justus lipsius building, brussels, and a Date with 23 may?`: ```sql
SELECT "type" FROM "2010_present" WHERE "location"='justus lipsius building, brussels' AND "year"=2012 AND "president"='herman van rompuy (1st term)' AND "date"='23 may';
## Task Generate a SQL query to answer the following question: `What is the Type with a Location with justus lipsius building, brussels, and a Year of 2012, and a President with herman van rompuy (1st term), and a Date with 23 may?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2010_present" ( "year" real, "date" text, "type" text, "president" text, "location" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the Type with a Location with justus lipsius building, brussels, and a Year of 2012, and a President with herman van rompuy (1st term), and a Date with 23 may?`: ```sql
SELECT "president" FROM "2010_present" WHERE "location"='justus lipsius building, brussels' AND "type"='scheduled' AND "year">2011 AND "date"='18–19 october';
## Task Generate a SQL query to answer the following question: `What is the President with a Location of justus lipsius building, brussels, and a Type with scheduled, and a Year larger than 2011, and a Date with 18–19 october?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2010_present" ( "year" real, "date" text, "type" text, "president" text, "location" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the President with a Location of justus lipsius building, brussels, and a Type with scheduled, and a Year larger than 2011, and a Date with 18–19 october?`: ```sql
SELECT "location" FROM "2010_present" WHERE "year">2011 AND "president"='herman van rompuy (2nd term)' AND "date"='28–29 june' AND "type"='scheduled';
## Task Generate a SQL query to answer the following question: `What is the Location with a Year larger than 2011, and a President with herman van rompuy (2nd term), and a Date of 28–29 june, and a Type with scheduled?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2010_present" ( "year" real, "date" text, "type" text, "president" text, "location" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the Location with a Year larger than 2011, and a President with herman van rompuy (2nd term), and a Date of 28–29 june, and a Type with scheduled?`: ```sql
SELECT "president" FROM "2010_present" WHERE "year">2011 AND "date"='23 may';
## Task Generate a SQL query to answer the following question: `What is the President with a Year larger than 2011, and a Date with 23 may?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2010_present" ( "year" real, "date" text, "type" text, "president" text, "location" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the President with a Year larger than 2011, and a Date with 23 may?`: ```sql
SELECT "type" FROM "2010_present" WHERE "year">2010 AND "location"='justus lipsius building, brussels' AND "president"='herman van rompuy (2nd term)' AND "date"='28–29 june';
## Task Generate a SQL query to answer the following question: `What is the Type with a Year larger than 2010, and a Location with justus lipsius building, brussels, and a President of herman van rompuy (2nd term), and a Date with 28–29 june?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2010_present" ( "year" real, "date" text, "type" text, "president" text, "location" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the Type with a Year larger than 2010, and a Location with justus lipsius building, brussels, and a President of herman van rompuy (2nd term), and a Date with 28–29 june?`: ```sql
SELECT "competition" FROM "international_goals" WHERE "goal"=13;
## Task Generate a SQL query to answer the following question: `What competition has a goal number of 13?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "international_goals" ( "goal" real, "date" text, "score" text, "result" text, "competition" text ); ### SQL Given the database schema, here is the SQL query that answers `What competition has a goal number of 13?`: ```sql
SELECT SUM("yards") FROM "defense" WHERE "asst"=19 AND "total_tk"=60 AND "sack">0;
## Task Generate a SQL query to answer the following question: `What is the total of yards when asst. is 19, totaltk is 60 and sack is more than 0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "defense" ( "player" text, "tackles" real, "asst" real, "total_tk" real, "sack" real, "yards" real, "fum_r" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the total of yards when asst. is 19, totaltk is 60 and sack is more than 0?`: ```sql
SELECT SUM("sack") FROM "defense" WHERE "player"='mike green' AND "fum_r"<0;
## Task Generate a SQL query to answer the following question: `what is the total sack for mike green when fumr is less than 0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "defense" ( "player" text, "tackles" real, "asst" real, "total_tk" real, "sack" real, "yards" real, "fum_r" real ); ### SQL Given the database schema, here is the SQL query that answers `what is the total sack for mike green when fumr is less than 0?`: ```sql
SELECT SUM("sack") FROM "defense" WHERE "total_tk"=1 AND "asst">0;
## Task Generate a SQL query to answer the following question: `what is the total sack when totaltk is 1 and asst. is more than 0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "defense" ( "player" text, "tackles" real, "asst" real, "total_tk" real, "sack" real, "yards" real, "fum_r" real ); ### SQL Given the database schema, here is the SQL query that answers `what is the total sack when totaltk is 1 and asst. is more than 0?`: ```sql
SELECT COUNT("tackles") FROM "defense" WHERE "fum_r"=0 AND "total_tk"=54 AND "yards"<0;
## Task Generate a SQL query to answer the following question: `what is the total number of tackles when fumr is 0, totaltk is 54 and yards is less than 0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "defense" ( "player" text, "tackles" real, "asst" real, "total_tk" real, "sack" real, "yards" real, "fum_r" real ); ### SQL Given the database schema, here is the SQL query that answers `what is the total number of tackles when fumr is 0, totaltk is 54 and yards is less than 0?`: ```sql
SELECT SUM("total_tk") FROM "defense" WHERE "yards"<0;
## Task Generate a SQL query to answer the following question: `what is the sum of totaltk when yards is less than 0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "defense" ( "player" text, "tackles" real, "asst" real, "total_tk" real, "sack" real, "yards" real, "fum_r" real ); ### SQL Given the database schema, here is the SQL query that answers `what is the sum of totaltk when yards is less than 0?`: ```sql
SELECT "class" FROM "grand_prix_motorcycle_racing_results" WHERE "year">1973 AND "points"=41;
## Task Generate a SQL query to answer the following question: `What class is after 1973 with 41 points?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "grand_prix_motorcycle_racing_results" ( "year" real, "class" text, "team" text, "points" real, "wins" real ); ### SQL Given the database schema, here is the SQL query that answers `What class is after 1973 with 41 points?`: ```sql
SELECT COUNT("wins") FROM "grand_prix_motorcycle_racing_results" WHERE "points"<54 AND "team"='yamaha' AND "class"='250cc' AND "year"<1977;
## Task Generate a SQL query to answer the following question: `How many wins for bikes with under 54 points, team yamaha, a 250cc bike, and before 1977?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "grand_prix_motorcycle_racing_results" ( "year" real, "class" text, "team" text, "points" real, "wins" real ); ### SQL Given the database schema, here is the SQL query that answers `How many wins for bikes with under 54 points, team yamaha, a 250cc bike, and before 1977?`: ```sql
SELECT "distance" FROM "stages" WHERE "stage">5 AND "winner"='giovanni lombardi';
## Task Generate a SQL query to answer the following question: `What distance did giovanni lombardi win after stage 5?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "stages" ( "stage" real, "date" text, "course" text, "distance" text, "winner" text, "gc_leader" text ); ### SQL Given the database schema, here is the SQL query that answers `What distance did giovanni lombardi win after stage 5?`: ```sql
SELECT "gc_leader" FROM "stages" WHERE "course"='ávila - segovia';
## Task Generate a SQL query to answer the following question: `Who is the GC leader at ávila - segovia?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "stages" ( "stage" real, "date" text, "course" text, "distance" text, "winner" text, "gc_leader" text ); ### SQL Given the database schema, here is the SQL query that answers `Who is the GC leader at ávila - segovia?`: ```sql
SELECT COUNT("grid") FROM "race" WHERE "laps"<41 AND "driver"='pedro de la rosa';
## Task Generate a SQL query to answer the following question: `How many grids have less than 41 laps and a Driver of pedro de la rosa?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "race" ( "driver" text, "constructor" text, "laps" real, "time_retired" text, "grid" real ); ### SQL Given the database schema, here is the SQL query that answers `How many grids have less than 41 laps and a Driver of pedro de la rosa?`: ```sql
SELECT "time_retired" FROM "race" WHERE "grid"<3 AND "driver"='mika häkkinen';
## Task Generate a SQL query to answer the following question: `Which Time/Retired has a Grid smaller than 3, and a Driver of mika häkkinen?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "race" ( "driver" text, "constructor" text, "laps" real, "time_retired" text, "grid" real ); ### SQL Given the database schema, here is the SQL query that answers `Which Time/Retired has a Grid smaller than 3, and a Driver of mika häkkinen?`: ```sql
SELECT AVG("laps") FROM "race" WHERE "driver"='toranosuke takagi';
## Task Generate a SQL query to answer the following question: `What are toranosuke takagi's average laps?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "race" ( "driver" text, "constructor" text, "laps" real, "time_retired" text, "grid" real ); ### SQL Given the database schema, here is the SQL query that answers `What are toranosuke takagi's average laps?`: ```sql
SELECT MIN("grid") FROM "race" WHERE "time_retired"='+5.004';
## Task Generate a SQL query to answer the following question: `Which grid has a Time/Retired of +5.004?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "race" ( "driver" text, "constructor" text, "laps" real, "time_retired" text, "grid" real ); ### SQL Given the database schema, here is the SQL query that answers `Which grid has a Time/Retired of +5.004?`: ```sql
SELECT "score" FROM "november" WHERE "visitor"='atlanta' AND "date"='november 9';
## Task Generate a SQL query to answer the following question: `What was the score of the game on November 9 when Atlanta was the visiting team?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "november" ( "date" text, "visitor" text, "score" text, "home" text, "decision" text, "attendance" real, "record" text ); ### SQL Given the database schema, here is the SQL query that answers `What was the score of the game on November 9 when Atlanta was the visiting team?`: ```sql
SELECT "score" FROM "november" WHERE "home"='tampa bay';
## Task Generate a SQL query to answer the following question: `What was the score of the home game at Tampa Bay?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "november" ( "date" text, "visitor" text, "score" text, "home" text, "decision" text, "attendance" real, "record" text ); ### SQL Given the database schema, here is the SQL query that answers `What was the score of the home game at Tampa Bay?`: ```sql
SELECT "date" FROM "november" WHERE "visitor"='atlanta' AND "home"='ottawa';
## Task Generate a SQL query to answer the following question: `What was the date of the game where Ottawa was the home team and Atlanta is the visiting team?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "november" ( "date" text, "visitor" text, "score" text, "home" text, "decision" text, "attendance" real, "record" text ); ### SQL Given the database schema, here is the SQL query that answers `What was the date of the game where Ottawa was the home team and Atlanta is the visiting team?`: ```sql
SELECT "result" FROM "awards" WHERE "team"='giants';
## Task Generate a SQL query to answer the following question: `I want the result for team of giants` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "awards" ( "pitcher" text, "date" text, "team" text, "result" text, "site" text ); ### SQL Given the database schema, here is the SQL query that answers `I want the result for team of giants`: ```sql
SELECT "pitcher" FROM "awards" WHERE "date"='september 6, 2006';
## Task Generate a SQL query to answer the following question: `Tell me the pitcher on september 6, 2006` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "awards" ( "pitcher" text, "date" text, "team" text, "result" text, "site" text ); ### SQL Given the database schema, here is the SQL query that answers `Tell me the pitcher on september 6, 2006`: ```sql
SELECT "date" FROM "awards" WHERE "team"='rockies';
## Task Generate a SQL query to answer the following question: `I want the date for rockies` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "awards" ( "pitcher" text, "date" text, "team" text, "result" text, "site" text ); ### SQL Given the database schema, here is the SQL query that answers `I want the date for rockies`: ```sql
SELECT "date" FROM "awards" WHERE "pitcher"='aníbal sánchez';
## Task Generate a SQL query to answer the following question: `I want the date for aníbal sánchez` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "awards" ( "pitcher" text, "date" text, "team" text, "result" text, "site" text ); ### SQL Given the database schema, here is the SQL query that answers `I want the date for aníbal sánchez`: ```sql
SELECT "result" FROM "awards" WHERE "team"='giants';
## Task Generate a SQL query to answer the following question: `I want the result for team of giants` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "awards" ( "pitcher" text, "date" text, "team" text, "result" text, "site" text ); ### SQL Given the database schema, here is the SQL query that answers `I want the result for team of giants`: ```sql
SELECT "site" FROM "awards" WHERE "date"='september 29, 2013';
## Task Generate a SQL query to answer the following question: `I want the site for september 29, 2013` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "awards" ( "pitcher" text, "date" text, "team" text, "result" text, "site" text ); ### SQL Given the database schema, here is the SQL query that answers `I want the site for september 29, 2013`: ```sql
SELECT "right_ascension_j2000" FROM "5001_5100" WHERE "apparent_magnitude"=10.5;
## Task Generate a SQL query to answer the following question: `When the apparent magnitude is 10.5, what is the right ascension?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "5001_5100" ( "ngc_number" real, "object_type" text, "constellation" text, "right_ascension_j2000" text, "declination_j2000" text, "apparent_magnitude" real ); ### SQL Given the database schema, here is the SQL query that answers `When the apparent magnitude is 10.5, what is the right ascension?`: ```sql
SELECT "livery" FROM "north_british_railway_coaches" WHERE "date"='1919';
## Task Generate a SQL query to answer the following question: `Which livery is from 1919?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "north_british_railway_coaches" ( "number_name" text, "description" text, "current_status" text, "livery" text, "date" text ); ### SQL Given the database schema, here is the SQL query that answers `Which livery is from 1919?`: ```sql
SELECT MAX("attendance") FROM "game_log" WHERE "record"='80-81';
## Task Generate a SQL query to answer the following question: `Of the games with a record of 80-81, what was the highest attendance?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "game_log" ( "date" text, "opponent" text, "score" text, "loss" text, "attendance" real, "record" text ); ### SQL Given the database schema, here is the SQL query that answers `Of the games with a record of 80-81, what was the highest attendance?`: ```sql
SELECT COUNT("peak") FROM "highest_rating_drama_series_of_2005" WHERE "hk_viewers"='2.23 million' AND "rank">2;
## Task Generate a SQL query to answer the following question: `How many entries have a HK viewers of 2.23 million, and a Rank below 2?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "highest_rating_drama_series_of_2005" ( "rank" real, "english_title" text, "chinese_title" text, "average" real, "peak" real, "premiere" real, "finale" real, "hk_viewers" text ); ### SQL Given the database schema, here is the SQL query that answers `How many entries have a HK viewers of 2.23 million, and a Rank below 2?`: ```sql
SELECT "premiere" FROM "highest_rating_drama_series_of_2005" WHERE "finale"<41 AND "peak"<40 AND "average">31 AND "chinese_title"='學警雄心';
## Task Generate a SQL query to answer the following question: `What premiere has a finale of less than 41, peak less than 40, average above 31, and a Chinese title of 學警雄心?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "highest_rating_drama_series_of_2005" ( "rank" real, "english_title" text, "chinese_title" text, "average" real, "peak" real, "premiere" real, "finale" real, "hk_viewers" text ); ### SQL Given the database schema, here is the SQL query that answers `What premiere has a finale of less than 41, peak less than 40, average above 31, and a Chinese title of 學警雄心?`: ```sql
SELECT MAX("average") FROM "highest_rating_drama_series_of_2005" WHERE "finale">35 AND "hk_viewers"='2.12 million' AND "peak">40;
## Task Generate a SQL query to answer the following question: `What is the high average that has a Finale larger than 35, a HK viewers of 2.12 million, and a Peak larger than 40?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "highest_rating_drama_series_of_2005" ( "rank" real, "english_title" text, "chinese_title" text, "average" real, "peak" real, "premiere" real, "finale" real, "hk_viewers" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the high average that has a Finale larger than 35, a HK viewers of 2.12 million, and a Peak larger than 40?`: ```sql
SELECT "home_team_score" FROM "round_18" WHERE "venue"='junction oval';
## Task Generate a SQL query to answer the following question: `What is the score for the home team when the venue is Junction Oval?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_18" ( "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 score for the home team when the venue is Junction Oval?`: ```sql
SELECT "venue" FROM "round_18" WHERE "home_team_score"='11.16 (82)' AND "away_team_score"='18.13 (121)';
## Task Generate a SQL query to answer the following question: `What is the location when the home team score is 11.16 (82) and the away team score is 18.13 (121)?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_18" ( "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 location when the home team score is 11.16 (82) and the away team score is 18.13 (121)?`: ```sql
SELECT MIN("crowd") FROM "round_18" WHERE "venue"='mcg';
## Task Generate a SQL query to answer the following question: `What is the lowest crowd number at the venue MCG?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_18" ( "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 lowest crowd number at the venue MCG?`: ```sql
SELECT SUM("viewers_millions") FROM "american_weekly_ratings" WHERE "episode"='\"the summer house\"';
## Task Generate a SQL query to answer the following question: `How many total viewers for "the summer house"?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "american_weekly_ratings" ( "episode" text, "air_date" text, "timeslot_est" text, "rating" real, "share" text, "18_49_rating" text, "viewers_millions" real, "rank" text ); ### SQL Given the database schema, here is the SQL query that answers `How many total viewers for "the summer house"?`: ```sql
SELECT AVG("round") FROM "2011_supercross_results" WHERE "place"='jacksonville';
## Task Generate a SQL query to answer the following question: `Name the average round for jacksonville` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2011_supercross_results" ( "round" real, "date" text, "place" text, "finished" text, "total_points" real, "standing" text ); ### SQL Given the database schema, here is the SQL query that answers `Name the average round for jacksonville`: ```sql
SELECT "standing" FROM "2011_supercross_results" WHERE "total_points"<248 AND "finished"='3rd' AND "date"='january 29';
## Task Generate a SQL query to answer the following question: `I want the standing for january 29 and finished of 3rd and total points less than 248` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2011_supercross_results" ( "round" real, "date" text, "place" text, "finished" text, "total_points" real, "standing" text ); ### SQL Given the database schema, here is the SQL query that answers `I want the standing for january 29 and finished of 3rd and total points less than 248`: ```sql
SELECT "result" FROM "season_schedule" WHERE "date"='february 22';
## Task Generate a SQL query to answer the following question: `What was the result and score of the game on February 22?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "season_schedule" ( "week" real, "date" text, "opponent" text, "result" text, "record" text ); ### SQL Given the database schema, here is the SQL query that answers `What was the result and score of the game on February 22?`: ```sql
SELECT MAX("rd_num") FROM "list_of_vancouver_canucks_draft_picks" WHERE "pl_gp">0 AND "reg_gp"<62;
## Task Generate a SQL query to answer the following question: `What is the largest Rd# for a PI GP greater than 0 and a Reg GP less than 62?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "list_of_vancouver_canucks_draft_picks" ( "rd_num" real, "pick_num" real, "player" text, "team_league" text, "reg_gp" real, "pl_gp" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the largest Rd# for a PI GP greater than 0 and a Reg GP less than 62?`: ```sql
SELECT "team_league" FROM "list_of_vancouver_canucks_draft_picks" WHERE "reg_gp">62;
## Task Generate a SQL query to answer the following question: `Which team has a Reg GP over 62?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "list_of_vancouver_canucks_draft_picks" ( "rd_num" real, "pick_num" real, "player" text, "team_league" text, "reg_gp" real, "pl_gp" real ); ### SQL Given the database schema, here is the SQL query that answers `Which team has a Reg GP over 62?`: ```sql
SELECT SUM("year") FROM "achievements" WHERE "position"='12th';
## Task Generate a SQL query to answer the following question: `What is the total year with a Position of 12th?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "achievements" ( "year" real, "competition" text, "venue" text, "position" text, "event" text, "notes" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the total year with a Position of 12th?`: ```sql
SELECT MIN("grid") FROM "race" WHERE "time_retired"='accident' AND "laps"<18;
## Task Generate a SQL query to answer the following question: `When a race had less than 18 laps and time/retired of accident, what was the smallest grid?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "race" ( "driver" text, "constructor" text, "laps" real, "time_retired" text, "grid" real ); ### SQL Given the database schema, here is the SQL query that answers `When a race had less than 18 laps and time/retired of accident, what was the smallest grid?`: ```sql
SELECT "time_retired" FROM "race" WHERE "grid">17 AND "laps"=74;
## Task Generate a SQL query to answer the following question: `What is the time/retired for a grid over 17 with 74 laps?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "race" ( "driver" text, "constructor" text, "laps" real, "time_retired" text, "grid" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the time/retired for a grid over 17 with 74 laps?`: ```sql
SELECT SUM("grid") FROM "race" WHERE "driver"='david coulthard';
## Task Generate a SQL query to answer the following question: `What is the grid total for david coulthard?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "race" ( "driver" text, "constructor" text, "laps" real, "time_retired" text, "grid" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the grid total for david coulthard?`: ```sql
SELECT "date" FROM "walking" WHERE "athlete"='chris maddocks' AND "event"='35000 m';
## Task Generate a SQL query to answer the following question: `What day did Chris Maddocks compete in the 35000 m?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "walking" ( "event" text, "data" text, "athlete" text, "date" text, "place" text ); ### SQL Given the database schema, here is the SQL query that answers `What day did Chris Maddocks compete in the 35000 m?`: ```sql
SELECT "athlete" FROM "walking" WHERE "data"='214.061km';
## Task Generate a SQL query to answer the following question: `Who has a walking data of 214.061km?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "walking" ( "event" text, "data" text, "athlete" text, "date" text, "place" text ); ### SQL Given the database schema, here is the SQL query that answers `Who has a walking data of 214.061km?`: ```sql
SELECT "athlete" FROM "walking" WHERE "data"='3:10:48+';
## Task Generate a SQL query to answer the following question: `Who has a walking data of 3:10:48+?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "walking" ( "event" text, "data" text, "athlete" text, "date" text, "place" text ); ### SQL Given the database schema, here is the SQL query that answers `Who has a walking data of 3:10:48+?`: ```sql
SELECT "title" FROM "season_1" WHERE "original_air_date"='october2,2002';
## Task Generate a SQL query to answer the following question: `what is the title of the episode with the original air date of october2,2002?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "season_1" ( "title" text, "directed_by" text, "written_by" text, "original_air_date" text, "production_code" text ); ### SQL Given the database schema, here is the SQL query that answers `what is the title of the episode with the original air date of october2,2002?`: ```sql
SELECT "title" FROM "season_1" WHERE "production_code"='ad1a22';
## Task Generate a SQL query to answer the following question: `what is the title of the episode with the production code of ad1a22?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "season_1" ( "title" text, "directed_by" text, "written_by" text, "original_air_date" text, "production_code" text ); ### SQL Given the database schema, here is the SQL query that answers `what is the title of the episode with the production code of ad1a22?`: ```sql
SELECT "directed_by" FROM "season_1" WHERE "production_code"='ad1a26';
## Task Generate a SQL query to answer the following question: `who was the director of the episode with production code ad1a26?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "season_1" ( "title" text, "directed_by" text, "written_by" text, "original_air_date" text, "production_code" text ); ### SQL Given the database schema, here is the SQL query that answers `who was the director of the episode with production code ad1a26?`: ```sql
SELECT "constructor" FROM "non_championship_race_results" WHERE "circuit"='oulton park';
## Task Generate a SQL query to answer the following question: `Who is the constructor whose circuit was Oulton Park?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "non_championship_race_results" ( "race_name" text, "circuit" text, "date" text, "winning_driver" text, "constructor" text, "report" text ); ### SQL Given the database schema, here is the SQL query that answers `Who is the constructor whose circuit was Oulton Park?`: ```sql
SELECT "race_name" FROM "non_championship_race_results" WHERE "circuit"='snetterton';
## Task Generate a SQL query to answer the following question: `What is the name of the race for which the circuit was Snetterton?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "non_championship_race_results" ( "race_name" text, "circuit" text, "date" text, "winning_driver" text, "constructor" text, "report" text ); ### SQL Given the database schema, here is the SQL query that answers `What is the name of the race for which the circuit was Snetterton?`: ```sql
SELECT "years_for_rockets" FROM "b" WHERE "height_in_ft"='6-6' AND "position"='guard' AND "school_club_team_country"='oklahoma';
## Task Generate a SQL query to answer the following question: `During what years did the Guard from Oklahoma with a height of 6-6 play for the Rockets?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "b" ( "player" text, "no_s" text, "height_in_ft" text, "position" text, "years_for_rockets" text, "school_club_team_country" text ); ### SQL Given the database schema, here is the SQL query that answers `During what years did the Guard from Oklahoma with a height of 6-6 play for the Rockets?`: ```sql
SELECT "away_team_score" FROM "round_3" WHERE "crowd">'24,365' AND "venue"='mcg';
## Task Generate a SQL query to answer the following question: `What was the away team's score at MCG when attendance was more than 24,365?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_3" ( "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 at MCG when attendance was more than 24,365?`: ```sql
SELECT COUNT("drawn") FROM "season_summaries" WHERE "position"='6th' AND "competition"='super league xvii' AND "played">27;
## Task Generate a SQL query to answer the following question: `how many times what the position 6th, the competition was super league xvii and played was larger than 27?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "season_summaries" ( "competition" text, "played" real, "drawn" real, "lost" real, "position" text ); ### SQL Given the database schema, here is the SQL query that answers `how many times what the position 6th, the competition was super league xvii and played was larger than 27?`: ```sql
SELECT COUNT("average") FROM "highest_goalscorers" WHERE "caps"<69 AND "scotland_career"='1986–1998';
## Task Generate a SQL query to answer the following question: `What is the average cap number in scotland in 1986–1998 leass than 69?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "highest_goalscorers" ( "name" text, "scotland_career" text, "caps" real, "goals" real, "average" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the average cap number in scotland in 1986–1998 leass than 69?`: ```sql
SELECT "caps" FROM "highest_goalscorers" WHERE "scotland_career"='1920–1923';
## Task Generate a SQL query to answer the following question: `Which caps was in scotland in 1920–1923?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "highest_goalscorers" ( "name" text, "scotland_career" text, "caps" real, "goals" real, "average" real ); ### SQL Given the database schema, here is the SQL query that answers `Which caps was in scotland in 1920–1923?`: ```sql
SELECT MIN("goals") FROM "highest_goalscorers" WHERE "caps"<38 AND "average"<1.083;
## Task Generate a SQL query to answer the following question: `What is the goal low with caps less than 38 and an average less than 1.083?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "highest_goalscorers" ( "name" text, "scotland_career" text, "caps" real, "goals" real, "average" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the goal low with caps less than 38 and an average less than 1.083?`: ```sql
SELECT MAX("goals") FROM "highest_goalscorers" WHERE "caps"=38 AND "average"<0.579;
## Task Generate a SQL query to answer the following question: `What is the goal top with caps of 38 and an average less than 0.579?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "highest_goalscorers" ( "name" text, "scotland_career" text, "caps" real, "goals" real, "average" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the goal top with caps of 38 and an average less than 0.579?`: ```sql
SELECT MIN("goals") FROM "highest_goalscorers" WHERE "name"='kenny miller' AND "average"<0.261;
## Task Generate a SQL query to answer the following question: `What is the low goal for kenny miller with an average smaller than 0.261?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "highest_goalscorers" ( "name" text, "scotland_career" text, "caps" real, "goals" real, "average" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the low goal for kenny miller with an average smaller than 0.261?`: ```sql
SELECT "home_team" FROM "round_11" WHERE "venue"='victoria park';
## Task Generate a SQL query to answer the following question: `What home team plays at victoria park?` ### 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 `What home team plays at victoria park?`: ```sql
SELECT "home_team" FROM "round_11" WHERE "home_team_score"='23.17 (155)';
## Task Generate a SQL query to answer the following question: `What home team scored 23.17 (155)?` ### 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 `What home team scored 23.17 (155)?`: ```sql
SELECT "venue" FROM "round_11" WHERE "crowd">'22,764' AND "away_team"='st kilda';
## Task Generate a SQL query to answer the following question: `Where did away team st kilda play with a crowd larger than 22,764?` ### 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 `Where did away team st kilda play with a crowd larger than 22,764?`: ```sql
SELECT "away_team_score" FROM "round_11" WHERE "home_team"='north melbourne';
## Task Generate a SQL query to answer the following question: `When north melbourne played as the home team, what was the away team score?` ### 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 `When north melbourne played as the home team, what was the away team score?`: ```sql
SELECT "away_team" FROM "round_11" WHERE "home_team_score"='17.15 (117)';
## Task Generate a SQL query to answer the following question: `What is the away team when home scored 17.15 (117)?` ### 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 `What is the away team when home scored 17.15 (117)?`: ```sql
SELECT "away_team_score" FROM "round_11" WHERE "venue"='victoria park';
## Task Generate a SQL query to answer the following question: `What is the away team score at victoria park?` ### 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 `What is the away team score at victoria park?`: ```sql
SELECT MAX("goals_against") FROM "league_standings" WHERE "wins"=18 AND "goal_difference"=43 AND "draws"<6;
## Task Generate a SQL query to answer the following question: `What is the high goal against associated with 18 wins, a Goal Difference of 43, and under 6 draws?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "league_standings" ( "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 high goal against associated with 18 wins, a Goal Difference of 43, and under 6 draws?`: ```sql
SELECT AVG("wins") FROM "league_standings" WHERE "draws"<4 AND "goals_for"<15;
## Task Generate a SQL query to answer the following question: `What is the average win total associated with under 4 draws, and under 15 goals?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "league_standings" ( "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 win total associated with under 4 draws, and under 15 goals?`: ```sql
SELECT "home_team" FROM "round_5" WHERE "venue"='moorabbin oval';
## Task Generate a SQL query to answer the following question: `Who was the home team that played at Moorabbin Oval?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_5" ( "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 played at Moorabbin Oval?`: ```sql
SELECT COUNT("crowd") FROM "round_5" WHERE "away_team_score"='11.15 (81)';
## Task Generate a SQL query to answer the following question: `How large was the crowd when the away team scored 11.15 (81)?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_5" ( "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 when the away team scored 11.15 (81)?`: ```sql
SELECT "home_team" FROM "round_5" WHERE "crowd">'20,350' AND "away_team_score"='12.19 (91)';
## Task Generate a SQL query to answer the following question: `Who was the home team when the away team scored 12.19 (91) and the crowd was larger than 20,350?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_5" ( "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 when the away team scored 12.19 (91) and the crowd was larger than 20,350?`: ```sql
SELECT COUNT("crowd") FROM "round_5" WHERE "away_team"='carlton';
## Task Generate a SQL query to answer the following question: `How large was the crowd when Carlton was the away team?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_5" ( "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 when Carlton was the away team?`: ```sql
SELECT "home_team" FROM "round_5" WHERE "home_team_score"='19.11 (125)';
## Task Generate a SQL query to answer the following question: `Which home team scored 19.11 (125)?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_5" ( "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 scored 19.11 (125)?`: ```sql
SELECT SUM("year") FROM "player_selections" WHERE "player_name"='mark barron';
## Task Generate a SQL query to answer the following question: `I want the sum of year for mark barron` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "player_selections" ( "year" real, "pick" text, "player_name" text, "position" text, "college" text ); ### SQL Given the database schema, here is the SQL query that answers `I want the sum of year for mark barron`: ```sql
SELECT "year" FROM "player_selections" WHERE "position"='defensive tackle' AND "college"='lsu';
## Task Generate a SQL query to answer the following question: `Tell me the year for defensive tackle and college of lsu` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "player_selections" ( "year" real, "pick" text, "player_name" text, "position" text, "college" text ); ### SQL Given the database schema, here is the SQL query that answers `Tell me the year for defensive tackle and college of lsu`: ```sql
SELECT AVG("attendance") FROM "playoffs" WHERE "date"='april 28';
## Task Generate a SQL query to answer the following question: `On April 28, what was the average number of people attending?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "playoffs" ( "date" text, "visitor" text, "score" text, "home" text, "decision" text, "attendance" real, "series" text ); ### SQL Given the database schema, here is the SQL query that answers `On April 28, what was the average number of people attending?`: ```sql
SELECT "player" FROM "draft_picks" WHERE "position"='centre';
## Task Generate a SQL query to answer the following question: `Which player is a centre?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "draft_picks" ( "round" real, "player" text, "position" text, "nationality" text, "college_junior_club_team_league" text ); ### SQL Given the database schema, here is the SQL query that answers `Which player is a centre?`: ```sql
SELECT "venue" FROM "round_5" WHERE "away_team"='collingwood';
## Task Generate a SQL query to answer the following question: `What was the venue when Collingwood was the away team?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "round_5" ( "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 venue when Collingwood was the away team?`: ```sql
SELECT "venue" FROM "most_tries_in_a_match" WHERE "conv"='0' AND "player"='brian hightower';
## Task Generate a SQL query to answer the following question: `Where did Brian Hightower play when he has the Conv of 0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "most_tries_in_a_match" ( "player" text, "tries" text, "conv" text, "venue" text, "date" text ); ### SQL Given the database schema, here is the SQL query that answers `Where did Brian Hightower play when he has the Conv of 0?`: ```sql
SELECT "conv" FROM "most_tries_in_a_match" WHERE "player"='dick hyland';
## Task Generate a SQL query to answer the following question: `What was Dick Hyland's conv?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "most_tries_in_a_match" ( "player" text, "tries" text, "conv" text, "venue" text, "date" text ); ### SQL Given the database schema, here is the SQL query that answers `What was Dick Hyland's conv?`: ```sql
SELECT "tries" FROM "most_tries_in_a_match" WHERE "date"='06/07/1996';
## Task Generate a SQL query to answer the following question: `How many tries took place on 06/07/1996?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "most_tries_in_a_match" ( "player" text, "tries" text, "conv" text, "venue" text, "date" text ); ### SQL Given the database schema, here is the SQL query that answers `How many tries took place on 06/07/1996?`: ```sql
SELECT "player" FROM "most_tries_in_a_match" WHERE "date"='07/06/1997';
## Task Generate a SQL query to answer the following question: `Which player played on 07/06/1997?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "most_tries_in_a_match" ( "player" text, "tries" text, "conv" text, "venue" text, "date" text ); ### SQL Given the database schema, here is the SQL query that answers `Which player played on 07/06/1997?`: ```sql
SELECT "date" FROM "round_4" WHERE "home_team_score"='11.17 (83)';
## Task Generate a SQL query to answer the following question: `The home team scored 11.17 (83) on what day?` ### 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 `The home team scored 11.17 (83) on what day?`: ```sql
SELECT "date" FROM "round_4" WHERE "crowd">'16,000' AND "away_team"='south melbourne';
## Task Generate a SQL query to answer the following question: `When the crowd was over 16,000 people and south melbourne was the away team, what date was the game?` ### 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 `When the crowd was over 16,000 people and south melbourne was the away team, what date was the game?`: ```sql
SELECT "home_team" FROM "round_4" WHERE "home_team_score"='16.16 (112)';
## Task Generate a SQL query to answer the following question: `Which home team scored 16.16 (112)?` ### 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 `Which home team scored 16.16 (112)?`: ```sql
SELECT "venue" FROM "round_4" WHERE "away_team"='melbourne';
## Task Generate a SQL query to answer the following question: `When the Away team is melbourne, what venue do they play at?` ### 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 `When the Away team is melbourne, what venue do they play at?`: ```sql
SELECT MIN("interview") FROM "final_competition" WHERE "state"='texas' AND "average">9.531;
## Task Generate a SQL query to answer the following question: `What is the lowest interview of Texas, with an average larger than 9.531?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "final_competition" ( "state" text, "interview" real, "swimsuit" real, "evening_gown" real, "average" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the lowest interview of Texas, with an average larger than 9.531?`: ```sql
SELECT COUNT("interview") FROM "final_competition" WHERE "state"='iowa' AND "evening_gown"<9.625;
## Task Generate a SQL query to answer the following question: `What is the total interviews of Iowa, and with an evening gown smaller than 9.625?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "final_competition" ( "state" text, "interview" real, "swimsuit" real, "evening_gown" real, "average" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the total interviews of Iowa, and with an evening gown smaller than 9.625?`: ```sql
SELECT SUM("average") FROM "final_competition" WHERE "state"='hawaii' AND "interview">9.636;
## Task Generate a SQL query to answer the following question: `What is the sum of the average of Hawaii, with an interviewer larger than 9.636?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "final_competition" ( "state" text, "interview" real, "swimsuit" real, "evening_gown" real, "average" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the sum of the average of Hawaii, with an interviewer larger than 9.636?`: ```sql
SELECT MAX("evening_gown") FROM "final_competition" WHERE "average"=9.531 AND "swimsuit"<9.449;
## Task Generate a SQL query to answer the following question: `What is the highest evening gown with an average of 9.531 and swimsuit smaller than 9.449?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "final_competition" ( "state" text, "interview" real, "swimsuit" real, "evening_gown" real, "average" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the highest evening gown with an average of 9.531 and swimsuit smaller than 9.449?`: ```sql
SELECT SUM("swimsuit") FROM "final_competition" WHERE "evening_gown"=9.773 AND "average">9.674;
## Task Generate a SQL query to answer the following question: `What is the sum of swimsuit with an evening gown of 9.773 and average larger than 9.674?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "final_competition" ( "state" text, "interview" real, "swimsuit" real, "evening_gown" real, "average" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the sum of swimsuit with an evening gown of 9.773 and average larger than 9.674?`: ```sql
SELECT AVG("average") FROM "final_competition" WHERE "swimsuit"<9.545 AND "state"='iowa' AND "evening_gown">9.625;
## Task Generate a SQL query to answer the following question: `What is the average of the swimsuit smaller than 9.545 , of Iowa, with an evening gown larger than 9.625?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "final_competition" ( "state" text, "interview" real, "swimsuit" real, "evening_gown" real, "average" real ); ### SQL Given the database schema, here is the SQL query that answers `What is the average of the swimsuit smaller than 9.545 , of Iowa, with an evening gown larger than 9.625?`: ```sql
SELECT "leading_scorer" FROM "april" WHERE "date"='1 april 2008';
## Task Generate a SQL query to answer the following question: `Name the leading scorer for 1 april 2008` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "april" ( "date" text, "visitor" text, "score" text, "home" text, "leading_scorer" text, "record" text ); ### SQL Given the database schema, here is the SQL query that answers `Name the leading scorer for 1 april 2008`: ```sql