instruction stringlengths 212 6.3k | output stringlengths 6 2.03k |
|---|---|
### 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 MAX("current\ndistance") - MIN("current\ndistance") FROM table_203_56 |
### Instruction:
CREATE TABLE table_27812 (
"Position" real,
"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 for the tables provided ab... | SELECT "Elapsed time d:hh:mm:ss" FROM table_27812 WHERE "Yacht type" = 'Farr 65' |
### Instruction:
CREATE TABLE college (
College_ID int,
Name text,
Leader_Name text,
College_Location text
)
CREATE TABLE round (
Round_ID int,
Member_ID int,
Decoration_Theme text,
Rank_in_Round int
)
CREATE TABLE member (
Member_ID int,
Name text,
Country text,
Colleg... | SELECT Country, COUNT(*) FROM member GROUP BY Country ORDER BY COUNT(*) |
### 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 Name, Code FROM Products WHERE Price BETWEEN 60 AND 120 |
### Instruction:
CREATE TABLE table_73176 (
"Conventional" text,
"Sarikoli (in IPA )" text,
"Uyghur ( K\u0322ona Yezik\u0322 )" text,
"Uyghur ( Yen\u0261i Yezik\u0322 )" text,
"Chinese" text,
"Pinyin" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
... | SELECT "Pinyin" FROM table_73176 WHERE "Conventional" = 'Mazar' |
### Instruction:
CREATE TABLE member_of_club (
stuid number,
clubid number,
position text
)
CREATE TABLE club (
clubid number,
clubname text,
clubdesc text,
clublocation text
)
CREATE TABLE student (
stuid number,
lname text,
fname text,
age number,
sex text,
major ... | SELECT clublocation FROM club WHERE clubname = "Hopkins Student Enterprises" |
### Instruction:
CREATE TABLE table_203_741 (
id number,
"season" text,
"competition" text,
"round" text,
"opponent" text,
"home" text,
"away" text,
"aggregate" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- did they play austria wein be... | SELECT (SELECT id FROM table_203_741 WHERE "opponent" = 'austria wien') < (SELECT id FROM table_203_741 WHERE "opponent" = 'jeunesse esch') |
### Instruction:
CREATE TABLE table_916 (
"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 "Tries for" FROM table_916 WHERE "Points" = '70' |
### 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 Name, Height FROM people ORDER BY Height |
### Instruction:
CREATE TABLE table_44922 (
"Technology" text,
"Moving Parts" text,
"Room Temperature" text,
"Flammable" text,
"Toxic Materials" text,
"In production" text,
"Rare metals" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What's ... | SELECT "In production" FROM table_44922 WHERE "Toxic Materials" = 'yes' AND "Technology" = 'sodium-sulfur batteries' |
### Instruction:
CREATE TABLE manufacturers (
code number,
name text,
headquarter text,
founder text,
revenue number
)
CREATE TABLE products (
code number,
name text,
price number,
manufacturer number
)
-- Using valid SQLite, answer the following questions for the tables provided ... | SELECT AVG(T1.price), T2.name FROM products AS T1 JOIN manufacturers AS T2 ON T1.manufacturer = T2.code GROUP BY T2.name HAVING AVG(T1.price) >= 150 |
### Instruction:
CREATE TABLE table_203_322 (
id number,
"club" text,
"played" number,
"won" number,
"drawn" number,
"lost" number,
"points for" number,
"points against" number,
"bonus points" number,
"points" number
)
-- Using valid SQLite, answer the following questions for t... | SELECT "club" FROM table_203_322 WHERE "club" IN ('su agen', 'castres olympique') ORDER BY "points" DESC LIMIT 1 |
### Instruction:
CREATE TABLE table_35850 (
"Name" text,
"Hanzi" text,
"Hanyu Pinyin" text,
"Population (2010-11-01)" text,
"Area (km\u00b2)" text,
"Density (/km\u00b2)" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the Pinyin for the i... | SELECT "Hanyu Pinyin" FROM table_35850 WHERE "Density (/km\u00b2)" = '77' |
### Instruction:
CREATE TABLE table_train_236 (
"id" int,
"renal_disease" bool,
"creatinine_clearance_cl" float,
"estimated_glomerular_filtration_rate_egfr" int,
"hba1c" float,
"fbg" int,
"NOUSE" float
)
-- Using valid SQLite, answer the following questions for the tables provided above.
... | SELECT * FROM table_train_236 WHERE renal_disease = 1 AND creatinine_clearance_cl > 1.5 |
### Instruction:
CREATE TABLE table_1914 (
"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 provid... | SELECT COUNT("GEO ID") FROM table_1914 WHERE "Latitude" = '48.578664' |
### Instruction:
CREATE TABLE table_75508 (
"Season" text,
"Competition" text,
"Round" text,
"Club" text,
"Home result" text,
"Away result" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Away result of 1 1, and a Round of 1r, and a Season of 196... | SELECT "Club" FROM table_75508 WHERE "Away result" = '1–1' AND "Round" = '1r' AND "Season" = '1967-68' |
### Instruction:
CREATE TABLE table_41782 (
"Date" text,
"Score" text,
"Set 1" text,
"Set 2" text,
"Set 3" text,
"Set 4" text,
"Set 5" text,
"Total" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is Set 1, when Date is Jun 26, and w... | SELECT "Set 1" FROM table_41782 WHERE "Date" = 'jun 26' AND "Set 4" = '26-24' |
### Instruction:
CREATE TABLE table_19799 (
"Rank" real,
"Country" text,
"Miss Universe" real,
"1st Runner-up" real,
"2nd Runner-up" real,
"3rd Runner-up" real,
"4th Runner-up" real,
"Semifinalists" real,
"Total" real
)
-- Using valid SQLite, answer the following questions for the ... | SELECT MAX("Rank") FROM table_19799 WHERE "2nd Runner-up" = '6' |
### Instruction:
CREATE TABLE table_2761 (
"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 "Poles" FROM table_2761 WHERE "Avg. Start" = '4.7' |
### Instruction:
CREATE TABLE table_23556 (
"Year" real,
"Starts" real,
"Wins" 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 the tables provi... | SELECT "Team(s)" FROM table_23556 WHERE "Winnings" = '$2,605,05' |
### Instruction:
CREATE TABLE table_train_100 (
"id" int,
"systolic_blood_pressure_sbp" int,
"stroke" bool,
"body_weight" float,
"diastolic_blood_pressure_dbp" int,
"rosen_modified_hachinski_ischemic_score" int,
"body_mass_index_bmi" float,
"age" float,
"NOUSE" float
)
-- Using val... | SELECT * FROM table_train_100 WHERE stroke = 1 |
### Instruction:
CREATE TABLE table_15920 (
"Country ( exonym )" text,
"Capital ( exonym )" text,
"Country ( endonym )" text,
"Capital ( endonym )" text,
"Official or native language(s) (alphabet/script)" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
... | SELECT "Country ( exonym )" FROM table_15920 WHERE "Official or native language(s) (alphabet/script)" = 'Icelandic' |
### Instruction:
CREATE TABLE table_2681 (
"N" real,
"P" text,
"Name" text,
"EU" text,
"Country" text,
"Age" real,
"Type" text,
"Moving from" text,
"Transfer window" text,
"Ends" real,
"Transfer fee" text,
"Source" text
)
-- Using valid SQLite, answer the following ques... | SELECT COUNT("Ends") FROM table_2681 WHERE "Source" = 'Cardiff City' AND "P" = 'DF' |
### Instruction:
CREATE TABLE table_46860 (
"Province" text,
"Total" real,
"Hindu" real,
"% Hindu 2010" text,
"% Hindu 2000" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What % Hindu 2010 has a 0.01% % Hindu 2000, and a greater than 136 Hindu?
#... | SELECT "% Hindu 2010" FROM table_46860 WHERE "% Hindu 2000" = '0.01%' AND "Hindu" > '136' |
### Instruction:
CREATE TABLE table_9909 (
"Game" real,
"Date" text,
"Team" text,
"Score" text,
"High points" text,
"High assists" text,
"Location Attendance" text,
"Record" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Can you tell me ... | SELECT "Location Attendance" FROM table_9909 WHERE "High assists" = 'luke ridnour (10)' AND "Date" = 'december 3' |
### Instruction:
CREATE TABLE table_77970 (
"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 "Date" FROM table_77970 WHERE "Winning driver" = 'graham hill' AND "Circuit" = 'nürburgring' |
### Instruction:
CREATE TABLE table_77036 (
"Athlete" text,
"Event" text,
"100 m" real,
"400 m" real,
"110H" real,
"1500 m" text,
"Final" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the final for Mikalai Shubianok who had a 110H ... | SELECT SUM("Final") FROM table_77036 WHERE "Athlete" = 'mikalai shubianok' AND "110H" < '908' |
### Instruction:
CREATE TABLE table_name_31 (
fall_05 VARCHAR,
fall_09 VARCHAR,
states VARCHAR,
fall_08 VARCHAR,
fall_06 VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the sum amount of fall 05 when fall 08 is more than 5, fall 06 is more... | SELECT COUNT(fall_05) FROM table_name_31 WHERE fall_08 > 5 AND fall_06 > 7 AND states = "maryland" AND fall_09 > 471 |
### Instruction:
CREATE TABLE table_18208 (
"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.
-- how many district with candidates being eliot l. engel ... | SELECT COUNT("District") FROM table_18208 WHERE "Candidates" = 'Eliot L. Engel (D) 85.2% Martin Richman (R) 14.8%' |
### Instruction:
CREATE TABLE table_45970 (
"Round" real,
"Pick" real,
"Overall" real,
"Name" text,
"Position" text,
"College" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which player was drafted overall from the college of Nebraska in a roun... | SELECT "Name" FROM table_45970 WHERE "Overall" < '224' AND "Round" < '6' AND "Pick" = '15' AND "College" = 'nebraska' |
### 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, Price FROM Products WHERE Price BETWEEN 60 AND 120 |
### 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(Height) FROM people GROUP BY Sex |
### Instruction:
CREATE TABLE HOTELS (
star_rating_code VARCHAR,
price_range INTEGER
)
CREATE TABLE Ref_Hotel_Star_Ratings (
star_rating_description VARCHAR,
star_rating_code VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What are the star rating de... | SELECT T2.star_rating_description FROM HOTELS AS T1 JOIN Ref_Hotel_Star_Ratings AS T2 ON T1.star_rating_code = T2.star_rating_code WHERE T1.price_range > 10000 |
### Instruction:
CREATE TABLE table_15791 (
"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
)
-- Using valid SQLite, answer the following questions for... | SELECT "Points against" FROM table_15791 WHERE "Played" = '22' AND "Lost" = '6' |
### Instruction:
CREATE TABLE table_204_781 (
id number,
"name(s)" text,
"yard no." number,
"type (as built)" text,
"owner" text,
"imo number" number,
"laid down" text,
"launched" text,
"delivered/\ncommissioned" text,
"fate/\ndecommissioned" text,
"notes" text
)
-- Using v... | SELECT "owner" FROM table_204_781 WHERE id = 1 |
### Instruction:
CREATE TABLE table_76083 (
"Name" text,
"Year commissioned" real,
"Gross head (metres)" real,
"Installed capacity (megawatts)" real,
"Average annual output (million KWh)" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the Av... | SELECT AVG("Average annual output (million KWh)") FROM table_76083 WHERE "Name" = 'culligran' AND "Installed capacity (megawatts)" < '19' |
### Instruction:
CREATE TABLE table_872 (
"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 ab... | SELECT "Record" FROM table_872 WHERE "High points" = 'Dwyane Wade (27)' AND "Location Attendance" = 'ARCO Arena' |
### Instruction:
CREATE TABLE table_41127 (
"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.
-- Who had the lowest rank for a capacity of ... | SELECT MIN("Rank") FROM table_41127 WHERE "Capacity in use" = '197,13%' AND "Capacity" > '1,010,000' |
### Instruction:
CREATE TABLE table_24148 (
"Season" text,
"Games" real,
"Won" real,
"Lost" real,
"Tied" real,
"Points" real,
"Pct %" text,
"Goals For" real,
"Goals Against" real,
"Standing" text
)
-- Using valid SQLite, answer the following questions for the tables provided ab... | SELECT MAX("Goals For") FROM table_24148 WHERE "Pct %" = '0.604' |
### Instruction:
CREATE TABLE table_44171 (
"Rank" real,
"City" text,
"Province" text,
"Date of Official Foundation of Municipality" real,
"2006" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the highest Rank, when Date of Official Foundati... | SELECT MAX("Rank") FROM table_44171 WHERE "Date of Official Foundation of Municipality" = '1952' AND "2006" < '189120' |
### Instruction:
CREATE TABLE table_23779 (
"Epoch (UTC)" text,
"Periselene (km)" text,
"Aposelene (km)" text,
"Eccentricity" text,
"Inclination (deg) (to Moon equator)" text,
"Period (h)" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is e... | SELECT "Epoch (UTC)" FROM table_23779 WHERE "Periselene (km)" = '5,454.925' |
### Instruction:
CREATE TABLE table_204_651 (
id number,
"date" text,
"championship" text,
"location" text,
"category" text,
"surface" text,
"prev. result" text,
"prev. points" number,
"new points" number,
"outcome" text
)
-- Using valid SQLite, answer the following questions f... | SELECT "new points" - "prev. points" FROM table_204_651 WHERE "championship" = 'brisbane international' |
### Instruction:
CREATE TABLE table_58680 (
"County" text,
"Per capita income" text,
"Median household income" text,
"Median family income" text,
"Population" real,
"Number of households" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is th... | SELECT COUNT("Number of households") FROM table_58680 WHERE "Population" > '25,692' AND "Median household income" = '$51,914' |
### Instruction:
CREATE TABLE table_43963 (
"Bank type" text,
"Number of branches" real,
"On-site ATMs" real,
"Off-site ATMs" real,
"Total ATMs" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the minimum total ATMs with new private sector ba... | SELECT MIN("Total ATMs") FROM table_43963 WHERE "Bank type" = 'new private sector banks' AND "On-site ATMs" > '1883' |
### Instruction:
CREATE TABLE table_64291 (
"Year" real,
"Political Rights" real,
"Civil Liberties" real,
"Status" text,
"President" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- When the president was Yoweri Museveni, and the year was 1993, with r... | SELECT SUM("Civil Liberties") FROM table_64291 WHERE "Political Rights" = '6' AND "President" = 'yoweri museveni' AND "Year" = '1993' |
### Instruction:
CREATE TABLE table_11033 (
"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.
-- Where the home team score is 15... | SELECT "Away team score" FROM table_11033 WHERE "Home team score" = '15.19 (109)' AND "Away team" = 'footscray' |
### Instruction:
CREATE TABLE table_name_68 (
elevation_groundstation INTEGER,
slope_length VARCHAR,
capacity_in_persons_hour VARCHAR,
name_or_route VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which elevation groundstation has a capacity in person... | SELECT AVG(elevation_groundstation) FROM table_name_68 WHERE capacity_in_persons_hour > 820 AND name_or_route = "lager 1" AND slope_length < 336 |
### Instruction:
CREATE TABLE table_21064 (
"Team" text,
"P" real,
"W" real,
"D" real,
"L" real,
"Tries for" real,
"Tries against" real,
"Try diff" text,
"Points for" real,
"Points against" real,
"Points diff" text,
"Pts" real
)
-- Using valid SQLite, answer the followi... | SELECT MAX("Tries against") FROM table_21064 WHERE "Team" = 'Bridgend' |
### Instruction:
CREATE TABLE table_50985 (
"Poll Year" text,
"Winner" text,
"Second" text,
"Third" text,
"Fourth" text,
"Fifth" text,
"Sixth" text,
"Seventh" text,
"Eighth" text,
"Ninth" text,
"Tenth" text
)
-- Using valid SQLite, answer the following questions for the tab... | SELECT "Second" FROM table_50985 WHERE "Tenth" = 'dan black' |
### Instruction:
CREATE TABLE table_74094 (
"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 "Episode" FROM table_74094 WHERE "Official ITV1 HD rating (millions)" = '1.185' |
### Instruction:
CREATE TABLE school_bus (
school_id number,
driver_id number,
years_working number,
if_full_time others
)
CREATE TABLE school (
school_id number,
grade text,
school text,
location text,
type text
)
CREATE TABLE driver (
driver_id number,
name text,
part... | SELECT home_city FROM driver EXCEPT SELECT home_city FROM driver WHERE age > 40 |
### Instruction:
CREATE TABLE table_29518 (
"No. in series" real,
"No. in season" real,
"Title" text,
"Directed by" text,
"Written by" text,
"Original air date" text,
"U.S. viewers (millions)" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- L... | SELECT "No. in season" FROM table_29518 WHERE "Directed by" = 'Brad Tanenbaum' AND "No. in series" > '241.0' |
### Instruction:
CREATE TABLE table_70168 (
"Year" real,
"Team" text,
"Chassis" text,
"Engine" text,
"Points" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the total year with a Team of scuderia ferrari, an Engine of ferrari 106 2.5 l4, and... | SELECT SUM("Year") FROM table_70168 WHERE "Team" = 'scuderia ferrari' AND "Engine" = 'ferrari 106 2.5 l4' AND "Points" > '12' |
### Instruction:
CREATE TABLE roller_coaster (
roller_coaster_id number,
name text,
park text,
country_id number,
length number,
height number,
speed text,
opened text,
status text
)
CREATE TABLE country (
country_id number,
name text,
population number,
area number,... | SELECT status FROM roller_coaster WHERE length > 3300 OR height > 100 |
### Instruction:
CREATE TABLE table_21599 (
"Release" real,
"Title" text,
"Start" real,
"Pieces" real,
"Board (inches)" text,
"Board (cm)" text,
"Type" text,
"New units New units when compared to the original A&A: Classic version of the game." text,
"Playable Powers" text
)
-- Usin... | SELECT "Release" FROM table_21599 WHERE "Title" = 'Axis & Allies: D-Day' |
### Instruction:
CREATE TABLE table_31471 (
"Event" real,
"Circuit" text,
"GT3 Pro Cup Winner" text,
"GT3 Pro / Am Cup Winner" text,
"GT3 Citation Cup Winner" text,
"GT4 Cup Winner" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who are the gt3 ... | SELECT "GT3 Pro / Am Cup Winner" FROM table_31471 WHERE "GT3 Pro Cup Winner" = 'No. 1 Vita4One' |
### Instruction:
CREATE TABLE employee (
eid number,
name text,
salary number
)
CREATE TABLE aircraft (
aid number,
name text,
distance number
)
CREATE TABLE flight (
flno number,
origin text,
destination text,
distance number,
departure_date time,
arrival_date time,
... | SELECT flno, distance FROM flight ORDER BY price DESC LIMIT 1 |
### Instruction:
CREATE TABLE table_203_564 (
id number,
"hand" text,
"1 credit" number,
"2 credits" number,
"3 credits" number,
"4 credits" number,
"5 credits" number
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- is a 2 credit full house the sa... | SELECT (SELECT "2 credits" FROM table_203_564 WHERE "hand" = 'full house') = (SELECT "5 credits" FROM table_203_564 WHERE "hand" = 'three of a kind') |
### Instruction:
CREATE TABLE table_1900 (
"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 provid... | SELECT MIN("ANSI code") FROM table_1900 WHERE "Pop. (2010)" = '609' |
### Instruction:
CREATE TABLE table_4586 (
"Stage" text,
"Start time" text,
"Stage name" text,
"Distance" text,
"Winning driver" text,
"Time" text,
"Avg. Speed" text,
"Rally leader" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was... | SELECT "Time" FROM table_4586 WHERE "Distance" = '24.00km' AND "Start time" = '21:27' |
### Instruction:
CREATE TABLE table_67978 (
"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 7:00 has a 10:00 of dirty sexy money?
#... | SELECT "7:00" FROM table_67978 WHERE "10:00" = 'dirty sexy money' |
### Instruction:
CREATE TABLE table_204_200 (
id number,
"iso/iec standard" text,
"title" text,
"status" text,
"description" text,
"wg" number
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- which has the same wg as systems and software engineering - ... | SELECT "title" FROM table_204_200 WHERE "title" <> 'systems and software engineering - system life cycle processes' AND "wg" = (SELECT "wg" FROM table_204_200 WHERE "title" = 'systems and software engineering - system life cycle processes') |
### Instruction:
CREATE TABLE table_16678 (
"Source" text,
"Date" text,
"Method" text,
"iOS" text,
"Android" text,
"BlackBerry" text,
"Symbian / Series 40" text,
"Bada" text,
"Windows" text,
"Other" text
)
-- Using valid SQLite, answer the following questions for the tables pro... | SELECT "Other" FROM table_16678 WHERE "Symbian / Series 40" = '0.40%' |
### Instruction:
CREATE TABLE table_79258 (
"Railroad (quantity)" text,
"Class" text,
"Road numbers" text,
"Builder" text,
"Build year" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what is the road numbers when the builder is alco, the railroad (q... | SELECT "Road numbers" FROM table_79258 WHERE "Builder" = 'alco' AND "Railroad (quantity)" = 'union pacific railroad (105)' AND "Class" = 'csa-2' |
### Instruction:
CREATE TABLE table_12376 (
"Team" text,
"Wins" text,
"Losses" text,
"Points" text,
"WPct." text,
"G.F." text,
"G.A." text,
"Assists" text,
"Penalties" text,
"P.I.M." text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
--... | SELECT "Penalties" FROM table_12376 WHERE "G.F." = '40' |
### Instruction:
CREATE TABLE table_54026 (
"Date" text,
"Opponents" text,
"H / A" text,
"Result F\u2013A" text,
"Attendance" real,
"Group position" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which opponents have an Attendance larger than 61... | SELECT "Opponents" FROM table_54026 WHERE "Attendance" > '61,000' AND "Result F\u2013A" = '3–2' |
### Instruction:
CREATE TABLE table_19163 (
"School Name" text,
"City" text,
"Students" real,
"FTE Teachers" text,
"Pupil/Teacher Ratio" text,
"School Level" text,
"Low Grade" text,
"High Grade" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.... | SELECT "FTE Teachers" FROM table_19163 WHERE "Pupil/Teacher Ratio" = '19' |
### Instruction:
CREATE TABLE table_41809 (
"Year" real,
"Income" real,
"Expenditure" real,
"Surplus(Deficit)" text,
"% GDP" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which % GDP has an Expenditure larger than 50.9, and a Year larger than 2009,... | SELECT "% GDP" FROM table_41809 WHERE "Expenditure" > '50.9' AND "Year" > '2009' AND "Income" = '39.3' |
### Instruction:
CREATE TABLE table_3037 (
"Character" text,
"Original Berkeley Cast" text,
"Original Broadway Cast" text,
"Original 1st US Tour Cast" text,
"Original UK Cast" text,
"Original Tokyo / Seoul Tour Cast" text,
"Original 3rd US Tour Cast" text
)
-- Using valid SQLite, answer th... | SELECT COUNT("Original 3rd US Tour Cast") FROM table_3037 WHERE "Original UK Cast" = 'Alyssa DiPalma' |
### Instruction:
CREATE TABLE table_train_85 (
"id" int,
"mini_mental_state_examination_mmse" int,
"elevated_serum_phenylalanine" int,
"elevated_creatinine" float,
"renal_disease" bool,
"geriatric_depression_scale_gds" int,
"NOUSE" float
)
-- Using valid SQLite, answer the following questi... | SELECT * FROM table_train_85 WHERE mini_mental_state_examination_mmse < 25 |
### Instruction:
CREATE TABLE table_58033 (
"Round" real,
"Player" text,
"Nationality" text,
"NHL Team" text,
"College/Junior/Club Team (League)" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what is the college/junior/club team (league) when the r... | SELECT "College/Junior/Club Team (League)" FROM table_58033 WHERE "Round" > '2' AND "Player" = 'bert robertsson (d)' |
### Instruction:
CREATE TABLE table_18837 (
"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 for" FROM table_18837 WHERE "Points" = '53' |
### Instruction:
CREATE TABLE table_29391 (
"Province" text,
"Registered voters" real,
"People voted" real,
"Valid votes" real,
"Invalid votes" real,
"Yes" real,
"Yes (%)" text,
"No" real,
"No (%)" text,
"Turnout (%)" text
)
-- Using valid SQLite, answer the following questions... | SELECT MAX("Yes") FROM table_29391 WHERE "Yes (%)" = '95.17' |
### Instruction:
CREATE TABLE Scientists (
SSN int,
Name Char(30)
)
CREATE TABLE Projects (
Code Char(4),
Name Char(50),
Hours int
)
CREATE TABLE AssignedTo (
Scientist int,
Project char(4)
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What ar... | SELECT Name, COUNT(*) FROM Projects AS T1 JOIN AssignedTo AS T2 ON T1.Code = T2.Project GROUP BY T1.Name ORDER BY COUNT(*) |
### 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 People_ID, Height FROM people GROUP BY Sex |
### Instruction:
CREATE TABLE table_43243 (
"Team" text,
"Game 1" real,
"Game 2" real,
"Game 3" real,
"Game 4" real,
"Game 5" real,
"Game 6" text,
"Total" real,
"Average" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the gam... | SELECT SUM("Game 2") FROM table_43243 WHERE "Total" = '759,997' |
### Instruction:
CREATE TABLE table_203_656 (
id number,
"date" text,
"opponent" text,
"venue" text,
"result" text,
"scorers" text,
"report" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- previous to october 5 , 2008 how many matches were wo... | SELECT COUNT(*) FROM table_203_656 WHERE id < (SELECT id FROM table_203_656 WHERE "date" = 'october 5, 2008 - 15:00') AND "result" = 'won' |
### Instruction:
CREATE TABLE table_train_249 (
"id" int,
"gender" string,
"allergy_to_dapagliflozin" bool,
"body_weight" float,
"estimated_glomerular_filtration_rate_egfr" int,
"body_mass_index_bmi" float,
"age" float,
"NOUSE" float
)
-- Using valid SQLite, answer the following questi... | SELECT * FROM table_train_249 WHERE allergy_to_dapagliflozin = 1 |
### Instruction:
CREATE TABLE table_66321 (
"Producer" text,
"Product" text,
"Samples taken" real,
"Samples failed" real,
"Melamine content(mg/kg)" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What's the most melamine content that has more than 1 ... | SELECT MAX("Melamine content(mg/kg)") FROM table_66321 WHERE "Producer" = 'guangzhou jinding dairy products factory' AND "Samples failed" > '1' |
### Instruction:
CREATE TABLE table_204_628 (
id number,
"trial number" text,
"date" text,
"name of trial" text,
"celebrity/ies taking part" text,
"winner/number of stars" text,
"notes" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what cha... | SELECT "name of trial" FROM table_204_628 WHERE "date" > (SELECT "date" FROM table_204_628 WHERE "name of trial" = 'jungle falls') ORDER BY "date" LIMIT 1 |
### Instruction:
CREATE TABLE table_10816 (
"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.
-- In the game where the away team... | SELECT "Venue" FROM table_10816 WHERE "Crowd" > '25,000' AND "Away team" = 'carlton' |
### Instruction:
CREATE TABLE mountain (
id number,
name text,
height number,
prominence number,
range text,
country text
)
CREATE TABLE camera_lens (
id number,
brand text,
name text,
focal_length_mm number,
max_aperture number
)
CREATE TABLE photos (
id number,
ca... | SELECT MAX(height), AVG(height) FROM mountain |
### Instruction:
CREATE TABLE Course_Authors_and_Tutors (
address_line_1 VARCHAR,
author_id VARCHAR
)
CREATE TABLE Courses (
author_id VARCHAR,
course_name VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Find the addresses of the course authors who t... | SELECT T1.address_line_1 FROM Course_Authors_and_Tutors AS T1 JOIN Courses AS T2 ON T1.author_id = T2.author_id WHERE T2.course_name = "operating system" OR T2.course_name = "data structure" |
### Instruction:
CREATE TABLE table_27825 (
"Lighthouse" text,
"Location" text,
"Province/City" text,
"Date First Lit" text,
"Tower height in ft (m)" text,
"Focal plane in ft (m)" text,
"Current Status" text,
"Current Condition/ Description" text
)
-- Using valid SQLite, answer the fol... | SELECT "Province/City" FROM table_27825 WHERE "Lighthouse" = 'Corregidor Island (2)' |
### Instruction:
CREATE TABLE table_19185 (
"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 2000 carlton television... | SELECT "2000 ( Carlton Television )" FROM table_19185 WHERE "1951 ( BBC )" = 'John Stuart' |
### Instruction:
CREATE TABLE table_48537 (
"Gatchaman" text,
"Eagle Riders" text,
"Rank" text,
"Bird Uniform" text,
"Weapon" text,
"Mecha" text,
"Japanese voice actor" text,
"Voice actor (Eagle Riders)" text
)
-- Using valid SQLite, answer the following questions for the tables provid... | SELECT "Japanese voice actor" FROM table_48537 WHERE "Eagle Riders" = 'ollie keeawani' |
### Instruction:
CREATE TABLE table_20066 (
"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 MAX("V(mph)") FROM table_20066 WHERE "CHI" = '13.5' |
### Instruction:
CREATE TABLE table_27985 (
"Rnd" text,
"Circuit" text,
"Location" text,
"Date" text,
"Pole position" text,
"Fastest lap" text,
"Most laps led" text,
"Winning driver" text,
"Winning team" text,
"Supporting" text
)
-- Using valid SQLite, answer the following ques... | SELECT "Location" FROM table_27985 WHERE "Most laps led" = 'Patrick McKenna' |
### Instruction:
CREATE TABLE table_4388 (
"Party" text,
"Constituency" text,
"Election" real,
"Candidate" text,
"Votes" real,
"Percentage" real,
"Position" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What are the election totals for Davi... | SELECT COUNT("Election") FROM table_4388 WHERE "Candidate" = 'david cook' AND "Votes" = '6,963' AND "Percentage" > '21.3' |
### Instruction:
CREATE TABLE table_74258 (
"Year" real,
"Round" real,
"Winner" text,
"Hawthorn score" text,
"St Kilda score" text,
"Attendance" real,
"Venue" text,
"Silk-Miller Medallist" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- W... | SELECT "Attendance" FROM table_74258 WHERE "Hawthorn score" = '18.15.123' |
### Instruction:
CREATE TABLE college (
College_ID int,
Name text,
Leader_Name text,
College_Location text
)
CREATE TABLE round (
Round_ID int,
Member_ID int,
Decoration_Theme text,
Rank_in_Round int
)
CREATE TABLE member (
Member_ID int,
Name text,
Country text,
Colleg... | SELECT Country, COUNT(Country) FROM member GROUP BY Country ORDER BY COUNT(Country) |
### Instruction:
CREATE TABLE table_54159 (
"Outcome" text,
"Date" text,
"Tournament" text,
"Surface" text,
"Opponent in the final" text,
"Score in the final" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the date when Steffi Graf was ... | SELECT "Date" FROM table_54159 WHERE "Opponent in the final" = 'steffi graf' AND "Score in the final" = '2–6, 0–6' |
### Instruction:
CREATE TABLE table_name_97 (
preliminaries VARCHAR,
interview VARCHAR,
state VARCHAR,
evening_gown VARCHAR,
average VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the preliminaries of the contestant from Massachusetts wit... | SELECT COUNT(preliminaries) FROM table_name_97 WHERE evening_gown > 8.631 AND average < 8.791 AND state = "massachusetts" AND interview > 8.608 |
### Instruction:
CREATE TABLE school (
school_id number,
grade text,
school text,
location text,
type text
)
CREATE TABLE school_bus (
school_id number,
driver_id number,
years_working number,
if_full_time others
)
CREATE TABLE driver (
driver_id number,
name text,
part... | SELECT party FROM driver WHERE home_city = 'Hartford' AND age > 40 |
### Instruction:
CREATE TABLE table_28430 (
"Specimen weight/size" text,
"Calculated activity ( Bq )" real,
"Calculated activity ( Ci )" text,
"Estimated activity GR(api)" text,
"Estimated exposure ( mRem )/hr*" text
)
-- Using valid SQLite, answer the following questions for the tables provided a... | SELECT COUNT("Specimen weight/size") FROM table_28430 WHERE "Estimated exposure ( mRem )/hr*" = '0.28' |
### Instruction:
CREATE TABLE table_7917 (
"Rank" real,
"Company" text,
"Headquarters" text,
"Industry" text,
"Sales (billion $)" real,
"Profits (billion $)" real,
"Assets (billion $)" real,
"Market Value (billion $)" real
)
-- Using valid SQLite, answer the following questions for the... | SELECT MIN("Profits (billion $)") FROM table_7917 WHERE "Rank" = '6' |
### Instruction:
CREATE TABLE table_59555 (
"Season" real,
"Year" real,
"Mole" text,
"Winner" text,
"Runner-up" text,
"Total prize money" text,
"Potential prize money" text,
"Destination" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Wh... | SELECT "Runner-up" FROM table_59555 WHERE "Season" > '2' AND "Total prize money" = '$108,000' |
### Instruction:
CREATE TABLE table_6930 (
"Name" text,
"Overs Bowled" real,
"Maidens" real,
"Runs Conceded" real,
"Wickets" real,
"Extras" real,
"E.R." real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the average Extras for Muttiah Mu... | SELECT AVG("Extras") FROM table_6930 WHERE "Name" = 'muttiah muralitharan' AND "Runs Conceded" < '353' |
### Instruction:
CREATE TABLE table_3819 (
"No. in series" text,
"No. in season" text,
"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 t... | SELECT COUNT("No. in series") FROM table_3819 WHERE "U.S. viewers (millions)" = '5.2' |
### Instruction:
CREATE TABLE table_62420 (
"Pick #" real,
"Player" text,
"Nationality" text,
"Position" text,
"Team from" text,
"League from" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Pick # has a League from of ontario hockey league... | SELECT COUNT("Pick #") FROM table_62420 WHERE "League from" = 'ontario hockey league' AND "Nationality" = 'united states' AND "Team from" = 'brampton battalion' |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.