instruction stringlengths 151 7.46k | output stringlengths 2 4.44k | source stringclasses 26
values |
|---|---|---|
CREATE TABLE table_64888 (
"Final" text,
"Date" text,
"Home Team" text,
"Score" text,
"Away Team" text,
"Attendance" real,
"Stadium" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What stadium had the score 1 - 1 dodd 38'?
| SELECT "Stadium" FROM table_64888 WHERE "Score" = '1 - 1 dodd 38' | wikisql |
CREATE TABLE table_35765 (
"Date" text,
"Visitor" text,
"Score" text,
"Home" text,
"Record" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who was the visiting team on January 27?
| SELECT "Visitor" FROM table_35765 WHERE "Date" = 'january 27' | wikisql |
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 WHERE t_kc21.PERSON_NM = '杨艳芳' AND t_kc21.IN_HOSP_DATE BETWEEN '2017-04-12' AND '2018-08-25' AND t_kc21.CLINIC_TYPE = '住院' | css |
CREATE TABLE table_31790 (
"Week" real,
"Date" text,
"Opponent" text,
"Result" text,
"Attendance" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the total attendance on December 14, 1975 after week 13?
| SELECT COUNT("Attendance") FROM table_31790 WHERE "Date" = 'december 14, 1975' AND "Week" > '13' | wikisql |
CREATE TABLE table_name_46 (
location VARCHAR,
stadium VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the Location of the Hietalahti Stadium?
| SELECT location FROM table_name_46 WHERE stadium = "hietalahti stadium" | sql_create_context |
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 lab ON demographic.hadm_id = lab.hadm_id WHERE lab.flag = "delta" AND lab.label = "Thyroxine (T4), Free" | mimicsql_data |
CREATE TABLE ReviewTaskResultTypes (
Id number,
Name text,
Description text
)
CREATE TABLE PostFeedback (
Id number,
PostId number,
IsAnonymous boolean,
VoteTypeId number,
CreationDate time
)
CREATE TABLE SuggestedEditVotes (
Id number,
SuggestedEditId number,
UserId number... | SELECT PostLinks.RelatedPostId AS "post_link", COUNT(*) AS Times FROM Posts INNER JOIN PostHistory ON PostHistory.PostId = Posts.Id INNER JOIN PostLinks ON PostLinks.PostId = Posts.Id WHERE NOT Posts.ClosedDate IS NULL AND PostLinks.LinkTypeId = 3 AND PostHistory.Comment IN ('1', '101') GROUP BY PostLinks.RelatedPostId... | sede |
CREATE TABLE table_name_58 (
class VARCHAR,
co_drivers VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the class of the co-driver emanuele pirro jj lehto?
| SELECT class FROM table_name_58 WHERE co_drivers = "emanuele pirro jj lehto" | sql_create_context |
CREATE TABLE table_29635 (
"#" real,
"Title" text,
"Directed by" text,
"Written by" text,
"Viewers" real,
"Original airdate" text,
"Prod. code" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the original air date of the episode with ... | SELECT "Original airdate" FROM table_29635 WHERE "Viewers" = '908000' | wikisql |
CREATE TABLE table_name_20 (
record VARCHAR,
opponent VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is Bob Ostovich's opponents record?
| SELECT record FROM table_name_20 WHERE opponent = "bob ostovich" | sql_create_context |
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 * FROM person_info JOIN hz_info JOIN wdmzjzjlb 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 WHERE person_info.XM = '李莹华' AND hz_info.YLJGDM = '4179709' AND wdmzjzjlb.CYKSMC LIKE '%眼外伤%' UNION SELECT * FROM person_info JOIN ... | css |
CREATE TABLE table_1089 (
"Call sign" text,
"Launched" text,
"Transmitting from" text,
"Coverage" text,
"Languages" text,
"Frequency" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What languages are spoken when call sign XEJAM is used?
| SELECT "Languages" FROM table_1089 WHERE "Call sign" = 'XEJAM' | wikisql |
CREATE TABLE microlab (
microlabid number,
patientunitstayid number,
culturesite text,
organism text,
culturetakentime time
)
CREATE TABLE treatment (
treatmentid number,
patientunitstayid number,
treatmentname text,
treatmenttime time
)
CREATE TABLE medication (
medicationid n... | SELECT patient.uniquepid FROM patient WHERE patient.patientunitstayid IN (SELECT diagnosis.patientunitstayid FROM diagnosis WHERE diagnosis.diagnosisname = 'polyuria - post atn diuresis' AND DATETIME(diagnosis.diagnosistime) <= DATETIME(CURRENT_TIME(), '-4 year')) | eicu |
CREATE TABLE table_name_73 (
outcome VARCHAR,
opponent VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the outcome of the match against Magdalena Maleeva?
| SELECT outcome FROM table_name_73 WHERE opponent = "magdalena maleeva" | 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 demographic (... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.diagnosis = "NEWBORN" AND lab.fluid = "Cerebrospinal Fluid (CSF)" | mimicsql_data |
CREATE TABLE table_32787 (
"Texas vs." text,
"Overall Record" text,
"at Austin" text,
"at Opponent's Venue" text,
"at Neutral Site" text,
"Last 5 Meetings" text,
"Last 10 Meetings" text,
"Current Streak" text
)
-- Using valid SQLite, answer the following questions for the tables provid... | SELECT "Last 5 Meetings" FROM table_32787 WHERE "Current Streak" = 'l 1' | wikisql |
CREATE TABLE table_36796 (
"Body" text,
"Equatorial diameter" text,
"Polar diameter" text,
"Equatorial bulge" text,
"Flattening ratio" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the Equatorial bulge of the Body: Earth?
| SELECT "Equatorial bulge" FROM table_36796 WHERE "Body" = 'earth' | wikisql |
CREATE TABLE table_5762 (
"Candidate" text,
"Party" text,
"Votes" text,
"Quotient" text,
"Municipality" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Votes of 27,391 has which quotient?
| SELECT "Quotient" FROM table_5762 WHERE "Votes" = '27,391' | wikisql |
CREATE TABLE table_20861261_4 (
choice INTEGER,
weight VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What's the choice score of the player who weights 303lb (137kg)?
| SELECT MIN(choice) FROM table_20861261_4 WHERE weight = "303lb (137kg)" | sql_create_context |
CREATE TABLE table_30058355_3 (
tues_23_aug VARCHAR,
thurs_25_aug VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is every entry for Tuesday August 23 when Thursday August 25 is 24' 31.87 92.282mph?
| SELECT tues_23_aug FROM table_30058355_3 WHERE thurs_25_aug = "24' 31.87 92.282mph" | sql_create_context |
CREATE TABLE table_name_69 (
opponent_in_the_final VARCHAR,
date VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What opponent in the final has October 9, 2005 as the date?
| SELECT opponent_in_the_final FROM table_name_69 WHERE date = "october 9, 2005" | sql_create_context |
CREATE TABLE table_18323 (
"District" text,
"Incumbent" text,
"Party" text,
"First elected" real,
"Result" text,
"Candidates" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- When was the first elected for district missouri 7?
| SELECT MIN("First elected") FROM table_18323 WHERE "District" = 'Missouri 7' | wikisql |
CREATE TABLE table_name_37 (
club VARCHAR,
drawn VARCHAR,
points_for VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who is the club that had 617 points and a draw of 0?
| SELECT club FROM table_name_37 WHERE drawn = "0" AND points_for = "617" | sql_create_context |
CREATE TABLE diagnosis (
diagnosisid number,
patientunitstayid number,
diagnosisname text,
diagnosistime time,
icd9code text
)
CREATE TABLE treatment (
treatmentid number,
patientunitstayid number,
treatmentname text,
treatmenttime time
)
CREATE TABLE intakeoutput (
intakeoutpu... | SELECT medication.drugstarttime FROM medication WHERE medication.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '017-37716')) AND medication.routeadmin = 'arterial' AND STRFTI... | eicu |
CREATE TABLE table_204_246 (
id number,
"department" text,
"total deputies" number,
"uninominal deputies" number,
"plurinominal deputies" number,
"special indigenous\nor campesino deputies" number,
"senators" number
)
-- Using valid SQLite, answer the following questions for the tables pro... | SELECT (SELECT "uninominal deputies" FROM table_204_246 WHERE "department" = 'oruro') > (SELECT "uninominal deputies" FROM table_204_246 WHERE "department" = 'la paz') | squall |
CREATE TABLE table_name_27 (
years VARCHAR,
transmission VARCHAR,
no_of_channels VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What years are listed for analogue cable with 35 channels?
| SELECT years FROM table_name_27 WHERE transmission = "analogue cable" AND no_of_channels = "35" | sql_create_context |
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 t_kc21.MED_ORG_DEPT_CD, t_kc21.MED_ORG_DEPT_NM, AVG(t_kc21.IN_HOSP_DAYS) FROM t_kc21 WHERE t_kc21.MED_SER_ORG_NO = '3701034' GROUP BY t_kc21.MED_ORG_DEPT_CD ORDER BY AVG(t_kc21.IN_HOSP_DAYS) | css |
CREATE TABLE table_name_99 (
result VARCHAR,
date VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the result on September 20?
| SELECT result FROM table_name_99 WHERE date = "september 20" | 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 SUM(t_kc24.MED_AMOUT) FROM t_kc24 WHERE t_kc24.MED_CLINIC_ID IN (SELECT t_kc24.MED_CLINIC_ID FROM t_kc24 WHERE t_kc24.t_kc21_MED_SER_ORG_NO = '2687252' AND t_kc24.t_kc21_MED_ORG_DEPT_NM = '小儿神经内科') AND t_kc24.CLINIC_SLT_DATE BETWEEN '2001-05-05' AND '2008-07-19' | css |
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 qtb.MED_CLINIC_ID FROM qtb WHERE qtb.PERSON_ID = '75572641' AND qtb.MED_CLINIC_ID IN (SELECT t_kc22.MED_CLINIC_ID FROM t_kc22 WHERE t_kc22.AMOUNT > 5155.81) UNION SELECT gyb.MED_CLINIC_ID FROM gyb WHERE gyb.PERSON_ID = '75572641' AND gyb.MED_CLINIC_ID IN (SELECT t_kc22.MED_CLINIC_ID FROM t_kc22 WHERE t_kc22.AMOU... | css |
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 ACC_Road, AVG(Team_ID) FROM basketball_match GROUP BY ACC_Road ORDER BY ACC_Road | nvbench |
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.diagnosis = "ABDOMINAL ABSCESS" AND prescriptions.drug_type = "MAIN" | mimicsql_data |
CREATE TABLE table_31189 (
"Year" text,
"Universities" real,
"No. of Students Signed up" real,
"% electricity reduction" text,
"Tonnes of CO2 Saved" real,
"\u00a3 Saved" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- When 337,000 is saved what i... | SELECT "% electricity reduction" FROM table_31189 WHERE "\u00a3 Saved" = '£337,000' | 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 hz_info (
KH text,
KLX number... | SELECT jyjgzbb.BGDH FROM hz_info JOIN mzjzjlb JOIN jyjgzbb ON hz_info.YLJGDM = mzjzjlb.YLJGDM AND hz_info.KH = mzjzjlb.KH AND hz_info.KLX = mzjzjlb.KLX AND mzjzjlb.YLJGDM = jyjgzbb.jybgb_YLJGDM_MZJZJLB AND mzjzjlb.JZLSH = jyjgzbb.jybgb_JZLSH_MZJZJLB WHERE hz_info.RYBH = '13423195' AND NOT jyjgzbb.BGDH IN (SELECT jyjgzb... | css |
CREATE TABLE table_15394 (
"Operator" text,
"Shipyard" text,
"Project" text,
"Commissioned" text,
"Status" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the commissioned with a 636.3 project, and ordered status?
| SELECT "Commissioned" FROM table_15394 WHERE "Project" = '636.3' AND "Status" = 'ordered' | wikisql |
CREATE TABLE mzjzjlb (
HXPLC number,
HZXM text,
JLSJ time,
JZJSSJ time,
JZKSBM text,
JZKSMC text,
JZKSRQ time,
JZLSH text,
JZZDBM text,
JZZDSM text,
JZZTDM number,
JZZTMC text,
KH text,
KLX number,
MJZH text,
ML number,
MZZYZDZZBM text,
MZZYZDZZMC ... | SELECT * 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.YLJGDM AND hz_info_mzjz... | 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 * 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_MZJZJLB AND jybgb.YLJGDM = jy... | css |
CREATE TABLE flight_leg (
flight_id int,
leg_number int,
leg_flight int
)
CREATE TABLE flight_stop (
flight_id int,
stop_number int,
stop_days text,
stop_airport text,
arrival_time int,
arrival_airline text,
arrival_flight_number int,
departure_time int,
departure_airlin... | 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, date_day, days, flight WHERE (CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'WASHINGTON' AND date_day.day_number = 23 AND date_day.month_number = 4 AN... | atis |
CREATE TABLE table_38803 (
"Season" text,
"Races" real,
"Podiums" real,
"Pole" real,
"FLap" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Can you tell me the sum of FLap that has the Pole larger than 0, and the Podiums of 6?
| SELECT SUM("FLap") FROM table_38803 WHERE "Pole" > '0' AND "Podiums" = '6' | wikisql |
CREATE TABLE table_2562572_9 (
cyrillic_name_other_names VARCHAR,
population__2011_ VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the cyrillic name for the settlement with the population of 2125?
| SELECT cyrillic_name_other_names FROM table_2562572_9 WHERE population__2011_ = 2125 | sql_create_context |
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 prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE demographic.admission_type = "ELECTIVE" AND prescriptions.drug = "Tacrolimus" | mimicsql_data |
CREATE TABLE table_name_64 (
channel VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the channel with a 2011 rating of 8.5?
| SELECT channel FROM table_name_64 WHERE 2011 = "8.5" | sql_create_context |
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 WHERE demographic.religion = "JEHOVAH'S WITNESS" | mimicsql_data |
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 HIRE_DATE, SUM(MANAGER_ID) FROM employees WHERE NOT DEPARTMENT_ID IN (SELECT DEPARTMENT_ID FROM departments WHERE MANAGER_ID BETWEEN 100 AND 200) ORDER BY SUM(MANAGER_ID) | nvbench |
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 * FROM person_info JOIN hz_info JOIN zyjzjlb ON person_info.RYBH = hz_info.RYBH AND hz_info.YLJGDM = zyjzjlb.YLJGDM AND hz_info.KH = zyjzjlb.KH AND hz_info.KLX = zyjzjlb.KLX WHERE person_info.XM = '褚宏放' AND hz_info.YLJGDM = '6199140' AND zyjzjlb.CYKSMC LIKE '%肿瘤科%' | css |
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.dod_year <= "2112.0" AND prescriptions.formulary_drug_cd = "INSULIN" | mimicsql_data |
CREATE TABLE food_service (
meal_code text,
meal_number int,
compartment text,
meal_description varchar
)
CREATE TABLE airport (
airport_code varchar,
airport_name text,
airport_location text,
state_code varchar,
country_name varchar,
time_zone_code varchar,
minimum_connect_... | 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 (CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'DENVER' AND flight.departure_time > 845 AND flight.to_airport = AIRPORT_SERVICE_1.airport... | atis |
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, SUM(DEPARTMENT_ID) FROM employees WHERE NOT DEPARTMENT_ID IN (SELECT DEPARTMENT_ID FROM departments WHERE MANAGER_ID BETWEEN 100 AND 200) ORDER BY SUM(DEPARTMENT_ID) DESC | nvbench |
CREATE TABLE table_1792 (
"Country" text,
"Population (2011)" real,
"GDP (nominal) (2010, US$ millions)" real,
"Military expenditures (2011, US$ millions)" real,
"Military expenditures (2011, % of GDP)" text,
"Defence expenditures, (2011, per capita)" real,
"Deployable military (2011, thousa... | SELECT "Country" FROM table_1792 WHERE "Deployable military (2011, thousands)" = '23' | wikisql |
CREATE TABLE grapes (
id number,
grape text,
color text
)
CREATE TABLE wine (
no number,
grape text,
winery text,
appelation text,
state text,
name text,
year number,
price number,
score number,
cases number,
drink text
)
CREATE TABLE appellations (
no numbe... | SELECT DISTINCT name FROM wine WHERE price > (SELECT MIN(price) FROM wine WHERE winery = "John Anthony") | spider |
CREATE TABLE Votes (
Id number,
PostId number,
VoteTypeId number,
UserId number,
CreationDate time,
BountyAmount number
)
CREATE TABLE Posts (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
... | SELECT CreationDate, ClosedDate, AnswerCount, ViewCount, CommentCount, Body FROM PostTags AS pt JOIN Posts AS q ON q.Id = pt.PostId JOIN Tags AS t ON t.Id = pt.TagId WHERE TagName IN ('python') AND NOT ClosedDate IS NULL GROUP BY CreationDate, ClosedDate, AnswerCount, ViewCount, CommentCount, Body ORDER BY CreationDate | sede |
CREATE TABLE table_64953 (
"Player" text,
"Current Club" text,
"Born" text,
"Debut" text,
"Manager" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Where was the player whose Current Club Elfsborg born?
| SELECT "Born" FROM table_64953 WHERE "Current Club" = 'elfsborg' | wikisql |
CREATE TABLE table_12807904_5 (
played VARCHAR,
tries_for VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what amount played tried for 60?
| SELECT COUNT(played) FROM table_12807904_5 WHERE tries_for = "60" | sql_create_context |
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 demographic.dob, demographic.days_stay FROM demographic WHERE demographic.subject_id = "2560" | mimicsql_data |
CREATE TABLE weather (
date TEXT,
max_temperature_f INTEGER,
mean_temperature_f INTEGER,
min_temperature_f INTEGER,
max_dew_point_f INTEGER,
mean_dew_point_f INTEGER,
min_dew_point_f INTEGER,
max_humidity INTEGER,
mean_humidity INTEGER,
min_humidity INTEGER,
max_sea_level_pre... | SELECT date, AVG(mean_humidity) FROM weather ORDER BY max_gust_speed_mph DESC LIMIT 3 | nvbench |
CREATE TABLE table_19208 (
"Competition" text,
"Stage" text,
"Result" text,
"Opponent" text,
"Position" text,
"Scorers" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who played in the series that resulted in matches with the following scores: 0... | SELECT "Opponent" FROM table_19208 WHERE "Result" = '0–3 0–8 0–1 0–2 0–3 1–4 0–9 0–5' | wikisql |
CREATE TABLE table_name_29 (
location_attendance VARCHAR,
high_rebounds VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Location/Attendance has High rebounds of lennox (7)?
| SELECT location_attendance FROM table_name_29 WHERE high_rebounds = "lennox (7)" | sql_create_context |
CREATE TABLE table_64137 (
"Club" text,
"Active" text,
"Wins" real,
"Losses" real,
"Draws" real,
"Percentage wins" text,
"Flags" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What's the most flags that had 473 wins and less than 633 losses?... | SELECT MAX("Flags") FROM table_64137 WHERE "Wins" = '473' AND "Losses" < '633' | wikisql |
CREATE TABLE ta (
campus_job_id int,
student_id int,
location varchar
)
CREATE TABLE course_prerequisite (
pre_course_id int,
course_id int
)
CREATE TABLE jobs (
job_id int,
job_title varchar,
description varchar,
requirement varchar,
city varchar,
state varchar,
countr... | SELECT DISTINCT COURSE_0.department, COURSE_0.name, COURSE_0.number FROM course AS COURSE_0, course AS COURSE_1, course_prerequisite WHERE (COURSE_1.number = 504 OR COURSE_1.number = 433) AND COURSE_0.course_id = course_prerequisite.pre_course_id AND COURSE_1.course_id = course_prerequisite.course_id AND COURSE_1.depar... | advising |
CREATE TABLE table_name_80 (
launch_date VARCHAR,
cospar_id VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- When was the satellite that has a COSPAR ID of 1967-042a launched?
| SELECT launch_date FROM table_name_80 WHERE cospar_id = "1967-042a" | sql_create_context |
CREATE TABLE PostNoticeTypes (
Id number,
ClassId number,
Name text,
Body text,
IsHidden boolean,
Predefined boolean,
PostNoticeDurationId number
)
CREATE TABLE ReviewRejectionReasons (
Id number,
Name text,
Description text,
PostTypeId number
)
CREATE TABLE Badges (
Id... | SELECT Id, Reputation, CreationDate, DisplayName, LastAccessDate, WebsiteUrl, Location, AboutMe, Views, UpVotes, DownVotes, ProfileImageUrl, Age, AccountId FROM Users WHERE Id = '##UserId##' | sede |
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 WHERE demographic.admission_type = "ELECTIVE" AND demographic.dob_year < "2094" | mimicsql_data |
CREATE TABLE labevents (
row_id number,
subject_id number,
hadm_id number,
itemid number,
charttime time,
valuenum number,
valueuom text
)
CREATE TABLE prescriptions (
row_id number,
subject_id number,
hadm_id number,
startdate time,
enddate time,
drug text,
dose... | SELECT labevents.valuenum FROM labevents WHERE labevents.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 3403) AND labevents.itemid IN (SELECT d_labitems.itemid FROM d_labitems WHERE d_labitems.label = 'po2') AND STRFTIME('%y-%m', labevents.charttime) = '2105-07' ORDER BY labevents.c... | mimic_iii |
CREATE TABLE table_name_2 (
team VARCHAR,
best VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the team with best of 58.846
| SELECT team FROM table_name_2 WHERE best = "58.846" | sql_create_context |
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 lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.diagnosis = "NEWBORN" AND lab.flag = "delta" | mimicsql_data |
CREATE TABLE table_name_53 (
length VARCHAR,
song_title VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the average length for the song 'Ma Ke Jaisi'?
| SELECT length FROM table_name_53 WHERE song_title = "ma ke jaisi" | sql_create_context |
CREATE TABLE table_name_39 (
date VARCHAR,
score VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- When has a Score of 6 3, 6 4?
| SELECT date FROM table_name_39 WHERE score = "6–3, 6–4" | sql_create_context |
CREATE TABLE table_29049 (
"Date" text,
"Time" text,
"Visiting team" text,
"Home team" text,
"Site" text,
"Broadcast" text,
"Result" text,
"Attendance" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the result in the game broadc... | SELECT "Result" FROM table_29049 WHERE "Broadcast" = 'SEC Network' | wikisql |
CREATE TABLE table_name_61 (
build_date VARCHAR,
prr_class VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the build date of the model with a PRR Class of brs24?
| SELECT build_date FROM table_name_61 WHERE prr_class = "brs24" | sql_create_context |
CREATE TABLE table_26182 (
"Warship" text,
"tons ( L.ton )" text,
"Horse- power" real,
"Speed ( Knots )" real,
"Main Artillery" text,
"Built Year" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How man horse power did the ship covadonga have?
| SELECT "Horse- power" FROM table_26182 WHERE "Warship" = 'Covadonga' | wikisql |
CREATE TABLE table_name_71 (
developer_s_ VARCHAR,
year VARCHAR,
genre VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who were the developers for the Action RPG made after 2010?
| SELECT developer_s_ FROM table_name_71 WHERE year > 2010 AND genre = "action rpg" | sql_create_context |
CREATE TABLE airport_service (
city_code varchar,
airport_code varchar,
miles_distant int,
direction varchar,
minutes_distant int
)
CREATE TABLE code_description (
code varchar,
description text
)
CREATE TABLE airport (
airport_code varchar,
airport_name text,
airport_location ... | 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.departure_time <= 0 AND flight.departure_time >= 1200) AND CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'PHILADELPHIA' AND fli... | atis |
CREATE TABLE table_59214 (
"Player" text,
"Seasons" text,
"Games" text,
"Goals" text,
"Assists" text,
"Points" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many goals did the player score who had 33 assists in 85 games?
| SELECT "Goals" FROM table_59214 WHERE "Assists" = '33' AND "Games" = '85' | wikisql |
CREATE TABLE table_1153898_1 (
emulated_class VARCHAR,
comparisons VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Is usb re-enumeration required part of the emulated class?
| SELECT emulated_class FROM table_1153898_1 WHERE comparisons = "USB RE-Enumeration Required" | sql_create_context |
CREATE TABLE table_65800 (
"Date" text,
"Venue" text,
"Score" text,
"Result" text,
"Competition" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the venue when the score was 7-1?
| SELECT "Venue" FROM table_65800 WHERE "Score" = '7-1' | wikisql |
CREATE TABLE table_50088 (
"Date" real,
"Tournament" text,
"Surface" text,
"Partnering" text,
"Opponent in the final" text,
"Score" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which Opponent in the final has a Score of 6 3, 3 6, 6 8?
| SELECT "Opponent in the final" FROM table_50088 WHERE "Score" = '6–3, 3–6, 6–8' | wikisql |
CREATE TABLE table_name_64 (
position VARCHAR,
first_election VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the Position of the person with a First Election of 1988 as Vice Mayor 2009?
| SELECT position FROM table_name_64 WHERE first_election = "1988 as vice mayor 2009" | 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(*) FROM gwyjzb WHERE gwyjzb.MED_SER_ORG_NO = '7030360' AND gwyjzb.HOSP_STS > 0 UNION SELECT COUNT(*) FROM fgwyjzb WHERE fgwyjzb.MED_SER_ORG_NO = '7030360' AND fgwyjzb.HOSP_STS > 0 | css |
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 jyjgzbb (
BGDH text,
BGRQ tim... | SELECT jybgb.JYXMDM, jybgb.JYXMMC FROM jybgb WHERE jybgb.BGDH = '23522676937' | css |
CREATE TABLE table_204_70 (
id number,
"pick #" number,
"nfl team" text,
"player" text,
"position" text,
"college" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- how many players went to the miami dolphins ?
| SELECT COUNT("player") FROM table_204_70 WHERE "nfl team" = 'miami dolphins' | squall |
CREATE TABLE table_42556 (
"Date" text,
"Score" text,
"Set 1" text,
"Set 2" text,
"Set 3" text,
"Set 4" text,
"Set 5" text,
"Total" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which set 3 has a Set 1 of 19-25, and a Set 2 of 19-25?
| SELECT "Set 3" FROM table_42556 WHERE "Set 1" = '19-25' AND "Set 2" = '19-25' | wikisql |
CREATE TABLE medication (
medicationid number,
patientunitstayid number,
drugname text,
dosage text,
routeadmin text,
drugstarttime time,
drugstoptime time
)
CREATE TABLE intakeoutput (
intakeoutputid number,
patientunitstayid number,
cellpath text,
celllabel text,
cellv... | SELECT COUNT(*) > 0 FROM diagnosis WHERE diagnosis.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '006-42293')) AND diagnosis.diagnosisname = 'hypovolemic shock - inadequate i... | eicu |
CREATE TABLE table_41203 (
"Year" real,
"Competition" text,
"Club" text,
"Nation" text,
"Result" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the Club of mexico, Year of 2010, and a Competition of preseason, and a Result of w 0 1?
| SELECT "Club" FROM table_41203 WHERE "Nation" = 'mexico' AND "Year" = '2010' AND "Competition" = 'preseason' AND "Result" = 'w 0–1' | wikisql |
CREATE TABLE table_name_48 (
time VARCHAR,
set_1 VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the time when the set 1 is 21 25?
| SELECT time FROM table_name_48 WHERE set_1 = "21–25" | sql_create_context |
CREATE TABLE table_28716 (
"Monarch" text,
"Heir" text,
"Status" text,
"Relationship to Monarch" text,
"Became heir; reason" text,
"Ceased to be heir; reason" text,
"Next in succession" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who was ... | SELECT "Monarch" FROM table_28716 WHERE "Status" = 'Heir presumptive' AND "Relationship to Monarch" = 'son' | wikisql |
CREATE TABLE mzjzjlb (
HXPLC number,
HZXM text,
JLSJ time,
JZJSSJ time,
JZKSBM text,
JZKSMC text,
JZKSRQ time,
JZLSH text,
JZZDBM text,
JZZDSM text,
JZZTDM number,
JZZTMC text,
KH text,
KLX number,
MJZH text,
ML number,
MZZYZDZZBM text,
MZZYZDZZMC ... | SELECT jybgb.SQRGH, jybgb.SQRXM FROM jybgb WHERE jybgb.BGDH = '77601421796' | css |
CREATE TABLE table_28677723_14 (
style VARCHAR,
total VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the style for 39
| SELECT style FROM table_28677723_14 WHERE total = 39 | sql_create_context |
CREATE TABLE table_21146729_6 (
director VARCHAR,
writer_s_ VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who was the director when the writer(s) was John W. Bloch?
| SELECT director FROM table_21146729_6 WHERE writer_s_ = "John W. Bloch" | sql_create_context |
CREATE TABLE table_name_85 (
combined_consumption VARCHAR,
code VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the combined consumption of the engine with the code k9k 796?
| SELECT combined_consumption FROM table_name_85 WHERE code = "k9k 796" | sql_create_context |
CREATE TABLE Tryout (
pID numeric(5,0),
cName varchar(20),
pPos varchar(8),
decision varchar(3)
)
CREATE TABLE Player (
pID numeric(5,0),
pName varchar(20),
yCard varchar(3),
HS numeric(5,0)
)
CREATE TABLE College (
cName varchar(20),
state varchar(2),
enr numeric(5,0)
)
... | SELECT pPos, MIN(T2.HS) FROM Tryout AS T1 JOIN Player AS T2 ON T1.pID = T2.pID GROUP BY pPos ORDER BY pPos DESC | nvbench |
CREATE TABLE table_5072 (
"Team" text,
"Driver" text,
"Laps" real,
"Time" text,
"Grid" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what driver has 12 in grid?
| SELECT "Driver" FROM table_5072 WHERE "Grid" = '12' | wikisql |
CREATE TABLE table_41074 (
"Position" text,
"Name v t e" text,
"Height (cm)" real,
"Weight (kg)" real,
"Birthplace" text,
"1999-2000 team" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the 1999-2000 team, when the Height (cm) is less th... | SELECT "1999-2000 team" FROM table_41074 WHERE "Height (cm)" < '187' AND "Birthplace" = 'cloquet, minnesota' | wikisql |
CREATE TABLE table_204_23 (
id number,
"#" number,
"wrestlers" text,
"reign" number,
"date" text,
"days held" number,
"location" text,
"event" text,
"notes" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what event comes before hardc... | SELECT "event" FROM table_204_23 WHERE id = (SELECT id FROM table_204_23 WHERE "event" = 'hardcore tv #14') - 1 | squall |
CREATE TABLE table_42436 (
"Round" real,
"Pick #" real,
"Player" text,
"Position" text,
"College" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What's the average draft pick number from Carson-Newman College before Round 7?
| SELECT AVG("Pick #") FROM table_42436 WHERE "College" = 'carson-newman' AND "Round" < '7' | wikisql |
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 demographic (... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN procedures ON demographic.hadm_id = procedures.hadm_id WHERE procedures.short_title = "Coronary arteriogram NEC" | mimicsql_data |
CREATE TABLE table_25426 (
"Date" text,
"Location" text,
"Opponent" text,
"Cards Points" real,
"Opp. Points" real,
"Record" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the record for kentucky
| SELECT "Record" FROM table_25426 WHERE "Opponent" = 'Kentucky' | wikisql |
CREATE TABLE table_65731 (
"Round" real,
"Pick" real,
"Player" text,
"Nationality" text,
"College" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many picks did Jay Bruchak have?
| SELECT COUNT("Pick") FROM table_65731 WHERE "Player" = 'jay bruchak' | wikisql |
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 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 '2003-04-08' AND '2013-01-06' AND t_kc22.MED_INV_ITEM_TYPE = '检查费' | css |
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 t3.drugname FROM (SELECT t2.drugname, DENSE_RANK() OVER (ORDER BY COUNT(*) DESC) AS c1 FROM (SELECT patient.uniquepid, diagnosis.diagnosistime FROM diagnosis JOIN patient ON diagnosis.patientunitstayid = patient.patientunitstayid WHERE diagnosis.diagnosisname = 'acute respiratory failure' AND DATETIME(diagnosis.... | eicu |
CREATE TABLE hz_info_mzjzjlb (
JZLSH number,
YLJGDM number,
mzjzjlb_id number
)
CREATE TABLE mzjzjlb (
HXPLC number,
HZXM text,
JLSJ time,
JZJSSJ time,
JZKSBM text,
JZKSMC text,
JZKSRQ time,
JZLSH text,
JZZDBM text,
JZZDSM text,
JZZTDM number,
JZZTMC text,
... | SELECT AVG(jyjgzbb.JCZBJGDL), MIN(jyjgzbb.JCZBJGDL), MAX(jyjgzbb.JCZBJGDL) FROM mzjzjlb JOIN jybgb JOIN jyjgzbb JOIN hz_info_mzjzjlb ON hz_info_mzjzjlb.YLJGDM = jybgb.YLJGDM_MZJZJLB AND mzjzjlb.JZLSH = jybgb.JZLSH_MZJZJLB AND jybgb.YLJGDM = jyjgzbb.YLJGDM AND jybgb.BGDH = jyjgzbb.BGDH AND hz_info_mzjzjlb.JZLSH = mzjzjl... | css |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.