instruction stringlengths 151 7.46k | output stringlengths 2 4.44k | source stringclasses 26
values |
|---|---|---|
CREATE TABLE table_66564 (
"Pick" real,
"Team" text,
"Player" text,
"Position" text,
"College" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the position of the player with a pick less than 3 from team san diego?
| SELECT "Position" FROM table_66564 WHERE "Pick" < '3' AND "Team" = 'san diego' | wikisql |
CREATE TABLE schedule (
Cinema_ID int,
Film_ID int,
Date text,
Show_times_per_day int,
Price float
)
CREATE TABLE cinema (
Cinema_ID int,
Name text,
Openning_year int,
Capacity int,
Location text
)
CREATE TABLE film (
Film_ID int,
Rank_in_series int,
Number_in_seaso... | SELECT Directed_by, COUNT(*) FROM film GROUP BY Directed_by ORDER BY COUNT(*) | nvbench |
CREATE TABLE table_15824796_3 (
title VARCHAR,
original_air_date VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the title of the first episode of the season that begin on february 27, 1954?
| SELECT title FROM table_15824796_3 WHERE original_air_date = "February 27, 1954" | sql_create_context |
CREATE TABLE table_61408 (
"Year (Ceremony)" text,
"Film title used in nomination" text,
"Original title" text,
"Director" text,
"Result" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the Original Title of the movie directed by Aigars Graub... | SELECT "Original title" FROM table_61408 WHERE "Director" = 'aigars grauba' | wikisql |
CREATE TABLE table_name_95 (
result VARCHAR,
week VARCHAR,
opponent VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the result for the game before week 7 against BYE?
| SELECT result FROM table_name_95 WHERE week < 7 AND opponent = "bye" | sql_create_context |
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 medication (
medi... | SELECT COUNT(DISTINCT patient.patientunitstayid) FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '010-9756') AND DATETIME(patient.unitadmittime) >= DATETIME(CURRENT_TIME(), '-2 year') | eicu |
CREATE TABLE table_69298 (
"Name" text,
"Years" text,
"Gender" text,
"Area" text,
"Authority" text,
"Decile" real,
"Roll" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the roll number of the school in Aramoho with a decile of 1?
| SELECT "Roll" FROM table_69298 WHERE "Area" = 'aramoho' AND "Decile" = '1' | wikisql |
CREATE TABLE Comments (
Id number,
PostId number,
Score number,
Text text,
CreationDate time,
UserDisplayName text,
UserId number,
ContentLicense text
)
CREATE TABLE PostNoticeTypes (
Id number,
ClassId number,
Name text,
Body text,
IsHidden boolean,
Predefined b... | SELECT Id, Title, Tags, CreationDate, Score, ViewCount, OwnerUserId, OwnerDisplayName, LastActivityDate, Tags, AnswerCount, CommentCount FROM Posts WHERE CreationDate BETWEEN '2019-04-01 00:00:00' AND '2019-06-01 00:00:00' AND (Title LIKE '%misspelling%') AND ViewCount <= 0 AND PostTypeId = 1 | sede |
CREATE TABLE lab (
labid number,
patientunitstayid number,
labname text,
labresult number,
labresulttime time
)
CREATE TABLE vitalperiodic (
vitalperiodicid number,
patientunitstayid number,
temperature number,
sao2 number,
heartrate number,
respiration number,
systemics... | SELECT patient.age FROM patient WHERE patient.uniquepid = '015-100195' AND NOT patient.hospitaldischargetime IS NULL ORDER BY patient.hospitaladmittime LIMIT 1 | eicu |
CREATE TABLE t_kc21_t_kc24 (
MED_CLINIC_ID text,
MED_SAFE_PAY_ID number
)
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... | SELECT AVG(t_kc24.MED_AMOUT) FROM t_kc24 WHERE t_kc21_t_kc24.MED_CLINIC_ID IN (SELECT t_kc21.MED_CLINIC_ID FROM t_kc21 WHERE t_kc21.PERSON_AGE >= 20) | css |
CREATE TABLE table_56179 (
"Name" text,
"Location" text,
"Elevation + Height" text,
"Delivery" text,
"Purpose" text,
"Yield" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the yield for a blast that was in nts area 3s?
| SELECT "Yield" FROM table_56179 WHERE "Location" = 'nts area 3s' | wikisql |
CREATE TABLE table_4715 (
"Round" real,
"Overall" real,
"Player" text,
"Position" text,
"School/Club Team" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What total number of Overalls has a round that was smaller than 1?
| SELECT COUNT("Overall") FROM table_4715 WHERE "Round" < '1' | wikisql |
CREATE TABLE table_5332 (
"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 above.
-- Which jun... | SELECT "Junior High School (12\u201315 yrs)" FROM table_5332 WHERE "Gender" = 'male and female' | wikisql |
CREATE TABLE t_kc21 (
MED_CLINIC_ID text,
OVERALL_CD_ORG text,
OVERALL_CD_PERSON text,
COMP_ID text,
PERSON_ID text,
PERSON_NM text,
IDENTITY_CARD text,
SOC_SRT_CARD text,
PERSON_SEX number,
PERSON_AGE number,
IN_HOSP_DATE time,
OUT_HOSP_DATE time,
DIFF_PLACE_FLG numb... | SELECT COUNT(*) FROM t_kc21 JOIN t_kc22 ON t_kc21.MED_CLINIC_ID = t_kc22.MED_CLINIC_ID WHERE t_kc21.PERSON_NM = '姜承运' AND t_kc22.STA_DATE BETWEEN '2008-03-30' AND '2021-02-01' AND t_kc22.SOC_SRT_DIRE_CD = '4940' | 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 hz_info_mzjzjlb.YLJGDM FROM person_info JOIN hz_info JOIN mzjzjlb JOIN hz_info_mzjzjlb ON person_info.RYBH = hz_info.RYBH AND hz_info.YLJGDM = hz_info_mzjzjlb.YLJGDM AND hz_info.KH = mzjzjlb.KH AND hz_info.KLX = mzjzjlb.KLX AND hz_info_mzjzjlb.JZLSH = mzjzjlb.JZLSH AND hz_info_mzjzjlb.YLJGDM = hz_info_mzjzjlb.YL... | css |
CREATE TABLE table_name_43 (
lane INTEGER,
time VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What lane did the swimmer with a time of 52.84 have?
| SELECT MAX(lane) FROM table_name_43 WHERE time = 52.84 | sql_create_context |
CREATE TABLE table_18882 (
"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 above.
-- How ma... | SELECT COUNT("Record") FROM table_18882 WHERE "Date" = 'January 14' | wikisql |
CREATE TABLE person_info (
CSD text,
CSRQ time,
GJDM text,
GJMC text,
JGDM text,
JGMC text,
MZDM text,
MZMC text,
RYBH text,
XBDM number,
XBMC text,
XLDM text,
XLMC text,
XM text,
ZYLBDM text,
ZYMC text
)
CREATE TABLE jybgb (
BBCJBW text,
BBDM tex... | SELECT jyjgzbb.YQBH, jyjgzbb.YQMC 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.BG... | css |
CREATE TABLE table_name_3 (
cars_per_set INTEGER,
operator VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Tell me the sum of cars per set for operator of london midland
| SELECT SUM(cars_per_set) FROM table_name_3 WHERE operator = "london midland" | sql_create_context |
CREATE TABLE table_25675509_1 (
latitude VARCHAR,
time__utc_ VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- At what latitude did the shock at time 13:10:02 occur?
| SELECT latitude FROM table_25675509_1 WHERE time__utc_ = "13:10:02" | sql_create_context |
CREATE TABLE jyjgzbb (
JYZBLSH text,
YLJGDM text,
BGDH text,
BGRQ time,
JYRQ time,
JCRGH text,
JCRXM text,
SHRGH text,
SHRXM text,
JCXMMC text,
JCZBDM text,
JCFF text,
JCZBMC text,
JCZBJGDX text,
JCZBJGDL number,
JCZBJGDW text,
SBBM text,
YQBH text... | SELECT mzjzjlb.JZLSH FROM person_info JOIN hz_info JOIN mzjzjlb 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 WHERE person_info.XM = '韦坚秉' AND NOT mzjzjlb.JZLSH IN (SELECT JZLSH FROM jybgb WHERE BGRQ >= '2001-02-23') | css |
CREATE TABLE table_name_90 (
fa_cup_apps VARCHAR,
total_goals VARCHAR,
fa_cup_goals VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which FA Cup Apps have Total Goals larger than 6, and an FA Cup Goals smaller than 1?
| SELECT fa_cup_apps FROM table_name_90 WHERE total_goals > 6 AND fa_cup_goals < 1 | sql_create_context |
CREATE TABLE patient (
uniquepid text,
patienthealthsystemstayid number,
patientunitstayid number,
gender text,
age text,
ethnicity text,
hospitalid number,
wardid number,
admissionheight number,
admissionweight number,
dischargeweight number,
hospitaladmittime time,
... | SELECT 1 * (STRFTIME('%j', CURRENT_TIME()) - STRFTIME('%j', treatment.treatmenttime)) FROM treatment WHERE treatment.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '012-37411'... | eicu |
CREATE TABLE table_26986076_7 (
rider VARCHAR,
tues_24_aug VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who had the time of 22' 09.44 93.840mph on Tuesday August 24th?
| SELECT rider FROM table_26986076_7 WHERE tues_24_aug = "22' 09.44 93.840mph" | sql_create_context |
CREATE TABLE table_name_66 (
title VARCHAR,
director VARCHAR,
year VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What title was directed by Raoul Walsh later than 1945?
| SELECT title FROM table_name_66 WHERE director = "raoul walsh" AND year > 1945 | sql_create_context |
CREATE TABLE rental (
staff_id VARCHAR,
customer_id VARCHAR
)
CREATE TABLE customer (
customer_id VARCHAR,
first_name VARCHAR,
last_name VARCHAR
)
CREATE TABLE staff (
first_name VARCHAR,
last_name VARCHAR,
staff_id VARCHAR
)
-- Using valid SQLite, answer the following questions for ... | SELECT DISTINCT T1.first_name, T1.last_name FROM staff AS T1 JOIN rental AS T2 ON T1.staff_id = T2.staff_id JOIN customer AS T3 ON T2.customer_id = T3.customer_id WHERE T3.first_name = 'APRIL' AND T3.last_name = 'BURNS' | sql_create_context |
CREATE TABLE table_39067 (
"Week" real,
"Date" text,
"Opponent" text,
"Result" text,
"Game site" text,
"Record" text,
"Attendance" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the record in a week less than 13 on November 9, 2003?... | SELECT "Record" FROM table_39067 WHERE "Week" < '13' AND "Date" = 'november 9, 2003' | wikisql |
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 Affiliation, SUM(Enrollment) FROM university WHERE Founded > 1850 GROUP BY Affiliation | nvbench |
CREATE TABLE table_204_678 (
id number,
"record" text,
"athlete" text,
"nation" text,
"venue" text,
"date" text,
"#" number
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- which nation has set the record the most times ?
| SELECT "nation" FROM table_204_678 GROUP BY "nation" ORDER BY COUNT(*) DESC LIMIT 1 | squall |
CREATE TABLE table_19871 (
"Eviction No." real,
"Nominee" text,
"Vote to Save" text,
"Vote to Evict" text,
"Net vote" text,
"Eviction result" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many nominee's had a vote to evict percentage of 3.9... | SELECT COUNT("Nominee") FROM table_19871 WHERE "Vote to Evict" = '3.92%' | wikisql |
CREATE TABLE CHARACTERISTICS (
characteristic_id VARCHAR,
characteristic_name VARCHAR
)
CREATE TABLE products (
product_id VARCHAR,
color_code VARCHAR
)
CREATE TABLE ref_colors (
color_code VARCHAR,
color_description VARCHAR
)
CREATE TABLE product_characteristics (
product_id VARCHAR,
... | SELECT product_name FROM products AS t1 JOIN product_characteristics AS t2 ON t1.product_id = t2.product_id JOIN CHARACTERISTICS AS t3 ON t2.characteristic_id = t3.characteristic_id JOIN ref_colors AS t4 ON t1.color_code = t4.color_code WHERE t4.color_description = "red" AND t3.characteristic_name = "fast" | sql_create_context |
CREATE TABLE table_2387790_2 (
position VARCHAR,
year VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What position did he finish in 1987?
| SELECT position FROM table_2387790_2 WHERE year = 1987 | sql_create_context |
CREATE TABLE requirement (
requirement_id int,
requirement varchar,
college varchar
)
CREATE TABLE comment_instructor (
instructor_id int,
student_id int,
score int,
comment_text varchar
)
CREATE TABLE student_record (
student_id int,
course_id int,
semester int,
grade varc... | SELECT DISTINCT instructor.name FROM course, course_offering, instructor, offering_instructor WHERE course.course_id = course_offering.course_id AND course.department = 'EECS' AND course.number = 385 AND NOT instructor.name LIKE '%Harun Echols%' AND offering_instructor.instructor_id = instructor.instructor_id AND offer... | advising |
CREATE TABLE member (
Member_ID int,
Member_Name text,
Party_ID text,
In_office text
)
CREATE TABLE party_events (
Event_ID int,
Event_Name text,
Party_ID int,
Member_in_charge_ID int
)
CREATE TABLE party (
Party_ID int,
Minister text,
Took_office text,
Left_office text... | SELECT Left_office, COUNT(Left_office) FROM party GROUP BY Minister ORDER BY COUNT(Left_office) | nvbench |
CREATE TABLE table_36848 (
"Year" real,
"Award Ceremony" text,
"Category" text,
"Nominee" text,
"Result" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What year is associated with a drama desk award ceremony and a Category of outstanding featured a... | SELECT AVG("Year") FROM table_36848 WHERE "Award Ceremony" = 'drama desk award' AND "Category" = 'outstanding featured actress in a musical' | wikisql |
CREATE TABLE person_info (
CSD text,
CSRQ time,
GJDM text,
GJMC text,
JGDM text,
JGMC text,
MZDM text,
MZMC text,
RYBH text,
XBDM number,
XBMC text,
XLDM text,
XLMC text,
XM text,
ZYLBDM text,
ZYMC text
)
CREATE TABLE jybgb_jyjgzbb (
JYZBLSH number,
... | SELECT * FROM hz_info JOIN mzjzjlb JOIN jybgb JOIN jyjgzbb JOIN jybgb_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 = jybgb_jyjgzbb.YLJGDM AND jybgb.BGDH = jyjgzbb.BG... | css |
CREATE TABLE table_69900 (
"Heat" real,
"Lane" real,
"Name" text,
"Nationality" text,
"Time" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- At time 15:29.69 what was the heat?
| SELECT "Heat" FROM table_69900 WHERE "Time" = '15:29.69' | wikisql |
CREATE TABLE workshop (
workshop_id number,
date text,
venue text,
name text
)
CREATE TABLE submission (
submission_id number,
scores number,
author text,
college text
)
CREATE TABLE acceptance (
submission_id number,
workshop_id number,
result text
)
-- Using valid SQLit... | SELECT date, venue FROM workshop ORDER BY venue | spider |
CREATE TABLE t_kc22 (
MED_EXP_DET_ID text,
OVERALL_CD_ORG text,
OVERALL_CD_PERSON text,
MED_CLINIC_ID text,
MED_EXP_BILL_ID text,
SOC_SRT_DIRE_CD text,
SOC_SRT_DIRE_NM text,
DIRE_TYPE number,
CHA_ITEM_LEV number,
MED_INV_ITEM_TYPE text,
MED_DIRE_CD text,
MED_DIRE_NM text,... | SELECT t_kc22.SOC_SRT_DIRE_CD, t_kc22.SOC_SRT_DIRE_NM FROM t_kc21 JOIN t_kc22 ON t_kc21.MED_CLINIC_ID = t_kc22.MED_CLINIC_ID WHERE t_kc21.IN_DIAG_DIS_NM = '躁狂抑郁性精神病当前为抑郁相' | css |
CREATE TABLE table_36690 (
"Rank" real,
"Name" text,
"Height* m (ft)" text,
"Floors" real,
"Year* (est.)" text,
"City" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many floors were there with a building rank of less than 3 and a height of ... | SELECT COUNT("Floors") FROM table_36690 WHERE "Height* m (ft)" = '300 / 985' AND "Rank" < '3' | wikisql |
CREATE TABLE table_name_98 (
title VARCHAR,
rank VARCHAR,
director VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- WHAT IS THE TITLE THAT HAS A RANK BIGGER THAN 10, FOR DIRECTOR WALTER HILL?
| SELECT title FROM table_name_98 WHERE rank > 10 AND director = "walter hill" | sql_create_context |
CREATE TABLE routes (
rid number,
dst_apid number,
dst_ap text,
src_apid number,
src_ap text,
alid number,
airline text,
codeshare text
)
CREATE TABLE airports (
apid number,
name text,
city text,
country text,
x number,
y number,
elevation number,
iata t... | SELECT name, city, country, elevation FROM airports WHERE city = 'New York' | spider |
CREATE TABLE table_name_36 (
week_1_aug_26 VARCHAR,
week_7_oct_6 VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is listed for the Week 1 Aug 26 that has a Week 7 Oct 6 of USC (3-2)?
| SELECT week_1_aug_26 FROM table_name_36 WHERE week_7_oct_6 = "usc (3-2)" | sql_create_context |
CREATE TABLE table_203_784 (
id number,
"no. in\nseries" number,
"no. in\nseason" number,
"performer" text,
"appearance" text,
"air date" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what is the name of the last performer on this chart ?
| SELECT "performer" FROM table_203_784 ORDER BY id DESC LIMIT 1 | squall |
CREATE TABLE table_47692 (
"Rider" text,
"Manufacturer" text,
"Laps" real,
"Time" text,
"Grid" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Laps have a Time of +39.476, and a Grid larger than 11?
| SELECT AVG("Laps") FROM table_47692 WHERE "Time" = '+39.476' AND "Grid" > '11' | wikisql |
CREATE TABLE TagSynonyms (
Id number,
SourceTagName text,
TargetTagName text,
CreationDate time,
OwnerUserId number,
AutoRenameCount number,
LastAutoRename time,
Score number,
ApprovedByUserId number,
ApprovalDate time
)
CREATE TABLE Votes (
Id number,
PostId number,
... | SELECT p.Id, p.CreationDate, p.Score, p.ViewCount, p.Title, p.AnswerCount, p.CommentCount, p.FavoriteCount, p.AcceptedAnswerId, u.DisplayName AS CreatorName, e.DisplayName AS EditorName FROM Posts AS p INNER JOIN PostTags AS pt ON pt.PostId = p.Id INNER JOIN Users AS u ON p.OwnerUserId = u.Id LEFT JOIN Users AS e ON p.... | sede |
CREATE TABLE university (
School_ID int,
School text,
Location text,
Founded real,
Affiliation text,
Enrollment real,
Nickname text,
Primary_conference text
)
CREATE TABLE basketball_match (
Team_ID int,
School_ID int,
Team_Name text,
ACC_Regular_Season text,
ACC_Per... | SELECT Team_Name, ACC_Percent FROM basketball_match ORDER BY Team_Name | nvbench |
CREATE TABLE table_27846651_1 (
writer VARCHAR,
viewers__millions_ VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who wrote the episode that had 5.93 million viewers?
| SELECT writer FROM table_27846651_1 WHERE viewers__millions_ = "5.93" | sql_create_context |
CREATE TABLE table_4776 (
"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.
-- Which away team had a score of 5.6 (36)?
| SELECT "Away team" FROM table_4776 WHERE "Away team score" = '5.6 (36)' | wikisql |
CREATE TABLE table_37568 (
"Year" real,
"Class" text,
"Team" text,
"Points" real,
"Wins" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Points have Wins larger than 1?
| SELECT AVG("Points") FROM table_37568 WHERE "Wins" > '1' | wikisql |
CREATE TABLE table_72266 (
"State" text,
"Preliminaries" text,
"Interview" text,
"Swimsuit" text,
"Evening Gown" text,
"Average" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what's the preliminaries where state is south dakota
| SELECT "Preliminaries" FROM table_72266 WHERE "State" = 'South Dakota' | wikisql |
CREATE TABLE table_10230 (
"Model name" text,
"Power (ps)" real,
"Torque (Nm@rpm)" text,
"Displacement (cm\u00b3)" real,
"Engine code" text,
"Comment" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which engine has a 2435 cm displacement and is ... | SELECT "Engine code" FROM table_10230 WHERE "Displacement (cm\u00b3)" = '2435' AND "Model name" = '2.4 (2001-2007)' | wikisql |
CREATE TABLE table_name_80 (
diameter VARCHAR,
€_equiv VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the diameter of the coin with a equivalence of 0.60?
| SELECT diameter FROM table_name_80 WHERE €_equiv = "0.60" | sql_create_context |
CREATE TABLE countries (
COUNTRY_ID varchar(2),
COUNTRY_NAME varchar(40),
REGION_ID decimal(10,0)
)
CREATE TABLE employees (
EMPLOYEE_ID decimal(6,0),
FIRST_NAME varchar(20),
LAST_NAME varchar(25),
EMAIL varchar(25),
PHONE_NUMBER varchar(20),
HIRE_DATE date,
JOB_ID varchar(10),
... | SELECT HIRE_DATE, COUNT(HIRE_DATE) FROM employees WHERE HIRE_DATE < '2002-06-21' ORDER BY COUNT(HIRE_DATE) | nvbench |
CREATE TABLE table_name_9 (
surface VARCHAR,
semi_finalists VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Surface has a Semi finalists of conchita mart nez arantxa s nchez?
| SELECT surface FROM table_name_9 WHERE semi_finalists = "conchita martínez arantxa sánchez" | sql_create_context |
CREATE TABLE table_12932 (
"Percentage Range" text,
"Grade" text,
"Points for Higher" real,
"Points for Ordinary" real,
"Points for Foundation" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What average points for highers has 0 has points for ordin... | SELECT AVG("Points for Higher") FROM table_12932 WHERE "Points for Ordinary" = '0' AND "Grade" = 'ng' AND "Points for Foundation" < '0' | wikisql |
CREATE TABLE inputevents_cv (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime time,
itemid number,
amount number
)
CREATE TABLE diagnoses_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
CREATE TABLE... | SELECT COUNT(DISTINCT icustays.icustay_id) FROM icustays WHERE icustays.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 62298 AND NOT admissions.dischtime IS NULL ORDER BY admissions.admittime DESC LIMIT 1) | mimic_iii |
CREATE TABLE table_29506171_2 (
year INTEGER,
earnings___€__ VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- In what year were Reid's earnings 4,050 1?
| SELECT MIN(year) FROM table_29506171_2 WHERE earnings___€__ = "4,050 1" | sql_create_context |
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 jybgb.JYKSBM, jybgb.JYKSMC FROM jybgb WHERE jybgb.BGDH = '80525175494' | css |
CREATE TABLE hz_info (
KH text,
KLX number,
YLJGDM text
)
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 num... | SELECT mzjzjlb.JZLSH FROM person_info JOIN hz_info JOIN mzjzjlb JOIN person_info_hz_info ON person_info.RYBH = person_info_hz_info.RYBH AND hz_info.YLJGDM = mzjzjlb.YLJGDM AND hz_info.KH = mzjzjlb.KH AND hz_info.KLX = mzjzjlb.KLX AND person_info_hz_info.KH = hz_info.KH AND person_info_hz_info.KLX = hz_info.KLX AND pers... | css |
CREATE TABLE t_kc21_t_kc22 (
MED_CLINIC_ID text,
MED_EXP_DET_ID number
)
CREATE TABLE t_kc22 (
AMOUNT number,
CHA_ITEM_LEV number,
DATA_ID text,
DIRE_TYPE number,
DOSE_FORM text,
DOSE_UNIT text,
EACH_DOSAGE text,
EXP_OCC_DATE time,
FLX_MED_ORG_ID text,
FXBZ number,
H... | SELECT SUM(t_kc24.PER_ACC_PAY) 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 '2014-06-30' AND '2015-06-30' | css |
CREATE TABLE table_name_14 (
result VARCHAR,
time VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What result had a time of 1:02?
| SELECT result FROM table_name_14 WHERE time = "1:02" | sql_create_context |
CREATE TABLE table_name_30 (
erp_w INTEGER,
call_sign VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Call sign of k231bg has what sum of erp w?
| SELECT SUM(erp_w) FROM table_name_30 WHERE call_sign = "k231bg" | sql_create_context |
CREATE TABLE table_26278 (
"Level" text,
"Luma samples/s" real,
"Macroblocks/s" real,
"Luma samples" real,
"Macroblocks" real,
"Baseline, Extended and Main Profiles" real,
"High Profile" real,
"High 10 Profile" real,
"Examples for high resolution @ highest frame rate (max stored fram... | SELECT MAX("High 10 Profile") FROM table_26278 WHERE "High Profile" = '80' | wikisql |
CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE prescription... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id WHERE demographic.admission_location = "TRANSFER FROM HOSP/EXTRAM" AND diagnoses.icd9_code = "4820" | mimicsql_data |
CREATE TABLE table_10964 (
"Player" text,
"No.(s)" text,
"Height in Ft." text,
"Position" text,
"Years for Rockets" text,
"School/Club Team/Country" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the position for numbers of 41
| SELECT "Position" FROM table_10964 WHERE "No.(s)" = '41' | wikisql |
CREATE TABLE table_69603 (
"Polling Firm" text,
"Date Published" text,
"T. Papadopoulos" text,
"D. Christofias" text,
"I. Kasoulidis" text,
"K. Themistokleous" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which polling firm put T. Papadopoulos... | SELECT "Polling Firm" FROM table_69603 WHERE "T. Papadopoulos" = '31%' | wikisql |
CREATE TABLE table_name_59 (
voice_actor__japanese_ VARCHAR,
character_name VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what voice acter played tien
| SELECT voice_actor__japanese_ FROM table_name_59 WHERE character_name = "tien" | sql_create_context |
CREATE TABLE table_name_61 (
Id VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which is the lowest 1980 growth that had 2,610 in 1970?
| SELECT MIN(1980) FROM table_name_61 WHERE 1970 = 2 OFFSET 610 | sql_create_context |
CREATE TABLE patient (
uniquepid text,
patienthealthsystemstayid number,
patientunitstayid number,
gender text,
age text,
ethnicity text,
hospitalid number,
wardid number,
admissionheight number,
admissionweight number,
dischargeweight number,
hospitaladmittime time,
... | SELECT COUNT(DISTINCT patient.uniquepid) FROM patient WHERE patient.wardid = 669 | eicu |
CREATE TABLE table_7013 (
"Location" text,
"Aircraft" text,
"Tail number" text,
"Aircraft damage" text,
"Fatalities" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the location that had an accident by the F-27-600RF aircraft with tail numbe... | SELECT "Location" FROM table_7013 WHERE "Aircraft" = 'f-27-600rf' AND "Tail number" = '6o-saz' | wikisql |
CREATE TABLE intakeoutput (
intakeoutputid number,
patientunitstayid number,
cellpath text,
celllabel text,
cellvaluenumeric number,
intakeoutputtime time
)
CREATE TABLE lab (
labid number,
patientunitstayid number,
labname text,
labresult number,
labresulttime time
)
CREAT... | SELECT lab.labresulttime FROM lab WHERE lab.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '017-74343' AND NOT patient.hospitaldischargetime IS NULL ORDER BY patient.hospitala... | eicu |
CREATE TABLE table_3632 (
"No. in series" real,
"No. in season" real,
"Title" text,
"Director" text,
"Writer(s)" text,
"Original air date" text,
"Production code" text,
"U.S. viewers (million)" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
... | SELECT "U.S. viewers (million)" FROM table_3632 WHERE "Production code" = '4ALH19' | wikisql |
CREATE TABLE table_42378 (
"Team 1" text,
"Agg." text,
"Team 2" text,
"1st leg" text,
"2nd leg" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What 2nd leg has rk gold club kozina as team 1?
| SELECT "2nd leg" FROM table_42378 WHERE "Team 1" = 'rk gold club kozina' | wikisql |
CREATE TABLE table_54039 (
"Driver" text,
"Entrant" text,
"Constructor" text,
"Chassis" text,
"Engine" text,
"Tyre" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what is the tyre when the entrant is scuderia milano?
| SELECT "Tyre" FROM table_54039 WHERE "Entrant" = 'scuderia milano' | 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, COUNT(JOB_ID) FROM employees WHERE SALARY BETWEEN 8000 AND 12000 AND COMMISSION_PCT <> "null" OR DEPARTMENT_ID <> 40 GROUP BY JOB_ID ORDER BY JOB_ID DESC | nvbench |
CREATE TABLE table_15261_1 (
clock_multiplier VARCHAR,
part_number VARCHAR,
voltage_range__v_ VARCHAR,
input_clock__mhz_ VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the clock multiplier if the voltage range (v) is 3.3 - 3.6; input clock (m... | SELECT clock_multiplier FROM table_15261_1 WHERE voltage_range__v_ = "3.3 - 3.6" AND input_clock__mhz_ = "33 X 3 / 50 X 2" AND part_number = "A80486DX4-100" | sql_create_context |
CREATE TABLE table_name_29 (
partnering VARCHAR,
tournament VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who was the partner for the tournament in Lyon, France?
| SELECT partnering FROM table_name_29 WHERE tournament = "lyon, france" | sql_create_context |
CREATE TABLE table_1342256_10 (
result VARCHAR,
incumbent VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many races involve incumbent Pat Cannon?
| SELECT COUNT(result) FROM table_1342256_10 WHERE incumbent = "Pat Cannon" | sql_create_context |
CREATE TABLE table_name_75 (
away_team VARCHAR,
home_team VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the score for the away team when the home team was richmond?
| SELECT away_team AS score FROM table_name_75 WHERE home_team = "richmond" | sql_create_context |
CREATE TABLE table_name_34 (
name VARCHAR,
team_sites VARCHAR,
public VARCHAR,
personal_sites VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the name for the entry that has a public of Yes, a personal sites of No, and a team sites of No?
| SELECT name FROM table_name_34 WHERE public = "yes" AND personal_sites = "no" AND team_sites = "no" | sql_create_context |
CREATE TABLE jobs (
job_id int,
job_title varchar,
description varchar,
requirement varchar,
city varchar,
state varchar,
country varchar,
zip int
)
CREATE TABLE gsi (
course_offering_id int,
student_id int
)
CREATE TABLE area (
course_id int,
area varchar
)
CREATE TAB... | SELECT COUNT(*) > 0 FROM course INNER JOIN program_course ON program_course.course_id = course.course_id WHERE course.department = 'CMBIOL' AND course.number = 681 AND program_course.category LIKE '%ULCS%' | advising |
CREATE TABLE table_48282 (
"Athlete" text,
"Event" text,
"Swim (1.5km)" text,
"Trans 1" text,
"Bike (40km)" text,
"Trans 2" text,
"Run (10km)" text,
"Total Time" text,
"Rank" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- With a swim... | SELECT "Trans 2" FROM table_48282 WHERE "Swim (1.5km)" = '18:55' AND "Run (10km)" = '32:37' | 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 lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id WHERE demographic.ethnicity = "HISPANIC/LATINO - PUERTO RICAN" AND diagnoses.icd9_code = "34590" | mimicsql_data |
CREATE TABLE table_53003 (
"Outcome" text,
"Tournament" text,
"Surface" text,
"Partner" text,
"Opponents" text,
"Score" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the score for the game that Colin Fleming Scott Lipsky played in?
| SELECT "Score" FROM table_53003 WHERE "Opponents" = 'colin fleming scott lipsky' | wikisql |
CREATE TABLE table_26218124_1 (
original_club VARCHAR,
name VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which club was originally named hapoel katamon jerusalem f.c.?
| SELECT original_club FROM table_26218124_1 WHERE name = "Hapoel Katamon Jerusalem F.C." | sql_create_context |
CREATE TABLE table_1353096_2 (
channel_tv___dt__ VARCHAR,
city_of_license_market VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What TV channel had a license from Boston?
| SELECT channel_tv___dt__ FROM table_1353096_2 WHERE city_of_license_market = "Boston" | sql_create_context |
CREATE TABLE student (
stu_num number,
stu_lname text,
stu_fname text,
stu_init text,
stu_dob time,
stu_hrs number,
stu_class text,
stu_gpa number,
stu_transfer number,
dept_code text,
stu_phone text,
prof_num number
)
CREATE TABLE employee (
emp_num number,
emp_... | SELECT T1.emp_fname FROM employee AS T1 JOIN professor AS T2 ON T1.emp_num = T2.emp_num JOIN department AS T3 ON T2.dept_code = T3.dept_code WHERE T3.dept_name = 'History' EXCEPT SELECT T4.emp_fname FROM employee AS T4 JOIN class AS T5 ON T4.emp_num = T5.prof_num | spider |
CREATE TABLE table_63148 (
"Time" text,
"Home team" text,
"Score" text,
"Away team" text,
"Venue" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the score for the southern home team?
| SELECT "Score" FROM table_63148 WHERE "Home team" = 'southern' | wikisql |
CREATE TABLE table_63888 (
"Draw" real,
"Language" text,
"Artist" text,
"Song" text,
"English translation" text,
"Place" real,
"Points" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the total number of places for a song with a draw ... | SELECT COUNT("Place") FROM table_63888 WHERE "Draw" = '21' AND "Points" > '36' | wikisql |
CREATE TABLE table_4006 (
"Institution" text,
"Location" text,
"Founded" real,
"Affiliation" text,
"Enrollment" real,
"Team Nickname" text,
"Primary conference" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- When were the Spartans founded?
| SELECT MAX("Founded") FROM table_4006 WHERE "Team Nickname" = 'Spartans' | wikisql |
CREATE TABLE table_name_88 (
year VARCHAR,
vehicle VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which year had a vehicle of Mitsubishi?
| SELECT year FROM table_name_88 WHERE vehicle = "mitsubishi" | sql_create_context |
CREATE TABLE table_245801_1 (
flight_down VARCHAR,
crew VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the flight down for vladimir vasyutin , alexander volkov
| SELECT flight_down FROM table_245801_1 WHERE crew = "Vladimir Vasyutin , Alexander Volkov" | sql_create_context |
CREATE TABLE table_name_43 (
date VARCHAR,
opponent VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- On what date was the opponent the Green Bay Packers?
| SELECT date FROM table_name_43 WHERE opponent = "green bay packers" | sql_create_context |
CREATE TABLE table_77774 (
"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.
-- When the venue was lake oval what did the home t... | SELECT "Home team score" FROM table_77774 WHERE "Venue" = 'lake oval' | wikisql |
CREATE TABLE table_25949 (
"Game" real,
"Date" text,
"Opponent" text,
"Score" text,
"Location" text,
"Attendance" real,
"Record" text,
"Points" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many points were there scored on October 2... | SELECT MAX("Points") FROM table_25949 WHERE "Date" = 'October 27' | wikisql |
CREATE TABLE table_20942 (
"Year" text,
"Division" real,
"League" text,
"Regular Season" text,
"Playoffs" text,
"Open Cup" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the team's league in 2010?
| SELECT "League" FROM table_20942 WHERE "Year" = '2010' | wikisql |
CREATE TABLE table_58173 (
"Heir" text,
"Status" text,
"Relationship to Monarch" text,
"Became heir" text,
"Reason" text,
"Ceased to be heir" text,
"Monarch" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Reason is given when 1103 is t... | SELECT "Reason" FROM table_58173 WHERE "Became heir" = '1103' | wikisql |
CREATE TABLE table_73799 (
"Season" real,
"Series" text,
"Team" text,
"Races" real,
"Wins" real,
"Poles" real,
"F.L." real,
"Podiums" real,
"Points" real,
"Position" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many points ... | SELECT COUNT("Points") FROM table_73799 WHERE "Team" = 'Marussia Manor Racing' | wikisql |
CREATE TABLE ReviewTaskTypes (
Id number,
Name text,
Description text
)
CREATE TABLE ReviewRejectionReasons (
Id number,
Name text,
Description text,
PostTypeId number
)
CREATE TABLE ReviewTasks (
Id number,
ReviewTaskTypeId number,
CreationDate time,
DeletionDate time,
... | SELECT pl.RelatedPostId AS "post_link", COUNT(pl.RelatedPostId) AS "number_of_links", p.Title, p.Score, p.ViewCount, p.AnswerCount FROM PostLinks AS pl JOIN Posts AS p ON p.Id = pl.PostId AND p.OwnerUserId = @user_id GROUP BY pl.RelatedPostId, p.ViewCount, p.Score, p.AnswerCount, p.Title ORDER BY 'number_of_links' DESC | sede |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.