instruction
stringlengths
212
6.3k
output
stringlengths
6
2.03k
### Instruction: CREATE TABLE table_14007 ( "Position" real, "Team" text, "Played" real, "Wins" real, "Draws" real, "Losses" real, "Scored" real, "Conceded" real, "Points" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- How many point...
SELECT SUM("Scored") FROM table_14007 WHERE "Points" = '8' AND "Position" < '10'
### Instruction: CREATE TABLE table_38060 ( "Call sign" text, "Frequency MHz" real, "City of license" text, "ERP W" real, "Class" text, "FCC info" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Which ERP W is the highest one that has a Frequency...
SELECT MAX("ERP W") FROM table_38060 WHERE "Frequency MHz" > '88.3' AND "City of license" = 'lewis, kansas'
### Instruction: CREATE TABLE table_78170 ( "Season" real, "Belonging league" text, "Matches" real, "league point" real, "Draw" real, "Lose" real, "Goal difference" real, "Point" real, "Lost point" real, "Final rank" real ) -- Using valid SQLite, answer the following questions ...
SELECT MAX("Matches") FROM table_78170 WHERE "Point" = '43' AND "Final rank" < '7'
### Instruction: CREATE TABLE table_80205 ( "Name" text, "Period" text, "League" real, "FA Cup" real, "League Cup" real, "Other" real, "Total" real, "Apps" real, "Goal Ratio" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What's the ...
SELECT MAX("Goal Ratio") FROM table_80205 WHERE "League" = '88' AND "FA Cup" < '7'
### Instruction: CREATE TABLE table_7328 ( "Country or region" text, "Number of mobile phones" text, "Population" text, "# of phones as % of population" real, "Last updated date" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What percent is 327,577...
SELECT MAX("# of phones as % of population") FROM table_7328 WHERE "Last updated date" = 'june 2013' AND "Number of mobile phones" = '327,577,529'
### Instruction: CREATE TABLE table_42925 ( "Rank" real, "Location" text, "Total Passengers" real, "Annual change" text, "Capacity" real, "Capacity in use" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- How many Capacity has a Annual change of 5...
SELECT AVG("Capacity") FROM table_42925 WHERE "Annual change" = '53.4%' AND "Total Passengers" < '7,822,848'
### Instruction: CREATE TABLE table_11041 ( "Drobo (1st)" text, "Drobo (2nd)" text, "Drobo S" text, "Drobo S (2nd)" text, "Drobo FS" text, "Drobo Mini" text, "Drobo 5D" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Which Drobo (2nd) has a D...
SELECT "Drobo (2nd)" FROM table_11041 WHERE "Drobo S (2nd)" = '5'
### Instruction: CREATE TABLE table_24970 ( "No. in series" real, "No. in season" real, "Title" text, "Directed by" text, "Written by" text, "Original air date" text, "Production code" text, "U.S. viewers (millions)" text ) -- Using valid SQLite, answer the following questions for the ...
SELECT "Written by" FROM table_24970 WHERE "U.S. viewers (millions)" = '2.15'
### Instruction: CREATE TABLE table_204_708 ( id number, "victim(s)" text, "age" number, "gender" text, "date" text, "type of attack" text, "location" text, "details" text, "source(s)" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- w...
SELECT "date" FROM table_204_708 WHERE "victim(s)" = 'dr. bob piorkowski, alaska fish and game, and his wife'
### Instruction: CREATE TABLE table_204_154 ( id number, "player" text, "matches" number, "innings" number, "runs" number, "average" number, "100s" number, "50s" number ) -- Using valid SQLite, answer the following questions for the tables provided above. -- how many more runs does jo...
SELECT (SELECT "runs" FROM table_204_154 WHERE "player" = 'john challen') - (SELECT "runs" FROM table_204_154 WHERE "player" = 'albert clapp')
### Instruction: CREATE TABLE table_18963 ( "Club" text, "Played" text, "Won" text, "Drawn" text, "Lost" text, "Points for" text, "Points against" text, "Tries for" text, "Tries against" text, "Try bonus" text, "Losing bonus" text, "Points" text ) -- Using valid SQLite,...
SELECT "Club" FROM table_18963 WHERE "Points for" = '565'
### Instruction: CREATE TABLE table_58964 ( "Main contestant" text, "Co-contestant (Yaar vs. Pyaar)" text, "Date performed" text, "Scores by each individual judge" text, "Total score/week" text, "Position" text, "Status" text ) -- Using valid SQLite, answer the following questions for the ...
SELECT "Status" FROM table_58964 WHERE "Co-contestant (Yaar vs. Pyaar)" = 'tina parekh'
### Instruction: CREATE TABLE table_62709 ( "Club" text, "Played" text, "Drawn" text, "Lost" text, "Points for" text, "Points against" text, "Tries for" text, "Tries against" text, "Try bonus" text, "Losing bonus" text, "Points" text ) -- Using valid SQLite, answer the foll...
SELECT "Drawn" FROM table_62709 WHERE "Club" = 'furnace united rfc'
### Instruction: CREATE TABLE table_38090 ( "7:00" text, "7:30" text, "8:00" text, "8:30" text, "9:00" text, "9:30" text, "10:00" text, "10:30" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the 7:30 feature with an 8:30 feature ...
SELECT "7:30" FROM table_38090 WHERE "8:30" = 'melrose place'
### Instruction: CREATE TABLE table_12597 ( "State" text, "Status" text, "Association Agreement" text, "Membership Application" text, "Candidate status" text, "Negotiations start" text, "Screening completed" text, "Acquis Chapters open/closed" text ) -- Using valid SQLite, answer the f...
SELECT "Status" FROM table_12597 WHERE "Membership Application" = '2008-12-15'
### Instruction: CREATE TABLE table_10388 ( "Week" real, "Date" text, "Opponent" text, "Result" text, "Game site" text, "NFL Recap" text, "Attendance" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the NFL Recap with more than 62,310...
SELECT "NFL Recap" FROM table_10388 WHERE "Attendance" > '62,310' AND "Result" = 'w 30–29'
### Instruction: CREATE TABLE participants ( participant_id number, participant_type_code text, participant_details text ) CREATE TABLE participants_in_events ( event_id number, participant_id number ) CREATE TABLE events ( event_id number, service_id number, event_details text ) CREA...
SELECT participant_type_code FROM participants GROUP BY participant_type_code ORDER BY COUNT(*) DESC LIMIT 1
### Instruction: CREATE TABLE candidate ( Candidate_ID int, People_ID int, Poll_Source text, Date text, Support_rate real, Consider_rate real, Oppose_rate real, Unsure_rate real ) CREATE TABLE people ( People_ID int, Sex text, Name text, Date_of_Birth text, Height re...
SELECT Date_of_Birth, Weight FROM people
### Instruction: CREATE TABLE table_73825 ( "Settlement" text, "Cyrillic Name Other Names" text, "Type" text, "Population (2011)" real, "Largest ethnic group (2002)" text, "Dominant religion (2002)" text ) -- Using valid SQLite, answer the following questions for the tables provided above. --...
SELECT COUNT("Settlement") FROM table_73825 WHERE "Cyrillic Name Other Names" = 'Ђурђин (Croatian: Đurđin)'
### Instruction: CREATE TABLE table_203_413 ( id number, "rank" text, "city" text, "population" number, "area\n(km2)" number, "density\n(inhabitants/km2)" number, "altitude\n(mslm)" number ) -- Using valid SQLite, answer the following questions for the tables provided above. -- how many c...
SELECT COUNT("city") FROM table_203_413 WHERE "population" > (SELECT "population" FROM table_203_413 WHERE "city" = 'arquata scrivia')
### Instruction: CREATE TABLE table_572 ( "Club" text, "Played" text, "Won" text, "Drawn" text, "Lost" text, "Points for" text, "Points against" text, "Tries for" text, "Tries against" text, "Try bonus" text, "Losing bonus" text, "Points" text ) -- Using valid SQLite, a...
SELECT "Won" FROM table_572 WHERE "Tries against" = '54'
### Instruction: CREATE TABLE table_21881 ( "Season" text, "Date" text, "Driver" text, "Team" text, "Chassis" text, "Engine" text, "Laps" text, "Miles (km)" text, "Race Time" text, "Average Speed (mph)" text, "Report" text ) -- Using valid SQLite, answer the following quest...
SELECT COUNT("Driver") FROM table_21881 WHERE "Season" = '2005'
### Instruction: CREATE TABLE table_25989 ( "Player" text, "Games Played" real, "Minutes" real, "Field Goals" real, "Three Pointers" real, "Free Throws" real, "Rebounds" real, "Assists" real, "Blocks" real, "Steals" real, "Points" real ) -- Using valid SQLite, answer the fo...
SELECT "Steals" FROM table_25989 WHERE "Player" = 'Jasmine Wynne'
### Instruction: CREATE TABLE table_59552 ( "Rider" text, "Bike" text, "Laps" real, "Time" text, "Grid" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the highest Laps, when Bike is 'Yamaha YZF-R1', when Rider is 'David Checa', and when Grid...
SELECT MAX("Laps") FROM table_59552 WHERE "Bike" = 'yamaha yzf-r1' AND "Rider" = 'david checa' AND "Grid" > '18'
### Instruction: CREATE TABLE table_51951 ( "Res." text, "Record" text, "Opponent" text, "Method" text, "Event" text, "Round" real, "Time" text, "Location" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is his record for fights that...
SELECT "Record" FROM table_51951 WHERE "Round" > '2' AND "Event" = 'raging wolf 6: mayhem in the mist'
### Instruction: CREATE TABLE table_27511 ( "Song" text, "Singer" text, "Co-Singers" text, "Music Director" text, "Lyricist" text, "Co-Stars" text, "Movie/Album" text, "Year" real, "Additional Info" text ) -- Using valid SQLite, answer the following questions for the tables provide...
SELECT "Lyricist" FROM table_27511 WHERE "Music Director" = 'Madan Mohan Kohli'
### Instruction: CREATE TABLE table_75304 ( "Source" text, "Date" text, "Blagojevich (D)" text, "Topinka (R)" text, "Remainder" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Which Blagojevich (D) has a Source of zogby/wsj, and a Date of october 16,...
SELECT "Blagojevich (D)" FROM table_75304 WHERE "Source" = 'zogby/wsj' AND "Date" = 'october 16, 2006'
### Instruction: CREATE TABLE table_72476 ( "Locale" text, "Skip" text, "W" real, "L" real, "PF" real, "PA" real, "Ends Won" real, "Ends Lost" real, "Blank Ends" real, "Stolen Ends" real, "Shot Pct." real ) -- Using valid SQLite, answer the following questions for the table...
SELECT MIN("PA") FROM table_72476 WHERE "Ends Lost" = '45'
### Instruction: CREATE TABLE table_79247 ( "School" text, "Location" text, "Mascot" text, "# / County" text, "Enrollment" real, "IHSAA Class /Football/Soccer" text, "Year joined" real, "Previous Conference" text, "Year Left" real, "Conference Joined" text ) -- Using valid SQLi...
SELECT MAX("Enrollment") FROM table_79247 WHERE "School" = 'rochester community'
### Instruction: CREATE TABLE candidate ( Candidate_ID int, People_ID int, Poll_Source text, Date text, Support_rate real, Consider_rate real, Oppose_rate real, Unsure_rate real ) CREATE TABLE people ( People_ID int, Sex text, Name text, Date_of_Birth text, Height re...
SELECT Height, Weight FROM people GROUP BY Sex
### Instruction: CREATE TABLE table_2426 ( "Order" real, "Couple" text, "Karen" text, "Nicky" text, "Jason" text, "Ruthie" text, "Robin" text, "Total" text, "Scoreboard" text, "Song" text, "Public Vote %" text, "Result" text ) -- Using valid SQLite, answer the following...
SELECT "Robin" FROM table_2426 WHERE "Result" = 'Eliminated'
### Instruction: CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255), Price DECIMAL, Manufacturer INTEGER ) CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255), Headquarter VARCHAR(255), Founder VARCHAR(255), Revenue REAL ) -- Using valid SQLite, answer the following ...
SELECT Name, AVG(Price) FROM Products GROUP BY Name ORDER BY AVG(Price)
### Instruction: CREATE TABLE table_name_63 ( university_of_minnesota VARCHAR, rood_ VARCHAR, _taylor VARCHAR, buechel_ VARCHAR, _manhart_spelling__pronunciation_ VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Rood & Taylor of o, and a Buechel & ...
SELECT university_of_minnesota FROM table_name_63 WHERE rood_ & _taylor = "o" AND buechel_ & _manhart_spelling__pronunciation_ = "o"
### Instruction: CREATE TABLE table_train_76 ( "id" int, "mini_mental_state_examination_mmse" int, "language" string, "csf" int, "rosen_modified_hachinski_ischemic_score" int, "ad" bool, "age" float, "NOUSE" float ) -- Using valid SQLite, answer the following questions for the tables p...
SELECT * FROM table_train_76 WHERE ad = 1 AND csf < 600
### Instruction: CREATE TABLE table_60995 ( "Semi-closed initial unstressed vowels" text, "17th c." text, "American" text, "Australian" text, "Examples" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the American sound that has a 17th centur...
SELECT "American" FROM table_60995 WHERE "17th c." = 'ɪ' AND "Semi-closed initial unstressed vowels" = 'i /ɪ, ɨ/'
### Instruction: CREATE TABLE assignedto ( project VARCHAR, scientist VARCHAR ) CREATE TABLE scientists ( name VARCHAR, SSN VARCHAR ) CREATE TABLE projects ( code VARCHAR, hours INTEGER ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Find the names ...
SELECT name FROM scientists EXCEPT SELECT T3.name FROM assignedto AS T1 JOIN projects AS T2 ON T1.project = T2.code JOIN scientists AS T3 ON T1.scientist = T3.SSN WHERE T2.hours = (SELECT MAX(hours) FROM projects)
### Instruction: CREATE TABLE table_14373 ( "January" text, "February" text, "March" text, "April" text, "June" text, "July" text, "August" text, "September" text, "October" text, "November" text, "December" text ) -- Using valid SQLite, answer the following questions for t...
SELECT "June" FROM table_14373 WHERE "November" = 'lorraine olivia'
### Instruction: CREATE TABLE table_23149 ( "Player" text, "Team" text, "Matches" real, "Overs" text, "Wickets" real, "Economy Rate" text, "Average" text, "Strike Rate" text, "BBI" text, "BBM" text ) -- Using valid SQLite, answer the following questions for the tables provided ...
SELECT COUNT("Wickets") FROM table_23149 WHERE "Strike Rate" = '54.0'
### Instruction: CREATE TABLE table_10971 ( "Race" text, "Circuit" text, "Date" text, "Pole position" text, "Fastest lap" text, "Winning driver" text, "Constructor" text, "Tyre" text, "Report" text ) -- Using valid SQLite, answer the following questions for the tables provided abov...
SELECT "Winning driver" FROM table_10971 WHERE "Pole position" = 'jim clark' AND "Fastest lap" = 'jim clark'
### Instruction: CREATE TABLE member_attendance ( Member_ID int, Performance_ID int, Num_of_Pieces int ) CREATE TABLE performance ( Performance_ID real, Date text, Host text, Location text, Attendance int ) CREATE TABLE member ( Member_ID text, Name text, Nationality text, ...
SELECT Location, COUNT(*) FROM performance GROUP BY Location ORDER BY Location DESC
### Instruction: CREATE TABLE table_62703 ( "Season" real, "Winners" text, "Runners-up" text, "Third-place" text, "fourth-placed" text, "Number of clubs" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the number of clubs before 2003 with...
SELECT AVG("Number of clubs") FROM table_62703 WHERE "fourth-placed" = 'shenzhen jianlibao' AND "Season" < '2003'
### Instruction: CREATE TABLE table_31107 ( "Rank 2011" real, "Country" text, "Production in 2011 (1,000 ton)" real, "Share 2011" text, "Rank 2010" real, "Production in 2010 (1,000 ton)" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- When 5 is t...
SELECT "Country" FROM table_31107 WHERE "Rank 2011" = '5'
### Instruction: CREATE TABLE table_39356 ( "Outcome" text, "Year" real, "Championship" text, "Surface" text, "Partner" text, "Opponents in the final" text, "Score in the final" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What was the sur...
SELECT "Surface" FROM table_39356 WHERE "Partner" = 'julie halard' AND "Score in the final" = '6–3, 6–2'
### Instruction: CREATE TABLE table_29739 ( "Game" real, "Date" text, "Team" text, "Score" text, "High points" text, "High rebounds" text, "High assists" text, "Location Attendance" text, "Record" text ) -- Using valid SQLite, answer the following questions for the tables provided ...
SELECT "High assists" FROM table_29739 WHERE "Location Attendance" = 'Quicken Loans Arena 20,562'
### Instruction: CREATE TABLE table_28206 ( "Celebrity" text, "Known for" text, "Age" real, "Professional" text, "Series" real, "Place" text, "Dances" real, "Highest score" real, "Lowest score" real, "Aggregate" real, "Average" text ) -- Using valid SQLite, answer the follo...
SELECT MIN("Dances") FROM table_28206 WHERE "Celebrity" = 'John Barnes'
### Instruction: CREATE TABLE table_17903 ( "Unit" text, "Type" text, "Net power" text, "Total power" text, "Construction start" text, "Construction finish" text, "Commercial operation" text, "Shut down" text ) -- Using valid SQLite, answer the following questions for the tables provid...
SELECT "Construction start" FROM table_17903 WHERE "Commercial operation" = '04.03.1987'
### Instruction: CREATE TABLE member_of_club ( clubid VARCHAR, stuid VARCHAR ) CREATE TABLE club ( clubid VARCHAR ) CREATE TABLE student ( stuid VARCHAR, fname VARCHAR, lname VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Find the number of...
SELECT COUNT(*) FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t3.fname = "Tracy" AND t3.lname = "Kim"
### Instruction: CREATE TABLE table_20475 ( "Headphone Model" text, "Headphone Class" text, "Driver-matched dB" text, "Construction" text, "Earpads" text, "Termination" text, "US MSRP" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- How many ...
SELECT COUNT("Earpads") FROM table_20475 WHERE "Headphone Class" = 'Prestige' AND "US MSRP" = '$79'
### Instruction: CREATE TABLE chip_model ( Model_name VARCHAR, Launch_year VARCHAR, RAM_MiB VARCHAR ) CREATE TABLE phone ( Hardware_Model_name VARCHAR, chip_model VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- List the name of the phone model la...
SELECT T2.Hardware_Model_name FROM chip_model AS T1 JOIN phone AS T2 ON T1.Model_name = T2.chip_model WHERE T1.Launch_year = 2002 ORDER BY T1.RAM_MiB DESC LIMIT 1
### Instruction: CREATE TABLE tweets ( id number, uid number, text text, createdate time ) CREATE TABLE follows ( f1 number, f2 number ) CREATE TABLE user_profiles ( uid number, name text, email text, partitionid number, followers number ) -- Using valid SQLite, answer th...
SELECT T1.name, COUNT(*) FROM user_profiles AS T1 JOIN tweets AS T2 ON T1.uid = T2.uid GROUP BY T2.uid
### Instruction: CREATE TABLE route ( station_id VARCHAR, train_id VARCHAR ) CREATE TABLE train ( name VARCHAR, time VARCHAR, id VARCHAR ) CREATE TABLE station ( id VARCHAR, local_authority VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. --...
SELECT t3.name, t3.time FROM station AS t1 JOIN route AS t2 ON t1.id = t2.station_id JOIN train AS t3 ON t2.train_id = t3.id WHERE t1.local_authority = "Chiltern"
### Instruction: CREATE TABLE table_26434 ( "No. by series" real, "No. by season" real, "Title" text, "Directed by" text, "Written by" text, "Original air date" text, "Production number" real, "U.S. viewers (in millions)" text ) -- Using valid SQLite, answer the following questions for...
SELECT MIN("No. by season") FROM table_26434 WHERE "U.S. viewers (in millions)" = '10.81'
### Instruction: CREATE TABLE table_dev_50 ( "id" int, "gender" string, "hemoglobin_a1c_hba1c" float, "diabetic" string, "estimated_glomerular_filtration_rate_egfr" int, "hba1c" float, "age" float, "NOUSE" float ) -- Using valid SQLite, answer the following questions for the tables pro...
SELECT * FROM table_dev_50 WHERE gender = 'female' AND (age > 55 AND age < 80)
### Instruction: CREATE TABLE table_204_577 ( id number, "name" text, "first operational" text, "numeral system" text, "computing mechanism" text, "programming" text, "turing complete" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- what name...
SELECT "name" FROM table_204_577 WHERE "first operational" < (SELECT "first operational" FROM table_204_577 WHERE "first operational" = 'may 1944') ORDER BY "first operational" DESC LIMIT 1
### Instruction: CREATE TABLE table_22455 ( "Township" text, "County" text, "Pop. (2010)" real, "Land ( sqmi )" text, "Water (sqmi)" text, "Latitude" text, "Longitude" text, "GEO ID" real, "ANSI code" real ) -- Using valid SQLite, answer the following questions for the tables provi...
SELECT "Township" FROM table_22455 WHERE "Land ( sqmi )" = '35.766'
### Instruction: CREATE TABLE table_15167 ( "Representative" text, "Title" text, "Presentation of Credentials" text, "Termination of Mission" text, "Appointed by" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the Termination of Mission with...
SELECT "Termination of Mission" FROM table_15167 WHERE "Title" = 'ambassador extraordinary and plenipotentiary' AND "Representative" = 'reynold e. carlson'
### Instruction: CREATE TABLE table_train_155 ( "id" int, "cholesterol" float, "bleeding" int, "systolic_blood_pressure_sbp" int, "diabetic" string, "hyperlipidemia" bool, "creatinine_clearance_cl" float, "platelet_count" float, "hypertension" bool, "NOUSE" float ) -- Using val...
SELECT * FROM table_train_155 WHERE diabetic = 'ii'
### Instruction: CREATE TABLE PersonFriend ( name varchar(20), friend varchar(20), year INTEGER ) CREATE TABLE Person ( name varchar(20), age INTEGER, city TEXT, gender TEXT, job TEXT ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Who has fr...
SELECT T1.name, T1.age FROM Person AS T1 JOIN PersonFriend AS T2 ON T1.name = T2.friend WHERE T1.age > (SELECT AVG(age) FROM Person)
### Instruction: CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255), Price DECIMAL, Manufacturer INTEGER ) CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255), Headquarter VARCHAR(255), Founder VARCHAR(255), Revenue REAL ) -- Using valid SQLite, answer the following ...
SELECT Name, COUNT(Name) FROM Products GROUP BY Name ORDER BY COUNT(Name)
### Instruction: CREATE TABLE table_24006 ( "Round" real, "Date" text, "Grand Prix" text, "Circuit" text, "MotoGP winner" text, "Moto2 winner" text, "125cc winner" text, "Report" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- How many 12...
SELECT COUNT("125cc winner") FROM table_24006 WHERE "Moto2 winner" = 'Shoya Tomizawa'
### Instruction: CREATE TABLE table_19184 ( "Cast" text, "1951 ( BBC )" text, "1957 (BBC)" text, "1968 (BBC)" text, "1970 (film)" text, "2000 ( Carlton Television )" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Name the 1968 bbc for 1957 bbc a...
SELECT "1968 (BBC)" FROM table_19184 WHERE "1957 (BBC)" = 'Anneke Wills'
### Instruction: CREATE TABLE table_name_39 ( density__inhabitants_km_2__ INTEGER, city VARCHAR, area__km_2__ VARCHAR, altitude__mslm_ VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the lowest density of alessandria where the area is bigger t...
SELECT MIN(density__inhabitants_km_2__) FROM table_name_39 WHERE area__km_2__ > 16.02 AND altitude__mslm_ < 116 AND city = "alessandria"
### Instruction: CREATE TABLE table_42059 ( "8:00" text, "8:30" text, "9:00" text, "9:30" text, "10:00" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What played at 8:00 when Grey's Anatomy played at 9:00 and Ugly Betty played at 8:30? ### Respon...
SELECT "8:00" FROM table_42059 WHERE "9:00" = 'grey''s anatomy' AND "8:30" = 'ugly betty'
### Instruction: CREATE TABLE table_26040 ( "No. in series" real, "No. in season" real, "Title" text, "Directed by" text, "Written by" text, "Original air date" text, "Prod. code" text, "U.S. Viewers (in millions)" text ) -- Using valid SQLite, answer the following questions for the ta...
SELECT "U.S. Viewers (in millions)" FROM table_26040 WHERE "Title" = 'Ball of Trash'
### Instruction: CREATE TABLE table_63278 ( "Part Number" text, "Pins" text, "Body Width/mm" real, "Body Length/mm" real, "Lead Pitch/mm" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- How much Body Width/mm has a Part Number of tsop40/44, and a Bod...
SELECT SUM("Body Width/mm") FROM table_63278 WHERE "Part Number" = 'tsop40/44' AND "Body Length/mm" < '18.42'
### Instruction: CREATE TABLE table_76562 ( "Date" text, "Opponent" text, "Venue" text, "Result" text, "Attendance" text, "Competition" text, "Man of the Match" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- On what date was the venue Away a...
SELECT "Date" FROM table_76562 WHERE "Venue" = 'away' AND "Result" = 'lost 6-4 (lost 9-7 on agg)'
### Instruction: CREATE TABLE table_17814 ( "Club" text, "Played" text, "Won" text, "Drawn" text, "Lost" text, "Points for" text, "Points against" text, "Tries for" text, "Tries against" text, "Try bonus" text, "Losing bonus" text, "Points" text ) -- Using valid SQLite,...
SELECT "Played" FROM table_17814 WHERE "Points" = '80'
### Instruction: CREATE TABLE table_36445 ( "Year" text, "Flagship Station" text, "Play-by-play" text, "Color commentator(s)" text, "Studio host" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Name the studio host for glenn ordway and jerry sichting...
SELECT "Studio host" FROM table_36445 WHERE "Play-by-play" = 'glenn ordway' AND "Color commentator(s)" = 'jerry sichting' AND "Year" = '1993-94'
### Instruction: CREATE TABLE table_1733 ( "N" real, "P" text, "Name" text, "EU" text, "Country" text, "Age" real, "Type" text, "Moving from" text, "Transfer window" text, "Ends" text, "Transfer fee" text, "Source" text ) -- Using valid SQLite, answer the following ques...
SELECT "Ends" FROM table_1733 WHERE "Moving from" = 'Cary Clarets'
### Instruction: CREATE TABLE table_970 ( "Season" text, "Oberliga Bayern" text, "Oberliga Hessen" text, "Oberliga Baden-W\u00fcrttemberg" text, "Oberliga S\u00fcdwest" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Name the oberliga bayern for sv s...
SELECT "Oberliga Bayern" FROM table_970 WHERE "Oberliga Baden-W\u00fcrttemberg" = 'SV Sandhausen' AND "Season" = '1986-87'
### Instruction: CREATE TABLE table_22026 ( "Club" text, "Played" text, "Won" text, "Drawn" text, "Lost" text, "Points for" text, "Points against" text, "Tries for" text, "Tries against" text, "Try bonus" text, "Losing bonus" text, "Points" text ) -- Using valid SQLite,...
SELECT "Points" FROM table_22026 WHERE "Tries for" = '49'
### Instruction: CREATE TABLE table_5801 ( "Player" text, "Rec." real, "Yards" real, "Avg." real, "Long" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Which Yards has an Avg larger than 7, and a Long smaller than 60, and a Rec larger than 19, and a...
SELECT AVG("Yards") FROM table_5801 WHERE "Avg." > '7' AND "Long" < '60' AND "Rec." > '19' AND "Player" = 'correll buckhalter'
### Instruction: CREATE TABLE table_18247 ( "District" text, "Incumbent" text, "Party" text, "First elected" real, "Result" text, "Candidates" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What was the results for the candidates listed as bart ...
SELECT "Result" FROM table_18247 WHERE "Candidates" = 'Bart Gordon (D) 76.5% Wallace Embry (R) 23.5%'
### Instruction: CREATE TABLE table_73713 ( "Name" text, "Municipal district" text, "Population (2011)" real, "Population (2006)" real, "Change (%)" text, "Land area (km\u00b2)" text, "Population density (per km 2 )" text ) -- Using valid SQLite, answer the following questions for the tabl...
SELECT "Population density (per km 2 )" FROM table_73713 WHERE "Municipal district" = 'Smoky Lake County'
### Instruction: CREATE TABLE table_59781 ( "Team" text, "Outgoing manager" text, "Manner of departure" text, "Date of vacancy" text, "Replaced by" text, "Date of appointment" text, "Position in table" text ) -- Using valid SQLite, answer the following questions for the tables provided abo...
SELECT "Team" FROM table_59781 WHERE "Position in table" = 'pre-season' AND "Manner of departure" = 'end of tenure as caretaker'
### Instruction: CREATE TABLE table_204_84 ( id number, "no" number, "peak" text, "location" text, "elevation (m)" number, "prominence (m)" number, "col height (m)" number, "col location" text, "parent" text ) -- Using valid SQLite, answer the following questions for the tables pro...
SELECT "peak" FROM table_204_84 WHERE "peak" IN ('mont blanc', 'monte rosa') ORDER BY "elevation (m)" DESC LIMIT 1
### Instruction: CREATE TABLE table_204_954 ( id number, "no." number, "country" text, "2009 winter\nuniversiade" number, "2007 wjcc" number, "2007 wwcc" number, "2008 wjcc" number, "2008 wwcc" number, "points" number ) -- Using valid SQLite, answer the following questions for the ...
SELECT AVG("points") FROM table_204_954 WHERE "no." <= 5
### Instruction: CREATE TABLE table_203_865 ( id number, "place" number, "athlete" text, "nation" text, "best mark" text, "throw 1" number, "throw 2" number, "throw 3" number, "throw 4" number, "throw 5" number, "throw 6" number ) -- Using valid SQLite, answer the following...
SELECT "athlete" FROM table_203_865 WHERE "best mark" > 18
### Instruction: CREATE TABLE table_68185 ( "Season" real, "Overall" text, "Slalom" text, "Giant Slalom" text, "Super G" text, "Downhill" text, "Combined" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What super g was before 1998, had 2 gia...
SELECT "Super G" FROM table_68185 WHERE "Season" < '1998' AND "Giant Slalom" = '2' AND "Downhill" = '24'
### Instruction: CREATE TABLE table_73413 ( "Season no." real, "Series no." real, "Title" text, "Directed by" text, "Written by" text, "Original air date" text, "Production code" real, "U.S. Viewers (millions)" text ) -- Using valid SQLite, answer the following questions for the tables...
SELECT MAX("Series no.") FROM table_73413 WHERE "U.S. Viewers (millions)" = '3.14'
### Instruction: CREATE TABLE table_204_32 ( id number, "season" number, "division" text, "w-l" text, "finish" text, "home" text, "road" text, "gf" number, "ga" number, "coach" text, "playoffs" text, "avg attendance" number ) -- Using valid SQLite, answer the following ...
SELECT "season" FROM table_204_32 ORDER BY "w-l" DESC LIMIT 1
### Instruction: CREATE TABLE tryout ( cName VARCHAR, pPos VARCHAR ) CREATE TABLE college ( state VARCHAR, cName VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- How many states that have some college students playing in the mid position but not in th...
SELECT COUNT(*) FROM (SELECT T1.state FROM college AS T1 JOIN tryout AS T2 ON T1.cName = T2.cName WHERE T2.pPos = 'mid' EXCEPT SELECT T1.state FROM college AS T1 JOIN tryout AS T2 ON T1.cName = T2.cName WHERE T2.pPos = 'goalie')
### Instruction: CREATE TABLE table_59346 ( "Club" text, "Played" text, "Drawn" text, "Lost" text, "Points for" text, "Points against" text, "Tries for" text, "Tries against" text, "Try bonus" text, "Losing bonus" text, "Points" text ) -- Using valid SQLite, answer the foll...
SELECT "Tries for" FROM table_59346 WHERE "Points for" = '190'
### Instruction: CREATE TABLE table_59576 ( "Name" text, "Father" text, "Birth" text, "Marriage" text, "Became Duchess" text, "Ceased to be Duchess" text, "Death" text, "Spouse" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- When did the...
SELECT "Ceased to be Duchess" FROM table_59576 WHERE "Marriage" = '22 may 1657'
### Instruction: CREATE TABLE table_27686 ( "Casinos" real, "County" text, "Road" text, "1-Jul-08" real, "FY07 $millions" text, "FY08 $millions" text, "FY09 $millions" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- How many casinos are assoc...
SELECT COUNT("Casinos") FROM table_27686 WHERE "FY09 $millions" = '$279'
### Instruction: CREATE TABLE table_6293 ( "County" text, "Area (acres)" text, "Area (km\u00b2)" real, "Population" real, "Population Density (per km 2 )" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the area (km ) of Nairnshire county, wh...
SELECT SUM("Area (km\u00b2)") FROM table_6293 WHERE "County" = 'nairnshire' AND "Population" < '11,050'
### Instruction: CREATE TABLE table_34320 ( "Date" text, "Episode" real, "Performer 1" text, "Performer 2" text, "Performer 3" text, "Performer 4" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the total number of episodes where jim swee...
SELECT COUNT("Episode") FROM table_34320 WHERE "Performer 1" = 'jim sweeney' AND "Performer 2" = 'steve steen'
### Instruction: CREATE TABLE Elimination ( Elimination_ID text, Wrestler_ID text, Team text, Eliminated_By text, Elimination_Move text, Time text ) CREATE TABLE wrestler ( Wrestler_ID int, Name text, Reign text, Days_held text, Location text, Event text ) -- Using val...
SELECT Location, COUNT(Location) FROM wrestler GROUP BY Location ORDER BY COUNT(Location)
### Instruction: CREATE TABLE table_79414 ( "Date" text, "Opponent" text, "Score" text, "Loss" text, "Attendance" real, "Series" text, "Arena" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Which Attendance has an Arena of arrowhead pond of ...
SELECT MAX("Attendance") FROM table_79414 WHERE "Arena" = 'arrowhead pond of anaheim' AND "Loss" = 'giguere (3–3)'
### Instruction: CREATE TABLE table_20436 ( "Result" text, "Date" text, "Race" text, "Venue" text, "Group" text, "Distance" text, "Weight (kg)" text, "Time" text, "Jockey" text, "Winner/2nd" text ) -- Using valid SQLite, answer the following questions for the tables provided ab...
SELECT "Winner/2nd" FROM table_20436 WHERE "Time" = '1:35.98'
### Instruction: CREATE TABLE table_21108 ( "Rank" real, "Company" text, "Headquarters" text, "Industry" text, "Sales (billion $)" text, "Profits (billion $)" text, "Assets (billion $)" text, "Market Value (billion $)" text ) -- Using valid SQLite, answer the following questions for th...
SELECT "Profits (billion $)" FROM table_21108 WHERE "Company" = 'Wells Fargo'
### Instruction: CREATE TABLE table_51964 ( "State" text, "Norwegian Americans (2000)" real, "Percent (2000)" text, "Norwegian Americans (2009)" real, "Percent (2009)" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- How many Norwegian Americans have ...
SELECT COUNT("Norwegian Americans (2009)") FROM table_51964 WHERE "Norwegian Americans (2000)" = '109,744'
### Instruction: CREATE TABLE school ( School_ID int, Grade text, School text, Location text, Type text ) CREATE TABLE school_bus ( School_ID int, Driver_ID int, Years_Working int, If_full_time bool ) CREATE TABLE driver ( Driver_ID int, Name text, Party text, Home_...
SELECT Home_city, COUNT(Home_city) FROM driver GROUP BY Home_city
### Instruction: CREATE TABLE table_204_634 ( id number, "tour" number, "official title" text, "venue" text, "city" text, "date\nstart" text, "date\nfinish" text, "prize money\nusd" number, "report" text ) -- Using valid SQLite, answer the following questions for the tables provide...
SELECT COUNT(*) FROM table_204_634 WHERE "prize money\nusd" >= 500000
### Instruction: CREATE TABLE table_27787 ( "Position" real, "Race number" text, "Sail number" text, "Yacht" text, "State/country" text, "Yacht type" text, "LOA (Metres)" text, "Skipper" text, "Elapsed time d:hh:mm:ss" text ) -- Using valid SQLite, answer the following questions fo...
SELECT "Skipper" FROM table_27787 WHERE "Sail number" = 'AUS60000'
### Instruction: CREATE TABLE table_29685 ( "No. in series" real, "No. in season" real, "Title" text, "Directed by" text, "Written by" text, "U.S. viewers (millions)" text, "Original U.S. air date" text, "Prod. code" text ) -- Using valid SQLite, answer the following questions for the ...
SELECT "Original U.S. air date" FROM table_29685 WHERE "Prod. code" = '415'
### Instruction: CREATE TABLE table_26747 ( "Position" text, "Name" text, "Nationality" text, "Event 1 Medley" text, "Event 2 Truck Pull" text, "Event 3 Dead Lift" text, "Event 4 Fingals Fingers" text, "Event 5 Keg Toss" text, "Event 6 Atlas Stones" text ) -- Using valid SQLite, an...
SELECT "Name" FROM table_26747 WHERE "Nationality" = 'United States'
### Instruction: CREATE TABLE table_45864 ( "Player" text, "Club" text, "Games" real, "Goals" real, "Assists" real, "Points" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the average Assists, when Club is Iserlohn Roosters,when Points i...
SELECT AVG("Assists") FROM table_45864 WHERE "Club" = 'iserlohn roosters' AND "Points" = '71' AND "Goals" > '44'
### Instruction: CREATE TABLE table_77606 ( "Season" text, "Competition" text, "Matches" real, "Draw" real, "Lost" real, "Points" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the total number of matches with a loss less than 5 in the 2...
SELECT COUNT("Matches") FROM table_77606 WHERE "Lost" < '5' AND "Season" = '2008/2009' AND "Draw" > '9'
### Instruction: CREATE TABLE table_24841 ( "Type" text, "Registration" text, "Design" text, "Construction" text, "Service" text, "Construction date" text, "Conformity to original design" text, "Interest" text, "Number existing in Switzerland" text, "Number existing worldwide" te...
SELECT "Registration" FROM table_24841 WHERE "Type" = 'T 6 G'