NATURAL_LANG stringlengths 0 446 | SCHEMA stringlengths 27 2.21k | SQL stringlengths 18 453 | input_ids list | attention_mask list | labels list |
|---|---|---|---|---|---|
specify the gender and insurance of patient jesse ran | CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE 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
)
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 demographic.gender, demographic.insurance FROM demographic WHERE demographic.name = "Jesse Ran" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
4293,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
447,
26,
1298,
834,
4978,
1499,
6,
710,
834,
21869,
1499,
6,
307,
834,
21869,
1499,
3,
61,
3,
32102,
32103... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
14798,
5,
122,
3868,
6,
14798,
5,
29441,
21680,
14798,
549,
17444,
427,
14798,
5,
4350,
3274,
96,
683,
6119,
15039,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
count the number of patients with lab test item id 50995 who have been hospitalized for more than 29 days. | 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 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 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 COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.days_stay > "29" AND lab.itemid = "50995" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
18730,
7,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
447,
26,
1298,
834,
4978,
1499,
6,
710,
834,
21869,
1499,
6,
307,
834,
21869,
1499,
3,
61,
3,
32102,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
3388,
18206,
3,
15355,
3162,
7690,
9191,
14798,
5,
8399,
51,
834,
23,
26,
3274,
7690,
5,
8399,
51,
834,
23,
26,
549,
17444,... |
What was the original air date of the episode directed by frederick e. o. toye? | CREATE TABLE table_25923164_1 (
original_air_date VARCHAR,
directed_by VARCHAR
) | SELECT original_air_date FROM table_25923164_1 WHERE directed_by = "Frederick E. O. Toye" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1828,
4508,
3341,
4389,
834,
536,
41,
926,
834,
2256,
834,
5522,
584,
4280,
28027,
6,
6640,
834,
969,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
92... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
926,
834,
2256,
834,
5522,
21680,
953,
834,
1828,
4508,
3341,
4389,
834,
536,
549,
17444,
427,
6640,
834,
969,
3274,
96,
371,
1271,
15,
5206,
262,
5,
411,
5,
304,
63,
15,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100... |
Which year were both the Premier Division Ewyas Harold and Division Three Stoke Prior champions? | CREATE TABLE table_60250 (
"Season" text,
"Premier Division" text,
"Division One" text,
"Division Two" text,
"Division Three" text
) | SELECT "Season" FROM table_60250 WHERE "Premier Division" = 'ewyas harold' AND "Division Three" = 'stoke prior' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3328,
11434,
41,
96,
134,
15,
9,
739,
121,
1499,
6,
96,
10572,
51,
972,
6022,
121,
1499,
6,
96,
308,
23,
6610,
555,
121,
1499,
6,
96,
308,
23,
6610,
2759,
121,
1499,
6,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
134,
15,
9,
739,
121,
21680,
953,
834,
3328,
11434,
549,
17444,
427,
96,
10572,
51,
972,
6022,
121,
3274,
3,
31,
15,
210,
63,
9,
7,
3,
3272,
1490,
31,
3430,
96,
308,
23,
6610,
5245,
121,
3274,
3,
31,
7,
... |
What's the nationality of Livio Berruti? | CREATE TABLE table_name_53 (
nationality VARCHAR,
athlete VARCHAR
) | SELECT nationality FROM table_name_53 WHERE athlete = "livio berruti" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4867,
41,
1157,
485,
584,
4280,
28027,
6,
17893,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
31,
7,
8,
1157,
485,
13,
1414,
2099,
32,
5653,
6830... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
1157,
485,
21680,
953,
834,
4350,
834,
4867,
549,
17444,
427,
17893,
3274,
96,
40,
11687,
32,
3,
1152,
6830,
23,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Who was the centerfold model when the issue's pictorial was amanda beard, reby sky , girls of montauk ? | CREATE TABLE table_72701 (
"Date" text,
"Cover model" text,
"Centerfold model" text,
"Interview subject" text,
"20 Questions" text,
"Pictorials" text
) | SELECT "Centerfold model" FROM table_72701 WHERE "Pictorials" = 'Amanda Beard, Reby Sky , Girls of Montauk' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
5865,
2518,
536,
41,
96,
308,
342,
121,
1499,
6,
96,
254,
1890,
825,
121,
1499,
6,
96,
24382,
10533,
825,
121,
1499,
6,
96,
17555,
4576,
1426,
121,
1499,
6,
96,
1755,
142... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
24382,
10533,
825,
121,
21680,
953,
834,
5865,
2518,
536,
549,
17444,
427,
96,
345,
447,
17,
11929,
7,
121,
3274,
3,
31,
8123,
232,
9,
9034,
26,
6,
419,
969,
5643,
3,
6,
13312,
13,
5788,
9,
1598,
31,
1,
-1... |
Who ran in the race for the seat of incumbent Carl W. Rich? | CREATE TABLE table_1341865_37 (candidates VARCHAR, incumbent VARCHAR) | SELECT candidates FROM table_1341865_37 WHERE incumbent = "Carl W. Rich" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
23747,
2606,
4122,
834,
4118,
41,
1608,
12416,
6203,
584,
4280,
28027,
6,
28406,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
2645,
4037,
16,
8,
1964,
21,
8,
3143,
13... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
4341,
21680,
953,
834,
23747,
2606,
4122,
834,
4118,
549,
17444,
427,
28406,
3274,
96,
6936,
40,
549,
5,
10825,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
what's the original air date where written by is iain morris & damon beesley | CREATE TABLE table_72196 (
"No. in series" real,
"No. in season" real,
"Title" text,
"Directed by" text,
"Written by" text,
"Original air date" text
) | SELECT "Original air date" FROM table_72196 WHERE "Written by" = 'Iain Morris & Damon Beesley' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
5865,
26937,
41,
96,
4168,
5,
16,
939,
121,
490,
6,
96,
4168,
5,
16,
774,
121,
490,
6,
96,
382,
155,
109,
121,
1499,
6,
96,
23620,
15,
26,
57,
121,
1499,
6,
96,
24965... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
667,
3380,
10270,
799,
833,
121,
21680,
953,
834,
5865,
26937,
549,
17444,
427,
96,
24965,
324,
57,
121,
3274,
3,
31,
196,
9,
77,
12193,
3,
184,
10939,
106,
10024,
8887,
31,
1,
-100,
-100,
-100,
-100,
-100,
-1... |
What was the earliest date an institution was founded that joined in 1977? | CREATE TABLE table_261913_1 (
founded INTEGER,
joined VARCHAR
) | SELECT MIN(founded) FROM table_261913_1 WHERE joined = "1977" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2688,
2294,
2368,
834,
536,
41,
5710,
3,
21342,
17966,
6,
3311,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
3,
16454,
833,
46,
6568,
47,
5710,
24,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
3,
17684,
599,
23329,
61,
21680,
953,
834,
2688,
2294,
2368,
834,
536,
549,
17444,
427,
3311,
3274,
96,
2294,
4013,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
Who is the voice actor (harmony gold ova dub) of the character with a voice actor (adv TV/sentai ova dub) Kim Prause? | CREATE TABLE table_name_10 (
voice_actor__harmony_gold_ova_dub_ VARCHAR,
voice_actor__adv_tv_sentai_ova_dub_ VARCHAR
) | SELECT voice_actor__harmony_gold_ova_dub_ FROM table_name_10 WHERE voice_actor__adv_tv_sentai_ova_dub_ = "kim prause" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
1714,
41,
2249,
834,
9,
5317,
834,
834,
3272,
21208,
834,
14910,
834,
6194,
834,
1259,
115,
834,
584,
4280,
28027,
6,
2249,
834,
9,
5317,
834,
834,
9,
26,
208,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2249,
834,
9,
5317,
834,
834,
3272,
21208,
834,
14910,
834,
6194,
834,
1259,
115,
834,
21680,
953,
834,
4350,
834,
1714,
549,
17444,
427,
2249,
834,
9,
5317,
834,
834,
9,
26,
208,
834,
17,
208,
834,
5277,
9,
23,
... |
provide the number of patients whose days of hospital stay is greater than 10 and lab test fluid is ascites? | 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 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
) | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.days_stay > "10" AND lab.fluid = "Ascites" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
4293,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
447,
26,
1298,
834,
4978,
1499,
6,
710,
834,
21869,
1499,
6,
307,
834,
21869,
1499,
3,
61,
3,
32102,
32103... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
3388,
18206,
3,
15355,
3162,
7690,
9191,
14798,
5,
8399,
51,
834,
23,
26,
3274,
7690,
5,
8399,
51,
834,
23,
26,
549,
17444,... |
Name the disposition for date built is march 1909 | CREATE TABLE table_1748444_1 (
disposition VARCHAR,
date_built VARCHAR
) | SELECT disposition FROM table_1748444_1 WHERE date_built = "March 1909" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
27693,
4608,
3628,
834,
536,
41,
8295,
584,
4280,
28027,
6,
833,
834,
16152,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
5570,
8,
8295,
21,
833,
1192,
19,
10556,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
8295,
21680,
953,
834,
27693,
4608,
3628,
834,
536,
549,
17444,
427,
833,
834,
16152,
3274,
96,
25019,
957,
4198,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Scatterplot of card_number vs card id by card_type_code | CREATE TABLE Customers (
customer_id INTEGER,
customer_first_name VARCHAR(20),
customer_last_name VARCHAR(20),
customer_address VARCHAR(255),
customer_phone VARCHAR(255),
customer_email VARCHAR(255),
other_customer_details VARCHAR(255)
)
CREATE TABLE Customers_Cards (
card_id INTEGER,
customer_id INTEGER,
card_type_code VARCHAR(15),
card_number VARCHAR(80),
date_valid_from DATETIME,
date_valid_to DATETIME,
other_card_details VARCHAR(255)
)
CREATE TABLE Financial_Transactions (
transaction_id INTEGER,
previous_transaction_id INTEGER,
account_id INTEGER,
card_id INTEGER,
transaction_type VARCHAR(15),
transaction_date DATETIME,
transaction_amount DOUBLE,
transaction_comment VARCHAR(255),
other_transaction_details VARCHAR(255)
)
CREATE TABLE Accounts (
account_id INTEGER,
customer_id INTEGER,
account_name VARCHAR(50),
other_account_details VARCHAR(255)
) | SELECT card_id, card_number FROM Customers_Cards GROUP BY card_type_code | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
16423,
41,
884,
834,
23,
26,
3,
21342,
17966,
6,
884,
834,
14672,
834,
4350,
584,
4280,
28027,
599,
1755,
201,
884,
834,
5064,
834,
4350,
584,
4280,
28027,
599,
1755,
201,
884,
834,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
895,
834,
23,
26,
6,
895,
834,
5525,
1152,
21680,
16423,
834,
6936,
26,
7,
350,
4630,
6880,
272,
476,
895,
834,
6137,
834,
4978,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
What date was the game held at UMBC Field? | CREATE TABLE table_47863 (
"Date" text,
"Time" text,
"Opponent" text,
"Site" text,
"City" text
) | SELECT "Date" FROM table_47863 WHERE "Site" = 'umbc field' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4177,
3840,
519,
41,
96,
308,
342,
121,
1499,
6,
96,
13368,
121,
1499,
6,
96,
667,
102,
9977,
121,
1499,
6,
96,
26030,
121,
1499,
6,
96,
254,
485,
121,
1499,
3,
61,
3,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0... | [
3,
23143,
14196,
96,
308,
342,
121,
21680,
953,
834,
4177,
3840,
519,
549,
17444,
427,
96,
26030,
121,
3274,
3,
31,
5937,
75,
1057,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
What is Place, when Score is less than 70? | CREATE TABLE table_name_44 (
place VARCHAR,
score INTEGER
) | SELECT place FROM table_name_44 WHERE score < 70 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3628,
41,
286,
584,
4280,
28027,
6,
2604,
3,
21342,
17966,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
3399,
6,
116,
17763,
19,
705,
145,
2861,
58,
1,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
286,
21680,
953,
834,
4350,
834,
3628,
549,
17444,
427,
2604,
3,
2,
2861,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
Show all role codes and the number of employees in each role Show bar chart, and could you show by the bars in desc please? | CREATE TABLE Documents_to_be_Destroyed (
Document_ID INTEGER,
Destruction_Authorised_by_Employee_ID INTEGER,
Destroyed_by_Employee_ID INTEGER,
Planned_Destruction_Date DATETIME,
Actual_Destruction_Date DATETIME,
Other_Details VARCHAR(255)
)
CREATE TABLE Employees (
Employee_ID INTEGER,
Role_Code CHAR(15),
Employee_Name VARCHAR(255),
Gender_MFU CHAR(1),
Date_of_Birth DATETIME,
Other_Details VARCHAR(255)
)
CREATE TABLE Ref_Document_Types (
Document_Type_Code CHAR(15),
Document_Type_Name VARCHAR(255),
Document_Type_Description VARCHAR(255)
)
CREATE TABLE Ref_Locations (
Location_Code CHAR(15),
Location_Name VARCHAR(255),
Location_Description VARCHAR(255)
)
CREATE TABLE All_Documents (
Document_ID INTEGER,
Date_Stored DATETIME,
Document_Type_Code CHAR(15),
Document_Name CHAR(255),
Document_Description CHAR(255),
Other_Details VARCHAR(255)
)
CREATE TABLE Document_Locations (
Document_ID INTEGER,
Location_Code CHAR(15),
Date_in_Location_From DATETIME,
Date_in_Locaton_To DATETIME
)
CREATE TABLE Roles (
Role_Code CHAR(15),
Role_Name VARCHAR(255),
Role_Description VARCHAR(255)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME,
Day_Number INTEGER
) | SELECT Role_Code, COUNT(*) FROM Employees GROUP BY Role_Code ORDER BY Role_Code DESC | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
11167,
7,
834,
235,
834,
346,
834,
2962,
6626,
10093,
41,
11167,
834,
4309,
3,
21342,
17966,
6,
2973,
26853,
834,
23602,
127,
3375,
834,
969,
834,
427,
51,
7379,
63,
15,
15,
834,
430... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2158,
109,
834,
22737,
6,
2847,
17161,
599,
1935,
61,
21680,
15871,
7,
350,
4630,
6880,
272,
476,
2158,
109,
834,
22737,
4674,
11300,
272,
476,
2158,
109,
834,
22737,
309,
25067,
1,
-100,
-100,
-100,
-100,
-100,
-100,... |
How many bronzes associated with over 0 total medals, 3 golds, and over 6 games? | CREATE TABLE table_75034 (
"Games" real,
"First" real,
"Last" real,
"Gold" real,
"Bronze" real,
"Total" real,
"Best finish (first/last)" text
) | SELECT AVG("Bronze") FROM table_75034 WHERE "Total" > '0' AND "Gold" = '3' AND "Games" > '6' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
9979,
3710,
41,
96,
23055,
7,
121,
490,
6,
96,
25171,
121,
490,
6,
96,
3612,
7,
17,
121,
490,
6,
96,
23576,
121,
490,
6,
96,
22780,
29,
776,
121,
490,
6,
96,
3696,
19... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
71,
17217,
599,
121,
22780,
29,
776,
8512,
21680,
953,
834,
9979,
3710,
549,
17444,
427,
96,
3696,
1947,
121,
2490,
3,
31,
632,
31,
3430,
96,
23576,
121,
3274,
3,
31,
519,
31,
3430,
96,
23055,
7,
121,
2490,
3,
3... |
What city was completed in 1910-1978? | CREATE TABLE table_53460 (
"Area in m\u00b2" text,
"Completion" text,
"City" text,
"Country" text,
"Denomination" text
) | SELECT "City" FROM table_53460 WHERE "Completion" = '1910-1978' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4867,
25991,
41,
96,
188,
864,
16,
3,
51,
2,
76,
1206,
115,
357,
121,
1499,
6,
96,
5890,
4788,
1575,
121,
1499,
6,
96,
254,
485,
121,
1499,
6,
96,
10628,
651,
121,
1499... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
254,
485,
121,
21680,
953,
834,
4867,
25991,
549,
17444,
427,
96,
5890,
4788,
1575,
121,
3274,
3,
31,
2294,
1714,
4481,
3940,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What Player has a Place of t10? | CREATE TABLE table_name_2 (player VARCHAR, place VARCHAR) | SELECT player FROM table_name_2 WHERE place = "t10" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
357,
41,
20846,
584,
4280,
28027,
6,
286,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
12387,
65,
3,
9,
3399,
13,
3,
17,
1714,
58,
1,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
1959,
21680,
953,
834,
4350,
834,
357,
549,
17444,
427,
286,
3274,
96,
17,
1714,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
List the total number of defensive points for radek t p nek? | CREATE TABLE table_3056 (
"Rank" real,
"Player" text,
"Points" real,
"Points defending" real,
"Points won" real,
"New points" real,
"Withdrew due to" text
) | SELECT MIN("Points defending") FROM table_3056 WHERE "Player" = 'Radek Štěpánek' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1458,
4834,
41,
96,
22557,
121,
490,
6,
96,
15800,
49,
121,
1499,
6,
96,
22512,
7,
121,
490,
6,
96,
22512,
7,
3,
20309,
121,
490,
6,
96,
22512,
7,
751,
121,
490,
6,
9... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
3,
17684,
599,
121,
22512,
7,
3,
20309,
8512,
21680,
953,
834,
1458,
4834,
549,
17444,
427,
96,
15800,
49,
121,
3274,
3,
31,
448,
9,
221,
157,
3,
2,
17,
2,
102,
12916,
15,
157,
31,
1,
-100,
-100,
-100,
-100,
-... |
List the duration, file size and format of songs whose genre is pop, ordered by title? | CREATE TABLE song (f_id VARCHAR, genre_is VARCHAR, song_name VARCHAR); CREATE TABLE files (duration VARCHAR, file_size VARCHAR, formats VARCHAR, f_id VARCHAR) | SELECT T1.duration, T1.file_size, T1.formats FROM files AS T1 JOIN song AS T2 ON T1.f_id = T2.f_id WHERE T2.genre_is = "pop" ORDER BY T2.song_name | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
2324,
41,
89,
834,
23,
26,
584,
4280,
28027,
6,
5349,
834,
159,
584,
4280,
28027,
6,
2324,
834,
4350,
584,
4280,
28027,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
2073,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
332,
5411,
1259,
2661,
6,
332,
5411,
11966,
834,
7991,
6,
332,
5411,
8995,
7,
21680,
2073,
6157,
332,
536,
3,
15355,
3162,
2324,
6157,
332,
357,
9191,
332,
5411,
89,
834,
23,
26,
3274,
332,
4416,
89,
834,
23,
26,
... |
Which team was the opponent on December 30? | CREATE TABLE table_40741 (
"Game" real,
"Date" text,
"Team" text,
"Score" text,
"High points" text,
"High assists" text,
"Location Attendance" text,
"Record" text
) | SELECT "Team" FROM table_40741 WHERE "Date" = 'december 30' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2445,
4581,
536,
41,
96,
23055,
121,
490,
6,
96,
308,
342,
121,
1499,
6,
96,
18699,
121,
1499,
6,
96,
134,
9022,
121,
1499,
6,
96,
21417,
979,
121,
1499,
6,
96,
21417,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
18699,
121,
21680,
953,
834,
2445,
4581,
536,
549,
17444,
427,
96,
308,
342,
121,
3274,
3,
31,
221,
75,
18247,
604,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
what is the properties of potassium when lithium is h a l o g e n s and sodium is bromine? | CREATE TABLE table_name_76 (
potassium VARCHAR,
lithium VARCHAR,
sodium VARCHAR
) | SELECT potassium FROM table_name_76 WHERE lithium = "h a l o g e n s" AND sodium = "bromine" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3959,
41,
26110,
584,
4280,
28027,
6,
26780,
584,
4280,
28027,
6,
19049,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
125,
19,
8,
2605,
13,
26110,
116,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
26110,
21680,
953,
834,
4350,
834,
3959,
549,
17444,
427,
26780,
3274,
96,
107,
3,
9,
3,
40,
3,
32,
3,
122,
3,
15,
3,
29,
3,
7,
121,
3430,
19049,
3274,
96,
5702,
8695,
121,
1,
-100,
-100,
-100,
-100,
-100,
-10... |
What percentage of Azad Kashmir is Hindu? | CREATE TABLE table_name_74 (
_percentage_hindu VARCHAR,
area VARCHAR
) | SELECT _percentage_hindu FROM table_name_74 WHERE area = "azad kashmir" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4581,
41,
3,
834,
883,
3728,
545,
834,
107,
13580,
584,
4280,
28027,
6,
616,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
5294,
13,
12611,
9,
26,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
3,
834,
883,
3728,
545,
834,
107,
13580,
21680,
953,
834,
4350,
834,
4581,
549,
17444,
427,
616,
3274,
96,
5246,
26,
3,
157,
3198,
5884,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
What was the score of the game with away team chelsea on 29 january 1983? | CREATE TABLE table_59971 (
"Tie no" text,
"Home team" text,
"Score" text,
"Away team" text,
"Date" text
) | SELECT "Score" FROM table_59971 WHERE "Date" = '29 january 1983' AND "Away team" = 'chelsea' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3390,
4327,
536,
41,
96,
382,
23,
15,
150,
121,
1499,
6,
96,
19040,
372,
121,
1499,
6,
96,
134,
9022,
121,
1499,
6,
96,
188,
1343,
372,
121,
1499,
6,
96,
308,
342,
121,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
134,
9022,
121,
21680,
953,
834,
3390,
4327,
536,
549,
17444,
427,
96,
308,
342,
121,
3274,
3,
31,
3166,
3,
7066,
76,
1208,
15041,
31,
3430,
96,
188,
1343,
372,
121,
3274,
3,
31,
8738,
7,
15,
9,
31,
1,
-10... |
What was the production code of the episode ranked 28? | CREATE TABLE table_26200084_1 (production_code VARCHAR, rank__week_ VARCHAR) | SELECT production_code FROM table_26200084_1 WHERE rank__week_ = "28" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2688,
13527,
4608,
834,
536,
41,
20762,
834,
4978,
584,
4280,
28027,
6,
11003,
834,
834,
8041,
834,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
999,
1081... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
999,
834,
4978,
21680,
953,
834,
2688,
13527,
4608,
834,
536,
549,
17444,
427,
11003,
834,
834,
8041,
834,
3274,
96,
2577,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
Who is the owner of the branding gx94? | CREATE TABLE table_31718 (
"Frequency" text,
"Call sign" text,
"Branding" text,
"Format" text,
"Owner" text
) | SELECT "Owner" FROM table_31718 WHERE "Branding" = 'gx94' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
519,
2517,
2606,
41,
96,
371,
60,
835,
11298,
121,
1499,
6,
96,
254,
1748,
1320,
121,
1499,
6,
96,
18304,
727,
53,
121,
1499,
6,
96,
3809,
3357,
121,
1499,
6,
96,
667,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
667,
210,
687,
121,
21680,
953,
834,
519,
2517,
2606,
549,
17444,
427,
96,
18304,
727,
53,
121,
3274,
3,
31,
122,
226,
4240,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What numbered game did they play on april 5? | CREATE TABLE table_29919 (
"Game" real,
"Date" text,
"Team" text,
"Score" text,
"High points" text,
"High rebounds" text,
"High assists" text,
"Location Attendance" text,
"Record" text
) | SELECT MAX("Game") FROM table_29919 WHERE "Date" = 'April 5' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
357,
3264,
2294,
41,
96,
23055,
121,
490,
6,
96,
308,
342,
121,
1499,
6,
96,
18699,
121,
1499,
6,
96,
134,
9022,
121,
1499,
6,
96,
21417,
979,
121,
1499,
6,
96,
21417,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
4800,
4,
599,
121,
23055,
8512,
21680,
953,
834,
357,
3264,
2294,
549,
17444,
427,
96,
308,
342,
121,
3274,
3,
31,
23323,
305,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
What type are State Assemblyman | CREATE TABLE table_20478 (
"Office" text,
"Type" text,
"Location" text,
"Elected" real,
"Term began" text,
"Term ended" text
) | SELECT "Type" FROM table_20478 WHERE "Office" = 'State Assemblyman' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
26363,
3940,
41,
96,
22098,
121,
1499,
6,
96,
25160,
121,
1499,
6,
96,
434,
32,
75,
257,
121,
1499,
6,
96,
21543,
15,
26,
121,
490,
6,
96,
11679,
1553,
121,
1499,
6,
96... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0... | [
3,
23143,
14196,
96,
25160,
121,
21680,
953,
834,
26363,
3940,
549,
17444,
427,
96,
22098,
121,
3274,
3,
31,
134,
4748,
11993,
348,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
provide the number of patients whose death status is 1 and primary disease is sdh? | 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
)
CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE 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(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.expire_flag = "1" AND demographic.diagnosis = "SDH" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
18730,
7,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
447,
26,
1298,
834,
4978,
1499,
6,
710,
834,
21869,
1499,
6,
307,
834,
21869,
1499,
3,
61,
3,
32102,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
549,
17444,
427,
14798,
5,
994,
2388,
15,
834,
89,
5430,
3274,
96,
536,
121,
3430,
14798,
5,
25930,
4844,
159,
3274,
96,
13... |
What was Nick Faldo's score? | CREATE TABLE table_name_73 (
score VARCHAR,
player VARCHAR
) | SELECT score FROM table_name_73 WHERE player = "nick faldo" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4552,
41,
2604,
584,
4280,
28027,
6,
1959,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
7486,
10747,
26,
32,
31,
7,
2604,
58,
1,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2604,
21680,
953,
834,
4350,
834,
4552,
549,
17444,
427,
1959,
3274,
96,
11191,
12553,
26,
32,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Which Team has a Date of appointment on sep. 20, 2008? | CREATE TABLE table_name_14 (team VARCHAR, date_of_appointment VARCHAR) | SELECT team FROM table_name_14 WHERE date_of_appointment = "sep. 20, 2008" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2534,
41,
11650,
584,
4280,
28027,
6,
833,
834,
858,
834,
9,
102,
2700,
297,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
4073,
2271,
65,
3,
9,
7678,
13,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
372,
21680,
953,
834,
4350,
834,
2534,
549,
17444,
427,
833,
834,
858,
834,
9,
102,
2700,
297,
3274,
96,
7,
15,
102,
5,
16047,
2628,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Name the most ceiling temperature for very extra high | CREATE TABLE table_1538516_1 (maximum_ceiling_temperature VARCHAR, temperature_classification VARCHAR) | SELECT maximum_ceiling_temperature FROM table_1538516_1 WHERE temperature_classification = "Very Extra High" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
27025,
4433,
2938,
834,
536,
41,
9128,
603,
440,
834,
565,
173,
53,
834,
21010,
15,
584,
4280,
28027,
6,
2912,
834,
4057,
2420,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2411,
834,
565,
173,
53,
834,
21010,
15,
21680,
953,
834,
27025,
4433,
2938,
834,
536,
549,
17444,
427,
2912,
834,
4057,
2420,
3274,
96,
5000,
63,
8505,
1592,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
count the number of patients whose days of hospital stay is greater than 13 and lab test name is creatinine? | 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(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.days_stay > "13" AND lab.label = "Creatinine" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
18730,
7,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
447,
26,
1298,
834,
4978,
1499,
6,
710,
834,
21869,
1499,
6,
307,
834,
21869,
1499,
3,
61,
3,
32102,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
3388,
18206,
3,
15355,
3162,
7690,
9191,
14798,
5,
8399,
51,
834,
23,
26,
3274,
7690,
5,
8399,
51,
834,
23,
26,
549,
17444,... |
What was the score of the game with Nathalie Tauziat as a partner? | CREATE TABLE table_name_7 (score VARCHAR, partnering VARCHAR) | SELECT score FROM table_name_7 WHERE partnering = "nathalie tauziat" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
940,
41,
7,
9022,
584,
4280,
28027,
6,
3,
26361,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
2604,
13,
8,
467,
28,
9267,
1024,
1896,
11452,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2604,
21680,
953,
834,
4350,
834,
940,
549,
17444,
427,
3,
26361,
3274,
96,
29,
9,
189,
9,
1896,
7151,
702,
144,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
what team comes before hank stein ? | CREATE TABLE table_204_93 (
id number,
"round" number,
"pick" number,
"player" text,
"position" text,
"nationality" text,
"team" text,
"college" text
) | SELECT "team" FROM table_204_93 WHERE id = (SELECT id FROM table_204_93 WHERE "player" = 'hank stein') - 1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
26363,
834,
4271,
41,
3,
23,
26,
381,
6,
96,
7775,
121,
381,
6,
96,
17967,
121,
381,
6,
96,
20846,
121,
1499,
6,
96,
4718,
121,
1499,
6,
96,
16557,
485,
121,
1499,
6,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
11650,
121,
21680,
953,
834,
26363,
834,
4271,
549,
17444,
427,
3,
23,
26,
3274,
41,
23143,
14196,
3,
23,
26,
21680,
953,
834,
26363,
834,
4271,
549,
17444,
427,
96,
20846,
121,
3274,
3,
31,
2618,
157,
3,
4008... |
How many League Goals have League Cup Goals smaller than 0? | CREATE TABLE table_65893 (
"Name" text,
"Position" text,
"League Apps" text,
"League Goals" real,
"FA Cup Apps" text,
"FA Cup Goals" real,
"League Cup Apps" real,
"League Cup Goals" real,
"Total Apps" text,
"Total Goals" real
) | SELECT SUM("League Goals") FROM table_65893 WHERE "League Cup Goals" < '0' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4122,
3914,
519,
41,
96,
23954,
121,
1499,
6,
96,
345,
32,
7,
4749,
121,
1499,
6,
96,
2796,
9,
5398,
2276,
7,
121,
1499,
6,
96,
2796,
9,
5398,
17916,
7,
121,
490,
6,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
180,
6122,
599,
121,
2796,
9,
5398,
17916,
7,
8512,
21680,
953,
834,
4122,
3914,
519,
549,
17444,
427,
96,
2796,
9,
5398,
3802,
17916,
7,
121,
3,
2,
3,
31,
632,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What is every use for number 1? | CREATE TABLE table_1977 (
"Number" text,
"Previous Number(s)" real,
"Previous Class" text,
"Converted" real,
"Use" text,
"Withdrawn" real,
"Disposal" text
) | SELECT "Use" FROM table_1977 WHERE "Number" = '1' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2294,
4013,
41,
96,
567,
5937,
49,
121,
1499,
6,
96,
10572,
19117,
7720,
599,
7,
61,
121,
490,
6,
96,
10572,
19117,
4501,
121,
1499,
6,
96,
4302,
19825,
121,
490,
6,
96,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
1265,
7,
15,
121,
21680,
953,
834,
2294,
4013,
549,
17444,
427,
96,
567,
5937,
49,
121,
3274,
3,
31,
536,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the smallest preliminary when swimsuit is less than 8.822, interview is more than 8.744 and gown is more than 9.333? | CREATE TABLE table_name_50 (preliminary INTEGER, evening_gown VARCHAR, swimsuit VARCHAR, interview VARCHAR) | SELECT MIN(preliminary) FROM table_name_50 WHERE swimsuit < 8.822 AND interview > 8.744 AND evening_gown > 9.333 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
1752,
41,
2026,
4941,
77,
1208,
3,
21342,
17966,
6,
2272,
834,
122,
9197,
584,
4280,
28027,
6,
9728,
7628,
584,
4280,
28027,
6,
2772,
584,
4280,
28027,
61,
3,
32... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
3,
17684,
599,
2026,
4941,
77,
1208,
61,
21680,
953,
834,
4350,
834,
1752,
549,
17444,
427,
9728,
7628,
3,
2,
4848,
4613,
357,
3430,
2772,
2490,
4848,
4581,
591,
3430,
2272,
834,
122,
9197,
2490,
5835,
23360,
1,
-10... |
how many patients admitted to phys referral/normal deli were treated with simv40? | 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 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 (
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 procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
) | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE demographic.admission_location = "PHYS REFERRAL/NORMAL DELI" AND prescriptions.formulary_drug_cd = "SIMV40" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
7744,
7,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
23,
1071,
21545,
834,
23,
26,
1499,
6,
2672,
834,
6137,
1499,
6,
2672,
1499,
6,
5403,
651,
834,
26,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
3388,
18206,
3,
15355,
3162,
7744,
7,
9191,
14798,
5,
8399,
51,
834,
23,
26,
3274,
7744,
7,
5,
8399,
51,
834,
23,
26,
549... |
What is the record for Brussels translations? | CREATE TABLE table_name_84 (
recorded VARCHAR,
translation VARCHAR
) | SELECT recorded FROM table_name_84 WHERE translation = "brussels" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4608,
41,
4381,
584,
4280,
28027,
6,
7314,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
1368,
21,
20501,
7314,
7,
58,
1,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
4381,
21680,
953,
834,
4350,
834,
4608,
549,
17444,
427,
7314,
3274,
96,
9052,
9816,
7,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What is the railway number of t 4 ii class? | CREATE TABLE table_name_68 (
railway_number_s_ VARCHAR,
class VARCHAR
) | SELECT railway_number_s_ FROM table_name_68 WHERE class = "t 4 ii" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3651,
41,
14421,
834,
5525,
1152,
834,
7,
834,
584,
4280,
28027,
6,
853,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
14421,
381,
13,
3,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
14421,
834,
5525,
1152,
834,
7,
834,
21680,
953,
834,
4350,
834,
3651,
549,
17444,
427,
853,
3274,
96,
17,
314,
3,
23,
23,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
If second leg is Newell's Old Boys, what name is first leg? | CREATE TABLE table_22032 (
"Home (1st leg)" text,
"Home (2nd leg)" text,
"1st Leg" text,
"2nd leg" text,
"Aggregate" text
) | SELECT "1st Leg" FROM table_22032 WHERE "Home (2nd leg)" = 'Newell''s Old Boys' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
357,
1755,
2668,
41,
96,
19040,
4077,
7,
17,
4553,
61,
121,
1499,
6,
96,
19040,
4743,
727,
4553,
61,
121,
1499,
6,
96,
536,
7,
17,
18978,
121,
1499,
6,
96,
357,
727,
45... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
536,
7,
17,
18978,
121,
21680,
953,
834,
357,
1755,
2668,
549,
17444,
427,
96,
19040,
4743,
727,
4553,
61,
121,
3274,
3,
31,
6861,
3820,
31,
31,
7,
3525,
16575,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
What's the rank of Turkey (TUR) with a total more than 2? | CREATE TABLE table_name_14 (rank VARCHAR, nation VARCHAR, total VARCHAR) | SELECT COUNT(rank) FROM table_name_14 WHERE nation = "turkey (tur)" AND total > 2 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2534,
41,
6254,
584,
4280,
28027,
6,
2982,
584,
4280,
28027,
6,
792,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
31,
7,
8,
11003,
13,
9299,
41,
211... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2847,
17161,
599,
6254,
61,
21680,
953,
834,
4350,
834,
2534,
549,
17444,
427,
2982,
3274,
96,
2905,
4397,
41,
2905,
61,
121,
3430,
792,
2490,
204,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What are the number of the completion dates of all the tests that have result 'Fail'?, sort bars in desc order. | CREATE TABLE Course_Authors_and_Tutors (
author_id INTEGER,
author_tutor_ATB VARCHAR(3),
login_name VARCHAR(40),
password VARCHAR(40),
personal_name VARCHAR(80),
middle_name VARCHAR(80),
family_name VARCHAR(80),
gender_mf VARCHAR(1),
address_line_1 VARCHAR(80)
)
CREATE TABLE Students (
student_id INTEGER,
date_of_registration DATETIME,
date_of_latest_logon DATETIME,
login_name VARCHAR(40),
password VARCHAR(10),
personal_name VARCHAR(40),
middle_name VARCHAR(40),
family_name VARCHAR(40)
)
CREATE TABLE Student_Course_Enrolment (
registration_id INTEGER,
student_id INTEGER,
course_id INTEGER,
date_of_enrolment DATETIME,
date_of_completion DATETIME
)
CREATE TABLE Subjects (
subject_id INTEGER,
subject_name VARCHAR(120)
)
CREATE TABLE Student_Tests_Taken (
registration_id INTEGER,
date_test_taken DATETIME,
test_result VARCHAR(255)
)
CREATE TABLE Courses (
course_id INTEGER,
author_id INTEGER,
subject_id INTEGER,
course_name VARCHAR(120),
course_description VARCHAR(255)
) | SELECT date_of_completion, COUNT(date_of_completion) FROM Student_Course_Enrolment AS T1 JOIN Student_Tests_Taken AS T2 ON T1.registration_id = T2.registration_id WHERE T2.test_result = "Fail" GROUP BY date_of_completion ORDER BY date_of_completion DESC | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
8670,
834,
23602,
127,
7,
834,
232,
834,
28676,
7,
41,
2291,
834,
23,
26,
3,
21342,
17966,
6,
2291,
834,
17,
76,
17,
127,
834,
5767,
279,
584,
4280,
28027,
17867,
6,
11255,
834,
43... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
833,
834,
858,
834,
7699,
109,
1575,
6,
2847,
17161,
599,
5522,
834,
858,
834,
7699,
109,
1575,
61,
21680,
6341,
834,
3881,
3589,
15,
834,
8532,
3491,
297,
6157,
332,
536,
3,
15355,
3162,
6341,
834,
382,
222,
7,
8... |
Who was the opponent with the record of 15-21-6? | CREATE TABLE table_76320 (
"Game" real,
"January" real,
"Opponent" text,
"Score" text,
"Record" text
) | SELECT "Opponent" FROM table_76320 WHERE "Record" = '15-21-6' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3959,
15003,
41,
96,
23055,
121,
490,
6,
96,
30404,
121,
490,
6,
96,
667,
102,
9977,
121,
1499,
6,
96,
134,
9022,
121,
1499,
6,
96,
1649,
7621,
121,
1499,
3,
61,
3,
321... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0... | [
3,
23143,
14196,
96,
667,
102,
9977,
121,
21680,
953,
834,
3959,
15003,
549,
17444,
427,
96,
1649,
7621,
121,
3274,
3,
31,
1808,
16539,
5783,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the Date of the game with a Score of 6 4, 6 2? | CREATE TABLE table_78909 (
"Date" text,
"Tournament" text,
"Surface" text,
"Opponent in the final" text,
"Score" text
) | SELECT "Date" FROM table_78909 WHERE "Score" = '6–4, 6–2' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3940,
2394,
1298,
41,
96,
308,
342,
121,
1499,
6,
96,
382,
1211,
20205,
17,
121,
1499,
6,
96,
134,
450,
4861,
121,
1499,
6,
96,
667,
102,
9977,
16,
8,
804,
121,
1499,
6... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
308,
342,
121,
21680,
953,
834,
3940,
2394,
1298,
549,
17444,
427,
96,
134,
9022,
121,
3274,
3,
31,
948,
104,
8525,
431,
104,
357,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the maximum points received when Peeter V hl gave a 9? | CREATE TABLE table_29261215_4 (
points INTEGER,
peeter_vähi VARCHAR
) | SELECT MIN(points) FROM table_29261215_4 WHERE peeter_vähi = 9 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3166,
2688,
2122,
1808,
834,
591,
41,
979,
3,
21342,
17966,
6,
158,
15,
449,
834,
208,
5588,
23,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
2411,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
3,
17684,
599,
2700,
7,
61,
21680,
953,
834,
3166,
2688,
2122,
1808,
834,
591,
549,
17444,
427,
158,
15,
449,
834,
208,
5588,
23,
3274,
668,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
Which score has a Home Team of saskatoon accelerators? | CREATE TABLE table_name_61 (
score VARCHAR,
home_team VARCHAR
) | SELECT score FROM table_name_61 WHERE home_team = "saskatoon accelerators" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4241,
41,
2604,
584,
4280,
28027,
6,
234,
834,
11650,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
4073,
2604,
65,
3,
9,
1210,
2271,
13,
3,
7,
9,
10... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2604,
21680,
953,
834,
4350,
834,
4241,
549,
17444,
427,
234,
834,
11650,
3274,
96,
7,
9,
10717,
235,
106,
30202,
7,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What was the winning score of the Greater Vancouver Open tournament? | CREATE TABLE table_name_50 (winning_score VARCHAR, tournament VARCHAR) | SELECT winning_score FROM table_name_50 WHERE tournament = "greater vancouver open" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
1752,
41,
8163,
834,
7,
9022,
584,
4280,
28027,
6,
5892,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
3447,
2604,
13,
8,
15993,
11680,
2384,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
3447,
834,
7,
9022,
21680,
953,
834,
4350,
834,
1752,
549,
17444,
427,
5892,
3274,
96,
20288,
49,
4049,
3422,
624,
539,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
What was the score for a goal of 6? | CREATE TABLE table_name_57 (
score VARCHAR,
goal VARCHAR
) | SELECT score FROM table_name_57 WHERE goal = 6 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3436,
41,
2604,
584,
4280,
28027,
6,
1288,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
2604,
21,
3,
9,
1288,
13,
431,
58,
1,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2604,
21680,
953,
834,
4350,
834,
3436,
549,
17444,
427,
1288,
3274,
431,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
In what Election year was Adalberto Mosaner the Mayor with less than 16,170 Inhabitants? | CREATE TABLE table_50465 (
"Municipality" text,
"Inhabitants" real,
"Mayor" text,
"Party" text,
"Election" real
) | SELECT SUM("Election") FROM table_50465 WHERE "Mayor" = 'adalberto mosaner' AND "Inhabitants" < '16,170' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1752,
591,
4122,
41,
96,
329,
202,
23,
3389,
10355,
121,
1499,
6,
96,
1570,
29884,
7,
121,
490,
6,
96,
15881,
127,
121,
1499,
6,
96,
13725,
63,
121,
1499,
6,
96,
427,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
180,
6122,
599,
121,
427,
12252,
8512,
21680,
953,
834,
1752,
591,
4122,
549,
17444,
427,
96,
15881,
127,
121,
3274,
3,
31,
9,
26,
138,
7041,
32,
3,
3972,
9,
687,
31,
3430,
96,
1570,
29884,
7,
121,
3,
2,
3,
31... |
count the number of patients whose days of hospital stay is greater than 4 and procedure long title is angioplasty of other non-coronary vessel(s)? | 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 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 COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN procedures ON demographic.hadm_id = procedures.hadm_id WHERE demographic.days_stay > "4" AND procedures.long_title = "Angioplasty of other non-coronary vessel(s)" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
18730,
7,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
447,
26,
1298,
834,
4978,
1499,
6,
710,
834,
21869,
1499,
6,
307,
834,
21869,
1499,
3,
61,
3,
32102,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
3388,
18206,
3,
15355,
3162,
4293,
9191,
14798,
5,
8399,
51,
834,
23,
26,
3274,
4293,
5,
8399,
51,
834,
23,
26,
549,
17444,... |
When Brett Lancaster won the general classification, who won the team calssification? | CREATE TABLE table_25055040_22 (
team_classification VARCHAR,
general_classification VARCHAR
) | SELECT team_classification FROM table_25055040_22 WHERE general_classification = "Brett Lancaster" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
11434,
17147,
2445,
834,
2884,
41,
372,
834,
4057,
2420,
584,
4280,
28027,
6,
879,
834,
4057,
2420,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
366,
21203,
27830,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
372,
834,
4057,
2420,
21680,
953,
834,
11434,
17147,
2445,
834,
2884,
549,
17444,
427,
879,
834,
4057,
2420,
3274,
96,
279,
60,
17,
17,
27830,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What position has a pick less than 20? | CREATE TABLE table_name_2 (position VARCHAR, pick INTEGER) | SELECT position FROM table_name_2 WHERE pick < 20 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
357,
41,
4718,
584,
4280,
28027,
6,
1432,
3,
21342,
17966,
61,
3,
32102,
32103,
32101,
32103,
363,
1102,
65,
3,
9,
1432,
705,
145,
460,
58,
1,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
1102,
21680,
953,
834,
4350,
834,
357,
549,
17444,
427,
1432,
3,
2,
460,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
Which sum of AVE-No has a Name of albula alps, and a Height (m) larger than 3418? | CREATE TABLE table_name_98 (
ave__no INTEGER,
name VARCHAR,
height__m_ VARCHAR
) | SELECT SUM(ave__no) FROM table_name_98 WHERE name = "albula alps" AND height__m_ > 3418 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3916,
41,
3,
9,
162,
834,
834,
29,
32,
3,
21342,
17966,
6,
564,
584,
4280,
28027,
6,
3902,
834,
834,
51,
834,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
180,
6122,
599,
9,
162,
834,
834,
29,
32,
61,
21680,
953,
834,
4350,
834,
3916,
549,
17444,
427,
564,
3274,
96,
138,
6724,
9,
491,
102,
7,
121,
3430,
3902,
834,
834,
51,
834,
2490,
6154,
2606,
1,
-100,
-100,
-10... |
A bar chart showing the number of first name for all female students. Their sex is F. | CREATE TABLE Has_Allergy (
StuID INTEGER,
Allergy VARCHAR(20)
)
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)
) | SELECT Fname, COUNT(Fname) FROM Student WHERE Sex = 'F' GROUP BY Fname | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
4498,
834,
6838,
49,
122,
63,
41,
3,
13076,
4309,
3,
21342,
17966,
6,
432,
49,
122,
63,
584,
4280,
28027,
599,
1755,
61,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
377,
4350,
6,
2847,
17161,
599,
371,
4350,
61,
21680,
6341,
549,
17444,
427,
679,
226,
3274,
3,
31,
371,
31,
350,
4630,
6880,
272,
476,
377,
4350,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
What driver has under 19 laps and a grid under 10? | CREATE TABLE table_name_89 (driver VARCHAR, laps VARCHAR, grid VARCHAR) | SELECT driver FROM table_name_89 WHERE laps < 19 AND grid < 10 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3914,
41,
13739,
52,
584,
4280,
28027,
6,
14941,
7,
584,
4280,
28027,
6,
8634,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
2535,
65,
365,
957,
14941,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2535,
21680,
953,
834,
4350,
834,
3914,
549,
17444,
427,
14941,
7,
3,
2,
957,
3430,
8634,
3,
2,
335,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
What actor has onderweg naar morgen, as the soap opera, with aafke couwenberg as the character? | CREATE TABLE table_name_47 (
actor VARCHAR,
soap_opera VARCHAR,
character VARCHAR
) | SELECT actor FROM table_name_47 WHERE soap_opera = "onderweg naar morgen" AND character = "aafke couwenberg" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4177,
41,
7556,
584,
4280,
28027,
6,
10758,
834,
18140,
584,
4280,
28027,
6,
1848,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
7556,
65,
30,
588,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
7556,
21680,
953,
834,
4350,
834,
4177,
549,
17444,
427,
10758,
834,
18140,
3274,
96,
106,
588,
4189,
3,
29,
9,
291,
8030,
729,
121,
3430,
1848,
3274,
96,
9,
9,
89,
1050,
3,
3422,
210,
11063,
121,
1,
-100,
-100,
... |
What is the score of Tim Herron, who placed t1? | CREATE TABLE table_67161 (
"Place" text,
"Player" text,
"Country" text,
"Score" text,
"To par" text
) | SELECT "Score" FROM table_67161 WHERE "Place" = 't1' AND "Player" = 'tim herron' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3708,
2938,
536,
41,
96,
345,
11706,
121,
1499,
6,
96,
15800,
49,
121,
1499,
6,
96,
10628,
651,
121,
1499,
6,
96,
134,
9022,
121,
1499,
6,
96,
3696,
260,
121,
1499,
3,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
134,
9022,
121,
21680,
953,
834,
3708,
2938,
536,
549,
17444,
427,
96,
345,
11706,
121,
3274,
3,
31,
17,
536,
31,
3430,
96,
15800,
49,
121,
3274,
3,
31,
2998,
160,
52,
106,
31,
1,
-100,
-100,
-100,
-100,
-10... |
Which network returns april 3, and a Show of shop 'til you drop? | CREATE TABLE table_50874 (
"Show" text,
"Last Aired" real,
"Previous Network" text,
"Retitled as/Same" text,
"New/Returning/Same Network" text,
"Returning" text
) | SELECT "New/Returning/Same Network" FROM table_50874 WHERE "Returning" = 'april 3' AND "Show" = 'shop ''til you drop' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1752,
4225,
591,
41,
96,
134,
4067,
121,
1499,
6,
96,
3612,
7,
17,
1761,
15,
26,
121,
490,
6,
96,
10572,
19117,
3426,
121,
1499,
6,
96,
1649,
10920,
38,
87,
134,
265,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
6861,
87,
1649,
7535,
53,
87,
134,
265,
15,
3426,
121,
21680,
953,
834,
1752,
4225,
591,
549,
17444,
427,
96,
1649,
7535,
53,
121,
3274,
3,
31,
9,
2246,
40,
220,
31,
3430,
96,
134,
4067,
121,
3274,
3,
31,
... |
Name the most wins for losses more than 2 and points of two with place larger than 7 | CREATE TABLE table_name_4 (
wins INTEGER,
place VARCHAR,
losses VARCHAR,
points VARCHAR
) | SELECT MAX(wins) FROM table_name_4 WHERE losses > "2" AND points = "2" AND place > 7 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
591,
41,
9204,
3,
21342,
17966,
6,
286,
584,
4280,
28027,
6,
8467,
584,
4280,
28027,
6,
979,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
5570,
8,
167... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
4800,
4,
599,
3757,
7,
61,
21680,
953,
834,
4350,
834,
591,
549,
17444,
427,
8467,
2490,
96,
357,
121,
3430,
979,
3274,
96,
357,
121,
3430,
286,
2490,
489,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
How much To par has a Country of united states, and a Money ($) of 90? | CREATE TABLE table_name_42 (
to_par VARCHAR,
country VARCHAR,
money___$__ VARCHAR
) | SELECT COUNT(to_par) FROM table_name_42 WHERE country = "united states" AND money___$__ = 90 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4165,
41,
12,
834,
1893,
584,
4280,
28027,
6,
684,
584,
4280,
28027,
6,
540,
834,
834,
834,
3229,
834,
834,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
3210... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
235,
834,
1893,
61,
21680,
953,
834,
4350,
834,
4165,
549,
17444,
427,
684,
3274,
96,
15129,
15,
26,
2315,
121,
3430,
540,
834,
834,
834,
3229,
834,
834,
3274,
2777,
1,
-100,
-100,
-100,
-100,
-100... |
what is the number of newborn patients who have po/ng route of drug administration? | 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,
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 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
)
CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
) | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE demographic.admission_type = "NEWBORN" AND prescriptions.route = "PO/NG" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
7690,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
2118,
23,
26,
1499,
6,
5059,
715,
1499,
6,
5692,
1499,
6,
701,
834,
15129,
1499,
6,
3783,
1499,
6,
5798,
1499... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
3388,
18206,
3,
15355,
3162,
7744,
7,
9191,
14798,
5,
8399,
51,
834,
23,
26,
3274,
7744,
7,
5,
8399,
51,
834,
23,
26,
549... |
What are the points 1 for the team with position less than 13 and goal difference of +16? | CREATE TABLE table_48006 (
"Position" real,
"Team" text,
"Played" real,
"Drawn" real,
"Lost" real,
"Goals For" real,
"Goals Against" real,
"Goal Difference" text,
"Points 1" text
) | SELECT "Points 1" FROM table_48006 WHERE "Position" < '13' AND "Goal Difference" = '+16' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
20579,
5176,
41,
96,
345,
32,
7,
4749,
121,
490,
6,
96,
18699,
121,
1499,
6,
96,
15800,
15,
26,
121,
490,
6,
96,
308,
10936,
29,
121,
490,
6,
96,
434,
3481,
121,
490,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
22512,
7,
209,
121,
21680,
953,
834,
20579,
5176,
549,
17444,
427,
96,
345,
32,
7,
4749,
121,
3,
2,
3,
31,
2368,
31,
3430,
96,
6221,
138,
27187,
121,
3274,
3,
31,
1220,
2938,
31,
1,
-100,
-100,
-100,
-100,
... |
people working on query expansion | CREATE TABLE paperkeyphrase (
paperid int,
keyphraseid int
)
CREATE TABLE paperfield (
fieldid int,
paperid int
)
CREATE TABLE venue (
venueid int,
venuename varchar
)
CREATE TABLE journal (
journalid int,
journalname varchar
)
CREATE TABLE cite (
citingpaperid int,
citedpaperid int
)
CREATE TABLE field (
fieldid int
)
CREATE TABLE author (
authorid int,
authorname varchar
)
CREATE TABLE paperdataset (
paperid int,
datasetid int
)
CREATE TABLE keyphrase (
keyphraseid int,
keyphrasename varchar
)
CREATE TABLE paper (
paperid int,
title varchar,
venueid int,
year int,
numciting int,
numcitedby int,
journalid int
)
CREATE TABLE writes (
paperid int,
authorid int
)
CREATE TABLE dataset (
datasetid int,
datasetname varchar
) | SELECT DISTINCT author.authorname FROM author, keyphrase, paperkeyphrase, writes WHERE keyphrase.keyphrasename LIKE 'query expansion' AND paperkeyphrase.keyphraseid = keyphrase.keyphraseid AND writes.authorid = author.authorid AND writes.paperid = paperkeyphrase.paperid | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
1040,
4397,
27111,
41,
1040,
23,
26,
16,
17,
6,
843,
27111,
23,
26,
16,
17,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
1040,
1846,
41,
1057,
23,
26,
16,
17,
6,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
3,
15438,
25424,
6227,
2291,
5,
17415,
4350,
21680,
2291,
6,
843,
27111,
6,
1040,
4397,
27111,
6,
11858,
549,
17444,
427,
843,
27111,
5,
4397,
27111,
4350,
8729,
9914,
3,
31,
835,
651,
5919,
31,
3430,
1040,
4397,
27... |
What is Tie no, when Home Team is 'Gillingham'? | CREATE TABLE table_name_96 (
tie_no VARCHAR,
home_team VARCHAR
) | SELECT tie_no FROM table_name_96 WHERE home_team = "gillingham" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4314,
41,
6177,
834,
29,
32,
584,
4280,
28027,
6,
234,
834,
11650,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
2262,
15,
150,
6,
116,
1210,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
6177,
834,
29,
32,
21680,
953,
834,
4350,
834,
4314,
549,
17444,
427,
234,
834,
11650,
3274,
96,
122,
1092,
14799,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
Bar chart x axis publication date y axis how many publication date, rank in desc by the X-axis. | CREATE TABLE book (
Book_ID int,
Title text,
Issues real,
Writer text
)
CREATE TABLE publication (
Publication_ID int,
Book_ID int,
Publisher text,
Publication_Date text,
Price real
) | SELECT Publication_Date, COUNT(Publication_Date) FROM publication GROUP BY Publication_Date ORDER BY Publication_Date DESC | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
484,
41,
3086,
834,
4309,
16,
17,
6,
11029,
1499,
6,
13235,
7,
490,
6,
8733,
52,
1499,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
5707,
41,
2575,
257,
834,
4309,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2575,
257,
834,
308,
342,
6,
2847,
17161,
599,
30931,
257,
834,
308,
342,
61,
21680,
5707,
350,
4630,
6880,
272,
476,
2575,
257,
834,
308,
342,
4674,
11300,
272,
476,
2575,
257,
834,
308,
342,
309,
25067,
1,
-100,
... |
I want the sum of Laps for wolfgang von trips, and a grid larger than 5 | CREATE TABLE table_name_5 (laps INTEGER, driver VARCHAR, grid VARCHAR) | SELECT SUM(laps) FROM table_name_5 WHERE driver = "wolfgang von trips" AND grid > 5 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
755,
41,
8478,
7,
3,
21342,
17966,
6,
2535,
584,
4280,
28027,
6,
8634,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
27,
241,
8,
4505,
13,
325,
102,
7,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
180,
6122,
599,
8478,
7,
61,
21680,
953,
834,
4350,
834,
755,
549,
17444,
427,
2535,
3274,
96,
19747,
3810,
193,
6846,
121,
3430,
8634,
2490,
305,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What are the positions with both players having more than 20 points and less than 10 points. | CREATE TABLE player (POSITION VARCHAR, Points INTEGER) | SELECT POSITION FROM player WHERE Points > 20 INTERSECT SELECT POSITION FROM player WHERE Points < 10 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
1959,
41,
16034,
196,
9562,
584,
4280,
28027,
6,
4564,
7,
3,
21342,
17966,
61,
3,
32102,
32103,
32101,
32103,
363,
33,
8,
4655,
28,
321,
1508,
578,
72,
145,
460,
979,
11,
705,
145,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
3,
16034,
196,
9562,
21680,
1959,
549,
17444,
427,
4564,
7,
2490,
460,
3,
21342,
5249,
14196,
3,
23143,
14196,
3,
16034,
196,
9562,
21680,
1959,
549,
17444,
427,
4564,
7,
3,
2,
335,
1,
-100,
-100,
-100,
-100,
-100,
... |
When was Cardinal-Deacon of S. Giorgio in Velabro elevated? | CREATE TABLE table_65558 (
"Elector" text,
"Nationality" text,
"Cardinalatial order and title" text,
"Elevated" text,
"Elevator" text
) | SELECT "Elevated" FROM table_65558 WHERE "Cardinalatial order and title" = 'cardinal-deacon of s. giorgio in velabro' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4122,
755,
3449,
41,
96,
21543,
127,
121,
1499,
6,
96,
24732,
485,
121,
1499,
6,
96,
6936,
26,
10270,
9,
10646,
455,
11,
2233,
121,
1499,
6,
96,
427,
10912,
920,
121,
149... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
427,
10912,
920,
121,
21680,
953,
834,
4122,
755,
3449,
549,
17444,
427,
96,
6936,
26,
10270,
9,
10646,
455,
11,
2233,
121,
3274,
3,
31,
6043,
10270,
18,
221,
9,
1018,
13,
3,
7,
5,
3,
10253,
52,
10253,
16,
... |
What is Team, when Position is "LHP", and when Pick is "23"? | CREATE TABLE table_name_16 (team VARCHAR, position VARCHAR, pick VARCHAR) | SELECT team FROM table_name_16 WHERE position = "lhp" AND pick = 23 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2938,
41,
11650,
584,
4280,
28027,
6,
1102,
584,
4280,
28027,
6,
1432,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
2271,
6,
116,
14258,
19,
96,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
372,
21680,
953,
834,
4350,
834,
2938,
549,
17444,
427,
1102,
3274,
96,
40,
107,
102,
121,
3430,
1432,
3274,
1902,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
What league is Sun Source in? | CREATE TABLE table_name_6 (league_division VARCHAR, club VARCHAR) | SELECT league_division FROM table_name_6 WHERE club = "sun source" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
948,
41,
29512,
834,
26,
23,
6610,
584,
4280,
28027,
6,
1886,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
5533,
19,
3068,
9149,
16,
58,
1,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
5533,
834,
26,
23,
6610,
21680,
953,
834,
4350,
834,
948,
549,
17444,
427,
1886,
3274,
96,
7,
202,
1391,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What year is the death for a birth of 1873 and higher than rank 28? | CREATE TABLE table_13032 (
"Rank" real,
"Name" text,
"Country" text,
"Birth" real,
"Death" text
) | SELECT "Death" FROM table_13032 WHERE "Birth" = '1873' AND "Rank" > '28' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
21448,
2668,
41,
96,
22557,
121,
490,
6,
96,
23954,
121,
1499,
6,
96,
10628,
651,
121,
1499,
6,
96,
279,
23,
52,
189,
121,
490,
6,
96,
2962,
9,
189,
121,
1499,
3,
61,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
2962,
9,
189,
121,
21680,
953,
834,
21448,
2668,
549,
17444,
427,
96,
279,
23,
52,
189,
121,
3274,
3,
31,
2606,
4552,
31,
3430,
96,
22557,
121,
2490,
3,
31,
2577,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
name a year whose second venue was the same as 2011 . | CREATE TABLE table_204_983 (
id number,
"year" number,
"1st venue" text,
"2nd venue" text,
"3rd venue" text,
"4th venue" text,
"5th venue" text,
"6th venue" text
) | SELECT "year" FROM table_204_983 WHERE "year" <> 2011 AND "2nd venue" = (SELECT "2nd venue" FROM table_204_983 WHERE "year" = 2011) | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
26363,
834,
3916,
519,
41,
3,
23,
26,
381,
6,
96,
1201,
121,
381,
6,
96,
536,
7,
17,
5669,
121,
1499,
6,
96,
357,
727,
5669,
121,
1499,
6,
96,
519,
52,
26,
5669,
121,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
1201,
121,
21680,
953,
834,
26363,
834,
3916,
519,
549,
17444,
427,
96,
1201,
121,
3,
2,
3155,
2722,
3430,
96,
357,
727,
5669,
121,
3274,
41,
23143,
14196,
96,
357,
727,
5669,
121,
21680,
953,
834,
26363,
834,
... |
not pregnant and willing to take appropriate contraceptive measures if capable of becoming pregnant; | CREATE TABLE table_train_206 (
"id" int,
"gender" string,
"pregnancy_or_lactation" bool,
"systolic_blood_pressure_sbp" int,
"hematocrit_hct" float,
"diabetic" string,
"contraception" bool,
"diastolic_blood_pressure_dbp" int,
"serum_creatinine" float,
"NOUSE" float
) | SELECT * FROM table_train_206 WHERE pregnancy_or_lactation = 0 AND contraception = 1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
9719,
834,
24643,
41,
96,
23,
26,
121,
16,
17,
6,
96,
122,
3868,
121,
6108,
6,
96,
2026,
11260,
11298,
834,
127,
834,
9700,
6821,
121,
3,
12840,
40,
6,
96,
7,
63,
7,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
1429,
21680,
953,
834,
9719,
834,
24643,
549,
17444,
427,
8999,
834,
127,
834,
9700,
6821,
3274,
3,
632,
3430,
5314,
7239,
3274,
209,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What is the score of the hard court Ramat Hasharon tournament? | CREATE TABLE table_79660 (
"Date" text,
"Tournament" text,
"Surface" text,
"Opponent in final" text,
"Score" text,
"Prize Money" text
) | SELECT "Score" FROM table_79660 WHERE "Surface" = 'hard' AND "Tournament" = 'ramat hasharon' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4440,
27720,
41,
96,
308,
342,
121,
1499,
6,
96,
382,
1211,
20205,
17,
121,
1499,
6,
96,
134,
450,
4861,
121,
1499,
6,
96,
667,
102,
9977,
16,
804,
121,
1499,
6,
96,
13... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
134,
9022,
121,
21680,
953,
834,
4440,
27720,
549,
17444,
427,
96,
134,
450,
4861,
121,
3274,
3,
31,
5651,
31,
3430,
96,
382,
1211,
20205,
17,
121,
3274,
3,
31,
10819,
17,
65,
3272,
106,
31,
1,
-100,
-100,
-... |
what is the score when the venue is athens olympic stadium on 30 april 2011? | CREATE TABLE table_50532 (
"Year" text,
"Winner" text,
"Runner-up" text,
"Score" text,
"Venue" text
) | SELECT "Score" FROM table_50532 WHERE "Venue" = 'athens olympic stadium' AND "Year" = '30 april 2011' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1752,
4867,
357,
41,
96,
476,
2741,
121,
1499,
6,
96,
18455,
687,
121,
1499,
6,
96,
23572,
18,
413,
121,
1499,
6,
96,
134,
9022,
121,
1499,
6,
96,
553,
35,
76,
15,
121,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
134,
9022,
121,
21680,
953,
834,
1752,
4867,
357,
549,
17444,
427,
96,
553,
35,
76,
15,
121,
3274,
3,
31,
9,
189,
35,
7,
3,
32,
120,
51,
6174,
14939,
31,
3430,
96,
476,
2741,
121,
3274,
3,
31,
1458,
3,
9... |
What is the location for the game on October 20 with it's corresponding attendance? | CREATE TABLE table_28768469_2 (
location_attendance VARCHAR,
date VARCHAR
) | SELECT location_attendance FROM table_28768469_2 WHERE date = "October 20" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2577,
3959,
4608,
3951,
834,
357,
41,
1128,
834,
15116,
663,
584,
4280,
28027,
6,
833,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
1128,
21,
8,
467,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
1128,
834,
15116,
663,
21680,
953,
834,
2577,
3959,
4608,
3951,
834,
357,
549,
17444,
427,
833,
3274,
96,
28680,
460,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What's the Street address with a Name of New York Life Insurance building? | CREATE TABLE table_name_74 (
street_address VARCHAR,
name VARCHAR
) | SELECT street_address FROM table_name_74 WHERE name = "new york life insurance building" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4581,
41,
2815,
834,
9,
26,
12039,
584,
4280,
28027,
6,
564,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
31,
7,
8,
1887,
1115,
28,
3,
9,
5570,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2815,
834,
9,
26,
12039,
21680,
953,
834,
4350,
834,
4581,
549,
17444,
427,
564,
3274,
96,
5534,
25453,
280,
958,
740,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What was the average attendance at a game when the record was 6-13? | CREATE TABLE table_name_71 (attendance INTEGER, record VARCHAR) | SELECT AVG(attendance) FROM table_name_71 WHERE record = "6-13" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4450,
41,
15116,
663,
3,
21342,
17966,
6,
1368,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
1348,
11364,
44,
3,
9,
467,
116,
8,
1368,
47,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
71,
17217,
599,
15116,
663,
61,
21680,
953,
834,
4350,
834,
4450,
549,
17444,
427,
1368,
3274,
96,
948,
13056,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
How many % same-sex marriages are there for the year 2008? | CREATE TABLE table_19614212_1 (_percentage_same_sex_marriages VARCHAR, year VARCHAR) | SELECT COUNT(_percentage_same_sex_marriages) FROM table_19614212_1 WHERE year = "2008" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
26937,
24978,
2122,
834,
536,
41,
834,
883,
3728,
545,
834,
7,
265,
15,
834,
7,
994,
834,
51,
10269,
2568,
584,
4280,
28027,
6,
215,
584,
4280,
28027,
61,
3,
32102,
32103,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0... | [
3,
23143,
14196,
2847,
17161,
599,
834,
883,
3728,
545,
834,
7,
265,
15,
834,
7,
994,
834,
51,
10269,
2568,
61,
21680,
953,
834,
26937,
24978,
2122,
834,
536,
549,
17444,
427,
215,
3274,
96,
16128,
121,
1,
-100,
-100,
-100,
-100,
... |
when ghostbusters was released for the nes in 1988 what systems had it previously been released for ? | CREATE TABLE table_203_489 (
id number,
"year" number,
"title" text,
"system" text,
"developer" text,
"publisher" text
) | SELECT "system" FROM table_203_489 WHERE id = (SELECT id FROM table_203_489 WHERE "title" = 'ghostbusters' AND "year" = 1988) - 1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
23330,
834,
591,
3914,
41,
3,
23,
26,
381,
6,
96,
1201,
121,
381,
6,
96,
21869,
121,
1499,
6,
96,
3734,
121,
1499,
6,
96,
29916,
49,
121,
1499,
6,
96,
29337,
49,
121,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
3734,
121,
21680,
953,
834,
23330,
834,
591,
3914,
549,
17444,
427,
3,
23,
26,
3274,
41,
23143,
14196,
3,
23,
26,
21680,
953,
834,
23330,
834,
591,
3914,
549,
17444,
427,
96,
21869,
121,
3274,
3,
31,
122,
1267... |
What is the capacity for the stadium of kadrioru stadium and a current manager of sergei ratnikov? | CREATE TABLE table_name_14 (
capacity INTEGER,
stadium VARCHAR,
current_manager VARCHAR
) | SELECT AVG(capacity) FROM table_name_14 WHERE stadium = "kadrioru stadium" AND current_manager = "sergei ratnikov" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2534,
41,
2614,
3,
21342,
17966,
6,
14939,
584,
4280,
28027,
6,
750,
834,
24185,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
2614,
21,
8,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
71,
17217,
599,
4010,
9,
6726,
61,
21680,
953,
834,
4350,
834,
2534,
549,
17444,
427,
14939,
3274,
96,
1258,
26,
52,
23,
127,
76,
14939,
121,
3430,
750,
834,
24185,
3274,
96,
7,
49,
397,
23,
3,
1795,
29,
23,
978... |
Which Game site has a Week larger than 14? | CREATE TABLE table_name_44 (
game_site VARCHAR,
week INTEGER
) | SELECT game_site FROM table_name_44 WHERE week > 14 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3628,
41,
467,
834,
3585,
584,
4280,
28027,
6,
471,
3,
21342,
17966,
3,
61,
3,
32102,
32103,
32101,
32103,
4073,
4435,
353,
65,
3,
9,
6551,
2186,
145,
968,
58,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
467,
834,
3585,
21680,
953,
834,
4350,
834,
3628,
549,
17444,
427,
471,
2490,
968,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Which County has an Opposition of offaly? | CREATE TABLE table_name_64 (county VARCHAR, opposition VARCHAR) | SELECT county FROM table_name_64 WHERE opposition = "offaly" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4389,
41,
13362,
63,
584,
4280,
28027,
6,
8263,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
4073,
1334,
65,
46,
4495,
4718,
13,
326,
9,
120,
58,
1,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
5435,
21680,
953,
834,
4350,
834,
4389,
549,
17444,
427,
8263,
3274,
96,
1647,
9,
120,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
Who is the home team who plays at Glenferrie Oval? | CREATE TABLE table_name_95 (
home_team VARCHAR,
venue VARCHAR
) | SELECT home_team FROM table_name_95 WHERE venue = "glenferrie oval" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3301,
41,
234,
834,
11650,
584,
4280,
28027,
6,
5669,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
2645,
19,
8,
234,
372,
113,
4805,
44,
8300,
1010,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
234,
834,
11650,
21680,
953,
834,
4350,
834,
3301,
549,
17444,
427,
5669,
3274,
96,
3537,
29,
1010,
1753,
17986,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
give me the number of patients whose marital status is divorced and lab test name is chloride? | CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE 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
)
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(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.marital_status = "DIVORCED" AND lab.label = "Chloride" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
4293,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
447,
26,
1298,
834,
4978,
1499,
6,
710,
834,
21869,
1499,
6,
307,
834,
21869,
1499,
3,
61,
3,
32102,
32103... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
3388,
18206,
3,
15355,
3162,
7690,
9191,
14798,
5,
8399,
51,
834,
23,
26,
3274,
7690,
5,
8399,
51,
834,
23,
26,
549,
17444,... |
calculate the number of unmarried patients with lab test item id 51250. | 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 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 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
) | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.marital_status = "SINGLE" AND lab.itemid = "51250" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
7744,
7,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
23,
1071,
21545,
834,
23,
26,
1499,
6,
2672,
834,
6137,
1499,
6,
2672,
1499,
6,
5403,
651,
834,
26,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
3388,
18206,
3,
15355,
3162,
7690,
9191,
14798,
5,
8399,
51,
834,
23,
26,
3274,
7690,
5,
8399,
51,
834,
23,
26,
549,
17444,... |
What Venue is in Colorado? | CREATE TABLE table_name_19 (venue VARCHAR, state VARCHAR) | SELECT venue FROM table_name_19 WHERE state = "colorado" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2294,
41,
15098,
584,
4280,
28027,
6,
538,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
29940,
19,
16,
6144,
58,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
5669,
21680,
953,
834,
4350,
834,
2294,
549,
17444,
427,
538,
3274,
96,
8135,
19042,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the result for first elected in 1944 | CREATE TABLE table_18465 (
"District" text,
"Incumbent" text,
"Party" text,
"First elected" real,
"Result" text,
"Candidates" text
) | SELECT "Result" FROM table_18465 WHERE "First elected" = '1944' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
25987,
4122,
41,
96,
308,
23,
20066,
121,
1499,
6,
96,
1570,
75,
5937,
295,
121,
1499,
6,
96,
13725,
63,
121,
1499,
6,
96,
25171,
8160,
121,
490,
6,
96,
20119,
121,
1499,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
20119,
121,
21680,
953,
834,
25987,
4122,
549,
17444,
427,
96,
25171,
8160,
121,
3274,
3,
31,
2294,
3628,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
What was the home team's score when Geelong was the away team? | CREATE TABLE table_name_1 (home_team VARCHAR, away_team VARCHAR) | SELECT home_team AS score FROM table_name_1 WHERE away_team = "geelong" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
536,
41,
5515,
834,
11650,
584,
4280,
28027,
6,
550,
834,
11650,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
234,
372,
31,
7,
2604,
116,
961... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
234,
834,
11650,
6157,
2604,
21680,
953,
834,
4350,
834,
536,
549,
17444,
427,
550,
834,
11650,
3274,
96,
397,
15,
2961,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
What is the fewest number of top-25s for events with more than 13 cuts made? | CREATE TABLE table_name_31 (
top_25 INTEGER,
cuts_made INTEGER
) | SELECT MIN(top_25) FROM table_name_31 WHERE cuts_made > 13 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3341,
41,
420,
834,
1828,
3,
21342,
17966,
6,
8620,
834,
4725,
3,
21342,
17966,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
360,
222,
381,
13,
420,
14855,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
3,
17684,
599,
2916,
834,
1828,
61,
21680,
953,
834,
4350,
834,
3341,
549,
17444,
427,
8620,
834,
4725,
2490,
1179,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
what is minimum age of patients whose marital status is single and primary disease is acidosis? | 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 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 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 MIN(demographic.age) FROM demographic WHERE demographic.marital_status = "SINGLE" AND demographic.diagnosis = "ACIDOSIS" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
7690,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
2118,
23,
26,
1499,
6,
5059,
715,
1499,
6,
5692,
1499,
6,
701,
834,
15129,
1499,
6,
3783,
1499,
6,
5798,
1499... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
3,
17684,
599,
1778,
16587,
5,
545,
61,
21680,
14798,
549,
17444,
427,
14798,
5,
1635,
9538,
834,
8547,
302,
3274,
96,
134,
2365,
3765,
121,
3430,
14798,
5,
25930,
4844,
159,
3274,
96,
188,
3597,
9857,
14408,
121,
1... |
what was the top place the team achieved ? | CREATE TABLE table_204_524 (
id number,
"season" text,
"tier" number,
"division" text,
"place" text
) | SELECT "place" FROM table_204_524 ORDER BY "place" LIMIT 1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
26363,
834,
755,
2266,
41,
3,
23,
26,
381,
6,
96,
9476,
121,
1499,
6,
96,
3276,
121,
381,
6,
96,
26,
23,
6610,
121,
1499,
6,
96,
4687,
121,
1499,
3,
61,
3,
32102,
321... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
96,
4687,
121,
21680,
953,
834,
26363,
834,
755,
2266,
4674,
11300,
272,
476,
96,
4687,
121,
8729,
12604,
209,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
Which conventional plan has a POS of 13%? | CREATE TABLE table_name_55 (
conventional_plans VARCHAR,
pos_plans VARCHAR
) | SELECT conventional_plans FROM table_name_55 WHERE pos_plans = "13%" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3769,
41,
7450,
834,
3767,
7,
584,
4280,
28027,
6,
3,
2748,
834,
3767,
7,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
4073,
7450,
515,
65,
3,
9,
3,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
7450,
834,
3767,
7,
21680,
953,
834,
4350,
834,
3769,
549,
17444,
427,
3,
2748,
834,
3767,
7,
3274,
96,
536,
5170,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What is the name of the plan that has a downstream rate of 4,096 kbit? | CREATE TABLE table_name_21 (internet_plan VARCHAR, downstream VARCHAR) | SELECT internet_plan FROM table_name_21 WHERE downstream = "4,096 kbit" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2658,
41,
3870,
1582,
834,
3767,
584,
4280,
28027,
6,
26804,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
564,
13,
8,
515,
24,
65,
3,
9,
26... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
1396,
834,
3767,
21680,
953,
834,
4350,
834,
2658,
549,
17444,
427,
26804,
3274,
96,
8525,
632,
4314,
3,
157,
2360,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
What is the FCSL Team when the MLB Team is Toronto Blue Jays, in the 4th round? | CREATE TABLE table_name_22 (
fcsl_team VARCHAR,
mlb_team VARCHAR,
round VARCHAR
) | SELECT fcsl_team FROM table_name_22 WHERE mlb_team = "toronto blue jays" AND round = "4th" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2884,
41,
3,
89,
75,
7,
40,
834,
11650,
584,
4280,
28027,
6,
3,
51,
40,
115,
834,
11650,
584,
4280,
28027,
6,
1751,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
3,
89,
75,
7,
40,
834,
11650,
21680,
953,
834,
4350,
834,
2884,
549,
17444,
427,
3,
51,
40,
115,
834,
11650,
3274,
96,
235,
4438,
32,
1692,
2662,
63,
7,
121,
3430,
1751,
3274,
96,
591,
189,
121,
1,
-100,
-100,
... |
Who won the game on may 21? | CREATE TABLE table_13710464_1 (winning_team VARCHAR, date VARCHAR) | SELECT winning_team FROM table_13710464_1 WHERE date = "May 21" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
24636,
15442,
4389,
834,
536,
41,
8163,
834,
11650,
584,
4280,
28027,
6,
833,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
2645,
751,
8,
467,
30,
164,
1401,
58,
1,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
3447,
834,
11650,
21680,
953,
834,
24636,
15442,
4389,
834,
536,
549,
17444,
427,
833,
3274,
96,
15881,
1401,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
What is the sum of Sylvain Guintoli's laps? | CREATE TABLE table_name_8 (
laps INTEGER,
rider VARCHAR
) | SELECT SUM(laps) FROM table_name_8 WHERE rider = "sylvain guintoli" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
927,
41,
14941,
7,
3,
21342,
17966,
6,
2564,
52,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
4505,
13,
5224,
40,
900,
77,
2846,
77,
17,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
180,
6122,
599,
8478,
7,
61,
21680,
953,
834,
4350,
834,
927,
549,
17444,
427,
2564,
52,
3274,
96,
7,
63,
40,
900,
77,
3,
17996,
17,
4172,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.