instruction stringlengths 212 6.3k | output stringlengths 6 2.03k |
|---|---|
### Instruction:
CREATE TABLE table_16284 (
"Rnd" text,
"Race Name" text,
"Circuit" text,
"City/Location" text,
"Date" text,
"Pole position" text,
"Fastest lap" text,
"Winning driver" text,
"Winning team" text,
"Report" text
)
-- Using valid SQLite, answer the following questio... | SELECT "Report" FROM table_16284 WHERE "Pole position" = 'Michael Andretti' AND "Winning team" = 'Galles-Kraco Racing' |
### Instruction:
CREATE TABLE table_14171 (
"Model number" text,
"sSpec number" text,
"Cores" text,
"Frequency" text,
"Turbo" text,
"L2 cache" text,
"L3 cache" text,
"GPU model" text,
"GPU frequency" text,
"Socket" text,
"I/O bus" text,
"Release date" text,
"Release p... | SELECT "Socket" FROM table_14171 WHERE "sSpec number" = 'standard power' |
### Instruction:
CREATE TABLE table_79593 (
"Rank" real,
"Total Population (2010)" real,
"Indian American Population (2010)" real,
"% Indian American" real,
"Asian American Population (2010)" real,
"% Asian American" real
)
-- Using valid SQLite, answer the following questions for the tables p... | SELECT MIN("Total Population (2010)") FROM table_79593 WHERE "% Asian American" = '5.7' AND "Asian American Population (2010)" < '126,965' |
### Instruction:
CREATE TABLE table_8400 (
"Brigade" text,
"Staffing" text,
"Type" text,
"Location" text,
"Pumpers" real,
"Tankers" real,
"Telebooms" text,
"Platforms" text,
"Cars" text,
"Hazmat" text
)
-- Using valid SQLite, answer the following questions for the tables provid... | SELECT "Tankers" FROM table_8400 WHERE "Hazmat" = '–' AND "Platforms" = '–' AND "Staffing" = 'volunteer' |
### Instruction:
CREATE TABLE table_20098 (
"Club" text,
"Played" text,
"Won" text,
"Drawn" text,
"Lost" text,
"Points for" text,
"Points against" text,
"Points difference" text,
"Tries For" text,
"Tries Against" text,
"Try Bonus" text,
"Losing Bonus" text,
"Points" t... | SELECT "Losing Bonus" FROM table_20098 WHERE "Points difference" = '-99' |
### Instruction:
CREATE TABLE table_61872 (
"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 "Try bonus" FROM table_61872 WHERE "Losing bonus" = '1' AND "Points for" = '179' |
### Instruction:
CREATE TABLE table_203_757 (
id number,
"year" number,
"award ceremony" text,
"category" text,
"film/show" text,
"result" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what show/film were both the 2011 filmfare awards and the 2... | SELECT "film/show" FROM table_203_757 WHERE "year" = 2011 AND "award ceremony" = 'filmfare awards' INTERSECT SELECT "film/show" FROM table_203_757 WHERE "year" = 2011 AND "award ceremony" = 'screen awards' |
### Instruction:
CREATE TABLE table_train_253 (
"id" int,
"pregnancy_or_lactation" bool,
"pre_eclampsia" bool,
"acute_ischemia" bool,
"pre_gestational_hypertension" bool,
"diabetic" string,
"smoking" bool,
"coronary_artery_disease_cad" bool,
"NOUSE" float
)
-- Using valid SQLite, a... | SELECT * FROM table_train_253 WHERE pregnancy_or_lactation = 1 AND pre_gestational_hypertension = 1 |
### Instruction:
CREATE TABLE Manufacturers (
Code INTEGER,
Name VARCHAR(255),
Headquarter VARCHAR(255),
Founder VARCHAR(255),
Revenue REAL
)
CREATE TABLE Products (
Code INTEGER,
Name VARCHAR(255),
Price DECIMAL,
Manufacturer INTEGER
)
-- Using valid SQLite, answer the following ... | SELECT T1.Code, T1.Price FROM Products AS T1 JOIN Manufacturers AS T2 ON T1.Manufacturer = T2.Code GROUP BY Founder |
### 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 Price, Manufacturer FROM Products AS T1 JOIN Manufacturers AS T2 ON T1.Manufacturer = T2.Code GROUP BY Headquarter |
### Instruction:
CREATE TABLE table_13915 (
"Year(s)" text,
"Selection show" text,
"Venue" text,
"National final main host" text,
"National final co host" text,
"Semi final/heat host" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the na... | SELECT "National final co host" FROM table_13915 WHERE "National final main host" = 'david jacobs' AND "Selection show" = 'a song for europe' AND "Year(s)" = '1966' |
### Instruction:
CREATE TABLE table_72627 (
"Year" real,
"Mens singles" text,
"Womens singles" text,
"Mens doubles" text,
"Womens doubles" text,
"Mixed doubles" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- In the year 2006, the womens singles ... | SELECT "Womens doubles" FROM table_72627 WHERE "Womens singles" = 'no competition' AND "Mens doubles" = 'Roland Hilti Kilian Pfister' AND "Year" = '2006' |
### Instruction:
CREATE TABLE table_50041 (
"Date" text,
"Visitor" text,
"Score" text,
"Home" text,
"Decision" text,
"Attendance" real,
"Record" text,
"Points" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Points have a Visitor of... | SELECT MAX("Points") FROM table_50041 WHERE "Visitor" = 'montreal canadiens' AND "Attendance" > '18,568' AND "Record" = '2–0–1' |
### Instruction:
CREATE TABLE table_62847 (
"Peak" text,
"Country" text,
"Elevation (m)" real,
"Prominence (m)" real,
"Col (m)" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Elevation (m) has a Prominence (m) smaller than 2,456, and a Peak of... | SELECT MAX("Elevation (m)") FROM table_62847 WHERE "Prominence (m)" < '2,456' AND "Peak" = 'mount kyllini' AND "Col (m)" < '506' |
### Instruction:
CREATE TABLE film (
film_id number,
title text,
studio text,
director text,
gross_in_dollar number
)
CREATE TABLE film_market_estimation (
estimation_id number,
low_estimate number,
high_estimate number,
film_id number,
type text,
market_id number,
year ... | SELECT title FROM film WHERE NOT film_id IN (SELECT film_id FROM film_market_estimation) |
### Instruction:
CREATE TABLE table_58622 (
"Polling Firm" text,
"Polling Dates" text,
"Bob Chiarelli" text,
"Alex Munter" text,
"Larry O'Brien" text,
"Terry Kilrea (dropped out)" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What are the polli... | SELECT "Terry Kilrea (dropped out)" FROM table_58622 WHERE "Polling Firm" = 'holinshed' AND "Bob Chiarelli" = '22.5%' |
### Instruction:
CREATE TABLE table_51948 (
"Rank ( WJC )" real,
"Rank (ARDA)" real,
"Metro area" text,
"Number of Jews (WJC)" real,
"Number of Jews (ASARB)" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the total number of WJC rank when t... | SELECT COUNT("Rank ( WJC )") FROM table_51948 WHERE "Rank (ARDA)" < '2' AND "Number of Jews (ASARB)" < '2,028,200' |
### Instruction:
CREATE TABLE Projects (
project_details VARCHAR,
project_id VARCHAR
)
CREATE TABLE Project_outcomes (
project_id VARCHAR,
outcome_code VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- List the project details of the project both produ... | SELECT T1.project_details FROM Projects AS T1 JOIN Project_outcomes AS T2 ON T1.project_id = T2.project_id WHERE T2.outcome_code = 'Paper' INTERSECT SELECT T1.project_details FROM Projects AS T1 JOIN Project_outcomes AS T2 ON T1.project_id = T2.project_id WHERE T2.outcome_code = 'Patent' |
### Instruction:
CREATE TABLE table_57465 (
"Election" text,
"1st Member" text,
"1st Party" text,
"2nd Member" text,
"2nd Party" text,
"3rd Member" text,
"3rd Party" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Election had 2nd Membe... | SELECT "Election" FROM table_57465 WHERE "2nd Member" = 'george alexander morrison' AND "1st Party" = 'unionist' AND "3rd Member" = 'john buchan' |
### Instruction:
CREATE TABLE table_38693 (
"Career Card" text,
"Starting career/salary" text,
"2nd career/salary" text,
"3rd career/salary" text,
"4th career/salary" text,
"5th career/salary" text,
"6th career/salary" text
)
-- Using valid SQLite, answer the following questions for the ta... | SELECT "2nd career/salary" FROM table_38693 WHERE "4th career/salary" = 'clown ($80,000)' |
### Instruction:
CREATE TABLE program (
program_id number,
name text,
origin text,
launch number,
owner text
)
CREATE TABLE broadcast (
channel_id number,
program_id number,
time_of_day text
)
CREATE TABLE broadcast_share (
channel_id number,
program_id number,
date text,
... | SELECT name, origin, owner FROM program |
### Instruction:
CREATE TABLE people (
People_ID int,
Sex text,
Name text,
Date_of_Birth text,
Height real,
Weight real
)
CREATE TABLE candidate (
Candidate_ID int,
People_ID int,
Poll_Source text,
Date text,
Support_rate real,
Consider_rate real,
Oppose_rate real,
... | SELECT Sex, AVG(Height) FROM people GROUP BY Sex ORDER BY Sex DESC |
### Instruction:
CREATE TABLE table_49641 (
"County" text,
"Kerry%" text,
"Kerry#" real,
"Bush%" text,
"Bush#" real,
"Others%" text,
"Others#" real,
"2000 result" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many votes went to othe... | SELECT MIN("Others#") FROM table_49641 WHERE "Others%" = '1.9%' AND "Bush#" < '160,390' |
### Instruction:
CREATE TABLE table_20698 (
"Year" real,
"Lansing (LAN)" text,
"Detroit (DTW)" text,
"Grand Rapids (GRR)" text,
"Flint (FNT)" text,
"Kalamazoo (AZO)" text,
"Saginaw (MBS)" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What i... | SELECT "Kalamazoo (AZO)" FROM table_20698 WHERE "Saginaw (MBS)" = '$481.39' |
### Instruction:
CREATE TABLE people (
People_ID int,
Sex text,
Name text,
Date_of_Birth text,
Height real,
Weight real
)
CREATE TABLE candidate (
Candidate_ID int,
People_ID int,
Poll_Source text,
Date text,
Support_rate real,
Consider_rate real,
Oppose_rate real,
... | SELECT Sex, AVG(Weight) FROM people GROUP BY Sex ORDER BY Sex |
### Instruction:
CREATE TABLE table_64846 (
"Name" text,
"Position" text,
"League Apps" text,
"League Goals" real,
"FA Cup Apps" text,
"FA Cup Goals" real,
"League Cup Apps" text,
"League Cup Goals" real,
"FLT Apps" text,
"FLT Goals" real,
"Total Apps" text,
"Total Goals"... | SELECT "Total Apps" FROM table_64846 WHERE "Name" = 'paul wilson' |
### Instruction:
CREATE TABLE table_63114 (
"Season" text,
"LeagueContested" text,
"Level" real,
"LeaguePosition" text,
"Avg.Home Attendance 1" text,
"FA Cup" text,
"FA Trophy" text,
"Leading scorer 1" text
)
-- Using valid SQLite, answer the following questions for the tables provided... | SELECT "Leading scorer 1" FROM table_63114 WHERE "LeagueContested" = 'northern premier league premier division' AND "FA Cup" = '2q' |
### Instruction:
CREATE TABLE table_36458 (
"Name" text,
"GP-GS" real,
"Gain" real,
"Loss" real,
"Long" real,
"Avg/G" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the average Long that has a GP-GS less than 14, a AVg/G less than 0.8 an... | SELECT AVG("Long") FROM table_36458 WHERE "GP-GS" < '14' AND "Avg/G" < '0.8' AND "Gain" < '3' AND "Loss" > '8' |
### Instruction:
CREATE TABLE table_79164 (
"Year" real,
"Date" text,
"Home Team" text,
"Result" text,
"Visiting Team" text,
"Venue" text,
"Attendance" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- When the san francisco 49ers are visiting ... | SELECT "Home Team" FROM table_79164 WHERE "Visiting Team" = 'san francisco 49ers' AND "Attendance" > '45,532' AND "Date" = 'september 30' |
### Instruction:
CREATE TABLE table_39740 (
"Tournament" text,
"Wins" real,
"Top-5" real,
"Top-10" real,
"Top-25" real,
"Events" real,
"Cuts made" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the average Top-25 that has a Top-10 le... | SELECT AVG("Top-25") FROM table_39740 WHERE "Top-10" < '7' AND "Tournament" = 'the open championship' AND "Top-5" > '1' |
### Instruction:
CREATE TABLE people (
People_ID int,
Sex text,
Name text,
Date_of_Birth text,
Height real,
Weight real
)
CREATE TABLE candidate (
Candidate_ID int,
People_ID int,
Poll_Source text,
Date text,
Support_rate real,
Consider_rate real,
Oppose_rate real,
... | SELECT Sex, AVG(Height) FROM people GROUP BY Sex ORDER BY AVG(Height) |
### Instruction:
CREATE TABLE table_16892 (
"Year" real,
"Starts" real,
"Cuts made" text,
"Wins (Majors)" text,
"2nd" real,
"3rd" real,
"Top 10" real,
"Top 25" real,
"Earnings ($)" real,
"Money list rank" real,
"Adjusted scoring average (rank)" text
)
-- Using valid SQLite,... | SELECT MAX("2nd") FROM table_16892 WHERE "Cuts made" = '11' |
### Instruction:
CREATE TABLE table_29374 (
"Year" real,
"Network(s)" text,
"Bowl" text,
"Play-by-play announcer" text,
"Color analyst(s)" text,
"Sideline reporter(s)" text,
"Studio host(s)" text,
"Studio analyst(s)" text,
"TV Rating" text
)
-- Using valid SQLite, answer the follow... | SELECT COUNT("Bowl") FROM table_29374 WHERE "Studio analyst(s)" = 'Lee Corso, Gene Chizik and Chip Kelly' |
### Instruction:
CREATE TABLE table_52222 (
"County" text,
"1900" real,
"1930" real,
"1950" real,
"2000" real,
"2006 est." real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the highest 1930 population when the 2000 population is 43,966 and ... | SELECT MAX("1930") FROM table_52222 WHERE "2000" = '43,966' AND "1900" < '8,401' |
### Instruction:
CREATE TABLE table_42574 (
"Hangul" text,
"Hanja" text,
"Revised" text,
"McCune-Reischauer" text,
"2000 n South Korea population *" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the McCune-Reischauer when the 2000 n South K... | SELECT "McCune-Reischauer" FROM table_42574 WHERE "2000 n South Korea population *" > '6,796,227' AND "Hangul" = '송' |
### Instruction:
CREATE TABLE table_train_89 (
"id" int,
"chronically_uncontrolled_hypertension" bool,
"uncontrolled_diabetes" bool,
"hemoglobin_a1c_hba1c" float,
"body_weight" float,
"renal_disease" bool,
"creatinine_clearance_cl" float,
"geriatric_depression_scale_gds" int,
"major_... | SELECT * FROM table_train_89 WHERE body_weight > 300 |
### Instruction:
CREATE TABLE table_19036 (
"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_19036 WHERE "Played" = '22' AND "Points against" = '319' |
### Instruction:
CREATE TABLE table_9607 (
"Missouri vs." text,
"Overall Record" text,
"at Columbia" text,
"at Opponent's Venue" text,
"at Neutral Site" text,
"Last 5 Meetings" text,
"Last 10 Meetings" text,
"Current Streak" text,
"During Time in Big 12" text
)
-- Using valid SQLit... | SELECT "at Neutral Site" FROM table_9607 WHERE "Overall Record" = 'mu, 15-8' |
### Instruction:
CREATE TABLE manufacturer (
manufacturer_id number,
open_year number,
name text,
num_of_factories number,
num_of_shops number
)
CREATE TABLE furniture_manufacte (
manufacturer_id number,
furniture_id number,
price_in_dollar number
)
CREATE TABLE furniture (
furnitu... | SELECT open_year, name FROM manufacturer ORDER BY num_of_shops DESC LIMIT 1 |
### Instruction:
CREATE TABLE table_58000 (
"School" text,
"Location" text,
"Enrolment" real,
"Founded" real,
"Denomination" text,
"Day/Boarding" text,
"School Colours" text,
"Abbreviation" text,
"In competition since" real
)
-- Using valid SQLite, answer the following questions fo... | SELECT MAX("Enrolment") FROM table_58000 WHERE "Denomination" = 'anglican' AND "Day/Boarding" = 'day' AND "Founded" > '1929' |
### Instruction:
CREATE TABLE table_56232 (
"Yard Name" text,
"Location (City, State)" text,
"1st Ship Delivery Date" text,
"Ship Types Delivered" text,
"Total Number of Ways" text,
"Total Vessels Built for USMC" text
)
-- Using valid SQLite, answer the following questions for the tables provi... | SELECT "Ship Types Delivered" FROM table_56232 WHERE "Total Vessels Built for USMC" = '13 ships for usmc (plus 37 more for usn)' |
### Instruction:
CREATE TABLE table_12578 (
"Version" text,
"Fairing" text,
"CCBs" real,
"SRBs" text,
"Upper stage" text,
"Payload to LEO" text,
"Payload to GTO" text,
"Launches to date" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Wha... | SELECT MAX("CCBs") FROM table_12578 WHERE "Launches to date" = '4' AND "Payload to GTO" = '8,900kg' |
### Instruction:
CREATE TABLE table_7427 (
"Player" text,
"FG Pct" real,
"3FGM" real,
"3FGA" real,
"3FG Pct" real,
"FT Pct" real,
"Off Reb" real,
"Def Reb" real,
"Total Reb" real,
"Asst" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.... | SELECT MIN("Total Reb") FROM table_7427 WHERE "Player" = 'mcalarney' AND "3FGM" < '103' |
### Instruction:
CREATE TABLE table_204_590 (
id number,
"year" number,
"division" number,
"league" text,
"regular season" text,
"playoffs" text,
"open cup" text,
"avg. attendance" number
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what wa... | SELECT ABS((SELECT "avg. attendance" FROM table_204_590 WHERE "year" = 2010) - (SELECT "avg. attendance" FROM table_204_590 WHERE "year" = 2001)) |
### Instruction:
CREATE TABLE table_27773 (
"City/ municipality" text,
"Type" text,
"No. of Barangays" real,
"Population (2010)" real,
"Area (km\u00b2)" text,
"Pop. density (per km\u00b2)" real,
"Income Class" text,
"Zip Code" real
)
-- Using valid SQLite, answer the following question... | SELECT COUNT("Pop. density (per km\u00b2)") FROM table_27773 WHERE "Area (km\u00b2)" = '48.67' |
### Instruction:
CREATE TABLE school (
School_ID int,
Grade text,
School text,
Location text,
Type text
)
CREATE TABLE driver (
Driver_ID int,
Name text,
Party text,
Home_city text,
Age int
)
CREATE TABLE school_bus (
School_ID int,
Driver_ID int,
Years_Working int,... | SELECT Home_city, COUNT(Home_city) FROM driver GROUP BY Home_city ORDER BY COUNT(Home_city) |
### Instruction:
CREATE TABLE table_66471 (
"Rank:" real,
"State:" text,
"Premier:" text,
"Party:" text,
"Assumed office:" text,
"Left office:" text,
"TOTAL Time in office:" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the least ra... | SELECT MIN("Rank:") FROM table_66471 WHERE "TOTAL Time in office:" = '7 years, 335 days' AND "Assumed office:" = '17 may 1919' |
### Instruction:
CREATE TABLE table_17703 (
"Rank in Nyagatare Sectors, 2012" real,
"Sector" text,
"Area in sqkm" real,
"Population August 15, 2012" real,
"Population, August 15, 2002" real,
"Population Change 2002-2012 (%)" text,
"Population Density 2012 (km 2 )" real
)
-- Using valid SQL... | SELECT MAX("Population, August 15, 2002") FROM table_17703 |
### Instruction:
CREATE TABLE table_2289 (
"Type" text,
"Beam height (mm)" real,
"Flange width (mm)" real,
"Web thickness (mm)" text,
"Flange thickness (mm)" text,
"Weight (kg/m)" text,
"Cross-section area (cm 2 )" text,
"Moment of inertia in torsion (J) (cm 4 )" text
)
-- Using valid ... | SELECT "Flange thickness (mm)" FROM table_2289 WHERE "Weight (kg/m)" = '19.9' |
### Instruction:
CREATE TABLE table_204_690 (
id number,
"election" number,
"party name" text,
"total votes" number,
"share of votes" text,
"seats" number,
"share of seats" text,
"party leader(s)" text,
"notes" text
)
-- Using valid SQLite, answer the following questions for the ta... | SELECT "party leader(s)" FROM table_204_690 WHERE "election" < (SELECT MIN("election") FROM table_204_690 WHERE "party leader(s)" = 'colin eglin') ORDER BY "election" DESC LIMIT 1 |
### 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 Nationality, COUNT(Nationality) FROM ship GROUP BY Type, Nationality ORDER BY Nationality DESC |
### Instruction:
CREATE TABLE table_41549 (
"Headphone Model" text,
"Headphone Class" text,
"Sensitivity (dB)" text,
"Impedance (Ohms)" real,
"Driver-matched dB" text,
"Construction" text,
"Earpads" text,
"Termination" text,
"Succeeded by" text
)
-- Using valid SQLite, answer the f... | SELECT "Earpads" FROM table_41549 WHERE "Construction" = 'plastic' AND "Succeeded by" = 'igrado' |
### Instruction:
CREATE TABLE table_50741 (
"Date" text,
"Result" text,
"Opponent" text,
"Venue" text,
"Location" text,
"Method" text,
"Round" real,
"Time" text,
"Record" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- The match of at... | SELECT "Record" FROM table_50741 WHERE "Time" = '3:00' AND "Venue" = 'michael''s eighth avenue' AND "Opponent" = 'tim coleman' |
### Instruction:
CREATE TABLE table_12579 (
"Version" text,
"Fairing" text,
"CCBs" real,
"SRBs" text,
"Upper stage" text,
"Payload to LEO" text,
"Payload to GTO" text,
"Launches to date" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Wha... | SELECT "Payload to GTO" FROM table_12579 WHERE "CCBs" > '1' AND "Payload to LEO" = '29,400kg' |
### Instruction:
CREATE TABLE table_203_425 (
id number,
"season" number,
"driver" text,
"equipment" text,
"position" number,
"points" number,
"races" number,
"wins" number,
"second" number,
"third" number
)
-- Using valid SQLite, answer the following questions for the tables p... | SELECT "driver" FROM table_203_425 WHERE "driver" IN ('daniel willemsen', 'modris stelle') GROUP BY "driver" ORDER BY SUM("points") DESC LIMIT 1 |
### Instruction:
CREATE TABLE table_53637 (
"City" text,
"1970" real,
"1980" real,
"1990" real,
"2000" real,
"2010 est." real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- With 1990 growth greater than 19,988 and 1970 growth less than 10,522, what i... | SELECT AVG("1980") FROM table_53637 WHERE "1990" > '19,988' AND "1970" < '10,522' |
### Instruction:
CREATE TABLE table_2509 (
"Year" real,
"Starts" real,
"Wins" real,
"Top 5" real,
"Top 10" real,
"Poles" real,
"Avg. Start" text,
"Avg. Finish" text,
"Winnings" text,
"Position" text,
"Team(s)" text
)
-- Using valid SQLite, answer the following questions for... | SELECT "Avg. Finish" FROM table_2509 WHERE "Team(s)" = '#21/#07 SS-Green Light Racing' |
### Instruction:
CREATE TABLE table_train_97 (
"id" int,
"pulmonary_disease" bool,
"systolic_blood_pressure_sbp" int,
"diabetic" string,
"psychiatric_disease" bool,
"hematologic_disease" bool,
"diastolic_blood_pressure_dbp" int,
"lung_disease" bool,
"NOUSE" float
)
-- Using valid S... | SELECT * FROM table_train_97 WHERE pulmonary_disease = 1 OR lung_disease = 1 |
### Instruction:
CREATE TABLE table_47575 (
"Season" real,
"Date" text,
"Score" text,
"Winner" text,
"Venue" text,
"Competition round" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- On what date did Universitario win the Torneo Apertura round af... | SELECT "Date" FROM table_47575 WHERE "Venue" = 'estadio alejandro villanueva' AND "Season" > '2003' AND "Competition round" = 'torneo apertura' AND "Winner" = 'universitario' |
### Instruction:
CREATE TABLE table_40565 (
"Episode number Production number" text,
"Title" text,
"Original airing" text,
"Rating" real,
"Share" real,
"18-49" real,
"Total viewers (in millions)" real,
"Rank per week" text
)
-- Using valid SQLite, answer the following questions for the... | SELECT "Original airing" FROM table_40565 WHERE "Rating" < '10.1' AND "Episode number Production number" = '96 5-09' |
### Instruction:
CREATE TABLE people (
people_id number,
name text,
height number,
weight number,
date_of_birth text
)
CREATE TABLE entrepreneur (
entrepreneur_id number,
people_id number,
company text,
money_requested number,
investor text
)
-- Using valid SQLite, answer the ... | SELECT investor FROM entrepreneur WHERE money_requested > 140000 INTERSECT SELECT investor FROM entrepreneur WHERE money_requested < 120000 |
### Instruction:
CREATE TABLE table_7231 (
"7:00" text,
"7:30" text,
"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 is on at 10:00 when 60 minutes was on at 7:00 and million do... | SELECT "10:00" FROM table_7231 WHERE "7:00" = '60 minutes' AND "8:00" = 'million dollar password' |
### 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, MIN(Weight) FROM people GROUP BY Sex ORDER BY MIN(Weight) DESC |
### Instruction:
CREATE TABLE table_16238 (
"Province" text,
"Population (2004 estimate)" real,
"Area (km\u00b2)" real,
"Density" text,
"GDP (2003, PPS in mil. \u20ac )" real,
"GDP per cap. (2003, in \u20ac)" real
)
-- Using valid SQLite, answer the following questions for the tables provided ... | SELECT MIN("GDP per cap. (2003, in \u20ac)") FROM table_16238 WHERE "Province" = 'Friesland' |
### Instruction:
CREATE TABLE allergy_type (
allergy text,
allergytype text
)
CREATE TABLE has_allergy (
stuid number,
allergy text
)
CREATE TABLE student (
stuid number,
lname text,
fname text,
age number,
sex text,
major number,
advisor number,
city_code text
)
-- U... | SELECT fname, sex FROM student WHERE stuid IN (SELECT stuid FROM has_allergy WHERE allergy = "Milk" EXCEPT SELECT stuid FROM has_allergy WHERE allergy = "Cat") |
### Instruction:
CREATE TABLE table_74619 (
"Season" text,
"Season Total Att." text,
"K-League Season Total Att." text,
"Regular Season Average Att." text,
"League Cup Average Att." text,
"FA Cup Total / Average Att." text,
"ACL Total / Average Att." text,
"Friendly Match Att." text
)
... | SELECT "Season Total Att." FROM table_74619 WHERE "League Cup Average Att." = '32,415' |
### Instruction:
CREATE TABLE table_32788 (
"Outcome" text,
"Date" real,
"Tournament" 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.
-- Who is the partner... | SELECT "Partner" FROM table_32788 WHERE "Date" > '1971' AND "Outcome" = 'runner-up' AND "Score in the final" = '3–6, 3–6' |
### 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 Manufacturer, Revenue FROM Products AS T1 JOIN Manufacturers AS T2 ON T1.Manufacturer = T2.Code GROUP BY Founder |
### Instruction:
CREATE TABLE table_21962 (
"Voivodeship after 1569" text,
"Capital" text,
"Year established" real,
"Number of powiats" text,
"Area (km\u00b2) in 1590 (Lithuanian) Category:Articles with Lithuanian-language external links" real
)
-- Using valid SQLite, answer the following question... | SELECT COUNT("Capital") FROM table_21962 WHERE "Voivodeship after 1569" = 'Brest Litovsk Voivodeship' |
### Instruction:
CREATE TABLE table_202_196 (
id number,
"ethnicity" text,
"1880" text,
"1899" text,
"1913" text,
"19301" text,
"1956" text,
"1966" text,
"1977" text,
"1992" text,
"2002" text
)
-- Using valid SQLite, answer the following questions for the tables provided ab... | SELECT "ethnicity" FROM table_202_196 ORDER BY "1992" DESC LIMIT 1 |
### Instruction:
CREATE TABLE table_56645 (
"Model number" text,
"sSpec number" text,
"Frequency" text,
"L2 cache" text,
"Mult." text,
"Voltage" text,
"Socket" text,
"Release date" text,
"Part number(s)" text,
"Release price ( USD )" text
)
-- Using valid SQLite, answer the fol... | SELECT "Release price ( USD )" FROM table_56645 WHERE "Model number" = 'pentium dual-core t2330' |
### Instruction:
CREATE TABLE table_22387 (
"Season" real,
"Trophy Winner" text,
"Air Force \u2013 Navy score" text,
"Air Force \u2013 Army score" text,
"Army \u2013 Navy score" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many different seaso... | SELECT COUNT("Season") FROM table_22387 WHERE "Army \u2013 Navy score" = '10 Dec. 2016 at Baltimore, MD (M&T Bank Stadium)' |
### Instruction:
CREATE TABLE table_36538 (
"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 date of the episode with Ryan Stiles as... | SELECT "Date" FROM table_36538 WHERE "Performer 2" = 'ryan stiles' AND "Performer 3" = 'colin mochrie' AND "Performer 4" = 'tony slattery' |
### Instruction:
CREATE TABLE table_17439 (
"#" real,
"President" text,
"Date of birth" text,
"Date of inauguration" text,
"Age at inauguration" text,
"End of term" text,
"Length of retirement" text,
"Date of death" text,
"Lifespan" text
)
-- Using valid SQLite, answer the followin... | SELECT COUNT("End of term") FROM table_17439 WHERE "Age at inauguration" = '64-066 64years, 66days' |
### Instruction:
CREATE TABLE table_70873 (
"Year" real,
"Stage" real,
"Category" real,
"Start" text,
"Finish" text,
"Leader at the summit" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who was the leader at the summit when the stage was larger... | SELECT "Leader at the summit" FROM table_70873 WHERE "Stage" > '14' AND "Category" = '1' AND "Start" = 'saint-girons' AND "Finish" = 'cauterets' |
### Instruction:
CREATE TABLE table_14173 (
"Model number" text,
"sSpec number" text,
"Cores" text,
"Frequency" text,
"Turbo" text,
"L2 cache" text,
"L3 cache" text,
"GPU model" text,
"GPU frequency" text,
"Socket" text,
"I/O bus" text,
"Release date" text,
"Release p... | SELECT "Cores" FROM table_14173 WHERE "L2 cache" = 'low power' |
### Instruction:
CREATE TABLE table_74092 (
"Episode" text,
"Date" text,
"Official ITV1 rating (millions)" text,
"Weekly rank" real,
"Share (%)" text,
"Official ITV1 HD rating (millions)" text,
"Total ITV1 viewers (millions)" text
)
-- Using valid SQLite, answer the following questions for... | SELECT "Official ITV1 HD rating (millions)" FROM table_74092 WHERE "Official ITV1 rating (millions)" = '8.98' |
### Instruction:
CREATE TABLE table_15501 (
"model" text,
"engine type" text,
"max. power" text,
"max. torque" text,
"top speed" text,
"0\u2013100km/h (62mph)" text,
"CO 2 emissions" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the... | SELECT "engine type" FROM table_15501 WHERE "0\u2013100km/h (62mph)" = '11.2 sec' |
### Instruction:
CREATE TABLE table_203_584 (
id number,
"date" text,
"race name" text,
"d(f)" number,
"course" text,
"prize (\u00a3)" number,
"odds" text,
"runners" number,
"place" number,
"margin" number,
"winner/runner-up" text,
"time" text,
"jockey" text
)
-- Us... | SELECT "race name" FROM table_203_584 WHERE "date" = 'charles wood' |
### Instruction:
CREATE TABLE head (
head_ID int,
name text,
born_state text,
age real
)
CREATE TABLE department (
Department_ID int,
Name text,
Creation text,
Ranking int,
Budget_in_Billions real,
Num_Employees real
)
CREATE TABLE management (
department_ID int,
head_I... | SELECT born_state, COUNT(born_state) FROM head GROUP BY born_state ORDER BY COUNT(born_state) DESC |
### Instruction:
CREATE TABLE Allergy_Type (
Allergy VARCHAR(20),
AllergyType VARCHAR(20)
)
CREATE TABLE Has_Allergy (
StuID INTEGER,
Allergy VARCHAR(20)
)
CREATE TABLE Student (
StuID INTEGER,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
... | SELECT Sex, AVG(Age) FROM Student GROUP BY Sex |
### Instruction:
CREATE TABLE station (
Station_ID int,
Name text,
Annual_entry_exit real,
Annual_interchanges real,
Total_Passengers real,
Location text,
Main_Services text,
Number_of_Platforms int
)
CREATE TABLE train_station (
Train_ID int,
Station_ID int
)
CREATE TABLE trai... | SELECT Location, SUM(Total_Passengers) FROM station GROUP BY Location ORDER BY Location DESC |
### Instruction:
CREATE TABLE table_204_766 (
id number,
"event" text,
"meeting gaz de france\nparis" text,
"golden gala\nrome" text,
"bislett games\noslo" text,
"weltklasse zurich" text,
"memorial van damme\nbrussels" text,
"istaf\nberlin" text
)
-- Using valid SQLite, answer the foll... | SELECT "event" FROM table_204_766 WHERE id = (SELECT id FROM table_204_766 WHERE "event" = 'pole vault') - 1 |
### Instruction:
CREATE TABLE table_48843 (
"Model number" text,
"sSpec number" text,
"Frequency" text,
"L2 cache" text,
"Mult." text,
"Voltage" text,
"Socket" text,
"Release date" text,
"Part number(s)" text,
"Release price ( USD )" text
)
-- Using valid SQLite, answer the fol... | SELECT "Model number" FROM table_48843 WHERE "sSpec number" = 'sl3jm(kc0)sl3jt(kc0)' |
### Instruction:
CREATE TABLE people (
People_ID int,
Sex text,
Name text,
Date_of_Birth text,
Height real,
Weight real
)
CREATE TABLE candidate (
Candidate_ID int,
People_ID int,
Poll_Source text,
Date text,
Support_rate real,
Consider_rate real,
Oppose_rate real,
... | SELECT Date_of_Birth, Weight FROM people ORDER BY Date_of_Birth |
### Instruction:
CREATE TABLE table_43548 (
"Official #" real,
"TF1 #" real,
"French title" text,
"English title" text,
"Air date (France)" text,
"Original Beechwood Bunny Tale / Source material" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Wh... | SELECT MAX("TF1 #") FROM table_43548 WHERE "Official #" > '47' AND "Air date (France)" = '13 july 2010' |
### Instruction:
CREATE TABLE table_203_185 (
id number,
"season" text,
"a\ntechnical" text,
"b\nscientific" text,
"c\nfine arts" text,
"d\nimprovisational" text,
"e\nstructural" text,
"rising stars!\u00ae" text,
"po\nprojectoutreach\u00ae" text,
"university level" text
)
-- Us... | SELECT "d\nimprovisational" FROM table_203_185 ORDER BY "season" LIMIT 1 |
### Instruction:
CREATE TABLE table_58122 (
"Date" text,
"Tournament" text,
"Location" text,
"Purse( $ )" real,
"Winner" text,
"Score" text,
"1st Prize( $ )" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the first prize amount of th... | SELECT COUNT("1st Prize( $ )") FROM table_58122 WHERE "Score" = '207 (-9)' AND "Purse( $ )" > '800,000' |
### Instruction:
CREATE TABLE table_5331 (
"Specification" text,
"Gender" text,
"Junior High School (12\u201315 yrs)" text,
"Senior High School (15\u201318 yrs)" text,
"University students and Adults (18yrs+)" text
)
-- Using valid SQLite, answer the following questions for the tables provided abo... | SELECT "University students and Adults (18yrs+)" FROM table_5331 WHERE "Specification" = 'minimum diameter of sakigawa' AND "Gender" = 'female' |
### Instruction:
CREATE TABLE table_train_165 (
"id" int,
"gender" string,
"hemoglobin_a1c_hba1c" float,
"visual_impairment" bool,
"blood_glucose" int,
"body_mass_index_bmi" float,
"a1c" float,
"age" float,
"NOUSE" float
)
-- Using valid SQLite, answer the following questions for t... | SELECT * FROM table_train_165 WHERE blood_glucose > 150 AND a1c > 7.5 |
### Instruction:
CREATE TABLE table_38762 (
"The Kennel Club (UK) Toy Group" text,
"Canadian Kennel Club Toy Dogs Group" text,
"American Kennel Club Toy Group" text,
"Australian National Kennel Council Toy Dogs Group" text,
"New Zealand Kennel Club Toy Group" text
)
-- Using valid SQLite, answer t... | SELECT "Canadian Kennel Club Toy Dogs Group" FROM table_38762 WHERE "Australian National Kennel Council Toy Dogs Group" = 'australian silky terrier' |
### Instruction:
CREATE TABLE market (
Market_ID int,
District text,
Num_of_employees int,
Num_of_shops real,
Ranking int
)
CREATE TABLE phone (
Name text,
Phone_ID int,
Memory_in_G int,
Carrier text,
Price real
)
CREATE TABLE phone_market (
Market_ID int,
Phone_ID text... | SELECT Carrier, COUNT(Carrier) FROM phone GROUP BY Carrier ORDER BY COUNT(Carrier) DESC |
### Instruction:
CREATE TABLE table_38298 (
"Rank" real,
"Name" text,
"Nationality" text,
"1st (m)" real,
"2nd (m)" real,
"Points" real,
"Overall WC points (Rank)" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many 2nd (m) have aut as t... | SELECT SUM("2nd (m)") FROM table_38298 WHERE "Nationality" = 'aut' AND "Rank" = '4' AND "1st (m)" < '122.5' |
### Instruction:
CREATE TABLE certificate (
eid number,
aid number
)
CREATE TABLE flight (
flno number,
origin text,
destination text,
distance number,
departure_date time,
arrival_date time,
price number,
aid number
)
CREATE TABLE employee (
eid number,
name text,
... | SELECT departure_date, arrival_date FROM flight WHERE origin = "Los Angeles" AND destination = "Honolulu" |
### Instruction:
CREATE TABLE department (
Department_ID int,
Name text,
Creation text,
Ranking int,
Budget_in_Billions real,
Num_Employees real
)
CREATE TABLE head (
head_ID int,
name text,
born_state text,
age real
)
CREATE TABLE management (
department_ID int,
head_I... | SELECT Creation, AVG(Budget_in_Billions) FROM department ORDER BY Creation |
### Instruction:
CREATE TABLE table_6292 (
"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 lowest population of the county wit... | SELECT MIN("Population") FROM table_6292 WHERE "Area (km\u00b2)" = '565.39' AND "Population Density (per km 2 )" < '23.54' |
### Instruction:
CREATE TABLE table_11442 (
"NGC number" real,
"Object type" text,
"Constellation" text,
"Right ascension ( J2000 )" text,
"Declination ( J2000 )" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What Object Type has a 21h01m37.7s Righ... | SELECT "Object type" FROM table_11442 WHERE "NGC number" > '6995' AND "Right ascension ( J2000 )" = '21h01m37.7s' |
### Instruction:
CREATE TABLE table_66473 (
"Rank:" real,
"State:" text,
"Premier:" text,
"Party:" text,
"Assumed office:" text,
"Left office:" text,
"TOTAL Time in office:" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What average rank of... | SELECT AVG("Rank:") FROM table_66473 WHERE "State:" = 'nsw' AND "Party:" = 'liberalism' AND "Assumed office:" = '22 march 1877' |
### 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, Height FROM people ORDER BY Date_of_Birth |
### Instruction:
CREATE TABLE table_6261 (
"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 "Drawn" FROM table_6261 WHERE "Try bonus" = '5' AND "Points for" = '517' |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.