instruction stringlengths 151 7.46k | output stringlengths 2 4.44k | source stringclasses 26
values |
|---|---|---|
CREATE TABLE table_name_60 (
week INTEGER,
date VARCHAR,
attendance VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the latest week with a date of November 12, 1967 and less than 34,761 in attendance?
| SELECT MAX(week) FROM table_name_60 WHERE date = "november 12, 1967" AND attendance < 34 OFFSET 761 | sql_create_context |
CREATE TABLE table_name_79 (
decile INTEGER,
roll VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- For the roll of 651, what was the lowest Decile?
| SELECT MIN(decile) FROM table_name_79 WHERE roll = 651 | sql_create_context |
CREATE TABLE table_75565 (
"Name" text,
"Pada 1" text,
"Pada 2" text,
"Pada 3" text,
"Pada 4" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the Name of ng/na?
| SELECT "Name" FROM table_75565 WHERE "Pada 3" = 'ङ ng/na' | wikisql |
CREATE TABLE program_requirement (
program_id int,
category varchar,
min_credit int,
additional_req varchar
)
CREATE TABLE student (
student_id int,
lastname varchar,
firstname varchar,
program_id int,
declare_major varchar,
total_credit int,
total_gpa float,
entered_as ... | SELECT DISTINCT course.department, course.name, course.number, semester.semester FROM course, course_offering, semester WHERE course.course_id = course_offering.course_id AND course.department = 'department0' AND course.number BETWEEN 500 AND 500 + 100 AND semester.semester IN ('SP', 'SU', 'SS') AND semester.semester_i... | advising |
CREATE TABLE hz_info (
KH text,
KLX number,
RYBH text,
YLJGDM text
)
CREATE TABLE wdmzjzjlb (
CYBQDM text,
CYBQMC text,
CYCWH text,
CYKSDM text,
CYKSMC text,
CYSJ time,
CYZTDM number,
HZXM text,
JZKSDM text,
JZKSMC text,
JZLSH number,
KH text,
KLX num... | SELECT jyjgzbb.JCRGH, jyjgzbb.JCRXM FROM person_info JOIN hz_info JOIN mzjzjlb JOIN jybgb JOIN jyjgzbb ON person_info.RYBH = hz_info.RYBH AND hz_info.YLJGDM = mzjzjlb.YLJGDM AND hz_info.KH = mzjzjlb.KH AND hz_info.KLX = mzjzjlb.KLX AND mzjzjlb.YLJGDM = jybgb.YLJGDM_MZJZJLB AND mzjzjlb.JZLSH = jybgb.JZLSH_MZJZJLB AND jy... | css |
CREATE TABLE table_name_19 (
score VARCHAR,
partner VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the score when Mark parterned with lorenzo manta?
| SELECT score FROM table_name_19 WHERE partner = "lorenzo manta" | sql_create_context |
CREATE TABLE table_name_29 (
position VARCHAR,
nfl_club VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the position of the pittsburgh steelers?
| SELECT position FROM table_name_29 WHERE nfl_club = "pittsburgh steelers" | sql_create_context |
CREATE TABLE PostLinks (
Id number,
CreationDate time,
PostId number,
RelatedPostId number,
LinkTypeId number
)
CREATE TABLE PendingFlags (
Id number,
FlagTypeId number,
PostId number,
CreationDate time,
CloseReasonTypeId number,
CloseAsOffTopicReasonTypeId number,
Dupli... | SELECT 'http://chemistry.stackexchange.com/q/' + CAST(q.Id AS TEXT(10)) FROM Posts AS q WHERE q.PostTypeId = 1 ORDER BY q.Id | sede |
CREATE TABLE table_60681 (
"HD designation" text,
"Constellation" text,
"Distance ( ly )" real,
"Spectral type" text,
"Signal power ( kW )" real,
"Date sent" text,
"Arrival date" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is Date, w... | SELECT "Date sent" FROM table_60681 WHERE "Constellation" = 'delphinus' | wikisql |
CREATE TABLE table_70658 (
"Rank" text,
"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 value for Gold, when the value for Silver is greater than 2, and when th... | SELECT AVG("Gold") FROM table_70658 WHERE "Silver" > '2' AND "Nation" = 'west germany' | wikisql |
CREATE TABLE table_77120 (
"Day 1" text,
"Day 2" text,
"Day 3" text,
"Day 4" text,
"Day 5" text,
"Wednesday" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the day 1 when day 5 is math?
| SELECT "Day 1" FROM table_77120 WHERE "Day 5" = 'math' | wikisql |
CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
)
CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
C... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.dob_year < "2071" AND lab.itemid = "50953" | mimicsql_data |
CREATE TABLE table_67972 (
"Event" text,
"Time" text,
"Nationality" text,
"Date" text,
"Meet" text,
"Location" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- In what Location in the United States the Time 2:25.62?
| SELECT "Location" FROM table_67972 WHERE "Nationality" = 'united states' AND "Time" = '2:25.62' | wikisql |
CREATE TABLE table_name_63 (
length VARCHAR,
class VARCHAR,
date VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the length for all class and date of march 18
| SELECT length FROM table_name_63 WHERE class = "all" AND date = "march 18" | sql_create_context |
CREATE TABLE table_name_6 (
member VARCHAR,
party VARCHAR,
electorate VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which member of the National Party is from the Hinkler electorate?
| SELECT member FROM table_name_6 WHERE party = "national" AND electorate = "hinkler" | sql_create_context |
CREATE TABLE table_name_19 (
date VARCHAR,
home_team VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Date has a Home team of st kilda?
| SELECT date FROM table_name_19 WHERE home_team = "st kilda" | sql_create_context |
CREATE TABLE program_requirement (
program_id int,
category varchar,
min_credit int,
additional_req varchar
)
CREATE TABLE course (
course_id int,
name varchar,
department varchar,
number varchar,
credits varchar,
advisory_requirement varchar,
enforced_requirement varchar,
... | SELECT DISTINCT course.department, course.name, course.number, program_course.workload, program_course.workload FROM course, program_course WHERE program_course.category LIKE '%Other%' AND program_course.course_id = course.course_id AND program_course.workload = (SELECT MIN(PROGRAM_COURSEalias1.workload) FROM program_c... | advising |
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.expire_flag = "1" AND demographic.diagnosis = "MORBID OBESITY/SDA" | mimicsql_data |
CREATE TABLE table_15780049_6 (
score VARCHAR,
game VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the score of game 33?
| SELECT score FROM table_15780049_6 WHERE game = 33 | sql_create_context |
CREATE TABLE Badges (
Id number,
UserId number,
Name text,
Date time,
Class number,
TagBased boolean
)
CREATE TABLE PostsWithDeleted (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
View... | SELECT Posts.Id AS "post_link", Votes.BountyAmount AS "Bounty Amount", Votes.CreationDate AS "Bounty Creation Date" FROM Posts INNER JOIN Votes ON Votes.PostId = Posts.Id WHERE Votes.VoteTypeId = 8 ORDER BY Votes.BountyAmount DESC, Votes.CreationDate DESC | sede |
CREATE TABLE table_27767 (
"Series #" real,
"Season #" real,
"Title" text,
"Directed by" text,
"Written by" text,
"Original air date" text,
"Production code" real,
"U.S. viewers (millions)" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- ... | SELECT "Original air date" FROM table_27767 WHERE "U.S. viewers (millions)" = '5.30' | wikisql |
CREATE TABLE Reviewer (
rID int,
name text
)
CREATE TABLE Movie (
mID int,
title text,
year int,
director text
)
CREATE TABLE Rating (
rID int,
mID int,
stars int,
ratingDate date
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Ignor... | SELECT title, MAX(T1.stars) FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID WHERE director <> "null" GROUP BY title ORDER BY title | nvbench |
CREATE TABLE table_62036 (
"Year" real,
"Result" text,
"Matches" real,
"Wins" real,
"Draws" real,
"Losses" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the smallest Draws with a Result of runner-up, and Losses larger than 1?
| SELECT MIN("Draws") FROM table_62036 WHERE "Result" = 'runner-up' AND "Losses" > '1' | wikisql |
CREATE TABLE table_name_58 (
away_team VARCHAR,
home_team VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Away team score has a Home team of richmond?
| SELECT away_team AS score FROM table_name_58 WHERE home_team = "richmond" | sql_create_context |
CREATE TABLE table_8715 (
"Event" text,
"Record" text,
"Nationality" text,
"Date" text,
"Meet" text,
"Place" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what is the meet when the date is 3 august 2012?
| SELECT "Meet" FROM table_8715 WHERE "Date" = '3 august 2012' | wikisql |
CREATE TABLE table_10518 (
"Order" real,
"Name" text,
"Seasons" text,
"Games" real,
"Goals" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What seasons had 288 games and more than 100 goals?
| SELECT "Seasons" FROM table_10518 WHERE "Goals" > '100' AND "Games" = '288' | wikisql |
CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
language text,
religion text,
... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE diagnoses.short_title = "Other psoriasis" AND prescriptions.drug_type = "MAIN" | mimicsql_data |
CREATE TABLE Tasks (
task_id INTEGER,
project_id INTEGER,
task_details VARCHAR(255),
"eg Agree Objectives" VARCHAR(1)
)
CREATE TABLE Grants (
grant_id INTEGER,
organisation_id INTEGER,
grant_amount DECIMAL(19,4),
grant_start_date DATETIME,
grant_end_date DATETIME,
other_details ... | SELECT staff_details, COUNT(staff_details) FROM Research_Staff GROUP BY staff_details ORDER BY staff_details | nvbench |
CREATE TABLE patients (
row_id number,
subject_id number,
gender text,
dob time,
dod time
)
CREATE TABLE d_icd_procedures (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE labevents (
row_id number,
subject_id number,
hadm_id number,
... | SELECT COUNT(DISTINCT admissions.subject_id) FROM admissions WHERE admissions.hadm_id IN (SELECT transfers.hadm_id FROM transfers WHERE transfers.careunit = 'csru' AND STRFTIME('%y', transfers.intime) <= '2101') | mimic_iii |
CREATE TABLE table_name_49 (
player VARCHAR,
to_par VARCHAR,
score VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who is the player with an E to par and a 68-73-69=210?
| SELECT player FROM table_name_49 WHERE to_par = "e" AND score = 68 - 73 - 69 = 210 | sql_create_context |
CREATE TABLE Web_client_accelerator (
id int,
name text,
Operating_system text,
Client text,
Connection text
)
CREATE TABLE browser (
id int,
name text,
market_share real
)
CREATE TABLE accelerator_compatible_browser (
accelerator_id int,
browser_id int,
compatible_since_ye... | SELECT name, id FROM Web_client_accelerator AS T1 JOIN accelerator_compatible_browser AS T2 ON T2.accelerator_id = T1.id | nvbench |
CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.diagnosis = "CORONARY ARTERY DISEASE\CORONARY ARTERY BYPASS GRAFT; MYOMECTOMY/SDA" AND demographic.admityear < "2162" | mimicsql_data |
CREATE TABLE jyjgzbb (
BGDH text,
BGRQ time,
CKZFWDX text,
CKZFWSX number,
CKZFWXX number,
JCFF text,
JCRGH text,
JCRXM text,
JCXMMC text,
JCZBDM text,
JCZBJGDL number,
JCZBJGDW text,
JCZBJGDX text,
JCZBMC text,
JLDW text,
JYRQ time,
JYZBLSH text,
... | SELECT jyjgzbb.YQBH, jyjgzbb.YQMC FROM person_info JOIN hz_info JOIN mzjzjlb JOIN zyjybgb JOIN jyjgzbb ON person_info.RYBH = hz_info.RYBH AND hz_info.YLJGDM = mzjzjlb.YLJGDM AND hz_info.KH = mzjzjlb.KH AND hz_info.KLX = mzjzjlb.KLX AND mzjzjlb.YLJGDM = zyjybgb.YLJGDM_MZJZJLB AND mzjzjlb.JZLSH = zyjybgb.JZLSH_MZJZJLB AN... | css |
CREATE TABLE zyjzjlb (
CYBQDM text,
CYBQMC text,
CYCWH text,
CYKSDM text,
CYKSMC text,
CYSJ time,
CYZTDM number,
HZXM text,
JZKSDM text,
JZKSMC text,
JZLSH text,
KH text,
KLX number,
MZBMLX number,
MZJZLSH text,
MZZDBM text,
MZZDMC text,
MZZYZDZZBM... | SELECT jyjgzbb.JCRGH, jyjgzbb.JCRXM FROM person_info JOIN hz_info JOIN wdmzjzjlb JOIN jybgb JOIN jyjgzbb ON person_info.RYBH = hz_info.RYBH AND hz_info.YLJGDM = wdmzjzjlb.YLJGDM AND hz_info.KH = wdmzjzjlb.KH AND hz_info.KLX = wdmzjzjlb.KLX AND wdmzjzjlb.YLJGDM = jybgb.YLJGDM_MZJZJLB AND wdmzjzjlb.JZLSH = jybgb.JZLSH_MZ... | css |
CREATE TABLE jybgb (
BBCJBW text,
BBDM text,
BBMC text,
BBZT number,
BGDH text,
BGJGDM text,
BGJGMC text,
BGRGH text,
BGRQ time,
BGRXM text,
BGSJ time,
CJRQ time,
JSBBRQSJ time,
JSBBSJ time,
JYBBH text,
JYJGMC text,
JYJSGH text,
JYJSQM text,
JY... | SELECT jybgb.BGDH FROM person_info JOIN hz_info JOIN mzjzjlb JOIN jybgb ON person_info.RYBH = hz_info.RYBH AND hz_info.YLJGDM = mzjzjlb.YLJGDM AND hz_info.KH = mzjzjlb.KH AND hz_info.KLX = mzjzjlb.KLX AND mzjzjlb.YLJGDM = jybgb.YLJGDM_MZJZJLB AND mzjzjlb.JZLSH = jybgb.JZLSH_MZJZJLB WHERE person_info.XM = '韩志明' AND NOT ... | css |
CREATE TABLE table_64036 (
"Draw" real,
"Artist" text,
"Song" text,
"Percentage" text,
"Place" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who is the artist that drew higher than 4?
| SELECT "Artist" FROM table_64036 WHERE "Draw" > '4' | wikisql |
CREATE TABLE Apartment_Facilities (
apt_id INTEGER,
facility_code CHAR(15)
)
CREATE TABLE Apartment_Buildings (
building_id INTEGER,
building_short_name CHAR(15),
building_full_name VARCHAR(80),
building_description VARCHAR(255),
building_address VARCHAR(255),
building_manager VARCHAR(5... | SELECT booking_status_code, COUNT(*) FROM Apartment_Bookings GROUP BY booking_status_code | nvbench |
CREATE TABLE Votes (
Id number,
PostId number,
VoteTypeId number,
UserId number,
CreationDate time,
BountyAmount number
)
CREATE TABLE Users (
Id number,
Reputation number,
CreationDate time,
DisplayName text,
LastAccessDate time,
WebsiteUrl text,
Location text,
... | SELECT p.Id AS "post_link", p.LastActivityDate FROM Posts AS p INNER JOIN Comments AS c ON c.PostId = p.Id INNER JOIN Users AS u ON p.OwnerUserId = u.Id INNER JOIN PostHistory AS h ON p.Id = h.PostId WHERE c.UserId = '##USERID##' AND h.PostHistoryTypeId = '12' ORDER BY p.LastActivityDate DESC | sede |
CREATE TABLE table_name_25 (
song VARCHAR,
score VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- For which song was the score 6.5 + 6.0 + 6.0 + 5.5 = 24.0?
| SELECT song FROM table_name_25 WHERE score = 6.5 + 6.0 + 6.0 + 5.5 = 24.0 | sql_create_context |
CREATE TABLE lab (
labid number,
patientunitstayid number,
labname text,
labresult number,
labresulttime time
)
CREATE TABLE intakeoutput (
intakeoutputid number,
patientunitstayid number,
cellpath text,
celllabel text,
cellvaluenumeric number,
intakeoutputtime time
)
CREAT... | SELECT t1.drugstarttime FROM (SELECT patient.uniquepid, medication.drugstarttime FROM medication JOIN patient ON medication.patientunitstayid = patient.patientunitstayid WHERE medication.drugname = 'zofran' AND patient.uniquepid = '013-29301' AND DATETIME(medication.drugstarttime, 'start of year') = DATETIME(CURRENT_TI... | eicu |
CREATE TABLE vitalperiodic (
vitalperiodicid number,
patientunitstayid number,
temperature number,
sao2 number,
heartrate number,
respiration number,
systemicsystolic number,
systemicdiastolic number,
systemicmean number,
observationtime time
)
CREATE TABLE diagnosis (
diagn... | SELECT t1.treatmentname FROM (SELECT treatment.treatmentname, COUNT(treatment.treatmenttime) AS c1 FROM treatment WHERE treatment.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid ... | eicu |
CREATE TABLE comment_instructor (
instructor_id int,
student_id int,
score int,
comment_text varchar
)
CREATE TABLE offering_instructor (
offering_instructor_id int,
offering_id int,
instructor_id int
)
CREATE TABLE student_record (
student_id int,
course_id int,
semester int,
... | SELECT DISTINCT COURSE_0.department, COURSE_0.name, COURSE_0.number FROM course AS COURSE_0 INNER JOIN course_prerequisite ON COURSE_0.course_id = course_prerequisite.course_id INNER JOIN course AS COURSE_1 ON COURSE_1.course_id = course_prerequisite.pre_course_id WHERE COURSE_1.department = 'PAT' AND COURSE_1.number =... | advising |
CREATE TABLE Posts (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
ViewCount number,
Body text,
OwnerUserId number,
OwnerDisplayName text,
LastEditorUserId number,
LastEditorDisplayName text... | SELECT DATE(p.CreationDate) AS pdate, COUNT(*) AS nposts_per_day, SUM(p.ViewCount) AS nviews_per_day, SUM(p.ViewCount) / COUNT(*) AS view_post_ratio FROM Tags JOIN PostTags AS pt ON Tags.Id = pt.TagId JOIN Posts AS p ON pt.PostId = p.Id WHERE Tags.TagName = @TagName GROUP BY DATE(p.CreationDate) ORDER BY pdate DESC LIM... | sede |
CREATE TABLE table_name_57 (
played VARCHAR,
points_1 VARCHAR,
goals_for VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the played number with points 1 is 80, and goals for is more than 77?
| SELECT COUNT(played) FROM table_name_57 WHERE points_1 = "80" AND goals_for > 77 | sql_create_context |
CREATE TABLE regions (
REGION_ID decimal(5,0),
REGION_NAME varchar(25)
)
CREATE TABLE countries (
COUNTRY_ID varchar(2),
COUNTRY_NAME varchar(40),
REGION_ID decimal(10,0)
)
CREATE TABLE jobs (
JOB_ID varchar(10),
JOB_TITLE varchar(35),
MIN_SALARY decimal(6,0),
MAX_SALARY decimal(6,... | SELECT JOB_ID, AVG(MANAGER_ID) FROM employees WHERE FIRST_NAME LIKE '%D%' OR FIRST_NAME LIKE '%S%' GROUP BY JOB_ID ORDER BY AVG(MANAGER_ID) | nvbench |
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.
-- which paralymics year had the largest number of medals overall ?
| SELECT "event" FROM table_204_374 ORDER BY "total" DESC LIMIT 1 | squall |
CREATE TABLE table_dev_57 (
"id" int,
"intra_aortic_balloon_pump_iabp" bool,
"systolic_blood_pressure_sbp" int,
"heart_disease" bool,
"vasopressors" bool,
"temperature" float,
"creatinine_clearance_cl" float,
"cardiogenic_shock" bool,
"height" int,
"serum_creatinine" float,
"... | SELECT * FROM table_dev_57 WHERE serum_creatinine > 2 OR creatinine_clearance_cl <= 50 | criteria2sql |
CREATE TABLE Problem_Status_Codes (
problem_status_code VARCHAR(20),
problem_status_description VARCHAR(80)
)
CREATE TABLE Staff (
staff_id INTEGER,
staff_first_name VARCHAR(80),
staff_last_name VARCHAR(80),
other_staff_details VARCHAR(255)
)
CREATE TABLE Problems (
problem_id INTEGER,
... | SELECT COUNT(*), T1.product_id FROM Problems AS T1 JOIN Product AS T2 ON T1.product_id = T2.product_id GROUP BY T2.product_id | nvbench |
CREATE TABLE table_58479 (
"Driver" text,
"Constructor" text,
"Laps" real,
"Time/Retired" text,
"Grid" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the driver for Grid 8?
| SELECT "Driver" FROM table_58479 WHERE "Grid" = '8' | wikisql |
CREATE TABLE intakeoutput (
intakeoutputid number,
patientunitstayid number,
cellpath text,
celllabel text,
cellvaluenumeric number,
intakeoutputtime time
)
CREATE TABLE diagnosis (
diagnosisid number,
patientunitstayid number,
diagnosisname text,
diagnosistime time,
icd9cod... | SELECT COUNT(DISTINCT t1.uniquepid) FROM (SELECT patient.uniquepid, treatment.treatmenttime, patient.patienthealthsystemstayid FROM treatment JOIN patient ON treatment.patientunitstayid = patient.patientunitstayid WHERE treatment.treatmentname = 'pulmonary/ccm consultation' AND DATETIME(treatment.treatmenttime) <= DATE... | eicu |
CREATE TABLE SuggestedEditVotes (
Id number,
SuggestedEditId number,
UserId number,
VoteTypeId number,
CreationDate time,
TargetUserId number,
TargetRepChange number
)
CREATE TABLE Comments (
Id number,
PostId number,
Score number,
Text text,
CreationDate time,
UserD... | SELECT Posts.Id AS "post_link", Posts.OwnerUserId AS "user_link", Posts.Score, Posts.CreationDate, CASE WHEN Posts.PostTypeId = 2 THEN 'Answer' ELSE (CASE WHEN NOT Posts.ClosedDate IS NULL THEN 'Closed Question' ELSE 'Open Question' END) END AS "Post Type" FROM Posts JOIN PostTypes ON Posts.PostTypeId = PostTypes.Id OR... | sede |
CREATE TABLE basketball_match (
Team_ID int,
School_ID int,
Team_Name text,
ACC_Regular_Season text,
ACC_Percent text,
ACC_Home text,
ACC_Road text,
All_Games text,
All_Games_Percent int,
All_Home text,
All_Road text,
All_Neutral text
)
CREATE TABLE university (
Scho... | SELECT All_Neutral, ACC_Percent FROM basketball_match ORDER BY All_Neutral DESC | nvbench |
CREATE TABLE table_32942 (
"Player" text,
"Nationality" text,
"Position" text,
"From" text,
"School/Country" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the name of the player who begin playing for the LA Lakers in 1974?
| SELECT "Player" FROM table_32942 WHERE "From" = '1974' | wikisql |
CREATE TABLE job_history (
EMPLOYEE_ID decimal(6,0),
START_DATE date,
END_DATE date,
JOB_ID varchar(10),
DEPARTMENT_ID decimal(4,0)
)
CREATE TABLE regions (
REGION_ID decimal(5,0),
REGION_NAME varchar(25)
)
CREATE TABLE countries (
COUNTRY_ID varchar(2),
COUNTRY_NAME varchar(40),
... | SELECT HIRE_DATE, AVG(SALARY) FROM employees WHERE HIRE_DATE < '2002-06-21' ORDER BY AVG(SALARY) DESC | nvbench |
CREATE TABLE table_45355 (
"Rank" text,
"Badge/Serial Number" text,
"Tenure" text,
"Date of death" text,
"Cause of death" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the Rank of the Officer with Badge/Serial Number 11755 who died in Gunfi... | SELECT "Rank" FROM table_45355 WHERE "Cause of death" = 'gunfire' AND "Badge/Serial Number" = '11755' | wikisql |
CREATE TABLE jyjgzbb (
BGDH text,
BGRQ time,
CKZFWDX text,
CKZFWSX number,
CKZFWXX number,
JCFF text,
JCRGH text,
JCRXM text,
JCXMMC text,
JCZBDM text,
JCZBJGDL number,
JCZBJGDW text,
JCZBJGDX text,
JCZBMC text,
JLDW text,
JYRQ time,
JYZBLSH text,
... | SELECT * FROM hz_info JOIN mzjzjlb JOIN jybgb JOIN jyjgzbb ON hz_info.YLJGDM = mzjzjlb.YLJGDM AND hz_info.KH = mzjzjlb.KH AND hz_info.KLX = mzjzjlb.KLX AND mzjzjlb.YLJGDM = jybgb.YLJGDM_MZJZJLB AND mzjzjlb.JZLSH = jybgb.JZLSH_MZJZJLB AND jybgb.YLJGDM = jyjgzbb.YLJGDM AND jybgb.BGDH = jyjgzbb.BGDH WHERE hz_info.RYBH = '... | css |
CREATE TABLE diagnoses_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
CREATE TABLE icustays (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
first_careunit text,
last_careunit text,
first_wardid number,
... | SELECT DISTINCT cost.cost FROM cost WHERE cost.event_type = 'diagnoses_icd' AND cost.event_id IN (SELECT diagnoses_icd.row_id FROM diagnoses_icd WHERE diagnoses_icd.icd9_code = (SELECT d_icd_diagnoses.icd9_code FROM d_icd_diagnoses WHERE d_icd_diagnoses.short_title = 'poisoning-barbiturates')) | mimic_iii |
CREATE TABLE table_35262 (
"Nation" text,
"Gold" real,
"Silver" real,
"Bronze" real,
"Total" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Total of 3, and a Gold larger than 0, and a Nation of belarus, and a Silver larger than 2 has what sum of bro... | SELECT SUM("Bronze") FROM table_35262 WHERE "Total" = '3' AND "Gold" > '0' AND "Nation" = 'belarus' AND "Silver" > '2' | wikisql |
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE demographic.age < "48" AND prescriptions.route = "SL" | mimicsql_data |
CREATE TABLE t_kc21 (
CLINIC_ID text,
CLINIC_TYPE text,
COMP_ID text,
DATA_ID text,
DIFF_PLACE_FLG number,
FERTILITY_STS number,
FLX_MED_ORG_ID text,
HOSP_LEV number,
HOSP_STS number,
IDENTITY_CARD text,
INPT_AREA_BED text,
INSURED_IDENTITY number,
INSURED_STS text,
... | SELECT COUNT(*) FROM t_kc21 JOIN t_kc24 ON t_kc21.MED_CLINIC_ID = t_kc24.MED_CLINIC_ID WHERE t_kc21.PERSON_NM = '秦惜玉' AND t_kc24.CLINIC_SLT_DATE BETWEEN '2005-05-21' AND '2007-11-29' AND t_kc24.MED_AMOUT <= 10 | css |
CREATE TABLE table_name_25 (
overall INTEGER,
pick__number VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How much Overall has a Pick # of 26?
| SELECT SUM(overall) FROM table_name_25 WHERE pick__number = 26 | sql_create_context |
CREATE TABLE table_name_63 (
usn_2013 INTEGER,
cnn_2011 VARCHAR,
bw_2013 VARCHAR,
forbes_2011 VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the USN 2013 ranking with a BW 2013 ranking less than 1000, a Forbes 2011 ranking larger than 17, and... | SELECT SUM(usn_2013) FROM table_name_63 WHERE bw_2013 < 1000 AND forbes_2011 > 17 AND cnn_2011 < 13 | sql_create_context |
CREATE TABLE table_26479 (
"Episode #" real,
"Prod #" real,
"Title" text,
"Directed by" text,
"Written by" text,
"Originalairdate" text,
"Filmed" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many episodes have the title 'a perfect crim... | SELECT COUNT("Episode #") FROM table_26479 WHERE "Title" = 'A Perfect Crime' | wikisql |
CREATE TABLE table_45476 (
"Outcome" text,
"Date" text,
"Championship" 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 is the Date of the match with Opponent in the fin... | SELECT "Date" FROM table_45476 WHERE "Opponent in the final" = 'kenneth carlsen' | wikisql |
CREATE TABLE countries (
COUNTRY_ID varchar(2),
COUNTRY_NAME varchar(40),
REGION_ID decimal(10,0)
)
CREATE TABLE job_history (
EMPLOYEE_ID decimal(6,0),
START_DATE date,
END_DATE date,
JOB_ID varchar(10),
DEPARTMENT_ID decimal(4,0)
)
CREATE TABLE departments (
DEPARTMENT_ID decimal... | SELECT JOB_ID, MANAGER_ID FROM employees WHERE NOT DEPARTMENT_ID IN (SELECT DEPARTMENT_ID FROM departments WHERE MANAGER_ID BETWEEN 100 AND 200) ORDER BY JOB_ID DESC | nvbench |
CREATE TABLE table_48594 (
"Election" real,
"Leader" text,
"# of seats won" real,
"# of National votes" real,
"% of National vote" text,
"# of Prefectural votes" real,
"% of Prefectural vote" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Wh... | SELECT AVG("Election") FROM table_48594 WHERE "% of National vote" = '45.23%' AND "# of Prefectural votes" < '14,961,199' | wikisql |
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 questions for the... | SELECT T2.Founder, T1.Code FROM Products AS T1 JOIN Manufacturers AS T2 ON T1.Manufacturer = T2.Code GROUP BY T2.Founder ORDER BY T2.Founder DESC | nvbench |
CREATE TABLE table_name_74 (
tournament VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- WHAT IS THE 2011 PERFORMANCE AT THE MIAMI MASTERS?
| SELECT 2011 FROM table_name_74 WHERE tournament = "miami masters" | sql_create_context |
CREATE TABLE table_name_19 (
scoring_rank VARCHAR,
year VARCHAR,
events_played VARCHAR,
rank VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the Scoring rank when there are less than 21 events played with a rank of n/a in years less than 2011?... | SELECT scoring_rank FROM table_name_19 WHERE events_played < 21 AND rank = "n/a" AND year < 2011 | sql_create_context |
CREATE TABLE microlab (
microlabid number,
patientunitstayid number,
culturesite text,
organism text,
culturetakentime time
)
CREATE TABLE lab (
labid number,
patientunitstayid number,
labname text,
labresult number,
labresulttime time
)
CREATE TABLE cost (
costid number,
... | SELECT t1.treatmentname FROM (SELECT treatment.treatmentname, DENSE_RANK() OVER (ORDER BY COUNT(*) DESC) AS c1 FROM treatment WHERE treatment.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.age BETWEEN 30 AND 39) AND STRFTIME('%y', treatment.treatmenttime) = '2103' GROUP BY treatment.t... | eicu |
CREATE TABLE table_name_53 (
attendance INTEGER,
record VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the least attendance for 52-37 record
| SELECT MIN(attendance) FROM table_name_53 WHERE record = "52-37" | sql_create_context |
CREATE TABLE t_kc21_t_kc22 (
MED_CLINIC_ID text,
MED_EXP_DET_ID number
)
CREATE TABLE t_kc24 (
ACCOUNT_DASH_DATE time,
ACCOUNT_DASH_FLG number,
CASH_PAY number,
CIVIL_SUBSIDY number,
CKC102 number,
CLINIC_ID text,
CLINIC_SLT_DATE time,
COMP_ID text,
COM_ACC_PAY number,
C... | SELECT t_kc21.OUT_DIAG_DOC_CD, t_kc21.OUT_DIAG_DOC_NM FROM t_kc21 WHERE t_kc21.PERSON_ID = '18482943' GROUP BY t_kc21.OUT_DIAG_DOC_CD ORDER BY COUNT(*) DESC | css |
CREATE TABLE table_16094 (
"School Year" text,
"Class A" text,
"Class AA" text,
"Class AAA" text,
"Class AAAA" text,
"Class AAAAA" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who was Class AAA during the same year that Class AAAAA was Brownsv... | SELECT "Class AAA" FROM table_16094 WHERE "Class AAAAA" = 'Brownsville Pace' | wikisql |
CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
)
C... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE demographic.days_stay > "17" AND prescriptions.drug = "Potassium Phosphate" | mimicsql_data |
CREATE TABLE table_27833186_1 (
rider_names VARCHAR,
location VARCHAR,
horse_name VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who were the winning riders of the championship in Euer Valley, CA and whose horse was Magic Sirocco?
| SELECT rider_names FROM table_27833186_1 WHERE location = "Euer Valley, CA" AND horse_name = "Magic Sirocco" | sql_create_context |
CREATE TABLE table_14959246_2 (
attendance VARCHAR,
date VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the attendance at the game played on December 10, 1972?
| SELECT attendance FROM table_14959246_2 WHERE date = "December 10, 1972" | sql_create_context |
CREATE TABLE table_15187735_19 (
segment_c VARCHAR,
segment_b VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the segment C of the episode where segment B is Film Digitization?
| SELECT segment_c FROM table_15187735_19 WHERE segment_b = "Film Digitization" | sql_create_context |
CREATE TABLE table_66275 (
"Date Released" text,
"Polling institute" text,
"Social Democratic" text,
"Socialist" text,
"Green-Communist" text,
"People's Party" text,
"Left Bloc" text,
"Lead" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
--... | SELECT "Green-Communist" FROM table_66275 WHERE "Left Bloc" = '3.6%' | wikisql |
CREATE TABLE PostTypes (
Id number,
Name text
)
CREATE TABLE PostLinks (
Id number,
CreationDate time,
PostId number,
RelatedPostId number,
LinkTypeId number
)
CREATE TABLE PostNoticeTypes (
Id number,
ClassId number,
Name text,
Body text,
IsHidden boolean,
Predefin... | SELECT u.Id AS "user_link", u.Reputation AS Reputation FROM Posts AS p INNER JOIN Users AS u ON p.OwnerUserId = u.Id GROUP BY u.Id, u.Reputation HAVING SUM(p.Score * (1 - ABS(SIGN(p.PostTypeId - 2)))) < 100000 ORDER BY Reputation DESC LIMIT 100 | sede |
CREATE TABLE table_23286112_12 (
high_rebounds VARCHAR,
game VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who had the highest rebounds in game 2?
| SELECT high_rebounds FROM table_23286112_12 WHERE game = 2 | sql_create_context |
CREATE TABLE table_name_44 (
grid INTEGER,
time_retired VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the average grid for the +2.2 secs time/retired?
| SELECT AVG(grid) FROM table_name_44 WHERE time_retired = "+2.2 secs" | sql_create_context |
CREATE TABLE table_70328 (
"Tournament" text,
"2008" text,
"2010" text,
"2011" text,
"2012" text,
"2013" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the 2011 with 2010 of 2r
| SELECT "2011" FROM table_70328 WHERE "2010" = '2r' | wikisql |
CREATE TABLE t_kc24 (
MED_SAFE_PAY_ID text,
OVERALL_CD_ORG text,
OVERALL_CD_PERSON text,
MED_CLINIC_ID text,
REF_SLT_FLG number,
CLINIC_SLT_DATE time,
COMP_ID text,
PERSON_ID text,
FLX_MED_ORG_ID text,
INSU_TYPE text,
MED_AMOUT number,
PER_ACC_PAY number,
OVE_PAY numb... | SELECT MED_ORG_DEPT_NM, OUT_DIAG_DIS_NM, AVG(PERSON_AGE) FROM t_kc21 WHERE MED_SER_ORG_NO = '5033672' GROUP BY MED_ORG_DEPT_NM, OUT_DIAG_DIS_NM | css |
CREATE TABLE microbiologyevents (
row_id number,
subject_id number,
hadm_id number,
charttime time,
spec_type_desc text,
org_name text
)
CREATE TABLE chartevents (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
itemid number,
charttime time,
val... | SELECT prescriptions.startdate FROM prescriptions WHERE prescriptions.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 86555) AND prescriptions.route = 'po' ORDER BY prescriptions.startdate LIMIT 1 | mimic_iii |
CREATE TABLE vitalperiodic (
vitalperiodicid number,
patientunitstayid number,
temperature number,
sao2 number,
heartrate number,
respiration number,
systemicsystolic number,
systemicdiastolic number,
systemicmean number,
observationtime time
)
CREATE TABLE microlab (
microl... | SELECT SUM(intakeoutput.cellvaluenumeric) FROM intakeoutput WHERE intakeoutput.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '017-20711')) AND intakeoutput.celllabel = 'chest... | eicu |
CREATE TABLE course_offering (
offering_id int,
course_id int,
semester int,
section_number int,
start_time time,
end_time time,
monday varchar,
tuesday varchar,
wednesday varchar,
thursday varchar,
friday varchar,
saturday varchar,
sunday varchar,
has_final_proje... | SELECT DISTINCT course.department, course.name, course.number, instructor.name FROM course, course_offering, instructor, offering_instructor WHERE course.course_id = course_offering.course_id AND course.name LIKE '%Biochem Res-Med Stu%' AND NOT instructor.name LIKE '%Corrigan%' AND offering_instructor.instructor_id = i... | advising |
CREATE TABLE table_71744 (
"Position" text,
"Name" text,
"Party" text,
"First elected" real,
"District" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the total number of first elected for dranesville
| SELECT COUNT("First elected") FROM table_71744 WHERE "District" = 'dranesville' | wikisql |
CREATE TABLE PostTags (
PostId number,
TagId number
)
CREATE TABLE ReviewTaskTypes (
Id number,
Name text,
Description text
)
CREATE TABLE PostFeedback (
Id number,
PostId number,
IsAnonymous boolean,
VoteTypeId number,
CreationDate time
)
CREATE TABLE PostHistory (
Id num... | SELECT Id AS "post_link", OwnerDisplayName FROM Posts WHERE OwnerDisplayName = 'user121799' | sede |
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 questions for the... | SELECT T2.Name, T1.Code FROM Products AS T1 JOIN Manufacturers AS T2 ON T1.Manufacturer = T2.Code GROUP BY T2.Name ORDER BY T1.Code DESC | nvbench |
CREATE TABLE table_name_18 (
attendance INTEGER,
league_position VARCHAR,
opponents VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- When in the 1st league position, how many people watch as they faced West Ham United?
| SELECT MIN(attendance) FROM table_name_18 WHERE league_position = "1st" AND opponents = "west ham united" | sql_create_context |
CREATE TABLE PostNoticeTypes (
Id number,
ClassId number,
Name text,
Body text,
IsHidden boolean,
Predefined boolean,
PostNoticeDurationId number
)
CREATE TABLE PostTags (
PostId number,
TagId number
)
CREATE TABLE CloseAsOffTopicReasonTypes (
Id number,
IsUniversal boolean... | SELECT COUNT(P.ViewCount) FROM Posts AS P WHERE NOT P.Tags LIKE '%android%' | sede |
CREATE TABLE d_labitems (
row_id number,
itemid number,
label text
)
CREATE TABLE admissions (
row_id number,
subject_id number,
hadm_id number,
admittime time,
dischtime time,
admission_type text,
admission_location text,
discharge_location text,
insurance text,
lan... | SELECT COUNT(*) FROM inputevents_cv WHERE inputevents_cv.icustay_id IN (SELECT icustays.icustay_id FROM icustays WHERE icustays.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 26817)) AND inputevents_cv.itemid IN (SELECT d_items.itemid FROM d_items WHERE d_items.label = '.45ns flush'... | mimic_iii |
CREATE TABLE cost (
row_id number,
subject_id number,
hadm_id number,
event_type text,
event_id number,
chargetime time,
cost number
)
CREATE TABLE transfers (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
eventtype text,
careunit text,
war... | SELECT procedures_icd.charttime FROM procedures_icd WHERE procedures_icd.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 74159 AND NOT admissions.dischtime IS NULL ORDER BY admissions.admittime DESC LIMIT 1) ORDER BY procedures_icd.charttime DESC LIMIT 1 | mimic_iii |
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,
Unsure_rate re... | SELECT Sex, AVG(Height) FROM people GROUP BY Sex ORDER BY AVG(Height) | nvbench |
CREATE TABLE table_12562214_1 (
date__from_ VARCHAR,
date__to_ VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what is the date (from) where date (to) is 1919?
| SELECT date__from_ FROM table_12562214_1 WHERE date__to_ = "1919" | sql_create_context |
CREATE TABLE table_name_82 (
green_communist VARCHAR,
lead VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the green-communist with a 15.5% lead?
| SELECT green_communist FROM table_name_82 WHERE lead = "15.5%" | sql_create_context |
CREATE TABLE table_name_82 (
college_junior_club_team__league_ VARCHAR,
round INTEGER
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- WHAT IS THE LEAGUE WITH A ROUND LARGER THAN 6?
| SELECT college_junior_club_team__league_ FROM table_name_82 WHERE round > 6 | sql_create_context |
CREATE TABLE table_44690 (
"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 Rank of the Nation with more than 1 Gold and a more than 4 Total medals?
| SELECT SUM("Rank") FROM table_44690 WHERE "Gold" > '1' AND "Total" > '4' | wikisql |
CREATE TABLE table_name_19 (
attendance INTEGER,
result VARCHAR,
year VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the total attendance for a result of 7-23 before 1960?
| SELECT SUM(attendance) FROM table_name_19 WHERE result = "7-23" AND year < 1960 | sql_create_context |
CREATE TABLE table_name_8 (
constructor VARCHAR,
circuit VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the constructor where the circuit is Silverstone?
| SELECT constructor FROM table_name_8 WHERE circuit = "silverstone" | sql_create_context |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.