instruction stringlengths 151 7.46k | output stringlengths 2 4.44k | source stringclasses 26
values |
|---|---|---|
CREATE TABLE d_icd_diagnoses (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE d_labitems (
row_id number,
itemid number,
label text
)
CREATE TABLE icustays (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
first_care... | 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 = 'sports acc w/o sub fall')) | mimic_iii |
CREATE TABLE table_63035 (
"Model" text,
"Poweramp" text,
"Dimensions" text,
"Mass" text,
"Form factor(s)" text,
"Output" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What are the dimensions of the amp with a 180W output?
| SELECT "Dimensions" FROM table_63035 WHERE "Output" = '180w' | wikisql |
CREATE TABLE appellations (
No INTEGER,
Appelation TEXT,
County TEXT,
State TEXT,
Area TEXT,
isAVA TEXT
)
CREATE TABLE grapes (
ID INTEGER,
Grape TEXT,
Color TEXT
)
CREATE TABLE wine (
No INTEGER,
Grape TEXT,
Winery TEXT,
Appelation TEXT,
State TEXT,
Name TE... | SELECT Year, MAX(Score) FROM wine GROUP BY Year ORDER BY Year | nvbench |
CREATE TABLE table_45543 (
"Driver" text,
"Team" text,
"Laps" real,
"Time/Retired" text,
"Grid" real,
"Points" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What driver had a time/retired of + 10 laps and more than 6 points?
| SELECT "Driver" FROM table_45543 WHERE "Time/Retired" = '+ 10 laps' AND "Points" > '6' | wikisql |
CREATE TABLE transfers (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
eventtype text,
careunit text,
wardid number,
intime time,
outtime time
)
CREATE TABLE admissions (
row_id number,
subject_id number,
hadm_id number,
admittime time,
dis... | SELECT t3.drug FROM (SELECT t2.drug, DENSE_RANK() OVER (ORDER BY COUNT(*) DESC) AS c1 FROM (SELECT admissions.subject_id, diagnoses_icd.charttime FROM diagnoses_icd JOIN admissions ON diagnoses_icd.hadm_id = admissions.hadm_id WHERE diagnoses_icd.icd9_code = (SELECT d_icd_diagnoses.icd9_code FROM d_icd_diagnoses WHERE ... | mimic_iii |
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 ACC_Road, COUNT(ACC_Road) FROM basketball_match GROUP BY ACC_Road | nvbench |
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 allergy (
allergy... | SELECT t3.culturesite FROM (SELECT t2.culturesite, DENSE_RANK() OVER (ORDER BY COUNT(*) DESC) AS c1 FROM (SELECT patient.uniquepid, treatment.treatmenttime, patient.patienthealthsystemstayid FROM treatment JOIN patient ON treatment.patientunitstayid = patient.patientunitstayid WHERE treatment.treatmentname = 'surgery c... | eicu |
CREATE TABLE intakeoutput (
intakeoutputid number,
patientunitstayid number,
cellpath text,
celllabel text,
cellvaluenumeric number,
intakeoutputtime time
)
CREATE TABLE vitalperiodic (
vitalperiodicid number,
patientunitstayid number,
temperature number,
sao2 number,
heartr... | SELECT SUM(CASE WHEN patient.hospitaldischargestatus = 'alive' THEN 1 WHEN STRFTIME('%j', patient.hospitaldischargetime) - STRFTIME('%j', t4.diagnosistime) > 5 * 365 THEN 1 ELSE 0 END) * 100 / COUNT(*) FROM (SELECT t2.uniquepid, t2.diagnosistime FROM (SELECT t1.uniquepid, t1.diagnosistime FROM (SELECT patient.uniquepid... | eicu |
CREATE TABLE table_37138 (
"Year [A ]" real,
"Pick" text,
"Player name" text,
"Position" text,
"College" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who was a defensive end at California?
| SELECT "Player name" FROM table_37138 WHERE "Position" = 'defensive end' AND "College" = 'california' | wikisql |
CREATE TABLE table_1340667_3 (
finish_position VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what's the 3rd day with finbeingh position being 16th
| SELECT 3 AS rd_day FROM table_1340667_3 WHERE finish_position = "16th" | sql_create_context |
CREATE TABLE church (
Church_ID int,
Name text,
Organized_by text,
Open_Date int,
Continuation_of text
)
CREATE TABLE people (
People_ID int,
Name text,
Country text,
Is_Male text,
Age int
)
CREATE TABLE wedding (
Church_ID int,
Male_ID int,
Female_ID int,
Year ... | SELECT Open_Date, COUNT(Open_Date) FROM church ORDER BY COUNT(Open_Date) DESC | nvbench |
CREATE TABLE offering_instructor (
offering_instructor_id int,
offering_id int,
instructor_id int
)
CREATE TABLE program_requirement (
program_id int,
category varchar,
min_credit int,
additional_req varchar
)
CREATE TABLE course_offering (
offering_id int,
course_id int,
semes... | SELECT COUNT(*) FROM course, course_offering, semester WHERE course.course_id = course_offering.course_id AND course.department = 'PERSIAN' AND course.number = 102 AND semester.semester = 'FA' AND semester.semester_id = course_offering.semester AND semester.year = 2016 | advising |
CREATE TABLE table_20300 (
"#" real,
"Advocate # 1" text,
"Advocate # 2" text,
"Root of All Evil" text,
"Poll winner" text,
"Original air date" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the advocate #1 for american idol
| SELECT "Advocate # 1" FROM table_20300 WHERE "Root of All Evil" = 'American Idol' | wikisql |
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),
SALARY decimal(8,2),
COMMISSION_PCT decimal(2,2),
MANAGER_ID decimal(6,0),
DEPARTMENT_ID decimal(... | SELECT JOB_ID, AVG(EMPLOYEE_ID) FROM employees WHERE FIRST_NAME LIKE '%D%' OR FIRST_NAME LIKE '%S%' GROUP BY JOB_ID ORDER BY JOB_ID DESC | nvbench |
CREATE TABLE table_28652521_1 (
description VARCHAR,
singer_part_number VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What's the description of the buttonholer whose singer part number is 121795 kit 121908 buttonholer?
| SELECT description FROM table_28652521_1 WHERE singer_part_number = "121795 kit 121908 buttonholer" | sql_create_context |
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,
COM_PAY number,
DATA_ID text,
ENT_ACC_PAY number,
ENT_PAY number,
F... | SELECT COUNT(t_kc21.IN_DIAG_DIS_CD) FROM t_kc21 WHERE t_kc21.PERSON_ID = '22165131' AND t_kc21.IN_HOSP_DATE BETWEEN '2010-10-05' AND '2014-07-21' | css |
CREATE TABLE table_22816 (
"Episode title" text,
"Subject" text,
"Music by" text,
"Lyrics by" text,
"Performed by" text,
"First aired" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who is the music by for episode the Elbow Room?
| SELECT "Music by" FROM table_22816 WHERE "Episode title" = 'Elbow Room' | wikisql |
CREATE TABLE table_2603017_2 (
ba___running_bear VARCHAR,
ab___angry_boar VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what is ba - running bear where ab - angry boar is os - ox soldier?
| SELECT ba___running_bear FROM table_2603017_2 WHERE ab___angry_boar = "OS - Ox Soldier" | sql_create_context |
CREATE TABLE table_204_324 (
id number,
"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 team is before team botswana in column team 1 ?
| SELECT "team 1" FROM table_204_324 WHERE id = (SELECT id FROM table_204_324 WHERE "team 1" = 'botswana') - 1 | squall |
CREATE TABLE table_74743 (
"Rank" real,
"Rider" text,
"Team" text,
"Speed" text,
"Time" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Rider has a 1:06.02.0 Time?
| SELECT "Rider" FROM table_74743 WHERE "Time" = '1:06.02.0' | wikisql |
CREATE TABLE treatment (
treatmentid number,
patientunitstayid number,
treatmentname text,
treatmenttime time
)
CREATE TABLE intakeoutput (
intakeoutputid number,
patientunitstayid number,
cellpath text,
celllabel text,
cellvaluenumeric number,
intakeoutputtime time
)
CREATE TA... | SELECT t1.drugstarttime FROM (SELECT patient.uniquepid, medication.drugstarttime FROM medication JOIN patient ON medication.patientunitstayid = patient.patientunitstayid WHERE medication.drugname = 'percocet 5/325 tab' AND patient.uniquepid = '021-213732' AND DATETIME(medication.drugstarttime, 'start of month') = DATET... | eicu |
CREATE TABLE gyb (
CLINIC_ID 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,
INSU_TYPE text,
IN... | SELECT qtb.MED_SER_ORG_NO FROM qtb WHERE qtb.PERSON_NM = '邹承天' GROUP BY qtb.MED_SER_ORG_NO ORDER BY COUNT(*) DESC UNION SELECT gyb.MED_SER_ORG_NO FROM gyb WHERE gyb.PERSON_NM = '邹承天' GROUP BY gyb.MED_SER_ORG_NO ORDER BY COUNT(*) DESC UNION SELECT zyb.MED_SER_ORG_NO FROM zyb WHERE zyb.PERSON_NM = '邹承天' GROUP BY zyb.MED_... | css |
CREATE TABLE table_name_56 (
overall INTEGER,
pick__number INTEGER
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the least overall with pick number more than 27
| SELECT MIN(overall) FROM table_name_56 WHERE pick__number > 27 | sql_create_context |
CREATE TABLE table_57350 (
"Constructor" text,
"Chassis" text,
"Engine" text,
"Tyres" text,
"Driver" text,
"Rounds" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who is the constructor for driver alan jones using a chassis of fw06 fw07?
| SELECT "Constructor" FROM table_57350 WHERE "Chassis" = 'fw06 fw07' AND "Driver" = 'alan jones' | wikisql |
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,
COM_PAY number,
DATA_ID text,
ENT_ACC_PAY number,
ENT_PAY number,
F... | SELECT SUM(t_kc22.AMOUNT) FROM gwyjzb JOIN t_kc22 ON gwyjzb.MED_CLINIC_ID = t_kc22.MED_CLINIC_ID WHERE gwyjzb.PERSON_NM = '魏蕴美' AND gwyjzb.CLINIC_TYPE = '门诊' AND t_kc22.STA_DATE BETWEEN '2010-12-02' AND '2015-12-23' AND t_kc22.MED_INV_ITEM_TYPE = '手术费' UNION SELECT SUM(t_kc22.AMOUNT) FROM fgwyjzb JOIN t_kc22 ON fgwyjzb... | css |
CREATE TABLE table_name_41 (
engine_s_ VARCHAR,
points VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What engine has 2 points?
| SELECT engine_s_ FROM table_name_41 WHERE points = "2" | sql_create_context |
CREATE TABLE table_1342013_37 (
party VARCHAR,
district VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the party for the pennsylvania 25
| SELECT party FROM table_1342013_37 WHERE district = "Pennsylvania 25" | 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 allergy (
allergy... | 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 = '027-22704')) AND lab.labname = 'lactate' AND STRFTIME('%y-%m', lab.labresulttime) =... | eicu |
CREATE TABLE Users (
Id number,
Reputation number,
CreationDate time,
DisplayName text,
LastAccessDate time,
WebsiteUrl text,
Location text,
AboutMe text,
Views number,
UpVotes number,
DownVotes number,
ProfileImageUrl text,
EmailHash text,
AccountId number
)
CRE... | SELECT TagName FROM Tags WHERE TagName LIKE 'a%p%c%n' AND NOT TagName LIKE 'a%c%p%n' | sede |
CREATE TABLE table_26264 (
"Party" text,
"Week 32" text,
"Week 33" text,
"Week 34" text,
"Week 35" text,
"Week 36" text,
"Week 37" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- List the full amount of week 36 results when week 32 is 13.2%.
| SELECT COUNT("Week 36") FROM table_26264 WHERE "Week 32" = '13.2%' | wikisql |
CREATE TABLE time_zone (
time_zone_code text,
time_zone_name text,
hours_from_gmt int
)
CREATE TABLE airport_service (
city_code varchar,
airport_code varchar,
miles_distant int,
direction varchar,
minutes_distant int
)
CREATE TABLE flight_fare (
flight_id int,
fare_id int
)
C... | SELECT DISTINCT flight.flight_id FROM airport_service AS AIRPORT_SERVICE_0, airport_service AS AIRPORT_SERVICE_1, city AS CITY_0, city AS CITY_1, flight WHERE ((flight.arrival_time <= 2000 AND flight.arrival_time >= 1600) AND CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'ATLANTA' AND flight.to_... | atis |
CREATE TABLE table_name_22 (
drop_zone INTEGER,
troop_carrier_group VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the average drop zone time in the N drop zone for the 1st Pathfinder Prov.?
| SELECT AVG(drop_zone) AS Time FROM table_name_22 WHERE drop_zone = "n" AND troop_carrier_group = "1st pathfinder prov." | sql_create_context |
CREATE TABLE PostLinks (
Id number,
CreationDate time,
PostId number,
RelatedPostId number,
LinkTypeId number
)
CREATE TABLE PostsWithDeleted (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
... | SELECT Id AS "post_link", Score, CreationDate FROM Posts WHERE Tags = '<' + '##tagName:string##' + '>' ORDER BY CreationDate DESC | sede |
CREATE TABLE table_43085 (
"Driver" text,
"Constructor" text,
"Laps" real,
"Time/Retired" text,
"Grid" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What's the most laps when grid is 16?
| SELECT MAX("Laps") FROM table_43085 WHERE "Grid" = '16' | 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 zyjzjlb.JZLSH FROM hz_info JOIN zyjzjlb ON hz_info.YLJGDM = zyjzjlb.YLJGDM AND hz_info.KH = zyjzjlb.KH AND hz_info.KLX = zyjzjlb.KLX WHERE hz_info.RYBH = '91823210' AND NOT zyjzjlb.JZLSH IN (SELECT jybgb.JZLSH FROM jybgb WHERE jybgb.BGRQ >= '2008-05-03') | css |
CREATE TABLE table_name_38 (
story VARCHAR,
date VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the story code of the story published on 2002-12?
| SELECT story AS code FROM table_name_38 WHERE date = "2002-12" | sql_create_context |
CREATE TABLE table_204_524 (
id number,
"season" text,
"tier" number,
"division" text,
"place" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- is 3rd place listed above 18th place ?
| SELECT (SELECT id FROM table_204_524 WHERE "place" = 3) < (SELECT id FROM table_204_524 WHERE "place" = 18) | squall |
CREATE TABLE table_37928 (
"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 shows for gold when bronze is 1?
| SELECT "Gold" FROM table_37928 WHERE "Bronze" = '1' | wikisql |
CREATE TABLE offering_instructor (
offering_instructor_id int,
offering_id int,
instructor_id int
)
CREATE TABLE ta (
campus_job_id int,
student_id int,
location varchar
)
CREATE TABLE gsi (
course_offering_id int,
student_id int
)
CREATE TABLE program (
program_id int,
name v... | SELECT DISTINCT course.department, course.name, course.number FROM course INNER JOIN course_offering ON course.course_id = course_offering.course_id INNER JOIN offering_instructor ON offering_instructor.offering_id = course_offering.offering_id INNER JOIN instructor ON offering_instructor.instructor_id = instructor.ins... | advising |
CREATE TABLE table_8822 (
"City" text,
"Country" text,
"IATA" text,
"ICAO" text,
"Airport" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is Airport, when Country is 'Egypt', and when ICAO is 'Heba'?
| SELECT "Airport" FROM table_8822 WHERE "Country" = 'egypt' AND "ICAO" = 'heba' | wikisql |
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 jybgb.BBDM, jybgb.BBMC, jybgb.BBZT FROM jybgb WHERE jybgb.BGDH = '63924236375' | css |
CREATE TABLE table_50425 (
"Position" real,
"Team" text,
"Played" real,
"Drawn" real,
"Lost" real,
"Goals For" real,
"Goals Against" real,
"Goal Difference" text,
"Points 1" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the ... | SELECT MAX("Played") FROM table_50425 WHERE "Lost" < '13' AND "Goal Difference" = '+46' | wikisql |
CREATE TABLE jobs (
JOB_ID varchar(10),
JOB_TITLE varchar(35),
MIN_SALARY decimal(6,0),
MAX_SALARY decimal(6,0)
)
CREATE TABLE regions (
REGION_ID decimal(5,0),
REGION_NAME varchar(25)
)
CREATE TABLE job_history (
EMPLOYEE_ID decimal(6,0),
START_DATE date,
END_DATE date,
JOB_ID... | SELECT JOB_ID, SUM(MANAGER_ID) FROM employees WHERE FIRST_NAME LIKE '%D%' OR FIRST_NAME LIKE '%S%' GROUP BY JOB_ID ORDER BY JOB_ID DESC | nvbench |
CREATE TABLE table_43724 (
"Draw" real,
"Song" text,
"Performer" text,
"Points" real,
"Rank" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How much Draw has a Rank of 3rd, and a Performer of noelle, and Points larger than 79?
| SELECT COUNT("Draw") FROM table_43724 WHERE "Rank" = '3rd' AND "Performer" = 'noelle' AND "Points" > '79' | wikisql |
CREATE TABLE table_name_85 (
attendance INTEGER,
result VARCHAR,
week VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many people attended the game with a result of w 16-13 and a week earlier than 12?
| SELECT MAX(attendance) FROM table_name_85 WHERE result = "w 16-13" AND week < 12 | sql_create_context |
CREATE TABLE table_name_91 (
station VARCHAR,
japanese VARCHAR,
rapid VARCHAR,
distance__km_ VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What station has a Rapid of , is 3.4 km away, and has a Japanese title of ?
| SELECT station FROM table_name_91 WHERE rapid = "↑" AND distance__km_ > 3.4 AND japanese = "下鴨生" | sql_create_context |
CREATE TABLE table_45393 (
"Rank" text,
"Name" text,
"Height (m)" real,
"Height (ft)" real,
"Floors" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the Height (ft) of the Churchill House with a Height (m) less than 59?
| SELECT COUNT("Height (ft)") FROM table_45393 WHERE "Name" = 'churchill house' AND "Height (m)" < '59' | wikisql |
CREATE TABLE student_record (
student_id int,
course_id int,
semester int,
grade varchar,
how varchar,
transfer_source varchar,
earn_credit varchar,
repeat_term varchar,
test_id varchar
)
CREATE TABLE offering_instructor (
offering_instructor_id int,
offering_id int,
ins... | SELECT COUNT(*) > 0 FROM course, course_offering, instructor, offering_instructor, semester WHERE course.course_id = course_offering.course_id AND course.department = 'EECS' AND course.number = 445 AND instructor.name LIKE '%Jia Tolentino%' AND offering_instructor.instructor_id = instructor.instructor_id AND offering_i... | advising |
CREATE TABLE table_11727969_1 (
species_in_the_world VARCHAR,
peruvian_amazon_vs_peru__percent_ VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what's the species in the world with peruvian amazon vs. peru (percent) of 63
| SELECT species_in_the_world FROM table_11727969_1 WHERE peruvian_amazon_vs_peru__percent_ = 63 | sql_create_context |
CREATE TABLE table_15621965_8 (
school_club_team VARCHAR,
player VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What school did Dwight Howard play for
| SELECT school_club_team FROM table_15621965_8 WHERE player = "Dwight Howard" | sql_create_context |
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 (SELECT COUNT(*) FROM hz_info JOIN mzjzjlb ON hz_info.YLJGDM = mzjzjlb.YLJGDM AND hz_info.KH = mzjzjlb.KH AND hz_info.KLX = mzjzjlb.KLX WHERE hz_info.RYBH = '27285110' AND mzjzjlb.JZKSRQ BETWEEN '2013-01-08' AND '2021-04-27') + (SELECT COUNT(*) FROM hz_info JOIN zyjzjlb ON hz_info.YLJGDM = zyjzjlb.YLJGDM AND hz_... | css |
CREATE TABLE table_16215 (
"General election" real,
"# of candidates" real,
"# of seats won" real,
"% of popular vote" text,
"Result" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many seats were won in the election with 125 candidates?
| SELECT COUNT("# of seats won") FROM table_16215 WHERE "# of candidates" = '125' | wikisql |
CREATE TABLE CloseAsOffTopicReasonTypes (
Id number,
IsUniversal boolean,
InputTitle text,
MarkdownInputGuidance text,
MarkdownPostOwnerGuidance text,
MarkdownPrivilegedUserGuidance text,
MarkdownConcensusDescription text,
CreationDate time,
CreationModeratorId number,
ApprovalDa... | SELECT COUNT(Posts.Id) AS "new_questions" FROM Posts INNER JOIN PostTags ON PostTags.PostId = Posts.Id INNER JOIN Tags ON PostTags.TagId = Tags.Id WHERE Tags.TagName = '##Tag:string##' AND Posts.CreationDate > DATEADD(year, -1, GETDATE()) | sede |
CREATE TABLE Person (
gender VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many females does this network has?
| SELECT COUNT(*) FROM Person WHERE gender = 'female' | sql_create_context |
CREATE TABLE table_19023 (
"Rank" real,
"Airport" text,
"Total Passengers" real,
"% Change 2005/2006" text,
"International Passengers" real,
"Domestic Passengers" real,
"Transit Passengers" real,
"Aircraft Movements" real,
"Freight (Metric Tonnes)" real
)
-- Using valid SQLite, ans... | SELECT "Airport" FROM table_19023 WHERE "% Change 2005/2006" = '13.0%' | wikisql |
CREATE TABLE table_13773 (
"Tournament" text,
"Wins" real,
"Top-5" real,
"Top-25" real,
"Events" real,
"Cuts made" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the total number of cuts made when the top-25 is more than 0, and top-5 is ... | SELECT COUNT("Cuts made") FROM table_13773 WHERE "Top-25" > '0' AND "Top-5" > '1' | wikisql |
CREATE TABLE zyjzjlb (
YLJGDM text,
JZLSH text,
MZJZLSH text,
KH text,
KLX number,
HZXM text,
WDBZ number,
RYDJSJ time,
RYTJDM number,
RYTJMC text,
JZKSDM text,
JZKSMC text,
RZBQDM text,
RZBQMC text,
RYCWH text,
CYKSDM text,
CYKSMC text,
CYBQDM tex... | SELECT COUNT(*) FROM (SELECT jybgb.KSBM FROM mzjzjlb JOIN jybgb ON mzjzjlb.YLJGDM = jybgb.YLJGDM_MZJZJLB AND mzjzjlb.JZLSH = jybgb.JZLSH_MZJZJLB WHERE mzjzjlb.YLJGDM = '1771451' AND jybgb.BGRQ BETWEEN '2003-09-14' AND '2010-01-28' GROUP BY jybgb.KSBM HAVING COUNT(*) <= 20) AS T | css |
CREATE TABLE table_name_15 (
ihsaa_class VARCHAR,
year_joined VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the IHSAA Class for football for the team joining in 1968?
| SELECT ihsaa_class AS Football FROM table_name_15 WHERE year_joined = 1968 | sql_create_context |
CREATE TABLE CloseReasonTypes (
Id number,
Name text,
Description text
)
CREATE TABLE TagSynonyms (
Id number,
SourceTagName text,
TargetTagName text,
CreationDate time,
OwnerUserId number,
AutoRenameCount number,
LastAutoRename time,
Score number,
ApprovedByUserId numbe... | SELECT * FROM Posts WHERE Id > 500000 AND FavoriteCount > 30 | sede |
CREATE TABLE table_15873014_5 (
high_assists VARCHAR,
date VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who has the most assists on January 3?
| SELECT high_assists FROM table_15873014_5 WHERE date = "January 3" | sql_create_context |
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 locations (
LOCATION_ID decimal(4,0),
STREET_ADDRESS varchar(40),
POSTAL_CODE varchar(12),
CITY varchar(30),
STATE_PROVINCE varchar(... | SELECT DEPARTMENT_NAME, COUNT(*) FROM employees AS T1 JOIN departments AS T2 ON T1.DEPARTMENT_ID = T2.DEPARTMENT_ID GROUP BY T2.DEPARTMENT_NAME | nvbench |
CREATE TABLE ftxmzjzjlb (
HXPLC number,
HZXM text,
JLSJ time,
JZJSSJ time,
JZKSBM text,
JZKSMC text,
JZKSRQ time,
JZLSH number,
JZZDBM text,
JZZDSM text,
JZZTDM number,
JZZTMC text,
KH text,
KLX number,
MJZH text,
ML number,
MZZYZDZZBM text,
MZZYZD... | SELECT jybgb.BGDH FROM hz_info JOIN txmzjzjlb JOIN jybgb ON hz_info.YLJGDM = txmzjzjlb.YLJGDM AND hz_info.KH = txmzjzjlb.KH AND hz_info.KLX = txmzjzjlb.KLX AND txmzjzjlb.YLJGDM = jybgb.YLJGDM_MZJZJLB AND txmzjzjlb.JZLSH = jybgb.JZLSH_MZJZJLB WHERE hz_info.RYBH = '53573541' AND NOT jybgb.BGDH IN (SELECT jyjgzbb.BGDH FRO... | css |
CREATE TABLE table_29707 (
"School" text,
"Location" text,
"Mascot" text,
"Colors" text,
"Enrollment" real,
"IHSA Classes 2/3/4" text,
"IHSA Music Class" text,
"IHSA Football Class" text,
"IHSA Cheerleading Class" text
)
-- Using valid SQLite, answer the following questions for the... | SELECT "Colors" FROM table_29707 WHERE "Enrollment" = '2020' | wikisql |
CREATE TABLE table_name_39 (
time VARCHAR,
jockey VARCHAR,
winner VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which time contains the jockery of isaac murphy as well as the winner of kingman?
| SELECT time FROM table_name_39 WHERE jockey = "isaac murphy" AND winner = "kingman" | sql_create_context |
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,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE procedures (
... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.marital_status = "MARRIED" AND lab.itemid = "51438" | mimicsql_data |
CREATE TABLE ReviewTaskStates (
Id number,
Name text,
Description text
)
CREATE TABLE FlagTypes (
Id number,
Name text,
Description text
)
CREATE TABLE Votes (
Id number,
PostId number,
VoteTypeId number,
UserId number,
CreationDate time,
BountyAmount number
)
CREATE T... | SELECT Tags.TagName, Posts.Body FROM Tags INNER JOIN Posts ON Tags.ExcerptPostId = Posts.Id WHERE LOWER(Posts.Body) LIKE '%off-topic%' OR LOWER(Posts.Body) LIKE '%don%t use%' | sede |
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 * 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.person_i... | css |
CREATE TABLE procedures_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
CREATE TABLE d_icd_procedures (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE diagnoses_icd (
row_id number,
subject_id number,... | SELECT AVG(labevents.valuenum) FROM labevents WHERE labevents.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 16066) AND labevents.itemid IN (SELECT d_labitems.itemid FROM d_labitems WHERE d_labitems.label = 'mchc') AND STRFTIME('%y-%m', labevents.charttime) = '2104-01' | mimic_iii |
CREATE TABLE Participates_in (
stuid INTEGER,
actid INTEGER
)
CREATE TABLE Activity (
actid INTEGER,
activity_name varchar(25)
)
CREATE TABLE Faculty_Participates_in (
FacID INTEGER,
actid INTEGER
)
CREATE TABLE Faculty (
FacID INTEGER,
Lname VARCHAR(15),
Fname VARCHAR(15),
Ra... | SELECT activity_name, COUNT(*) FROM Activity AS T1 JOIN Faculty_Participates_in AS T2 ON T1.actid = T2.actid GROUP BY T1.actid | nvbench |
CREATE TABLE table_204_987 (
id number,
"city/municipality" text,
"no. of\nbarangays" number,
"area\n(km2)" number,
"population\n(2010 census)" number,
"pop. density\n(per km2)" number
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what is the larges... | SELECT "city/municipality" FROM table_204_987 ORDER BY "area\n(km2)" DESC LIMIT 1 | squall |
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 procedures.icd9_code FROM procedures WHERE procedures.subject_id = "1875" | mimicsql_data |
CREATE TABLE table_77329 (
"Player" text,
"Country" text,
"Year(s) won" text,
"Total" real,
"To par" real,
"Finish" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- WHAT IS THE TOTAL THAT HAS A WIN IN 1982?
| SELECT AVG("Total") FROM table_77329 WHERE "Year(s) won" = '1982' | wikisql |
CREATE TABLE table_name_52 (
nationality VARCHAR,
rank VARCHAR,
time VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What shows for nationality when there is a rank larger than 6, and a Time of 2:14.95?
| SELECT nationality FROM table_name_52 WHERE rank > 6 AND time = "2:14.95" | sql_create_context |
CREATE TABLE table_name_88 (
rider VARCHAR,
time VARCHAR,
bike VARCHAR,
laps VARCHAR,
grid VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who was the rider with more than 5 laps on a grid bigger than 29 on a Honda CBR600RR and time at +1:27.385?
| SELECT rider FROM table_name_88 WHERE laps > 5 AND grid > 29 AND bike = "honda cbr600rr" AND time = "+1:27.385" | sql_create_context |
CREATE TABLE table_13645 (
"Title" text,
"Series" text,
"Director" text,
"Release date" text,
"reissue?" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who was the director of the episode Rebel Rabbit?
| SELECT "Director" FROM table_13645 WHERE "Title" = 'rebel rabbit' | wikisql |
CREATE TABLE table_5099 (
"Game" real,
"Date" text,
"Opponent" text,
"Score" text,
"Series" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Series has a Score of 0 6?
| SELECT "Series" FROM table_5099 WHERE "Score" = '0–6' | wikisql |
CREATE TABLE tracks (
id number,
name text,
album_id number,
media_type_id number,
genre_id number,
composer text,
milliseconds number,
bytes number,
unit_price number
)
CREATE TABLE invoice_lines (
id number,
invoice_id number,
track_id number,
unit_price number,
... | SELECT COUNT(*) FROM customers WHERE city = "Prague" | spider |
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 procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE lab.fluid = "Ascites" | mimicsql_data |
CREATE TABLE table_203_630 (
id number,
"rank" number,
"nation" text,
"gold" number,
"silver" number,
"bronze" number,
"total" number
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- how many gold medals did germany earn ?
| SELECT "gold" FROM table_203_630 WHERE "nation" = 'germany' | squall |
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,
HOSP_DOC_CD text,
HOSP_DOC_NM text,
MED_CLINIC_ID text,
MED_DIRE_CD tex... | SELECT t_kc24.t_kc21_MED_ORG_DEPT_NM, t_kc24.t_kc21_OUT_DIAG_DIS_CD, MIN(t_kc24.PER_EXP) FROM t_kc24 WHERE t_kc24.t_kc21_MED_SER_ORG_NO = '1051519' GROUP BY t_kc24.t_kc21_MED_ORG_DEPT_NM, t_kc24.t_kc21_OUT_DIAG_DIS_CD ORDER BY MIN(t_kc24.PER_EXP / t_kc24.MED_AMOUT) | css |
CREATE TABLE table_2728 (
"Date" text,
"Location" text,
"Opponent" text,
"Spartans Points" real,
"Opp. Points" real,
"Record" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many points did the opponents with a 6-2 record against the Spartans... | SELECT MIN("Opp. Points") FROM table_2728 WHERE "Record" = '6-2' | wikisql |
CREATE TABLE student_record (
student_id int,
course_id int,
semester int,
grade varchar,
how varchar,
transfer_source varchar,
earn_credit varchar,
repeat_term varchar,
test_id varchar
)
CREATE TABLE course_tags_count (
course_id int,
clear_grading int,
pop_quiz int,
... | SELECT DISTINCT course.department, course.name, course.number, semester.semester, semester.year, student_record.grade FROM course, semester, student_record WHERE student_record.course_id = course.course_id AND student_record.semester = semester.semester_id AND student_record.student_id = 1 | advising |
CREATE TABLE table_59430 (
"Classification" text,
"% of all" text,
"John Kerry" text,
"John Edwards" text,
"Dennis Kucinich" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is % of All, when Dennis Kucinich is '5%'?
| SELECT "% of all" FROM table_59430 WHERE "Dennis Kucinich" = '5%' | wikisql |
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 jybgb.BGDH FROM person_info JOIN hz_info JOIN mzjzjlb JOIN jybgb JOIN mzjzjlb_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 = mzjzjlb_jybgb.YLJGDM_MZJZJLB AND mzjzjlb.JZLSH = jybgb.JZLSH_MZJZJLB AND mzjzjl... | css |
CREATE TABLE procedures (
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 demographic.admission_location, demographic.diagnosis FROM demographic WHERE demographic.name = "Steven Sepulveda" | mimicsql_data |
CREATE TABLE table_name_1 (
home_team VARCHAR,
away_team VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the home team score when the away team was Hawthorn?
| SELECT home_team AS score FROM table_name_1 WHERE away_team = "hawthorn" | sql_create_context |
CREATE TABLE table_204_543 (
id number,
"national team" text,
"title(s)\nrepresented" text,
"first\nworn" number,
"number\nof stars" number,
"notes" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- germany first wore them in 1996 . who was next ?
| SELECT "national team" FROM table_204_543 WHERE "first\nworn" > (SELECT "first\nworn" FROM table_204_543 WHERE "national team" = 'germany') ORDER BY "first\nworn" LIMIT 1 | squall |
CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
language text,
religion text,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location t... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE demographic.gender = "M" AND prescriptions.formulary_drug_cd = "ERGO50" | mimicsql_data |
CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
language text,
religion text,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location t... | SELECT demographic.admission_type, procedures.long_title FROM demographic INNER JOIN procedures ON demographic.hadm_id = procedures.hadm_id WHERE demographic.subject_id = "52012" | mimicsql_data |
CREATE TABLE table_62687 (
"Seat" real,
"Series 1" text,
"Series 2" text,
"Series 3" text,
"Series 4" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What shows for series 4 when the seat shows 1?
| SELECT "Series 4" FROM table_62687 WHERE "Seat" = '1' | wikisql |
CREATE TABLE table_48529 (
"Class" text,
"Part 1" text,
"Part 2" text,
"Part 3" text,
"Part 4" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is Class, when Part 2 is 'bl tu'?
| SELECT "Class" FROM table_48529 WHERE "Part 3" = 'blétu' | wikisql |
CREATE TABLE STUDENT (
STU_NUM int,
STU_LNAME varchar(15),
STU_FNAME varchar(15),
STU_INIT varchar(1),
STU_DOB datetime,
STU_HRS int,
STU_CLASS varchar(2),
STU_GPA float(8),
STU_TRANSFER numeric,
DEPT_CODE varchar(18),
STU_PHONE varchar(4),
PROF_NUM int
)
CREATE TABLE CL... | SELECT DEPT_CODE, AVG(STU_GPA) FROM STUDENT GROUP BY DEPT_CODE ORDER BY DEPT_CODE | nvbench |
CREATE TABLE table_23477 (
"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.
-- What w... | SELECT "Record" FROM table_23477 WHERE "Game" = '20' | wikisql |
CREATE TABLE table_204_471 (
id number,
"year" number,
"title" text,
"peak chart positions\nger" number,
"label" text,
"artist" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- how many albums were released under the emi record label ?
| SELECT COUNT("title") FROM table_204_471 WHERE "label" = 'emi' | squall |
CREATE TABLE table_19211 (
"Name" text,
"2011 Census" real,
"2006 Census" real,
"% change" text,
"Land area (km\u00b2)" text,
"Density (pop/km\u00b2)" text,
"Population rank" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many locations ... | SELECT COUNT("2011 Census") FROM table_19211 WHERE "Density (pop/km\u00b2)" = '91.8' | wikisql |
CREATE TABLE table_9197 (
"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.
-- What is the total number of people in attendanc... | SELECT COUNT("Attendance") FROM table_9197 WHERE "Location" = 'td banknorth garden' AND "Game" > '31' | wikisql |
CREATE TABLE SuggestedEditVotes (
Id number,
SuggestedEditId number,
UserId number,
VoteTypeId number,
CreationDate time,
TargetUserId number,
TargetRepChange number
)
CREATE TABLE CloseAsOffTopicReasonTypes (
Id number,
IsUniversal boolean,
InputTitle text,
MarkdownInputGui... | SELECT COUNT(*) FROM Posts AS q INNER JOIN Posts AS a ON q.AcceptedAnswerId = a.Id WHERE YEAR(a.CreationDate) = 2019 AND q.PostTypeId = 1 AND a.PostTypeId = 2 | sede |
CREATE TABLE table_1861 (
"No. in series" real,
"No. in season" real,
"Title" text,
"Directed by" text,
"Written by" text,
"Original air date" text,
"Production code" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- When 'car wars' is the titl... | SELECT "Original air date" FROM table_1861 WHERE "Title" = 'Car Wars' | wikisql |
CREATE TABLE table_22787 (
"Match no." real,
"Match Type" text,
"Team Europe" text,
"Score" text,
"Team USA" text,
"Progressive Total" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What's the match number where Bill Hoffman plays for Team USA?
| SELECT MIN("Match no.") FROM table_22787 WHERE "Team USA" = 'Bill Hoffman' | wikisql |
CREATE TABLE dual_carrier (
main_airline varchar,
low_flight_number int,
high_flight_number int,
dual_airline varchar,
service_name text
)
CREATE TABLE days (
days_code varchar,
day_name varchar
)
CREATE TABLE flight_fare (
flight_id int,
fare_id int
)
CREATE TABLE fare (
fare... | SELECT DISTINCT flight.flight_id FROM airport_service AS AIRPORT_SERVICE_0, airport_service AS AIRPORT_SERVICE_1, city AS CITY_0, city AS CITY_1, days, flight WHERE (((CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'BOSTON' AND days.day_name = 'TUESDAY' AND flight.flight_days = days.days_code AND... | atis |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.