context stringlengths 11 9.12k | question stringlengths 0 1.06k | SQL stringlengths 2 4.44k | source stringclasses 28
values |
|---|---|---|---|
CREATE TABLE d_icd_diagnoses (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE inputevents_cv (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime time,
itemid number,
amount number
)
CREATE TABLE chartevents (
... | tell me the dose of d5w (glass bottle) that patient 65582 had been prescribed in this month? | SELECT SUM(prescriptions.dose_val_rx) FROM prescriptions WHERE prescriptions.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 65582) AND prescriptions.drug = 'd5w (glass bottle)' AND DATETIME(prescriptions.startdate, 'start of month') = DATETIME(CURRENT_TIME(), 'start of month', '-0 m... | mimic_iii |
CREATE TABLE table_name_61 (
australian VARCHAR,
british VARCHAR
) | Which Australian has British of s? | SELECT australian FROM table_name_61 WHERE british = "ɒs" | sql_create_context |
CREATE TABLE table_27527 (
"June 10-11" text,
"March 27-29" text,
"January 15-16" text,
"November 3" text,
"August 21-22" text
) | During November 3 where august 21-22 is august 21, 2017? | SELECT "November 3" FROM table_27527 WHERE "August 21-22" = 'August 21, 2017' | wikisql |
CREATE TABLE table_75449 (
"Round" real,
"Pick" real,
"Player" text,
"Position" text,
"School/Club Team" text
) | Where did steve smith go to school? | SELECT "School/Club Team" FROM table_75449 WHERE "Player" = 'steve smith' | wikisql |
CREATE TABLE d_icd_diagnoses (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE chartevents (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
itemid number,
charttime time,
valuenum number,
valueuom text
)
CREATE TABLE... | did the platelet count value of patient 15986 last measured on the current hospital visit be less than second to last measured on the current hospital visit? | SELECT (SELECT labevents.valuenum FROM labevents WHERE labevents.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 15986 AND admissions.dischtime IS NULL) AND labevents.itemid IN (SELECT d_labitems.itemid FROM d_labitems WHERE d_labitems.label = 'platelet count') ORDER BY labevents.cha... | mimic_iii |
CREATE TABLE table_41335 (
"Rider" text,
"Bike" text,
"Laps" real,
"Time" text,
"Grid" real
) | How many laps had a time of +2.987? | SELECT COUNT("Laps") FROM table_41335 WHERE "Time" = '+2.987' | wikisql |
CREATE TABLE mzb (
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... | 列一下患者22859306在8775191这家医院的就诊记录中,在零七年十一月八号到一三年十月二十六这段时间里开出的全部药品名字和编号 | SELECT t_kc22.SOC_SRT_DIRE_CD, t_kc22.SOC_SRT_DIRE_NM FROM t_kc22 WHERE t_kc22.MED_CLINIC_ID IN (SELECT qtb.MED_CLINIC_ID FROM qtb WHERE qtb.PERSON_ID = '22859306' AND qtb.MED_SER_ORG_NO = '8775191' AND qtb.IN_HOSP_DATE BETWEEN '2007-11-08' AND '2013-10-26' UNION SELECT gyb.MED_CLINIC_ID FROM gyb WHERE gyb.PERSON_ID = ... | css |
CREATE TABLE table_33320 (
"Home team" text,
"Home team score" text,
"Away team" text,
"Away team score" text,
"Venue" text,
"Crowd" real,
"Date" text
) | What was Hawthorn's score when they were the home team? | SELECT "Home team score" FROM table_33320 WHERE "Home team" = 'hawthorn' | wikisql |
CREATE TABLE table_15672 (
"Year" real,
"Entrant" text,
"Chassis" text,
"Engine" text,
"Points" real
) | What year did Cooper Car Company enter? | SELECT AVG("Year") FROM table_15672 WHERE "Entrant" = 'cooper car company' | wikisql |
CREATE TABLE table_64647 (
"Year" real,
"Title" text,
"From album" text,
"Label" text,
"Label-Nr" text
) | Which Label-Nr has a Year smaller than 1968, and a Label of world pacific, and an album of chile con soul? | SELECT "Label-Nr" FROM table_64647 WHERE "Year" < '1968' AND "Label" = 'world pacific' AND "From album" = 'chile con soul' | wikisql |
CREATE TABLE table_14884844_2 (
location VARCHAR,
athletes VARCHAR
) | What are all the places where Birgit Fischer competed? | SELECT location FROM table_14884844_2 WHERE athletes = "Birgit Fischer" | sql_create_context |
CREATE TABLE table_36340 (
"Volume" text,
"Discs" real,
"Episodes" real,
"Region 1 release" text,
"Region 2 release" text,
"Region 4 release" text
) | What is the average episode that has September 11, 2007 as a region 1? | SELECT AVG("Episodes") FROM table_36340 WHERE "Region 1 release" = 'september 11, 2007' | wikisql |
CREATE TABLE table_69013 (
"Year" text,
"Venue" text,
"Winners" text,
"Runner-up" text,
"3rd place" text
) | What shows for Winners when it shows 3rd place of [[|]] (21 pts), and a Runner-up of united states (23 pts)? | SELECT "Winners" FROM table_69013 WHERE "3rd place" = '[[|]] (21 pts)' AND "Runner-up" = 'united states (23 pts)' | wikisql |
CREATE TABLE icustays (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
first_careunit text,
last_careunit text,
first_wardid number,
last_wardid number,
intime time,
outtime time
)
CREATE TABLE d_icd_procedures (
row_id number,
icd9_code text,
s... | how much does it cost to receive a diagnosis for leukocytosis nos? | 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 = 'leukocytosis nos')) | mimic_iii |
CREATE TABLE table_name_49 (
round VARCHAR,
pick VARCHAR,
school VARCHAR
) | In what Round does Duke have a Pick larger than 9? | SELECT COUNT(round) FROM table_name_49 WHERE pick > 9 AND school = "duke" | sql_create_context |
CREATE TABLE table_29109 (
"Series #" real,
"Season #" real,
"Title" text,
"Director" text,
"Writer" text,
"Original Airdate" text
) | What are the original air date(s) for season episode 20? | SELECT "Original Airdate" FROM table_29109 WHERE "Season #" = '20' | wikisql |
CREATE TABLE table_57237 (
"Res." text,
"Record" text,
"Opponent" text,
"Method" text,
"Round" text,
"Time" text,
"Location" text
) | What's the time for a round of n/a when the opponent is mikhail ilyukhin? | SELECT "Time" FROM table_57237 WHERE "Round" = 'n/a' AND "Opponent" = 'mikhail ilyukhin' | wikisql |
CREATE TABLE table_203_558 (
id number,
"election" number,
"number of\npopular votes" number,
"% of\npopular votes" number,
"total\nelected seats" text,
"+/-" number
) | how many total elected seats in 1991 ? | SELECT "total\nelected seats" FROM table_203_558 WHERE "election" = 1991 | squall |
CREATE TABLE table_28701 (
"No. in series" real,
"No. in season" real,
"Title" text,
"Directed by" text,
"Written by" text,
"Original air date" text,
"Production code" real,
"U.S. viewers (millions)" text
) | How many air dates had 3.2 million viewers? | SELECT COUNT("Original air date") FROM table_28701 WHERE "U.S. viewers (millions)" = '3.2' | wikisql |
CREATE TABLE table_67546 (
"Outcome" text,
"Date" text,
"Tournament" text,
"Surface" text,
"Partner" text,
"Opponents in the final" text,
"Score in the final" text
) | With Lindsay Lee-Waters as a partner, what was the final score? | SELECT "Score in the final" FROM table_67546 WHERE "Partner" = 'lindsay lee-waters' | wikisql |
CREATE TABLE PostNotices (
Id number,
PostId number,
PostNoticeTypeId number,
CreationDate time,
DeletionDate time,
ExpiryDate time,
Body text,
OwnerUserId number,
DeletionUserId number
)
CREATE TABLE Comments (
Id number,
PostId number,
Score number,
Text text,
... | Account Age Distribution for 10k+ Users. | SELECT DATEDIFF(month, CreationDate, GETDATE()) AS Age, COUNT(*) AS "count" FROM Users WHERE Reputation >= 10000 AND DATEDIFF(month, CreationDate, GETDATE()) <= '##MaxAge:int?120##' GROUP BY DATEDIFF(month, CreationDate, GETDATE()) ORDER BY Age | sede |
CREATE TABLE procedures (
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
)
... | what is insurance of subject id 990? | SELECT demographic.insurance FROM demographic WHERE demographic.subject_id = "990" | mimicsql_data |
CREATE TABLE table_17103729_8 (
score VARCHAR,
game VARCHAR
) | Name the score for game for 25 | SELECT score FROM table_17103729_8 WHERE game = 25 | sql_create_context |
CREATE TABLE table_28283535_4 (
date_aired VARCHAR,
episode VARCHAR
) | When did the episode 1.13 air for the first time? | SELECT date_aired FROM table_28283535_4 WHERE episode = "1.13" | sql_create_context |
CREATE TABLE patients (
row_id number,
subject_id number,
gender text,
dob time,
dod time
)
CREATE TABLE inputevents_cv (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime time,
itemid number,
amount number
)
CREATE TABLE prescriptions (
... | how many patients were diagnosed with crnry athrscl natve vssl within the same month since 5 years ago after the diagnosis of rheumatoid arthritis? | SELECT COUNT(DISTINCT t1.subject_id) 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 d_icd_diagnoses.short_title = 'crnry athrscl natv... | mimic_iii |
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... | 患者90265376的全部检查结果指标记录在在00年7月28日到11年6月19日内的质检人为32482264的检测指标流水号是多少? | SELECT jyjgzbb.JYZBLSH 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.BGD... | css |
CREATE TABLE table_66353 (
"Rank" real,
"Rowers" text,
"Country" text,
"Time" text,
"Notes" text
) | Who are the Rowers from Poland? | SELECT "Rowers" FROM table_66353 WHERE "Country" = 'poland' | 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... | 看看医院0002177有多少科室在门诊就诊中开出少于23张检验报告单,时间为2002年6月17日到2007年12月6日 | SELECT COUNT(*) FROM (SELECT jybgb.KSBM FROM zzmzjzjlb JOIN jybgb ON zzmzjzjlb.YLJGDM = jybgb.YLJGDM_MZJZJLB AND zzmzjzjlb.JZLSH = jybgb.JZLSH_MZJZJLB WHERE zzmzjzjlb.YLJGDM = '0002177' AND jybgb.BGRQ BETWEEN '2002-06-17' AND '2007-12-06' GROUP BY jybgb.KSBM HAVING COUNT(*) < 23 UNION SELECT jybgb.KSBM FROM fzzmzjzjlb ... | css |
CREATE TABLE table_name_70 (
total INTEGER,
bronze VARCHAR,
rank VARCHAR,
silver VARCHAR
) | What is the lowest total that has a rank less than 8, a silver greater than 6, and 20 as the bronze? | SELECT MIN(total) FROM table_name_70 WHERE rank < 8 AND silver > 6 AND bronze = 20 | sql_create_context |
CREATE TABLE PostHistoryTypes (
Id number,
Name text
)
CREATE TABLE ReviewTaskTypes (
Id number,
Name text,
Description text
)
CREATE TABLE PostTypes (
Id number,
Name text
)
CREATE TABLE PostLinks (
Id number,
CreationDate time,
PostId number,
RelatedPostId number,
Li... | Top 25 users from Thailand. | SELECT ROW_NUMBER() OVER (ORDER BY Reputation DESC) AS Rank, Id, DisplayName, Reputation, WebsiteUrl, Location FROM Users WHERE Location LIKE '%Thailand%' LIMIT 25 | sede |
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 PostTypes (
Id number,
Name text
)
C... | Top users from Innsbruck, Austria. | SELECT ROW_NUMBER() OVER (ORDER BY Reputation DESC) AS "#", Id AS "user_link", Reputation FROM Users WHERE LOWER(Location) LIKE '%innsbruck%' OR UPPER(Location) LIKE '%INNSBRUCK%' OR Location LIKE '%Innsbruck%' ORDER BY Reputation DESC | sede |
CREATE TABLE restaurant (
id int,
name varchar,
food_type varchar,
city_name varchar,
rating "decimal
)
CREATE TABLE location (
restaurant_id int,
house_number int,
street_name varchar,
city_name varchar
)
CREATE TABLE geographic (
city_name varchar,
county varchar,
reg... | where are some restaurants good for french food ? | SELECT location.house_number, restaurant.name FROM location, restaurant WHERE restaurant.food_type = 'french' AND restaurant.id = location.restaurant_id AND restaurant.rating > 2.5 | restaurants |
CREATE TABLE table_name_9 (
loss VARCHAR,
time VARCHAR
) | Who lost with a time of 2:42? | SELECT loss FROM table_name_9 WHERE time = "2:42" | sql_create_context |
CREATE TABLE table_15187735_8 (
segment_b VARCHAR,
segment_c VARCHAR
) | Name the segment b for graphite s fly rod | SELECT segment_b FROM table_15187735_8 WHERE segment_c = "Graphite s Fly Rod" | sql_create_context |
CREATE TABLE table_train_262 (
"id" int,
"gender" string,
"hemoglobin_a1c_hba1c" float,
"obesity" bool,
"diabetic" string,
"hba1c" float,
"body_mass_index_bmi" float,
"age" float,
"NOUSE" float
) | diagnosed with type ii diabetes for at least one year | SELECT * FROM table_train_262 WHERE diabetic = 'ii' | criteria2sql |
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... | 2371026这家医院的全部医疗就诊记录里,依照科室的区别查一查统筹基金的花费比上全部的医疗费得到的平均比值 | SELECT t_kc24.t_kc21_MED_ORG_DEPT_NM, AVG(t_kc24.OVE_PAY) FROM t_kc24 WHERE t_kc24.t_kc21_MED_SER_ORG_NO = '2371026' GROUP BY t_kc24.t_kc21_MED_ORG_DEPT_NM | css |
CREATE TABLE Engineer_Visits (
Id VARCHAR
)
CREATE TABLE Maintenance_Engineers (
engineer_id VARCHAR,
first_name VARCHAR,
last_name VARCHAR
) | Which engineer has visited the most times? Show the engineer id, first name and last name. | SELECT T1.engineer_id, T1.first_name, T1.last_name FROM Maintenance_Engineers AS T1 JOIN Engineer_Visits AS T2 GROUP BY T1.engineer_id ORDER BY COUNT(*) DESC LIMIT 1 | sql_create_context |
CREATE TABLE table_name_27 (
transfer_fee VARCHAR,
ends VARCHAR,
moving_from VARCHAR
) | Which Transfer fee has Ends larger than 2011, and a Moving from of psv? | SELECT transfer_fee FROM table_name_27 WHERE ends > 2011 AND moving_from = "psv" | sql_create_context |
CREATE TABLE Products (
Code INTEGER,
Name VARCHAR(255),
Price DECIMAL,
Manufacturer INTEGER
)
CREATE TABLE Manufacturers (
Code INTEGER,
Name VARCHAR(255),
Headquarter VARCHAR(255),
Founder VARCHAR(255),
Revenue REAL
) | For those records from the products and each product's manufacturer, find founder and the average of revenue , and group by attribute founder, and visualize them by a bar chart. | SELECT Founder, AVG(Revenue) FROM Products AS T1 JOIN Manufacturers AS T2 ON T1.Manufacturer = T2.Code GROUP BY Founder | nvbench |
CREATE TABLE Products (
Code INTEGER,
Name VARCHAR(255),
Price DECIMAL,
Manufacturer INTEGER
)
CREATE TABLE Manufacturers (
Code INTEGER,
Name VARCHAR(255),
Headquarter VARCHAR(255),
Founder VARCHAR(255),
Revenue REAL
) | For those records from the products and each product's manufacturer, show me about the distribution of name and the average of price , and group by attribute name in a bar chart, and could you display from high to low by the Name? | SELECT T1.Name, T1.Price FROM Products AS T1 JOIN Manufacturers AS T2 ON T1.Manufacturer = T2.Code GROUP BY T1.Name ORDER BY T1.Name DESC | nvbench |
CREATE TABLE table_78857 (
"Rank" real,
"Athlete" text,
"Nandao" real,
"Nanquan" real,
"Total" real
) | Which Nanquan has a Nandao larger than 9.49, and a Rank of 4? | SELECT "Nanquan" FROM table_78857 WHERE "Nandao" > '9.49' AND "Rank" = '4' | wikisql |
CREATE TABLE course (
course_id varchar(8),
title varchar(50),
dept_name varchar(20),
credits numeric(2,0)
)
CREATE TABLE section (
course_id varchar(8),
sec_id varchar(8),
semester varchar(6),
year numeric(4,0),
building varchar(15),
room_number varchar(7),
time_slot_id var... | Find the number of courses offered by Psychology department in each semester with a pie chart. | SELECT semester, COUNT(semester) FROM course AS T1 JOIN section AS T2 ON T1.course_id = T2.course_id WHERE T1.dept_name = 'Psychology' GROUP BY semester | nvbench |
CREATE TABLE table_7494 (
"Unemployment" text,
"2007-03" real,
"2008-03" real,
"2009-03" real,
"2010-03" real,
"2011-03" real,
"2012-03" real
) | What is the average 2011-03, when Unemployment is Sweden, and when 2009-03 is greater than 8? | SELECT AVG("2011-03") FROM table_7494 WHERE "Unemployment" = 'sweden' AND "2009-03" > '8' | wikisql |
CREATE TABLE table_name_75 (
sport VARCHAR,
medal VARCHAR,
event VARCHAR
) | Name the sport for men's light flyweight with medal of gold | SELECT sport FROM table_name_75 WHERE medal = "gold" AND event = "men's light flyweight" | sql_create_context |
CREATE TABLE table_49418 (
"Player" text,
"Country" text,
"Year(s) won" text,
"Total" real,
"To par" text,
"Finish" text
) | What is Player, when Country is 'United States', and when Year(s) Won is '1976'? | SELECT "Player" FROM table_49418 WHERE "Country" = 'united states' AND "Year(s) won" = '1976' | wikisql |
CREATE TABLE table_71102 (
"State" text,
"Preliminaries" real,
"Interview" real,
"Swimsuit" real,
"Evening Gown" real,
"Average" real
) | What is the lowest Preliminary score of a contestant that has an Evening Gown score of 8.472? | SELECT MIN("Preliminaries") FROM table_71102 WHERE "Evening Gown" = '8.472' | wikisql |
CREATE TABLE table_30886 (
"Code" text,
"Subdivision name ( be ) (BGN/PCGN)" text,
"Subdivision name ( be ) (GOST)" text,
"Subdivision name ( ru ) (BGN/PCGN)" text,
"Subdivision name ( ru ) (GOST)" text,
"Subdivision category" text
) | What are the subdivision names (RU) where the subdivision name (BE) is Hrodzenskaya Voblasts'? | SELECT "Subdivision name ( ru ) (GOST)" FROM table_30886 WHERE "Subdivision name ( be ) (BGN/PCGN)" = 'Hrodzenskaya voblasts' | wikisql |
CREATE TABLE table_1013129_11 (
nhl_team VARCHAR,
college_junior_club_team VARCHAR
) | What teams do the players from TPS (Finland) play for? | SELECT nhl_team FROM table_1013129_11 WHERE college_junior_club_team = "TPS (Finland)" | sql_create_context |
CREATE TABLE jybgb (
YLJGDM text,
YLJGDM_MZJZJLB text,
YLJGDM_ZYJZJLB text,
BGDH text,
BGRQ time,
JYLX number,
JZLSH text,
JZLSH_MZJZJLB text,
JZLSH_ZYJZJLB text,
JZLX number,
KSBM text,
KSMC text,
SQRGH text,
SQRXM text,
BGRGH text,
BGRXM text,
SHRGH ... | 我想知道病人79373971在2004年4月25日到2019年4月28日内开出的所有检验报告单的科室编码以及名称都是哪些? | (SELECT jybgb.KSBM, jybgb.KSMC FROM hz_info JOIN mzjzjlb JOIN jybgb 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 WHERE hz_info.RYBH = '79373971' AND jybgb.BGRQ BETWEEN '2004-04-25' AND '2019... | 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,
... | what is procedure short title of subject name jerry deberry? | SELECT procedures.short_title FROM demographic INNER JOIN procedures ON demographic.hadm_id = procedures.hadm_id WHERE demographic.name = "Jerry Deberry" | mimicsql_data |
CREATE TABLE microbiologyevents (
row_id number,
subject_id number,
hadm_id number,
charttime time,
spec_type_desc text,
org_name text
)
CREATE TABLE cost (
row_id number,
subject_id number,
hadm_id number,
event_type text,
event_id number,
chargetime time,
cost numb... | when did patient 49176 receive an mcv laboratory test for the first time since 01/2105? | SELECT labevents.charttime FROM labevents WHERE labevents.itemid IN (SELECT d_labitems.itemid FROM d_labitems WHERE d_labitems.label = 'mcv') AND labevents.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 49176) AND STRFTIME('%y-%m', labevents.charttime) >= '2105-01' ORDER BY labevent... | mimic_iii |
CREATE TABLE table_name_93 (
format VARCHAR,
region VARCHAR
) | Which Format is listed that has a Region of China? | SELECT format FROM table_name_93 WHERE region = "china" | sql_create_context |
CREATE TABLE patients (
row_id number,
subject_id number,
gender text,
dob time,
dod time
)
CREATE TABLE icustays (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
first_careunit text,
last_careunit text,
first_wardid number,
last_wardid number,
... | what are the five most frequently given diagnoses for patients who had oth chest cage ostectomy before within 2 months, until 4 years ago? | SELECT d_icd_diagnoses.short_title FROM d_icd_diagnoses WHERE d_icd_diagnoses.icd9_code IN (SELECT t3.icd9_code FROM (SELECT t2.icd9_code, DENSE_RANK() OVER (ORDER BY COUNT(*) DESC) AS c1 FROM (SELECT admissions.subject_id, procedures_icd.charttime FROM procedures_icd JOIN admissions ON procedures_icd.hadm_id = admissi... | mimic_iii |
CREATE TABLE table_name_22 (
opponent VARCHAR,
score VARCHAR
) | Who did the Rockies play at the game that had a score of 6 5 (10)? | SELECT opponent FROM table_name_22 WHERE score = "6–5 (10)" | sql_create_context |
CREATE TABLE table_22826 (
"DMA" real,
"Market" text,
"Station" text,
"Frequency" text,
"Branding" text,
"Format" text
) | What is the dma when the format is rhythmic contemporary? | SELECT MIN("DMA") FROM table_22826 WHERE "Format" = 'Rhythmic Contemporary' | wikisql |
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 cost (
costid number,
... | how many patients until 2104 were diagnosed with gi bleeding within 2 months after they underwent glucose - d10w? | SELECT COUNT(DISTINCT t1.uniquepid) FROM (SELECT patient.uniquepid, treatment.treatmenttime FROM treatment JOIN patient ON treatment.patientunitstayid = patient.patientunitstayid WHERE treatment.treatmentname = 'glucose - d10w' AND STRFTIME('%y', treatment.treatmenttime) <= '2104') AS t1 JOIN (SELECT patient.uniquepid,... | eicu |
CREATE TABLE table_name_32 (
catalog VARCHAR,
label VARCHAR,
date VARCHAR,
format VARCHAR,
region VARCHAR
) | What is Catalog, when Format is CD, when Region is US, when Date is before 2004, and when Label is Taang! Records? | SELECT catalog FROM table_name_32 WHERE format = "cd" AND region = "us" AND date < 2004 AND label = "taang! records" | sql_create_context |
CREATE TABLE table_4368 (
"Outcome" text,
"Date" text,
"Tournament" text,
"Surface" text,
"Opponent" text,
"Score" text
) | Tell me the surface for eastbourne 14 june 1999 | SELECT "Surface" FROM table_4368 WHERE "Tournament" = 'eastbourne' AND "Date" = '14 june 1999' | 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... | 这位褚泰鸿的患者在11年1月20日到21年4月6日期间医保的医疗总消费金额有多少 | SELECT SUM(t_kc24.MED_AMOUT) 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 '2011-01-20' AND '2021-04-06' | css |
CREATE TABLE table_20889 (
"Archbishop" text,
"Born" text,
"Ordained Priest" text,
"Ordained Bishop" text,
"Appointed Archbishop" text,
"Vacated throne" text,
"Died" text
) | What is the death date of the archbishop who was ordained as bishop April 26, 1927? | SELECT "Died" FROM table_20889 WHERE "Ordained Bishop" = 'April 26, 1927' | wikisql |
CREATE TABLE table_27406 (
"Year" real,
"Date" text,
"Intended Victim(s)" text,
"Title at the Time" text,
"Location" text,
"Would-be Assassin(s)" text,
"Method" text,
"Initial Outcome / Notes" text
) | What is the first year where the assassination attempt was at Martyrs' Mausoleum, Rangoon, Burma? | SELECT MIN("Year") FROM table_27406 WHERE "Location" = 'Martyrs'' Mausoleum, Rangoon, Burma' | wikisql |
CREATE TABLE PostNoticeTypes (
Id number,
ClassId number,
Name text,
Body text,
IsHidden boolean,
Predefined boolean,
PostNoticeDurationId number
)
CREATE TABLE PostHistoryTypes (
Id number,
Name text
)
CREATE TABLE CloseReasonTypes (
Id number,
Name text,
Description t... | HTML5 thread volume, page views, unique OPs by month. | SELECT COUNT(*) AS Volume, SUM(ViewCount) AS PageViews, COUNT(DISTINCT OwnerUserId) AS UniqueOPs, TIME_TO_STR(P.CreationDate, '%Y') AS "year", TIME_TO_STR(P.CreationDate, '%m') AS Month FROM Posts AS P WHERE (Tags LIKE '%<html5%' OR Tags LIKE '%<html-canvas>%' OR Tags LIKE '%<xhtml5>%') AND PostTypeId = 1 AND Community... | sede |
CREATE TABLE table_31765 (
"Draw" real,
"Artist" text,
"Song" text,
"Place" real,
"Points" real
) | Name the total number of places for vicky gordon and points more than 23 | SELECT COUNT("Place") FROM table_31765 WHERE "Artist" = 'vicky gordon' AND "Points" > '23' | wikisql |
CREATE TABLE screen_mode (
Char_cells VARCHAR,
Pixels VARCHAR,
Hardware_colours VARCHAR,
Graphics_mode VARCHAR
)
CREATE TABLE phone (
screen_mode VARCHAR,
Hardware_Model_name VARCHAR
) | Find the Char cells, Pixels and Hardware colours for the screen of the phone whose hardware model name is 'LG-P760'. | SELECT T1.Char_cells, T1.Pixels, T1.Hardware_colours FROM screen_mode AS T1 JOIN phone AS T2 ON T1.Graphics_mode = T2.screen_mode WHERE T2.Hardware_Model_name = "LG-P760" | sql_create_context |
CREATE TABLE Student (
StuID INTEGER,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE TABLE Allergy_Type (
Allergy VARCHAR(20),
AllergyType VARCHAR(20)
)
CREATE TABLE Has_Allergy (
StuID INTEGE... | Show the average age for all female students and group them by first name in a bar chart, and order by the Fname from low to high. | SELECT Fname, AVG(Age) FROM Student WHERE Sex = 'F' GROUP BY Fname ORDER BY Fname | nvbench |
CREATE TABLE table_78826 (
"College or Campus Name" text,
"Location" text,
"District" text,
"Affiliation" text,
"Weblink" text
) | What Location has a College or Campus Name of anna university - tharamani campus? | SELECT "Location" FROM table_78826 WHERE "College or Campus Name" = 'anna university - tharamani campus' | wikisql |
CREATE TABLE table_name_22 (
date VARCHAR,
opponents VARCHAR,
h___a VARCHAR,
league_position VARCHAR
) | What date was the game against manchester city when they had a league position of 2nd? | SELECT date FROM table_name_22 WHERE h___a = "a" AND league_position = "2nd" AND opponents = "manchester city" | 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.BGDH FROM person_info JOIN hz_info JOIN wdmzjzjlb JOIN jybgb 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 WHERE person_info.XM = '任... | css |
CREATE TABLE table_name_23 (
surface VARCHAR,
week VARCHAR
) | What was the type of surface played on for the week of March 17? | SELECT surface FROM table_name_23 WHERE week = "march 17" | sql_create_context |
CREATE TABLE stadium (
ID int,
name text,
Capacity int,
City text,
Country text,
Opening_year int
)
CREATE TABLE record (
ID int,
Result text,
Swimmer_ID int,
Event_ID int
)
CREATE TABLE swimmer (
ID int,
name text,
Nationality text,
meter_100 real,
meter_20... | Find the number of the names of stadiums that some Australian swimmers have been to, and list in descending by the x axis. | SELECT T4.Name, COUNT(T4.Name) FROM swimmer AS t1 JOIN record AS t2 ON t1.ID = t2.Swimmer_ID JOIN event AS t3 ON t2.Event_ID = t3.ID JOIN stadium AS t4 ON t4.ID = t3.Stadium_ID WHERE t1.Nationality = 'Australia' GROUP BY T4.Name ORDER BY T4.Name DESC | nvbench |
CREATE TABLE table_name_49 (
player VARCHAR,
hometown VARCHAR
) | Who is the player from Houston, TX? | SELECT player FROM table_name_49 WHERE hometown = "houston, tx" | sql_create_context |
CREATE TABLE table_78345 (
"Home team" text,
"Home team score" text,
"Away team" text,
"Away team score" text,
"Venue" text,
"Crowd" real,
"Date" text
) | When did the away team footscray score 11.15 (81)? | SELECT "Date" FROM table_78345 WHERE "Away team score" = '11.15 (81)' AND "Away team" = 'footscray' | 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,... | what is average age of patients whose marital status is widowed and admission location is emergency room admit? | SELECT AVG(demographic.age) FROM demographic WHERE demographic.marital_status = "WIDOWED" AND demographic.admission_location = "EMERGENCY ROOM ADMIT" | mimicsql_data |
CREATE TABLE vitalperiodic (
vitalperiodicid number,
patientunitstayid number,
temperature number,
sao2 number,
heartrate number,
respiration number,
systemicsystolic number,
systemicdiastolic number,
systemicmean number,
observationtime time
)
CREATE TABLE diagnosis (
diagn... | since 2102 how many patients were treated with c v v h in the same month after getting sedative agent - dexmedetomidine? | SELECT COUNT(DISTINCT t1.uniquepid) FROM (SELECT patient.uniquepid, treatment.treatmenttime FROM treatment JOIN patient ON treatment.patientunitstayid = patient.patientunitstayid WHERE treatment.treatmentname = 'sedative agent - dexmedetomidine' AND STRFTIME('%y', treatment.treatmenttime) >= '2102') AS t1 JOIN (SELECT ... | eicu |
CREATE TABLE locations (
LOCATION_ID decimal(4,0),
STREET_ADDRESS varchar(40),
POSTAL_CODE varchar(12),
CITY varchar(30),
STATE_PROVINCE varchar(25),
COUNTRY_ID varchar(2)
)
CREATE TABLE job_history (
EMPLOYEE_ID decimal(6,0),
START_DATE date,
END_DATE date,
JOB_ID varchar(10),
... | Just plot the manager id and the department id in a scatter chart. | SELECT T1.MANAGER_ID, T1.DEPARTMENT_ID FROM employees AS T1 JOIN departments AS T2 ON T1.DEPARTMENT_ID = T2.DEPARTMENT_ID WHERE T1.EMPLOYEE_ID = T2.MANAGER_ID | nvbench |
CREATE TABLE fgwyjzb (
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,
... | 这个医疗就诊15040416444入院时诊断的编号是什么?疾病名称是什么? | SELECT gwyjzb.IN_DIAG_DIS_CD, gwyjzb.IN_DIAG_DIS_NM FROM gwyjzb WHERE gwyjzb.MED_CLINIC_ID = '15040416444' UNION SELECT fgwyjzb.IN_DIAG_DIS_CD, fgwyjzb.IN_DIAG_DIS_NM FROM fgwyjzb WHERE fgwyjzb.MED_CLINIC_ID = '15040416444' | css |
CREATE TABLE table_74943 (
"Club" text,
"Played" text,
"Drawn" text,
"Lost" text,
"Points for" text,
"Points against" text,
"Tries for" text,
"Tries against" text,
"Try bonus" text,
"Losing bonus" text,
"Points" text
) | If the losing bonus was 6, what is the tries for? | SELECT "Tries for" FROM table_74943 WHERE "Losing bonus" = '6' | wikisql |
CREATE TABLE table_name_7 (
round VARCHAR,
winning_team VARCHAR,
date VARCHAR
) | What is the round on 30 June with a.z.k./roc-comp tition a.z.k./roc-comp tition as the winning team? | SELECT round FROM table_name_7 WHERE winning_team = "a.z.k./roc-compétition a.z.k./roc-compétition" AND date = "30 june" | 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),
... | For those employees who do not work in departments with managers that have ids between 100 and 200, return a bar chart about the distribution of last_name and manager_id . | SELECT LAST_NAME, MANAGER_ID FROM employees WHERE NOT DEPARTMENT_ID IN (SELECT DEPARTMENT_ID FROM departments WHERE MANAGER_ID BETWEEN 100 AND 200) | nvbench |
CREATE TABLE Institution (
Institution_id text,
Institution text,
Location text,
Founded real,
Type text,
Enrollment int,
Team text,
Primary_Conference text,
building_id text
)
CREATE TABLE protein (
common_name text,
protein_name text,
divergence_from_human_lineage real... | For each building, show the name of the building and the number of institutions in it Plot them as bar chart, and display X from low to high order. | SELECT Name, COUNT(*) FROM building AS T1 JOIN Institution AS T2 ON T1.building_id = T2.building_id GROUP BY T1.building_id ORDER BY Name | nvbench |
CREATE TABLE table_46392 (
"Game" real,
"Date" text,
"Team" text,
"Score" text,
"High points" text,
"High rebounds" text,
"High assists" text,
"Location Attendance" text,
"Record" text
) | What was the date of game 4? | SELECT "Date" FROM table_46392 WHERE "Game" = '4' | wikisql |
CREATE TABLE airline (
airline_code varchar,
airline_name text,
note text
)
CREATE TABLE time_interval (
period text,
begin_time int,
end_time int
)
CREATE TABLE class_of_service (
booking_class varchar,
rank int,
class_description text
)
CREATE TABLE time_zone (
time_zone_cod... | give me the flights from MILWAUKEE to PHOENIX on saturday or sunday on AA | 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 AS DATE_DAY_0, date_day AS DATE_DAY_1, days AS DAYS_0, days AS DAYS_1, flight WHERE (((flight.airline_code = 'AA') AND ((flight.flight_days = DAYS_0.days_code AND DA... | atis |
CREATE TABLE player (
name_first VARCHAR,
name_last VARCHAR,
weight VARCHAR,
height VARCHAR
) | List players' first name and last name who have weight greater than 220 or height shorter than 75. | SELECT name_first, name_last FROM player WHERE weight > 220 OR height < 75 | sql_create_context |
CREATE TABLE table_72001 (
"Call sign" text,
"Frequency MHz" real,
"City of license" text,
"ERP W" real,
"Class" text,
"FCC info" text
) | What class does the w298ak sign belong to? | SELECT "Class" FROM table_72001 WHERE "Call sign" = 'w298ak' | wikisql |
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
... | give me the number of patients whose death status is 0 and procedure icd9 code is 4513? | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN procedures ON demographic.hadm_id = procedures.hadm_id WHERE demographic.expire_flag = "0" AND procedures.icd9_code = "4513" | mimicsql_data |
CREATE TABLE table_name_44 (
pl_gp INTEGER,
rd__number VARCHAR,
pick__number VARCHAR,
player VARCHAR
) | What is the PI GP of Rob Flockhart, who has a pick # less than 122 and a round # less than 3? | SELECT SUM(pl_gp) FROM table_name_44 WHERE pick__number < 122 AND player = "rob flockhart" AND rd__number < 3 | sql_create_context |
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... | A bar chart shows the distribution of All_Games and ACC_Percent , could you list from high to low by the names? | SELECT All_Games, ACC_Percent FROM basketball_match ORDER BY All_Games DESC | nvbench |
CREATE TABLE table_36489 (
"Team 1" text,
"Agg." text,
"Team 2" text,
"1st leg" text,
"2nd leg" text
) | What is Team 1 where Team 2 is gombe united f.c.? | SELECT "Team 1" FROM table_36489 WHERE "Team 2" = 'gombe united f.c.' | wikisql |
CREATE TABLE table_74883 (
"District" text,
"Incumbent" text,
"Party" text,
"First elected" real,
"Result" text
) | Which Incumbent has a District of California 5? | SELECT "Incumbent" FROM table_74883 WHERE "District" = 'california 5' | wikisql |
CREATE TABLE table_name_88 (
finals_qualification VARCHAR,
season VARCHAR
) | What's the finals qualification during the 2009-10 season? | SELECT finals_qualification FROM table_name_88 WHERE season = "2009-10" | 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 treatment (
treat... | what are the genders of patient 009-338? | SELECT DISTINCT patient.gender FROM patient WHERE patient.uniquepid = '009-338' | eicu |
CREATE TABLE Dorm_amenity (
amenid INTEGER,
amenity_name VARCHAR(25)
)
CREATE TABLE Has_amenity (
dormid INTEGER,
amenid INTEGER
)
CREATE TABLE Lives_in (
stuid INTEGER,
dormid INTEGER,
room_number INTEGER
)
CREATE TABLE Student (
StuID INTEGER,
LName VARCHAR(12),
Fname VARCHA... | How many male students are there in each city? Show a bar chart, and list y axis from high to low order. | SELECT city_code, COUNT(*) FROM Student WHERE Sex = 'M' GROUP BY city_code ORDER BY COUNT(*) DESC | nvbench |
CREATE TABLE table_36817 (
"LEMA/SUBLEMA" text,
"Candidates" text,
"Votes" real,
"Ch. of Senators" text,
"Ch. of Deputies" text
) | Which LEMA/SUBLEMA has a Ch of Senators of 2? | SELECT "LEMA/SUBLEMA" FROM table_36817 WHERE "Ch. of Senators" = '2' | wikisql |
CREATE TABLE table_name_34 (
stadium VARCHAR,
sport VARCHAR,
league VARCHAR
) | Which stadium is for football with the China League One? | SELECT stadium FROM table_name_34 WHERE sport = "football" AND league = "china league one" | sql_create_context |
CREATE TABLE table_14724369_1 (
title VARCHAR,
directed_by VARCHAR
) | Which title did Neil Affleck direct? | SELECT title FROM table_14724369_1 WHERE directed_by = "Neil Affleck" | sql_create_context |
CREATE TABLE table_45144 (
"Res." text,
"Record" text,
"Opponent" text,
"Method" text,
"Event" text,
"Round" real,
"Time" text,
"Location" text
) | How many rounds had a time of 5:00 at UFC 155? | SELECT COUNT("Round") FROM table_45144 WHERE "Time" = '5:00' AND "Event" = 'ufc 155' | wikisql |
CREATE TABLE table_76316 (
"Tournament" text,
"1990" text,
"1991" text,
"1992" text,
"1993" text,
"1994" text,
"1995" text,
"1996" text,
"1997" text,
"Career SR" text,
"Career Win-Loss" text
) | What is 1997, when 1996 is '1R', when 1990 is '2R', and when 1991 is 'F'? | SELECT "1997" FROM table_76316 WHERE "1996" = '1r' AND "1990" = '2r' AND "1991" = 'f' | wikisql |
CREATE TABLE table_name_57 (
total INTEGER,
gold INTEGER
) | What is the largest total that has a gold less than 0? | SELECT MAX(total) FROM table_name_57 WHERE gold < 0 | sql_create_context |
CREATE TABLE table_name_48 (
school_club_team VARCHAR,
player VARCHAR
) | What school does Dell Curry play for? | SELECT school_club_team FROM table_name_48 WHERE player = "dell curry" | sql_create_context |
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... | in a year before, what are the three most common lab tests in patients aged 20s? | SELECT t1.labname FROM (SELECT lab.labname, DENSE_RANK() OVER (ORDER BY COUNT(*) DESC) AS c1 FROM lab WHERE lab.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.age BETWEEN 20 AND 29) AND DATETIME(lab.labresulttime, 'start of year') = DATETIME(CURRENT_TIME(), 'start of year', '-1 year')... | eicu |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.