instruction stringlengths 212 6.3k | output stringlengths 6 2.03k |
|---|---|
### Instruction:
CREATE TABLE college (
cname text,
state text,
enr number
)
CREATE TABLE player (
pid number,
pname text,
ycard text,
hs number
)
CREATE TABLE tryout (
pid number,
cname text,
ppos text,
decision text
)
-- Using valid SQLite, answer the following question... | SELECT MIN(T2.hs), T1.ppos FROM tryout AS T1 JOIN player AS T2 ON T1.pid = T2.pid GROUP BY T1.ppos |
### 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 Sex, SUM(Weight) FROM people GROUP BY Sex |
### Instruction:
CREATE TABLE table_24217 (
"Department" text,
"Micro (10ha)" real,
"Small (100ha)" real,
"Medium (500ha)" real,
"Big (>500ha)" real,
"Total" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many Small catagories are there for ... | SELECT COUNT("Small (100ha)") FROM table_24217 WHERE "Medium (500ha)" = '17101' |
### Instruction:
CREATE TABLE host (
host_id number,
name text,
nationality text,
age text
)
CREATE TABLE party_host (
party_id number,
host_id number,
is_main_in_charge others
)
CREATE TABLE party (
party_id number,
party_theme text,
location text,
first_year text,
las... | SELECT location FROM party ORDER BY number_of_hosts DESC LIMIT 1 |
### Instruction:
CREATE TABLE table_204_284 (
id number,
"jurisdiction" text,
"adherents" number,
"bishops" number,
"priests" number,
"monastics" number,
"monasteries" number,
"parishes" number
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- t... | SELECT SUM("adherents") FROM table_204_284 WHERE "jurisdiction" IN ('romania', 'cyprus', 'greece') |
### Instruction:
CREATE TABLE table_46721 (
"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_46721 WHERE "Location Attendance" = 'american airlines center 20,223' |
### Instruction:
CREATE TABLE table_66225 (
"Game" real,
"Date" text,
"Opponent" text,
"Score" text,
"High points" text,
"High rebounds" text,
"High assists" text,
"Location" text,
"Record" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
... | SELECT "High rebounds" FROM table_66225 WHERE "Game" < '9' AND "Opponent" = 'detroit' |
### Instruction:
CREATE TABLE table_203_11 (
id number,
"title" text,
"year" number,
"peak chart positions\nus" number,
"peak chart positions\nus r&b" number,
"peak chart positions\nus rap" number,
"peak chart positions\nuk" number,
"certifications" text,
"album" text
)
-- Using va... | SELECT "title" FROM table_203_11 ORDER BY id DESC LIMIT 1 |
### Instruction:
CREATE TABLE table_21771 (
"District" real,
"Incumbent" text,
"2008 Status" text,
"Democratic" text,
"Republican" text,
"Independent Green" text,
"Libertarian" text,
"Other Party" text
)
-- Using valid SQLite, answer the following questions for the tables provided abov... | SELECT "2008 Status" FROM table_21771 WHERE "Democratic" = 'Glenn Nye' |
### Instruction:
CREATE TABLE table_61008 (
"2006" real,
"2007" real,
"2008" real,
"2009" real,
"2010" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many 2010s have a 2007 greater than 4.6, and 8.2 as a 2006?
### Response:
| SELECT COUNT("2010") FROM table_61008 WHERE "2007" > '4.6' AND "2006" = '8.2' |
### Instruction:
CREATE TABLE table_203_452 (
id number,
"pos" number,
"no" number,
"driver" text,
"team" text,
"laps" number,
"time/retired" text,
"grid" number,
"points" number
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what driver ... | SELECT "driver" FROM table_203_452 WHERE "pos" = (SELECT "pos" FROM table_203_452 WHERE "driver" = 'tristan gommendy') - 1 |
### Instruction:
CREATE TABLE table_74032 (
"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 "Original air date" FROM table_74032 WHERE "Production code" = '5AKY13' |
### Instruction:
CREATE TABLE table_53531 (
"Series #" real,
"Season #" real,
"Title" text,
"Directed by" text,
"Original air date" text,
"Production code" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the air date for the seasons before 1... | SELECT "Original air date" FROM table_53531 WHERE "Season #" < '14' AND "Production code" > '709' AND "Series #" < '183' |
### Instruction:
CREATE TABLE table_203_320 (
id number,
"rank in\n2011" number,
"name of\nconcern" text,
"location of\nheadquarters" text,
"revenue\n(thou.\npln)" number,
"profit\n(thou.\npln)" number,
"employees" number
)
-- Using valid SQLite, answer the following questions for the tabl... | SELECT "name of\nconcern" FROM table_203_320 ORDER BY "employees" DESC LIMIT 1 |
### Instruction:
CREATE TABLE table_66679 (
"Date(s) Released" text,
"Polling institute" text,
"Nationalist" text,
"Labour" text,
"Democratic Alternative" text,
"Undecided/ No answer" text,
"Lead" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
... | SELECT "Nationalist" FROM table_66679 WHERE "Undecided/ No answer" = '29.2%' |
### Instruction:
CREATE TABLE table_204_47 (
id number,
"outcome" text,
"no." number,
"date" text,
"tournament" text,
"surface" text,
"partner" text,
"opponents" text,
"score" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- was there ... | SELECT (SELECT COUNT(*) FROM table_204_47 WHERE "surface" = 'clay') > (SELECT COUNT(*) FROM table_204_47 WHERE "surface" = 'hard') |
### Instruction:
CREATE TABLE table_45391 (
"Year" real,
"Champion" text,
"Runner-Up" text,
"Result" text,
"Date" text,
"Venue" text,
"Attendance" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the sum of the years where the attendan... | SELECT SUM("Year") FROM table_45391 WHERE "Attendance" = '95,000' AND "Runner-Up" = 'dresdner sc' |
### Instruction:
CREATE TABLE table_42739 (
"Season" text,
"Ep #" real,
"Season Premiere" text,
"Season Finale" text,
"Ranking" text,
"Viewers (Households in millions)" text,
"Rating" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many m... | SELECT "Viewers (Households in millions)" FROM table_42739 WHERE "Season Finale" = 'march 12, 1979' |
### Instruction:
CREATE TABLE table_60511 (
"Year" real,
"Song" text,
"U.S. Hot 100" text,
"U.S. R&B" text,
"U.S. Hot Adult Cont." text,
"Album" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which song has a U.S. R&B 100 in 2010?
### Response... | SELECT "Song" FROM table_60511 WHERE "Year" = '2010' AND "U.S. R&B" = '100' |
### Instruction:
CREATE TABLE table_70628 (
"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_70628 WHERE "Tries for" = '34' |
### Instruction:
CREATE TABLE table_204_461 (
id number,
"res." text,
"record" text,
"opponent" text,
"method" text,
"event" text,
"date" text,
"round" number,
"time" text,
"location" text,
"notes" text
)
-- Using valid SQLite, answer the following questions for the tables ... | SELECT "round" FROM table_204_461 WHERE "opponent" = 'ovince st. preux' |
### Instruction:
CREATE TABLE table_8549 (
"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 follo... | SELECT "Tries against" FROM table_8549 WHERE "Points for" = '564' |
### Instruction:
CREATE TABLE table_name_71 (
number__map_ INTEGER,
area_in_km² VARCHAR,
population_canada_2011_census VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Number (map) is the lowest one that has a Area in km of 9.7, and a Population Cana... | SELECT MIN(number__map_) FROM table_name_71 WHERE area_in_km² = 9.7 AND population_canada_2011_census > 66 OFFSET 158 |
### Instruction:
CREATE TABLE table_40256 (
"Rider" text,
"Manufacturer" text,
"Laps" real,
"Time/Retired" text,
"Grid" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the average number of laps completed by KTM riders, with times of +56.440... | SELECT AVG("Laps") FROM table_40256 WHERE "Manufacturer" = 'ktm' AND "Time/Retired" = '+56.440' AND "Grid" < '11' |
### Instruction:
CREATE TABLE table_203_173 (
id number,
"year(s)" text,
"serial name" text,
"role" text,
"co-star" text,
"note(s)" text,
"channel" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- did he act longer on sinndoor tere naam ka or ... | SELECT "serial name" FROM table_203_173 WHERE "serial name" IN ('sinndoor tere naam ka', 'saat phere') ORDER BY "year(s)" - "year(s)" DESC LIMIT 1 |
### Instruction:
CREATE TABLE table_28601467_1 (
final_venue VARCHAR,
winner VARCHAR,
host_nation_s_ VARCHAR,
runner_up VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the final venue whene England hasted the competition and the runner-up rec... | SELECT final_venue FROM table_28601467_1 WHERE host_nation_s_ = "England" AND runner_up = "[[|]] 4 points" AND winner = "[[|]] 6 points" |
### Instruction:
CREATE TABLE table_name_80 (
year INTEGER,
billboard_200_peak VARCHAR,
riaa_sales_certification VARCHAR,
title VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- For how many years did the song 'Lost Without Your Love' win the gold RIAA ... | SELECT SUM(year) FROM table_name_80 WHERE riaa_sales_certification = "gold" AND title = "lost without your love" AND billboard_200_peak > 26 |
### Instruction:
CREATE TABLE table_6296 (
"Season" text,
"Tropical Lows" real,
"Tropical Cyclones" real,
"Severe Tropical Cyclones" real,
"Strongest storm" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the highest number of severe tropical... | SELECT MAX("Severe Tropical Cyclones") FROM table_6296 WHERE "Tropical Cyclones" = '10' AND "Tropical Lows" = '14' |
### Instruction:
CREATE TABLE table_name_87 (
us_krag_jørgensen_m1892 VARCHAR,
norwegian_krag_jørgensen_m1894 VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the US Krag-J rgensen M1892 when the Norwegian Krag-J rgensen M1894 is 126.8cm?
### Respons... | SELECT us_krag_jørgensen_m1892 FROM table_name_87 WHERE norwegian_krag_jørgensen_m1894 = "126.8cm" |
### Instruction:
CREATE TABLE table_20444 (
"Party" text,
"Marplan" text,
"Gallup" text,
"National Opinion Polls (NOP)" text,
"Opinion Research Centre (OPC)" text,
"Harris" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- On all other parties the ... | SELECT "Opinion Research Centre (OPC)" FROM table_20444 WHERE "National Opinion Polls (NOP)" = '1.3%' |
### Instruction:
CREATE TABLE table_22078 (
"Position" real,
"Club" text,
"Games played" real,
"Wins" real,
"Draws" real,
"Loses" real,
"Goals scored" real,
"Goals conceded" real,
"Points" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
... | SELECT MAX("Loses") FROM table_22078 WHERE "Club" = 'Ekranas-2 Panevėžys' |
### Instruction:
CREATE TABLE table_75993 (
"Source" text,
"Date" text,
"Goberman" text,
"Loera" text,
"Merkley" text,
"Neville" text,
"Novick" text,
"Obrist" text,
"Other/ Undecided" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Wh... | SELECT "Novick" FROM table_75993 WHERE "Source" = 'surveyusa' AND "Neville" = '8%' |
### Instruction:
CREATE TABLE table_64019 (
"Position" real,
"Sail Number" text,
"Yacht" text,
"State/Country" text,
"Yacht Type" text,
"LOA (Metres)" real,
"Skipper" text,
"Corrected Time d:hh:mm:ss" text
)
-- Using valid SQLite, answer the following questions for the tables provided ... | SELECT "Yacht Type" FROM table_64019 WHERE "LOA (Metres)" = '15.15' |
### Instruction:
CREATE TABLE table_39812 (
"Year" real,
"Mission type" text,
"Shogun" text,
"Ry\u016bky\u016ban King" text,
"Lead Envoy" text,
"Number in entourage" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the latest year of a gra... | SELECT MAX("Year") FROM table_39812 WHERE "Number in entourage" = '99' AND "Mission type" = 'gratitude' |
### Instruction:
CREATE TABLE table_41467 (
"Club" text,
"2012" text,
"Seasons in Esiliiga" real,
"Current run since" real,
"Titles" real,
"Last title" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the highest run currently since the la... | SELECT MAX("Current run since") FROM table_41467 WHERE "Last title" = '2010' AND "Seasons in Esiliiga" > '10' |
### Instruction:
CREATE TABLE table_58438 (
"CDP name" text,
"County" text,
"Pop. (2010)" real,
"Land ( sq mi )" real,
"Water (sq mi)" real,
"Coordinates" text,
"FIPS code" real,
"ANSI code" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
--... | SELECT "CDP name" FROM table_58438 WHERE "FIPS code" = '3659708' |
### Instruction:
CREATE TABLE table_24620684_2 (
operating_mode VARCHAR,
epa_rated_combined_fuel_economy VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- When 87 mpg-e (39kw-hrs/100mi) is the epa rated combined fuel economy how many operating modes are there?
... | SELECT COUNT(operating_mode) FROM table_24620684_2 WHERE epa_rated_combined_fuel_economy = "87 mpg-e (39kW-hrs/100mi)" |
### Instruction:
CREATE TABLE table_15556 (
"Year" real,
"Award" text,
"Category" text,
"Recipient(s)" text,
"Result" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What category was Joe Jonas nominated for at the Kids' Choice Awards Mexico in 2010?... | SELECT "Category" FROM table_15556 WHERE "Result" = 'nominated' AND "Year" = '2010' AND "Award" = 'kids'' choice awards mexico' AND "Recipient(s)" = 'joe jonas' |
### Instruction:
CREATE TABLE table_68967 (
"Event" text,
"Date" text,
"DP / DA" real,
"NP / NNP" text,
"COPE" text,
"ACDP" real,
"Others" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the NP/NNP for ACDP of 1 and others of 1 and DP/DA... | SELECT "NP / NNP" FROM table_68967 WHERE "ACDP" = '1' AND "Others" = '1' AND "DP / DA" = '5' |
### Instruction:
CREATE TABLE actor (
Actor_ID int,
Name text,
Musical_ID int,
Character text,
Duration text,
age int
)
CREATE TABLE musical (
Musical_ID int,
Name text,
Year int,
Award text,
Category text,
Nominee text,
Result text
)
-- Using valid SQLite, answer ... | SELECT Nominee, COUNT(*) FROM musical GROUP BY Nominee ORDER BY Nominee |
### Instruction:
CREATE TABLE table_19232 (
"Team" text,
"Intercontinental" text,
"Recopa 1996" text,
"Supercopa 1996" text,
"CONMEBOL 1996" text,
"Copa Libertadores 1997" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what is the number of team... | SELECT COUNT("Team") FROM table_19232 WHERE "CONMEBOL 1996" = 'did not qualify' |
### Instruction:
CREATE TABLE table_name_28 (
polyunsaturated_fat VARCHAR,
monounsaturated_fat VARCHAR,
smoke_point VARCHAR,
total_fat VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the polyunsaturated fat with a smoke point of c (), a total ... | SELECT polyunsaturated_fat FROM table_name_28 WHERE smoke_point = "°c ()" AND total_fat = "100g" AND monounsaturated_fat = "63g" |
### Instruction:
CREATE TABLE table_61296 (
"Name" text,
"Location" text,
"Enrollment" real,
"1-year ranking of 727" real,
"5-year ranking of 693" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many enrollments have a location of Guelph and a 1-... | SELECT COUNT("Enrollment") FROM table_61296 WHERE "Location" = 'guelph' AND "1-year ranking of 727" > '717' |
### Instruction:
CREATE TABLE table_72900 (
"Position" real,
"Team" text,
"Played" real,
"Won" real,
"Drawn" real,
"Lost" real,
"Goals For" real,
"Goals Against" real,
"Goal Average 1" text,
"Points 2" real
)
-- Using valid SQLite, answer the following questions for the tables ... | SELECT "Team" FROM table_72900 WHERE "Goal Average 1" = '1.34' |
### Instruction:
CREATE TABLE Research_Staff (
employer_organisation_id VARCHAR
)
CREATE TABLE Organisations (
organisation_id VARCHAR,
organisation_type VARCHAR,
organisation_details VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which organisation... | SELECT T1.organisation_id, T1.organisation_type, T1.organisation_details FROM Organisations AS T1 JOIN Research_Staff AS T2 ON T1.organisation_id = T2.employer_organisation_id GROUP BY T1.organisation_id ORDER BY COUNT(*) DESC LIMIT 1 |
### Instruction:
CREATE TABLE table_train_197 (
"id" int,
"dyscrasia" bool,
"gender" string,
"bleeding" int,
"hemoglobin_a1c_hba1c" float,
"diabetic" string,
"body_mass_index_bmi" float,
"age" float,
"NOUSE" float
)
-- Using valid SQLite, answer the following questions for the tabl... | SELECT * FROM table_train_197 WHERE bleeding = 1 OR dyscrasia = 1 |
### Instruction:
CREATE TABLE table_20069 (
"Name" text,
"Year" real,
"Landfall" text,
"NHC Advisory Number" text,
"V(mph)" real,
"R(miles)" real,
"Saffir-Simpson Category" real,
"CHI" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What ... | SELECT "R(miles)" FROM table_20069 WHERE "CHI" = '9.9' |
### Instruction:
CREATE TABLE table_56507 (
"Position" real,
"Club" text,
"Played" real,
"Points" real,
"Wins" real,
"Draws" real,
"Losses" real,
"Goals for" real,
"Goals against" real,
"Goal Difference" real
)
-- Using valid SQLite, answer the following questions for the table... | SELECT AVG("Points") FROM table_56507 WHERE "Played" > '42' |
### Instruction:
CREATE TABLE table_61838 (
"Air Date" text,
"Rating" text,
"18-49" text,
"Viewers" text,
"Weekly Winner" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is Viewers, when 18-49 is 'N/A', and when Weekly Winner is 'Wedding DJ Chri... | SELECT "Viewers" FROM table_61838 WHERE "18-49" = 'n/a' AND "Weekly Winner" = 'wedding dj chris dixon' |
### Instruction:
CREATE TABLE ship (
Ship_ID int,
Name text,
Type text,
Nationality text,
Tonnage int
)
CREATE TABLE mission (
Mission_ID int,
Ship_ID int,
Code text,
Launched_Year int,
Location text,
Speed_knots int,
Fate text
)
-- Using valid SQLite, answer the follo... | SELECT Type, COUNT(Type) FROM ship GROUP BY Nationality, Type ORDER BY Type |
### Instruction:
CREATE TABLE events (
event_id number,
service_id number,
event_details text
)
CREATE TABLE participants_in_events (
event_id number,
participant_id number
)
CREATE TABLE services (
service_id number,
service_type_code text
)
CREATE TABLE participants (
participant_id... | SELECT COUNT(*) FROM participants WHERE participant_type_code = 'Organizer' |
### Instruction:
CREATE TABLE table_203_76 (
id number,
"pos" text,
"no" number,
"driver" text,
"constructor" text,
"laps" number,
"time/retired" text,
"grid" number,
"points" number
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- which dr... | SELECT "driver" FROM table_203_76 WHERE "pos" = (SELECT "pos" FROM table_203_76 WHERE "driver" = 'giancarlo fisichella') + 1 |
### Instruction:
CREATE TABLE mission (
Mission_ID int,
Ship_ID int,
Code text,
Launched_Year int,
Location text,
Speed_knots int,
Fate text
)
CREATE TABLE ship (
Ship_ID int,
Name text,
Type text,
Nationality text,
Tonnage int
)
-- Using valid SQLite, answer the follo... | SELECT Type, COUNT(Type) FROM ship GROUP BY Type ORDER BY COUNT(Type) DESC |
### Instruction:
CREATE TABLE table_203_513 (
id number,
"no." number,
"date" text,
"home team" text,
"visiting team" text,
"goals" text,
"score" text,
"result" text,
"venue" text,
"competition" text
)
-- Using valid SQLite, answer the following questions for the tables provide... | SELECT COUNT(DISTINCT "date") FROM table_203_513 WHERE "venue" = 'helsinki olympic stadium' |
### Instruction:
CREATE TABLE table_59337 (
"White" text,
"Black" text,
"Year" real,
"Result" text,
"Moves" real,
"Tournament" text,
"Opening" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is Tournament, when Black is 'Kramnik', when R... | SELECT "Tournament" FROM table_59337 WHERE "Black" = 'kramnik' AND "Result" = '½–½' AND "Moves" = '40' |
### Instruction:
CREATE TABLE table_60804 (
"Episode" text,
"1 season" text,
"2 season" text,
"3 season" text,
"4 season" text,
"5 season" text,
"6 season" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is 3 Season, when 4 Season is '2 ... | SELECT "3 season" FROM table_60804 WHERE "4 season" = '2 628 383 (3 june 2009)' |
### Instruction:
CREATE TABLE table_43123 (
"Livery" text,
"Locomotive type" text,
"Wheel Arrangement" text,
"Builder" text,
"Year built" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the livery of the steam locomotive built after 1950 with... | SELECT "Livery" FROM table_43123 WHERE "Locomotive type" = 'steam' AND "Year built" > '1950' AND "Wheel Arrangement" = '2-6-2' |
### Instruction:
CREATE TABLE table_203_743 (
id number,
"version" text,
"date" text,
"development cycle" text,
"size (in kb)" number,
"download" text,
"notes" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- which versions of cello have the s... | SELECT "version" FROM table_203_743 WHERE "version" <> '0.1' AND "development cycle" = (SELECT "development cycle" FROM table_203_743 WHERE "version" = '0.1') |
### Instruction:
CREATE TABLE table_203_166 (
id number,
"pos" text,
"no" number,
"rider" text,
"manufacturer" text,
"laps" number,
"time" text,
"grid" number,
"points" number
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- who came in imm... | SELECT "rider" FROM table_203_166 WHERE "pos" = (SELECT "pos" FROM table_203_166 WHERE "rider" = 'nicky hayden') + 1 |
### Instruction:
CREATE TABLE table_52191 (
"Home team" text,
"Home team score" text,
"Away team" text,
"Away team score" text,
"Venue" text,
"Crowd" real,
"Date" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who was the home team at Prince... | SELECT "Home team" FROM table_52191 WHERE "Crowd" > '30,848' AND "Venue" = 'princes park' |
### Instruction:
CREATE TABLE reviewer (
rid number,
name text
)
CREATE TABLE rating (
rid number,
mid number,
stars number,
ratingdate time
)
CREATE TABLE movie (
mid number,
title text,
year number,
director text
)
-- Using valid SQLite, answer the following questions for t... | SELECT T1.title, T1.year FROM movie AS T1 JOIN movie AS T2 ON T1.director = T2.director WHERE T1.title <> T2.title |
### Instruction:
CREATE TABLE table_71806 (
"Outcome" text,
"Date" text,
"Tournament" text,
"Surface" text,
"Partner" text,
"Opponents in the final" text,
"Score" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the outcome of the mat... | SELECT "Outcome" FROM table_71806 WHERE "Opponents in the final" = 'marius călugăru ciprian petre porumb' |
### Instruction:
CREATE TABLE table_204_624 (
id number,
"school" text,
"team name" text,
"town" text,
"county" text,
"enrollment (2010-11 & 2011-12)" number,
"primary mshsaa class*" number,
"football class" number
)
-- Using valid SQLite, answer the following questions for the tables ... | SELECT "football class" FROM table_204_624 WHERE "school" = 'lafayette high school' |
### Instruction:
CREATE TABLE table_61957 (
"President" text,
"Treasurer" text,
"Secretary" text,
"Social AO" text,
"Academic AO" text,
"Internal CO" text,
"External CO" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What Social AO has an Ex... | SELECT "Social AO" FROM table_61957 WHERE "External CO" = 'elena buscher' AND "President" = 'harm van leeuwen' |
### Instruction:
CREATE TABLE table_204_183 (
id number,
"rank" number,
"nation" text,
"gold" number,
"silver" number,
"bronze" number,
"total" number
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- which country/countries has the same number of t... | SELECT "nation" FROM table_204_183 WHERE "nation" <> 'thailand' AND "total" = (SELECT "total" FROM table_204_183 WHERE "nation" = 'thailand') |
### Instruction:
CREATE TABLE table_37292 (
"7:00" text,
"7:30" text,
"8:00" text,
"8:30" text,
"9:00" text,
"10:00" text,
"10:30" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which 8:00 has a 10:00 of movies & specials?
### Response:
| SELECT "8:00" FROM table_37292 WHERE "10:00" = 'movies & specials' |
### Instruction:
CREATE TABLE table_203_89 (
id number,
"#" number,
"name\n(birth-death)" text,
"took office" text,
"left office" text,
"monarch" text,
"prime minister" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- how old was gideon brand ... | SELECT "took office" - "name\n(birth-death)" FROM table_203_89 WHERE "name\n(birth-death)" = 'gideon brand van zyl' |
### Instruction:
CREATE TABLE table_79103 (
"Year" real,
"Theme" text,
"Face Value" text,
"Weight" text,
"Diameter" text,
"Mintage" real,
"Issue Price" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the Mintage of the 12.61 g Weight ... | SELECT COUNT("Mintage") FROM table_79103 WHERE "Weight" = '12.61 g' AND "Theme" = 'ruby-throated hummingbird' |
### Instruction:
CREATE TABLE table_76358 (
"Poll Source" text,
"Dates administered" text,
"Democrat: John Kerry" text,
"Republican: Jeff Beatty" text,
"Lead Margin" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What percent is the lead margin of 2... | SELECT "Republican: Jeff Beatty" FROM table_76358 WHERE "Lead Margin" = '25' AND "Poll Source" = 'rasmussen reports' |
### Instruction:
CREATE TABLE movie (
mid number,
title text,
year number,
director text
)
CREATE TABLE reviewer (
rid number,
name text
)
CREATE TABLE rating (
rid number,
mid number,
stars number,
ratingdate time
)
-- Using valid SQLite, answer the following questions for t... | SELECT DISTINCT year FROM movie AS T1 JOIN rating AS T2 ON T1.mid = T2.mid WHERE T2.stars >= 4 ORDER BY T1.year |
### Instruction:
CREATE TABLE table_31318 (
"Year" text,
"Conductor" text,
"Opera House or Orchestra" text,
"Label" text,
"Countess" text,
"Count" text,
"Flamand" text,
"Olivier" text,
"La Roche" text,
"Clairon" text
)
-- Using valid SQLite, answer the following questions for t... | SELECT "Conductor" FROM table_31318 WHERE "Count" = 'Hermann Uhde' |
### Instruction:
CREATE TABLE table_203_56 (
id number,
"star" text,
"start\nyear" number,
"end\nyear" number,
"maximum\nyear" number,
"maximum\nmagnitude" number,
"distance at\nmaximum (ly)" number,
"current\ndistance" number,
"current\nmagnitude" number
)
-- Using valid SQLite, a... | SELECT COUNT("star") FROM table_203_56 WHERE "current\nmagnitude" > 0 |
### Instruction:
CREATE TABLE table_19415 (
"Name (Alma Mater)" text,
"Seasons" text,
"Games" real,
"Wins" real,
"Losses" real,
"Win %" text,
"NCAA Tour" text,
"NIT Tour" text,
"MCC Tour" text,
"A-10 Tour" text
)
-- Using valid SQLite, answer the following questions for the tab... | SELECT "Name (Alma Mater)" FROM table_19415 WHERE "Wins" = '15' |
### Instruction:
CREATE TABLE table_204_374 (
id number,
"event" text,
"gold" number,
"silver" number,
"bronze" number,
"total" number,
"ranking" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- the 1984 paralympics had a total ranking of 5th ... | SELECT "event" FROM table_204_374 WHERE "event" <> '1984 winter paralympics' AND "ranking" < 6 |
### Instruction:
CREATE TABLE table_20856 (
"Year" real,
"Date" text,
"Driver" text,
"Team" text,
"Manufacturer" text,
"Laps" text,
"Miles (km)" text,
"Race time" text,
"Average speed (mph)" text,
"Report" text
)
-- Using valid SQLite, answer the following questions for the tab... | SELECT "Driver" FROM table_20856 WHERE "Race time" = '2:34:21' |
### Instruction:
CREATE TABLE journalist (
journalist_ID int,
Name text,
Nationality text,
Age text,
Years_working int
)
CREATE TABLE event (
Event_ID int,
Date text,
Venue text,
Name text,
Event_Attendance int
)
CREATE TABLE news_report (
journalist_ID int,
Event_ID in... | SELECT Nationality, COUNT(*) FROM journalist GROUP BY Nationality |
### Instruction:
CREATE TABLE table_76098 (
"Week of" text,
"Tier" text,
"Winner" text,
"Runner-up" text,
"Semi finalists" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- In which week is the winner listed as Jana Novotn Arantxa S nchez Vicario 5 7, ... | SELECT "Week of" FROM table_76098 WHERE "Winner" = 'jana novotná arantxa sánchez vicario 5–7, 7–5, 6–4' |
### Instruction:
CREATE TABLE table_61554 (
"Place" text,
"Player" text,
"Country" text,
"Score" text,
"To par" text,
"Money ( $ )" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the country of the player with playoff money and a score o... | SELECT "Country" FROM table_61554 WHERE "Money ( $ )" = 'playoff' AND "Score" = '66-67-70-67=270' |
### Instruction:
CREATE TABLE table_61741 (
"Conflicts prior to Israel's independence" text,
"Military deaths" text,
"Civilian deaths" text,
"Total deaths" text,
"Military and/or Civilian wounded" text,
"Total casualties" text
)
-- Using valid SQLite, answer the following questions for the tab... | SELECT "Total deaths" FROM table_61741 WHERE "Conflicts prior to Israel's independence" = 'battle of tel hai' |
### Instruction:
CREATE TABLE table_6833 (
"Season" text,
"Competition" text,
"Round" text,
"Opponent" text,
"Home" text,
"Away" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the home team of the UEFA cup in the 2000-2001 season with a ... | SELECT "Home" FROM table_6833 WHERE "Competition" = 'uefa cup' AND "Season" = '2000-2001' AND "Round" = 'second round' |
### Instruction:
CREATE TABLE table_56682 (
"Date" text,
"Visitor" text,
"Score" text,
"Home" text,
"Decision" text,
"Attendance" real,
"Record" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which date has a Home of washington, a Visitor of... | SELECT "Date" FROM table_56682 WHERE "Home" = 'washington' AND "Visitor" = 'florida' AND "Record" = '8-15-2' |
### Instruction:
CREATE TABLE table_25890 (
"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_25890 WHERE "High rebounds" = 'Marcus Camby (15)' |
### Instruction:
CREATE TABLE table_203_486 (
id number,
"place" number,
"team" text,
"matches" number,
"won" number,
"drawn" number,
"lost" number,
"difference" text,
"points" number
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- which c... | SELECT "team" FROM table_203_486 WHERE "team" IN ('switzerland', 'great britain') ORDER BY "place" LIMIT 1 |
### Instruction:
CREATE TABLE table_203_727 (
id number,
"year" number,
"miss northern ireland" text,
"hometown" text,
"placement at miss world" text,
"notes" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- who was miss uk 2005 and miss universe ... | SELECT "miss northern ireland" FROM table_203_727 WHERE "notes" = 'later miss united kingdom 2005 and miss universe united kingdom 2005 2nd runner-up' |
### Instruction:
CREATE TABLE table_64530 (
"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 "Date of vacancy" FROM table_64530 WHERE "Team" = 'firpo' AND "Replaced by" = 'oscar benitez' |
### Instruction:
CREATE TABLE news_report (
journalist_ID int,
Event_ID int,
Work_Type text
)
CREATE TABLE journalist (
journalist_ID int,
Name text,
Nationality text,
Age text,
Years_working int
)
CREATE TABLE event (
Event_ID int,
Date text,
Venue text,
Name text,
... | SELECT Nationality, AVG(Age) FROM journalist GROUP BY Nationality |
### Instruction:
CREATE TABLE table_204_739 (
id number,
"districts" text,
"ubigeo" number,
"area\n(km2)" number,
"population" number,
"population density\n(/km2)" number,
"created" text,
"postal\ncode" number
)
-- Using valid SQLite, answer the following questions for the tables provi... | SELECT COUNT("districts") FROM table_204_739 WHERE "population" > 100000 |
### Instruction:
CREATE TABLE table_74321 (
"No. in series" real,
"Title" text,
"Directed by" text,
"Written by" text,
"Original air date" text,
"Production code" text,
"U.S. viewers (million)" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- ... | SELECT "U.S. viewers (million)" FROM table_74321 WHERE "Production code" = '3X5710' |
### Instruction:
CREATE TABLE Movie (
mID int,
title text,
year int,
director text
)
CREATE TABLE Rating (
rID int,
mID int,
stars int,
ratingDate date
)
CREATE TABLE Reviewer (
rID int,
name text
)
-- Using valid SQLite, answer the following questions for the tables provided... | SELECT director, COUNT(*) FROM Movie AS T1 JOIN Rating AS T2 ON T1.mID = T2.mID GROUP BY T1.director ORDER BY director DESC |
### Instruction:
CREATE TABLE table_46790 (
"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 against" FROM table_46790 WHERE "Losing bonus" = '9' |
### Instruction:
CREATE TABLE table_36540 (
"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 episode number where Jim Sweeney was pe... | SELECT SUM("Episode") FROM table_36540 WHERE "Performer 1" = 'jim sweeney' AND "Performer 4" = 'mike mcshane' |
### Instruction:
CREATE TABLE table_name_77 (
title VARCHAR,
release_date VARCHAR,
director VARCHAR,
production_num VARCHAR,
series VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What's the title of the film directed by Friz Freleng with an MM Se... | SELECT title FROM table_name_77 WHERE production_num > 6209 AND series = "mm" AND director = "friz freleng" AND release_date = "1934-11-03" |
### Instruction:
CREATE TABLE people (
People_ID int,
Name text,
Height real,
Weight real,
Date_of_Birth text
)
CREATE TABLE entrepreneur (
Entrepreneur_ID int,
People_ID int,
Company text,
Money_Requested real,
Investor text
)
-- Using valid SQLite, answer the following quest... | SELECT Investor, COUNT(Investor) FROM entrepreneur GROUP BY Investor ORDER BY Investor DESC |
### Instruction:
CREATE TABLE table_52433 (
"Rank" real,
"Nation" text,
"Gold" real,
"Silver" real,
"Bronze" real,
"Total" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the average rank of a country with less than 13 bronze medals, a to... | SELECT AVG("Rank") FROM table_52433 WHERE "Bronze" < '13' AND "Total" = '11' AND "Gold" > '4' |
### Instruction:
CREATE TABLE table_51237 (
"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 "Team" FROM table_51237 WHERE "Game" < '78' AND "High rebounds" = 'perkins (9)' |
### Instruction:
CREATE TABLE ship (
Ship_ID int,
Name text,
Type text,
Nationality text,
Tonnage int
)
CREATE TABLE mission (
Mission_ID int,
Ship_ID int,
Code text,
Launched_Year int,
Location text,
Speed_knots int,
Fate text
)
-- Using valid SQLite, answer the follo... | SELECT Type, COUNT(Type) FROM ship GROUP BY Nationality, Type ORDER BY Type DESC |
### Instruction:
CREATE TABLE table_7534 (
"Position" text,
"Name" text,
"Height (cm)" real,
"Weight (kg)" real,
"Birthdate" text,
"Birthplace" text,
"Previous Club/Team" text,
"NHL rights, if any" text
)
-- Using valid SQLite, answer the following questions for the tables provided abo... | SELECT "Previous Club/Team" FROM table_7534 WHERE "NHL rights, if any" = 'vancouver canucks' |
### Instruction:
CREATE TABLE table_7856 (
"Player" text,
"League" real,
"Cups" real,
"Other" real,
"Total" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the number of cups when the other was more than 3, the league more than 3, for Lauri D... | SELECT AVG("Cups") FROM table_7856 WHERE "Other" > '3' AND "League" > '3' AND "Player" = 'lauri dalla valle' AND "Total" > '21' |
### Instruction:
CREATE TABLE table_12567 (
"Coach" text,
"Years coached" text,
"Seasons" real,
"Wins" real,
"Losses" real,
"Percentage" real,
"Conference titles" text,
"NCAA" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What are coach... | SELECT MAX("Wins") FROM table_12567 WHERE "Coach" = 'bill henderson' AND "Losses" > '233' |
### Instruction:
CREATE TABLE table_204_60 (
id number,
"sl no" number,
"constituency\nname" text,
"constituency\nnumber" number,
"member of legislative assembly" text,
"political party" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- between tin... | SELECT "constituency\nname" FROM table_204_60 WHERE "constituency\nname" IN ('tingkhong', 'sonari') ORDER BY "constituency\nnumber" DESC LIMIT 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.