answer stringlengths 6 3.91k | question stringlengths 7 766 | context stringlengths 27 7.14k |
|---|---|---|
SELECT vertical_0_b FROM table_25519358_1 WHERE name = "边 BIAN" | Name the vertical for 边 bian | CREATE TABLE table_25519358_1 (vertical_0_b VARCHAR, name VARCHAR) |
SELECT winner FROM table_name_89 WHERE fastest_lap = "katsuyuki hiranaka" | Who was the winner when Katsuyuki Hiranaka had the fastest lap? | CREATE TABLE table_name_89 (winner VARCHAR, fastest_lap VARCHAR) |
SELECT "Content" FROM table_20374 WHERE "Package/Option" = 'Sky Famiglia' AND "Language" = 'Italian' AND "DAR" = '16:9' AND "Television service" = 'MTV Hits' | Name the content for sky famiglia for italian and dar 16:9 for mtv hits | CREATE TABLE table_20374 (
"N\u00b0" real,
"Television service" text,
"Country" text,
"Language" text,
"Content" text,
"DAR" text,
"HDTV" text,
"PPV" text,
"Package/Option" text
) |
SELECT horizontal_0_a FROM table_25519358_1 WHERE name = "通 TONG" | Name the horizontal 0 for 通 tong | CREATE TABLE table_25519358_1 (horizontal_0_a VARCHAR, name VARCHAR) |
SELECT team FROM table_name_85 WHERE round < 9 AND pole_position = "takashi kogure" | Before round 9, when Takashi Kogure held pole position, who was the team? | CREATE TABLE table_name_85 (team VARCHAR, round VARCHAR, pole_position VARCHAR) |
SELECT DISTINCT t3.name FROM authors AS t1 JOIN authorship AS t2 ON t1.authid = t2.authid JOIN inst AS t3 ON t2.instid = t3.instid WHERE t1.fname = "Matthias" AND t1.lname = "Blume" | What is the name of the institution that 'Matthias Blume' belongs to? | CREATE TABLE authorship (
authid number,
instid number,
paperid number,
authorder number
)
CREATE TABLE papers (
paperid number,
title text
)
CREATE TABLE inst (
instid number,
name text,
country text
)
CREATE TABLE authors (
authid number,
lname text,
fname text
) |
SELECT horizontal_0_a FROM table_25519358_1 WHERE hypotenuse_0_c = "明弦(RY日月)" | Name the horizontal 0 for 明弦(ry日月) | CREATE TABLE table_25519358_1 (horizontal_0_a VARCHAR, hypotenuse_0_c VARCHAR) |
SELECT realvideo FROM table_name_86 WHERE mpeg_2 = "yes" AND mpeg_1 = "yes" | Tell me the MPEG-2 of yes and MPEG-1 of yes | CREATE TABLE table_name_86 (realvideo VARCHAR, mpeg_2 VARCHAR, mpeg_1 VARCHAR) |
SELECT date, COUNT(date) FROM weather WHERE max_temperature_f > 85 ORDER BY COUNT(date) | What are the number of the dates with a maximum temperature higher than 85?, I want to show the number of date from low to high order. | CREATE TABLE trip (
id INTEGER,
duration INTEGER,
start_date TEXT,
start_station_name TEXT,
start_station_id INTEGER,
end_date TEXT,
end_station_name TEXT,
end_station_id INTEGER,
bike_id INTEGER,
subscription_type TEXT,
zip_code INTEGER
)
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_pressure_inches NUMERIC,
mean_sea_level_pressure_inches NUMERIC,
min_sea_level_pressure_inches NUMERIC,
max_visibility_miles INTEGER,
mean_visibility_miles INTEGER,
min_visibility_miles INTEGER,
max_wind_Speed_mph INTEGER,
mean_wind_speed_mph INTEGER,
max_gust_speed_mph INTEGER,
precipitation_inches INTEGER,
cloud_cover INTEGER,
events TEXT,
wind_dir_degrees INTEGER,
zip_code INTEGER
)
CREATE TABLE station (
id INTEGER,
name TEXT,
lat NUMERIC,
long NUMERIC,
dock_count INTEGER,
city TEXT,
installation_date TEXT
)
CREATE TABLE status (
station_id INTEGER,
bikes_available INTEGER,
docks_available INTEGER,
time TEXT
) |
SELECT vertical_0_b FROM table_25519358_1 WHERE horizontal_0_a = "明勾(YS月南)" | Name the vertical for 明勾(ys月南) | CREATE TABLE table_25519358_1 (vertical_0_b VARCHAR, horizontal_0_a VARCHAR) |
SELECT mpeg_1 FROM table_name_77 WHERE realvideo = "no" | Tell me the MPEG-1 for real video of no | CREATE TABLE table_name_77 (mpeg_1 VARCHAR, realvideo VARCHAR) |
SELECT 24 * (STRFTIME('%j', CURRENT_TIME()) - STRFTIME('%j', transfers.intime)) FROM transfers WHERE transfers.icustay_id IN (SELECT icustays.icustay_id FROM icustays WHERE icustays.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 65582 AND admissions.dischtime IS NULL)) AND transfers.wardid = 50 ORDER BY transfers.intime LIMIT 1 | how many hours has it been since the first time patient 65582 visited ward 50 in this hospital visit? | CREATE TABLE outputevents (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime time,
itemid number,
value number
)
CREATE TABLE patients (
row_id number,
subject_id number,
gender text,
dob time,
dod time
)
CREATE TABLE procedures_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
CREATE TABLE d_icd_diagnoses (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE cost (
row_id number,
subject_id number,
hadm_id number,
event_type text,
event_id number,
chargetime time,
cost number
)
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 inputevents_cv (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime time,
itemid number,
amount number
)
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 admissions (
row_id number,
subject_id number,
hadm_id number,
admittime time,
dischtime time,
admission_type text,
admission_location text,
discharge_location text,
insurance text,
language text,
marital_status text,
ethnicity text,
age number
)
CREATE TABLE d_icd_procedures (
row_id number,
icd9_code text,
short_title text,
long_title text
)
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 microbiologyevents (
row_id number,
subject_id number,
hadm_id number,
charttime time,
spec_type_desc text,
org_name text
)
CREATE TABLE diagnoses_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
CREATE TABLE labevents (
row_id number,
subject_id number,
hadm_id number,
itemid number,
charttime time,
valuenum number,
valueuom text
)
CREATE TABLE d_labitems (
row_id number,
itemid number,
label text
)
CREATE TABLE prescriptions (
row_id number,
subject_id number,
hadm_id number,
startdate time,
enddate time,
drug text,
dose_val_rx text,
dose_unit_rx text,
route text
)
CREATE TABLE d_items (
row_id number,
itemid number,
label text,
linksto text
) |
SELECT COUNT(horizontal_0_a) FROM table_25519358_1 WHERE number = 10 | Name the horizontal number for number 10 | CREATE TABLE table_25519358_1 (horizontal_0_a VARCHAR, number VARCHAR) |
SELECT affiliation FROM table_name_28 WHERE mls_team = "metrostars" AND pick__number = 26 | Tell me the affiliation for mls team of metrostars and pick number of 26 | CREATE TABLE table_name_28 (affiliation VARCHAR, mls_team VARCHAR, pick__number VARCHAR) |
SELECT country FROM stadium EXCEPT SELECT country FROM stadium WHERE opening_year > 2006 | Which countries do not have a stadium that was opened after 2006? | CREATE TABLE stadium (
id number,
name text,
capacity number,
city text,
country text,
opening_year number
)
CREATE TABLE swimmer (
id number,
name text,
nationality text,
meter_100 number,
meter_200 text,
meter_300 text,
meter_400 text,
meter_500 text,
meter_600 text,
meter_700 text,
time text
)
CREATE TABLE event (
id number,
name text,
stadium_id number,
year text
)
CREATE TABLE record (
id number,
result text,
swimmer_id number,
event_id number
) |
SELECT COUNT(mls_team) FROM table_25518547_3 WHERE affiliation = "University of Maryland" | How many teams drafted players from the University of Maryland? | CREATE TABLE table_25518547_3 (mls_team VARCHAR, affiliation VARCHAR) |
SELECT COUNT(pick__number) FROM table_name_9 WHERE position = "m" AND affiliation = "williams college" | Tell me the total number of picks for position of m of williams college | CREATE TABLE table_name_9 (pick__number VARCHAR, position VARCHAR, affiliation VARCHAR) |
SELECT COUNT(scored) FROM table_name_83 WHERE draws < 5 AND wins = 8 AND points < 27 | How many points are in the scored category for the team that has less than 5 draws, 8 total wins, and total overall points less than 27? | CREATE TABLE table_name_83 (
scored VARCHAR,
points VARCHAR,
draws VARCHAR,
wins VARCHAR
) |
SELECT mls_team FROM table_25518547_3 WHERE player = "Samuel Appiah" | What MLS team drafted samuel appiah? | CREATE TABLE table_25518547_3 (mls_team VARCHAR, player VARCHAR) |
SELECT runner_up FROM table_name_25 WHERE year = 1915 | who was the runner-up in the 1915 competition for 'Articles with HCards'? | CREATE TABLE table_name_25 (runner_up VARCHAR, year VARCHAR) |
SELECT Team_ID, ACC_Percent FROM basketball_match GROUP BY All_Games | Draw a scatter chart about the correlation between Team_ID and ACC_Percent , and group by attribute All_Games. | 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 (
School_ID int,
School text,
Location text,
Founded real,
Affiliation text,
Enrollment real,
Nickname text,
Primary_conference text
) |
SELECT player FROM table_25518547_3 WHERE mls_team = "Philadelphia Union" | What player was drafted by the philadelphia union? | CREATE TABLE table_25518547_3 (player VARCHAR, mls_team VARCHAR) |
SELECT runner_up FROM table_name_39 WHERE year = 1887 | Who was the runner-up in 1887 competition for 'Articles with HCards'? | CREATE TABLE table_name_39 (runner_up VARCHAR, year VARCHAR) |
SELECT AVG("Played") FROM table_41533 WHERE "Drawn" = '1' AND "Against" = '24' | What is the average number played of the team with 1 drawn and 24 against? | CREATE TABLE table_41533 (
"Position" real,
"Team" text,
"Points" real,
"Played" real,
"Drawn" real,
"Lost" real,
"Against" real,
"Difference" text
) |
SELECT founded FROM table_255205_1 WHERE nickname = "Fightin' Engineers" | This institution nicknamed Fightin' engineers was founded on what year? | CREATE TABLE table_255205_1 (founded VARCHAR, nickname VARCHAR) |
SELECT home_team AS score FROM table_name_36 WHERE away_team = "collingwood" | What is the home team score when the away team is Collingwood? | CREATE TABLE table_name_36 (home_team VARCHAR, away_team VARCHAR) |
SELECT "Mascot" FROM table_64076 WHERE "School" = 'warsaw' | what is the mascot when the school is warsaw? | CREATE TABLE table_64076 (
"School" text,
"Location" text,
"Mascot" text,
"County" text,
"Year Joined" text,
"Previous Conference" text,
"Year Left" text
) |
SELECT COUNT(joined) FROM table_255205_1 WHERE location = "Franklin, Indiana" | How many inputs joined this institution located in Franklin, Indiana? | CREATE TABLE table_255205_1 (joined VARCHAR, location VARCHAR) |
SELECT fleet FROM table_name_61 WHERE number = "l4" | what fleet is associated with the number L4? | CREATE TABLE table_name_61 (fleet VARCHAR, number VARCHAR) |
SELECT d_items.label FROM d_items WHERE d_items.itemid IN (SELECT outputevents.itemid FROM outputevents WHERE outputevents.icustay_id IN (SELECT icustays.icustay_id FROM icustays WHERE icustays.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 12885)) AND DATETIME(outputevents.charttime, 'start of year') = DATETIME(CURRENT_TIME(), 'start of year', '-1 year') AND STRFTIME('%m-%d', outputevents.charttime) = '06-28' ORDER BY outputevents.charttime LIMIT 1) | what were the first outputs of patient 12885 on 06/28/last year? | CREATE TABLE labevents (
row_id number,
subject_id number,
hadm_id number,
itemid number,
charttime time,
valuenum number,
valueuom 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 d_icd_diagnoses (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE patients (
row_id number,
subject_id number,
gender text,
dob time,
dod time
)
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 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 number
)
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 admissions (
row_id number,
subject_id number,
hadm_id number,
admittime time,
dischtime time,
admission_type text,
admission_location text,
discharge_location text,
insurance text,
language text,
marital_status text,
ethnicity text,
age number
)
CREATE TABLE d_icd_procedures (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE procedures_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
CREATE TABLE outputevents (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime time,
itemid number,
value number
)
CREATE TABLE d_labitems (
row_id number,
itemid number,
label text
)
CREATE TABLE d_items (
row_id number,
itemid number,
label text,
linksto text
)
CREATE TABLE prescriptions (
row_id number,
subject_id number,
hadm_id number,
startdate time,
enddate time,
drug text,
dose_val_rx text,
dose_unit_rx text,
route text
)
CREATE TABLE diagnoses_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
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
) |
SELECT COUNT(founded) FROM table_255205_1 WHERE nickname = "Beavers" | How many times this institution was founded that was nicknamed Beavers? | CREATE TABLE table_255205_1 (founded VARCHAR, nickname VARCHAR) |
SELECT number FROM table_name_49 WHERE fleet = "baltic" AND name = "leninets (ленинец)" | what number is associated with the baltic fleet and leninets (ленинец)? | CREATE TABLE table_name_49 (number VARCHAR, fleet VARCHAR, name VARCHAR) |
SELECT "Model (list)" FROM table_26580 WHERE "TDP" = '5.5 W' | What's the model of the processor with a 5.5 w TDP? | CREATE TABLE table_26580 (
"Processor" text,
"Brand name" text,
"Model (list)" text,
"Cores" real,
"L2 Cache" text,
"Socket" text,
"TDP" text
) |
SELECT joined FROM table_255205_1 WHERE type = "Private/Church of God" | How many joined this Private/Church of God institution? | CREATE TABLE table_255205_1 (joined VARCHAR, type VARCHAR) |
SELECT launched FROM table_name_94 WHERE name = "garibaldets (гарибальдиец)" | when was garibaldets (гарибальдиец) launched? | CREATE TABLE table_name_94 (launched VARCHAR, name VARCHAR) |
SELECT "French" FROM table_19818 WHERE "Russian" = 'filtrovat (фильтровать)' | What is the french word for the Russian word filtrovat ( )? | CREATE TABLE table_19818 (
"Ido" text,
"English" text,
"Italian" text,
"French" text,
"German" text,
"Russian" text,
"Spanish" text
) |
SELECT joined FROM table_255205_1 WHERE institution = "Manchester University" | How many joined Manchester University? | CREATE TABLE table_255205_1 (joined VARCHAR, institution VARCHAR) |
SELECT launched FROM table_name_86 WHERE fleet = "black sea" AND number = "l6" | when was the number l6, with a fleet of black sea, launched? | CREATE TABLE table_name_86 (launched VARCHAR, fleet VARCHAR, number VARCHAR) |
SELECT TagName, COUNT(TagName) AS TagsPerAge, Age FROM Tags INNER JOIN PostTags ON PostTags.TagId = Tags.Id INNER JOIN Posts ON Posts.ParentId = PostTags.PostId INNER JOIN Users ON Users.Id = Posts.OwnerUserId WHERE TagName = 'php' AND age > 0 GROUP BY Age, TagName ORDER BY TagsPerAge DESC | Whats the age demographic per tag?. I tried to make this accept the tag as a
parameter but I kepy getting an error. | CREATE TABLE PostNoticeTypes (
Id number,
ClassId number,
Name text,
Body text,
IsHidden boolean,
Predefined boolean,
PostNoticeDurationId number
)
CREATE TABLE Posts (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
ViewCount number,
Body text,
OwnerUserId number,
OwnerDisplayName text,
LastEditorUserId number,
LastEditorDisplayName text,
LastEditDate time,
LastActivityDate time,
Title text,
Tags text,
AnswerCount number,
CommentCount number,
FavoriteCount number,
ClosedDate time,
CommunityOwnedDate time,
ContentLicense text
)
CREATE TABLE ReviewTasks (
Id number,
ReviewTaskTypeId number,
CreationDate time,
DeletionDate time,
ReviewTaskStateId number,
PostId number,
SuggestedEditId number,
CompletedByReviewTaskId number
)
CREATE TABLE PostNotices (
Id number,
PostId number,
PostNoticeTypeId number,
CreationDate time,
DeletionDate time,
ExpiryDate time,
Body text,
OwnerUserId number,
DeletionUserId number
)
CREATE TABLE Tags (
Id number,
TagName text,
Count number,
ExcerptPostId number,
WikiPostId number
)
CREATE TABLE Badges (
Id number,
UserId number,
Name text,
Date time,
Class number,
TagBased boolean
)
CREATE TABLE CloseAsOffTopicReasonTypes (
Id number,
IsUniversal boolean,
InputTitle text,
MarkdownInputGuidance text,
MarkdownPostOwnerGuidance text,
MarkdownPrivilegedUserGuidance text,
MarkdownConcensusDescription text,
CreationDate time,
CreationModeratorId number,
ApprovalDate time,
ApprovalModeratorId number,
DeactivationDate time,
DeactivationModeratorId number
)
CREATE TABLE SuggestedEditVotes (
Id number,
SuggestedEditId number,
UserId number,
VoteTypeId number,
CreationDate time,
TargetUserId number,
TargetRepChange number
)
CREATE TABLE SuggestedEdits (
Id number,
PostId number,
CreationDate time,
ApprovalDate time,
RejectionDate time,
OwnerUserId number,
Comment text,
Text text,
Title text,
Tags text,
RevisionGUID other
)
CREATE TABLE PostFeedback (
Id number,
PostId number,
IsAnonymous boolean,
VoteTypeId number,
CreationDate time
)
CREATE TABLE Votes (
Id number,
PostId number,
VoteTypeId number,
UserId number,
CreationDate time,
BountyAmount number
)
CREATE TABLE PostHistory (
Id number,
PostHistoryTypeId number,
PostId number,
RevisionGUID other,
CreationDate time,
UserId number,
UserDisplayName text,
Comment text,
Text text,
ContentLicense text
)
CREATE TABLE FlagTypes (
Id number,
Name text,
Description text
)
CREATE TABLE ReviewRejectionReasons (
Id number,
Name text,
Description text,
PostTypeId number
)
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 number,
ApprovalDate time
)
CREATE TABLE VoteTypes (
Id number,
Name text
)
CREATE TABLE Comments (
Id number,
PostId number,
Score number,
Text text,
CreationDate time,
UserDisplayName text,
UserId number,
ContentLicense text
)
CREATE TABLE PostTypes (
Id number,
Name text
)
CREATE TABLE PostLinks (
Id number,
CreationDate time,
PostId number,
RelatedPostId number,
LinkTypeId number
)
CREATE TABLE ReviewTaskStates (
Id number,
Name text,
Description text
)
CREATE TABLE PostHistoryTypes (
Id number,
Name text
)
CREATE TABLE PendingFlags (
Id number,
FlagTypeId number,
PostId number,
CreationDate time,
CloseReasonTypeId number,
CloseAsOffTopicReasonTypeId number,
DuplicateOfQuestionId number,
BelongsOnBaseHostAddress text
)
CREATE TABLE PostTags (
PostId number,
TagId number
)
CREATE TABLE ReviewTaskResultTypes (
Id number,
Name text,
Description text
)
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
)
CREATE TABLE PostsWithDeleted (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
ViewCount number,
Body text,
OwnerUserId number,
OwnerDisplayName text,
LastEditorUserId number,
LastEditorDisplayName text,
LastEditDate time,
LastActivityDate time,
Title text,
Tags text,
AnswerCount number,
CommentCount number,
FavoriteCount number,
ClosedDate time,
CommunityOwnedDate time,
ContentLicense text
)
CREATE TABLE ReviewTaskTypes (
Id number,
Name text,
Description text
)
CREATE TABLE ReviewTaskResults (
Id number,
ReviewTaskId number,
ReviewTaskResultTypeId number,
CreationDate time,
RejectionReasonId number,
Comment text
) |
SELECT circuit FROM table_25531112_2 WHERE event = "Clipsal 500" | What circuit was the Clipsal 500 on? | CREATE TABLE table_25531112_2 (circuit VARCHAR, event VARCHAR) |
SELECT number FROM table_name_85 WHERE name = "chartist (чартист)" | what number is associated with the name chartist (чартист)? | CREATE TABLE table_name_85 (number VARCHAR, name VARCHAR) |
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.diagnosis = "ACUTE SUBDURAL HEMATOMA" AND demographic.dod_year <= "2183.0" | how many patients whose primary disease is acute subdural hematoma and year of death is less than or equal to 2183? | 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,
route text,
drug_dose text
)
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 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 text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear text
) |
SELECT challenge FROM table_25531112_2 WHERE circuit = "Albert Park Grand Prix circuit" | Who made the challenge on the Albert Park Grand Prix Circuit? | CREATE TABLE table_25531112_2 (challenge VARCHAR, circuit VARCHAR) |
SELECT date FROM table_name_90 WHERE venue = "punt road oval" | What date did the VFL play Punt Road Oval? | CREATE TABLE table_name_90 (date VARCHAR, venue VARCHAR) |
SELECT OwnerUserId AS "user_link", Id AS "post_link" FROM Posts WHERE ParentId IN (SELECT Id FROM Posts WHERE Tags LIKE '%data.table%' AND Body COLLATE Latin1_General_CS_AS LIKE '%column%') AND Body COLLATE Latin1_General_CS_AS LIKE '%.BY%' | Answers with word '.BY' for 'data.table' tag posts. | CREATE TABLE Tags (
Id number,
TagName text,
Count number,
ExcerptPostId number,
WikiPostId number
)
CREATE TABLE ReviewTaskResultTypes (
Id number,
Name text,
Description text
)
CREATE TABLE VoteTypes (
Id number,
Name text
)
CREATE TABLE ReviewTaskResults (
Id number,
ReviewTaskId number,
ReviewTaskResultTypeId number,
CreationDate time,
RejectionReasonId number,
Comment text
)
CREATE TABLE PendingFlags (
Id number,
FlagTypeId number,
PostId number,
CreationDate time,
CloseReasonTypeId number,
CloseAsOffTopicReasonTypeId number,
DuplicateOfQuestionId number,
BelongsOnBaseHostAddress text
)
CREATE TABLE PostLinks (
Id number,
CreationDate time,
PostId number,
RelatedPostId number,
LinkTypeId number
)
CREATE TABLE ReviewTaskTypes (
Id number,
Name text,
Description text
)
CREATE TABLE SuggestedEdits (
Id number,
PostId number,
CreationDate time,
ApprovalDate time,
RejectionDate time,
OwnerUserId number,
Comment text,
Text text,
Title text,
Tags text,
RevisionGUID other
)
CREATE TABLE ReviewTaskStates (
Id number,
Name text,
Description text
)
CREATE TABLE SuggestedEditVotes (
Id number,
SuggestedEditId number,
UserId number,
VoteTypeId number,
CreationDate time,
TargetUserId number,
TargetRepChange number
)
CREATE TABLE PostsWithDeleted (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
ViewCount number,
Body text,
OwnerUserId number,
OwnerDisplayName text,
LastEditorUserId number,
LastEditorDisplayName text,
LastEditDate time,
LastActivityDate time,
Title text,
Tags text,
AnswerCount number,
CommentCount number,
FavoriteCount number,
ClosedDate time,
CommunityOwnedDate time,
ContentLicense text
)
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
)
CREATE TABLE PostFeedback (
Id number,
PostId number,
IsAnonymous boolean,
VoteTypeId number,
CreationDate time
)
CREATE TABLE PostNoticeTypes (
Id number,
ClassId number,
Name text,
Body text,
IsHidden boolean,
Predefined boolean,
PostNoticeDurationId number
)
CREATE TABLE Posts (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
ViewCount number,
Body text,
OwnerUserId number,
OwnerDisplayName text,
LastEditorUserId number,
LastEditorDisplayName text,
LastEditDate time,
LastActivityDate time,
Title text,
Tags text,
AnswerCount number,
CommentCount number,
FavoriteCount number,
ClosedDate time,
CommunityOwnedDate time,
ContentLicense text
)
CREATE TABLE ReviewRejectionReasons (
Id number,
Name text,
Description text,
PostTypeId number
)
CREATE TABLE PostTags (
PostId number,
TagId number
)
CREATE TABLE Badges (
Id number,
UserId number,
Name text,
Date time,
Class number,
TagBased boolean
)
CREATE TABLE CloseReasonTypes (
Id number,
Name text,
Description text
)
CREATE TABLE PostHistory (
Id number,
PostHistoryTypeId number,
PostId number,
RevisionGUID other,
CreationDate time,
UserId number,
UserDisplayName text,
Comment text,
Text text,
ContentLicense text
)
CREATE TABLE ReviewTasks (
Id number,
ReviewTaskTypeId number,
CreationDate time,
DeletionDate time,
ReviewTaskStateId number,
PostId number,
SuggestedEditId number,
CompletedByReviewTaskId number
)
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 Comments (
Id number,
PostId number,
Score number,
Text text,
CreationDate time,
UserDisplayName text,
UserId number,
ContentLicense text
)
CREATE TABLE PostTypes (
Id number,
Name text
)
CREATE TABLE PostNotices (
Id number,
PostId number,
PostNoticeTypeId number,
CreationDate time,
DeletionDate time,
ExpiryDate time,
Body text,
OwnerUserId number,
DeletionUserId number
)
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 TABLE CloseAsOffTopicReasonTypes (
Id number,
IsUniversal boolean,
InputTitle text,
MarkdownInputGuidance text,
MarkdownPostOwnerGuidance text,
MarkdownPrivilegedUserGuidance text,
MarkdownConcensusDescription text,
CreationDate time,
CreationModeratorId number,
ApprovalDate time,
ApprovalModeratorId number,
DeactivationDate time,
DeactivationModeratorId number
)
CREATE TABLE PostHistoryTypes (
Id number,
Name text
) |
SELECT rd FROM table_25531112_2 WHERE circuit = "Eastern Creek Raceway" | In what round was the circuit Eastern Creek Raceway? | CREATE TABLE table_25531112_2 (rd VARCHAR, circuit VARCHAR) |
SELECT home_team FROM table_name_99 WHERE venue = "arden street oval" | Who played home team at the Arden Street Oval game? | CREATE TABLE table_name_99 (home_team VARCHAR, venue VARCHAR) |
SELECT score FROM table_11214772_1 WHERE year = "2007" | what's the score where year is 2007 | CREATE TABLE table_11214772_1 (
score VARCHAR,
year VARCHAR
) |
SELECT challenge FROM table_25531112_2 WHERE event = "Australian Grand Prix" | Who made the challenge in the Australian Grand Prix? | CREATE TABLE table_25531112_2 (challenge VARCHAR, event VARCHAR) |
SELECT away_team AS score FROM table_name_84 WHERE venue = "victoria park" | How much did the away team score at Victoria park? | CREATE TABLE table_name_84 (away_team VARCHAR, venue VARCHAR) |
SELECT "9th Position" FROM table_33623 WHERE "10th Position" = 'rabat ajax' | What is in the ninth position where the tenth position is rabat ajax? | CREATE TABLE table_33623 (
"Year" text,
"1st Position" text,
"2nd Position" text,
"9th Position" text,
"10th Position" text
) |
SELECT shirt_sponsor FROM table_25527255_2 WHERE average_squad_age = "25.46" | Who is the shirt sponsor of the team with an average squad age of 25.46? | CREATE TABLE table_25527255_2 (shirt_sponsor VARCHAR, average_squad_age VARCHAR) |
SELECT closure_date FROM table_name_70 WHERE region = "north east england" | What date was the ensemble in North East England closed? | CREATE TABLE table_name_70 (closure_date VARCHAR, region VARCHAR) |
SELECT MIN("Round") FROM table_69835 WHERE "College" = 'southern' | What is the lowest round for Southern College? | CREATE TABLE table_69835 (
"Round" real,
"Pick #" real,
"Overall" real,
"Name" text,
"Position" text,
"College" text
) |
SELECT shirt_sponsor FROM table_25527255_2 WHERE team = "FC Bunyodkor" | Who is the shirt sponsor for FC Bunyodkor? | CREATE TABLE table_25527255_2 (shirt_sponsor VARCHAR, team VARCHAR) |
SELECT operator FROM table_name_89 WHERE region = "yorkshire" | What was the operator of the ensemble from Yorkshire? | CREATE TABLE table_name_89 (operator VARCHAR, region VARCHAR) |
SELECT "Away team score" FROM table_54881 WHERE "Home team score" = '12.7 (79)' AND "Away team" = 'melbourne' | What is the away team score of a Melbourne team that has a home team score of 12.7 (79)? | CREATE TABLE table_54881 (
"Home team" text,
"Home team score" text,
"Away team" text,
"Away team score" text,
"Venue" text,
"Date" text
) |
SELECT average_squad_age FROM table_25527255_2 WHERE shirt_sponsor = "Sho'rtan Gaz Mahsulot" AND kit_manufacturer = "Adidas" | What is the average squad age of the team whose shirt sponsor is Sho'rtan Gaz Mahsulot and whose kit manufacturer is Adidas? | CREATE TABLE table_25527255_2 (average_squad_age VARCHAR, shirt_sponsor VARCHAR, kit_manufacturer VARCHAR) |
SELECT closure_date FROM table_name_96 WHERE on_air_date = "june 2003" | When was the ensemble closed that went on air in June 2003? | CREATE TABLE table_name_96 (closure_date VARCHAR, on_air_date VARCHAR) |
SELECT transfers.wardid FROM transfers WHERE transfers.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 25733 AND admissions.dischtime IS NULL) AND NOT transfers.wardid IS NULL ORDER BY transfers.intime LIMIT 1 | what was patient 25733's first ward identification in their current hospital encounter? | CREATE TABLE admissions (
row_id number,
subject_id number,
hadm_id number,
admittime time,
dischtime time,
admission_type text,
admission_location text,
discharge_location text,
insurance text,
language text,
marital_status text,
ethnicity text,
age number
)
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 patients (
row_id number,
subject_id number,
gender text,
dob time,
dod time
)
CREATE TABLE d_labitems (
row_id number,
itemid number,
label text
)
CREATE TABLE procedures_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
CREATE TABLE cost (
row_id number,
subject_id number,
hadm_id number,
event_type text,
event_id number,
chargetime time,
cost number
)
CREATE TABLE outputevents (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime time,
itemid number,
value number
)
CREATE TABLE d_icd_diagnoses (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE d_icd_procedures (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE labevents (
row_id number,
subject_id number,
hadm_id number,
itemid number,
charttime time,
valuenum number,
valueuom text
)
CREATE TABLE microbiologyevents (
row_id number,
subject_id number,
hadm_id number,
charttime time,
spec_type_desc text,
org_name text
)
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 inputevents_cv (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime time,
itemid number,
amount number
)
CREATE TABLE prescriptions (
row_id number,
subject_id number,
hadm_id number,
startdate time,
enddate time,
drug text,
dose_val_rx text,
dose_unit_rx text,
route text
)
CREATE TABLE diagnoses_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
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 d_items (
row_id number,
itemid number,
label text,
linksto text
) |
SELECT captain FROM table_25527255_2 WHERE kit_manufacturer = "Nike" | Who is the captain of the team whose kit manufacturer is Nike? | CREATE TABLE table_25527255_2 (captain VARCHAR, kit_manufacturer VARCHAR) |
SELECT licence_award_date FROM table_name_67 WHERE on_air_date = "july 2001" AND region = "south wales and the severn estuary" | What was the license award date for the ensemble from South Wales and the Severn Estuary that was on air in July 2001? | CREATE TABLE table_name_67 (licence_award_date VARCHAR, on_air_date VARCHAR, region VARCHAR) |
SELECT demographic.admission_location, demographic.discharge_location FROM demographic WHERE demographic.subject_id = "17787" | what is admission location and discharge location of subject id 17787? | CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
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
)
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,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear text
) |
SELECT manager FROM table_25527255_2 WHERE team = "FK Andijan" | Who is the manager of FK Andijan? | CREATE TABLE table_25527255_2 (manager VARCHAR, team VARCHAR) |
SELECT operator FROM table_name_99 WHERE region = "yorkshire" | What is the operator of the ensemble from Yorkshire? | CREATE TABLE table_name_99 (operator VARCHAR, region VARCHAR) |
SELECT "Radio Electrical" FROM table_18772 WHERE "Secretariat" = 'WTR I' | What are radio electricals when secretariat is wtr i? | CREATE TABLE table_18772 (
"Serial & Branch" real,
"Seaman" text,
"Mechanical" text,
"Secretariat" text,
"Supply" text,
"Electrical" text,
"Radio Electrical" text,
"Regulating" text,
"Medical" text
) |
SELECT COUNT(year) FROM table_2553861_1 WHERE open_cup = "Did not qualify" AND playoffs = "National Final" | Name the year for open cup did not qualify and national final | CREATE TABLE table_2553861_1 (year VARCHAR, open_cup VARCHAR, playoffs VARCHAR) |
SELECT home_team FROM table_name_16 WHERE crowd > 41 OFFSET 846 | Who was the home team when attendance was over 41,846? | CREATE TABLE table_name_16 (home_team VARCHAR, crowd INTEGER) |
SELECT COUNT(DISTINCT admissions.subject_id) FROM admissions WHERE DATETIME(admissions.admittime) >= DATETIME(CURRENT_TIME(), '-4 year') | calculate the number of patients who have been hospitalized since 4 years ago. | CREATE TABLE patients (
row_id number,
subject_id number,
gender text,
dob time,
dod time
)
CREATE TABLE diagnoses_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
CREATE TABLE microbiologyevents (
row_id number,
subject_id number,
hadm_id number,
charttime time,
spec_type_desc text,
org_name text
)
CREATE TABLE d_labitems (
row_id number,
itemid number,
label 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 labevents (
row_id number,
subject_id number,
hadm_id number,
itemid number,
charttime time,
valuenum number,
valueuom text
)
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 cost (
row_id number,
subject_id number,
hadm_id number,
event_type text,
event_id number,
chargetime time,
cost number
)
CREATE TABLE admissions (
row_id number,
subject_id number,
hadm_id number,
admittime time,
dischtime time,
admission_type text,
admission_location text,
discharge_location text,
insurance text,
language text,
marital_status text,
ethnicity text,
age number
)
CREATE TABLE d_icd_procedures (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE d_items (
row_id number,
itemid number,
label text,
linksto text
)
CREATE TABLE procedures_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
CREATE TABLE prescriptions (
row_id number,
subject_id number,
hadm_id number,
startdate time,
enddate time,
drug text,
dose_val_rx text,
dose_unit_rx text,
route text
)
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 outputevents (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime time,
itemid number,
value number
)
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
) |
SELECT league FROM table_2553861_1 WHERE year = 2000 | Name the league for 2000 | CREATE TABLE table_2553861_1 (league VARCHAR, year VARCHAR) |
SELECT venue FROM table_name_28 WHERE home_team = "collingwood" | Where did Collingwood play as the home team? | CREATE TABLE table_name_28 (venue VARCHAR, home_team VARCHAR) |
SELECT date FROM table_name_56 WHERE tie_no = "3" | What was the date of the game that tied at 3? | CREATE TABLE table_name_56 (
date VARCHAR,
tie_no VARCHAR
) |
SELECT league FROM table_2553861_1 WHERE playoffs = "Conference Finals" | Name the league for conference finals | CREATE TABLE table_2553861_1 (league VARCHAR, playoffs VARCHAR) |
SELECT home_team AS score FROM table_name_9 WHERE home_team = "south melbourne" | What was South Melbourne's score when they played as the home team? | CREATE TABLE table_name_9 (home_team VARCHAR) |
SELECT "1997" FROM table_7412 WHERE "Tournament" = 'tennis masters cup' | In the Tennis Masters Cup, how did Ji Nov k do in 1997? | CREATE TABLE table_7412 (
"Tournament" text,
"1995" text,
"1996" text,
"1997" text,
"1998" text,
"1999" text,
"2000" text,
"2001" text,
"2002" text,
"2003" text,
"2004" text,
"2005" text,
"2006" text
) |
SELECT directed_by FROM table_25547943_1 WHERE written_by = "Bill Lawrence" | Who directed the episode that was written by Bill Lawrence? | CREATE TABLE table_25547943_1 (directed_by VARCHAR, written_by VARCHAR) |
SELECT COUNT(crowd) FROM table_name_44 WHERE venue = "lake oval" | What was the attendance when the VFL played Lake Oval? | CREATE TABLE table_name_44 (crowd VARCHAR, venue VARCHAR) |
SELECT place FROM table_name_73 WHERE player = "john cook" | What is the place of player john cook? | CREATE TABLE table_name_73 (
place VARCHAR,
player VARCHAR
) |
SELECT series AS result FROM table_2554479_2 WHERE season = "1998" | Name the series result for season being 1998 | CREATE TABLE table_2554479_2 (series VARCHAR, season VARCHAR) |
SELECT winning_team FROM table_name_80 WHERE winning_driver = "rick mears" AND name = "kraco twin 125 (r1)" | What is the Winning Team with Rick Mears' and Kraco Twin 125 (R1)? | CREATE TABLE table_name_80 (winning_team VARCHAR, winning_driver VARCHAR, name VARCHAR) |
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.age < "44" AND lab.itemid = "51067" | provide the number of patients with lab test item id 51067 who were younger than 44 years. | 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 (
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,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear 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
) |
SELECT COUNT(tests_won_by_australia) FROM table_2554479_2 WHERE series = 10 | Name the total number of tests won by australia for series 10 | CREATE TABLE table_2554479_2 (tests_won_by_australia VARCHAR, series VARCHAR) |
SELECT name FROM table_name_52 WHERE winning_team = "penske racing" | What is Penske Racing's name? | CREATE TABLE table_name_52 (name VARCHAR, winning_team VARCHAR) |
SELECT COUNT(*) FROM medication WHERE medication.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '010-5308')) AND medication.drugname = 'insulin lispro, recombinant' AND DATETIME(medication.drugstarttime, 'start of year') = DATETIME(CURRENT_TIME(), 'start of year', '-0 year') AND STRFTIME('%m', medication.drugstarttime) = '01' | what was the number of times insulin lispro, recombinant was prescribed for patient 010-5308 in 01/this year? | CREATE TABLE cost (
costid number,
uniquepid text,
patienthealthsystemstayid number,
eventtype text,
eventid number,
chargetime time,
cost number
)
CREATE TABLE allergy (
allergyid number,
patientunitstayid number,
drugname text,
allergyname text,
allergytime time
)
CREATE TABLE lab (
labid number,
patientunitstayid number,
labname text,
labresult number,
labresulttime time
)
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,
hospitaladmitsource text,
unitadmittime time,
unitdischargetime time,
hospitaldischargetime time,
hospitaldischargestatus text
)
CREATE TABLE medication (
medicationid number,
patientunitstayid number,
drugname text,
dosage text,
routeadmin text,
drugstarttime time,
drugstoptime time
)
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 diagnosis (
diagnosisid number,
patientunitstayid number,
diagnosisname text,
diagnosistime time,
icd9code text
)
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 intakeoutput (
intakeoutputid number,
patientunitstayid number,
cellpath text,
celllabel text,
cellvaluenumeric number,
intakeoutputtime time
) |
SELECT COUNT(winner) FROM table_25551880_2 WHERE mountains_classification = "not awarded" | How many winners were there when the mountains classification was not awarded? | CREATE TABLE table_25551880_2 (winner VARCHAR, mountains_classification VARCHAR) |
SELECT winning_driver FROM table_name_30 WHERE winning_team = "penske racing" AND pole_position = "rick mears" | Who is the winning driver of Penske Racing, and what was Rick Mears' pole position? | CREATE TABLE table_name_30 (winning_driver VARCHAR, winning_team VARCHAR, pole_position VARCHAR) |
SELECT meter_200, SUM(meter_100) FROM swimmer GROUP BY meter_200 ORDER BY meter_200 DESC | Find meter_200 and the sum of meter_100 , and group by attribute meter_200, and visualize them by a bar chart, list x-axis in descending order. | CREATE TABLE stadium (
ID int,
name text,
Capacity int,
City text,
Country text,
Opening_year int
)
CREATE TABLE event (
ID int,
Name text,
Stadium_ID int,
Year text
)
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_200 text,
meter_300 text,
meter_400 text,
meter_500 text,
meter_600 text,
meter_700 text,
Time text
) |
SELECT mountains_classification FROM table_25551880_2 WHERE winner = "Mikel Nieve" | Who was awarded mountains classifications when Mikel Nieve was the winner? | CREATE TABLE table_25551880_2 (mountains_classification VARCHAR, winner VARCHAR) |
SELECT winning_driver FROM table_name_6 WHERE name = "kraco twin 125 (r2)" | Who was Kraco Twin 125 (R2)'s Winning Driver? | CREATE TABLE table_name_6 (winning_driver VARCHAR, name VARCHAR) |
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.expire_flag = "1" AND demographic.dob_year < "2083" | How many of the patients born before 2083 have confirmed death status? | CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
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,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear 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
) |
SELECT mountains_classification FROM table_25551880_2 WHERE winner = "Alessandro Petacchi" | Who was awarded mountains classification when Alessandro petacchi won? | CREATE TABLE table_25551880_2 (mountains_classification VARCHAR, winner VARCHAR) |
SELECT report FROM table_name_68 WHERE winning_team = "penske racing" AND pole_position = "rick mears" | What is the Report of Winning Team Penske Racing, and what was Rick Mears' Pole position? | CREATE TABLE table_name_68 (report VARCHAR, winning_team VARCHAR, pole_position VARCHAR) |
SELECT COUNT("Jianshu") FROM table_12362 WHERE "Total" > '19.16' AND "Athlete" = 'nguyen huy thanh ( vie )' AND "Qiangshu" > '9.66' | What is the number of Jianshu when the total is more than 19.16, for Nguyen Huy Thanh ( vie ), and Qiangshu is more than 9.66? | CREATE TABLE table_12362 (
"Rank" real,
"Athlete" text,
"Qiangshu" real,
"Jianshu" real,
"Total" real
) |
SELECT COUNT(production_code) FROM table_25548213_1 WHERE directed_by = "Linda Mendoza" | List the number of episodes directed by linda mendoza. | CREATE TABLE table_25548213_1 (production_code VARCHAR, directed_by VARCHAR) |
SELECT pole_position FROM table_name_41 WHERE winning_team = "penske racing" AND name = "ii copa mexico 150" | What is the Pole Position for Winning Team Penske Racing, and the Name of II Copa Mexico 150? | CREATE TABLE table_name_41 (pole_position VARCHAR, winning_team VARCHAR, name VARCHAR) |
SELECT meter_600, ID FROM swimmer ORDER BY ID | Visualize a bar chart about the distribution of meter_600 and ID , display by the Y in asc. | CREATE TABLE event (
ID int,
Name text,
Stadium_ID int,
Year text
)
CREATE TABLE record (
ID int,
Result text,
Swimmer_ID int,
Event_ID int
)
CREATE TABLE stadium (
ID int,
name text,
Capacity int,
City text,
Country text,
Opening_year int
)
CREATE TABLE swimmer (
ID int,
name text,
Nationality text,
meter_100 real,
meter_200 text,
meter_300 text,
meter_400 text,
meter_500 text,
meter_600 text,
meter_700 text,
Time text
) |
SELECT us_viewers__million_ FROM table_25548213_1 WHERE written_by = "Kevin Biegel & Aseem Batra" | How many million viewers watch the episode that kevin biegel & aseem batra wrote? | CREATE TABLE table_25548213_1 (us_viewers__million_ VARCHAR, written_by VARCHAR) |
SELECT away_team FROM table_name_45 WHERE venue = "brunswick street oval" | Who was the away team at the game held at Brunswick Street Oval? | CREATE TABLE table_name_45 (away_team VARCHAR, venue VARCHAR) |
SELECT "Country of origin" FROM table_7703 WHERE "Year of intro" > '1985' AND "Primary cartridge" = '125mm' | What is Country of Origin, when Year of Intro is greater than 1985, and when Primary Cartridge is 125mm? | CREATE TABLE table_7703 (
"Name/ designation" text,
"Year of intro" real,
"Country of origin" text,
"Primary cartridge" text,
"Type" text
) |
SELECT MAX(series__number) FROM table_25548213_1 WHERE us_viewers__million_ = "5.31" | What is the series number that had 5.31 million viewers? | CREATE TABLE table_25548213_1 (series__number INTEGER, us_viewers__million_ VARCHAR) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.