NATURAL_LANG stringlengths 0 446 | SCHEMA stringlengths 27 2.21k | SQL stringlengths 18 453 | input_ids list | attention_mask list | labels list |
|---|---|---|---|---|---|
How many times was the incumbent john dawson redistricted from the 15th district? | CREATE TABLE table_2668393_18 (
candidates VARCHAR,
incumbent VARCHAR
) | SELECT COUNT(candidates) FROM table_2668393_18 WHERE incumbent = "John Dawson Redistricted from the 15th district" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2688,
3651,
3288,
519,
834,
2606,
41,
4341,
584,
4280,
28027,
6,
28406,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
571,
186,
648,
47,
8,
28406,
3,
27341,
836,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2847,
17161,
599,
1608,
12416,
6203,
61,
21680,
953,
834,
2688,
3651,
3288,
519,
834,
2606,
549,
17444,
427,
28406,
3274,
96,
18300,
31676,
1624,
159,
3929,
1054,
45,
8,
627,
189,
3939,
121,
1,
-100,
-100,
-100,
-100,... |
What was the course type on 22 May? | CREATE TABLE table_name_13 (type VARCHAR, date VARCHAR) | SELECT type FROM table_name_13 WHERE date = "22 may" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2368,
41,
6137,
584,
4280,
28027,
6,
833,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
503,
686,
30,
1630,
932,
58,
1,
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,
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... | [
3,
23143,
14196,
686,
21680,
953,
834,
4350,
834,
2368,
549,
17444,
427,
833,
3274,
96,
2884,
164,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What language has viaggi as the content? | CREATE TABLE table_name_65 (
language VARCHAR,
content VARCHAR
) | SELECT language FROM table_name_65 WHERE content = "viaggi" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4122,
41,
1612,
584,
4280,
28027,
6,
738,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
1612,
65,
1009,
15406,
38,
8,
738,
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,
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,
1612,
21680,
953,
834,
4350,
834,
4122,
549,
17444,
427,
738,
3274,
96,
5907,
15406,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
In the tkkm o manawatu coed school in kelvin grove, what is the Authority listed/ | CREATE TABLE table_71426 (
"Name" text,
"Years" text,
"Gender" text,
"Area" text,
"Authority" text,
"Decile" real,
"Roll" text
) | SELECT "Authority" FROM table_71426 WHERE "Gender" = 'coed' AND "Area" = 'kelvin grove' AND "Name" = 'tkkm o manawatu' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
940,
2534,
2688,
41,
96,
23954,
121,
1499,
6,
96,
476,
2741,
7,
121,
1499,
6,
96,
517,
3868,
121,
1499,
6,
96,
188,
864,
121,
1499,
6,
96,
23602,
127,
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,
23602,
127,
485,
121,
21680,
953,
834,
940,
2534,
2688,
549,
17444,
427,
96,
517,
3868,
121,
3274,
3,
31,
509,
15,
26,
31,
3430,
96,
188,
864,
121,
3274,
3,
31,
5768,
2494,
3,
20254,
31,
3430,
96,
23954,
121... |
how many patients are divorced and followed the procedure small-to-small intestinal anastomosis? | 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 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 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 procedures ON demographic.hadm_id = procedures.hadm_id WHERE demographic.marital_status = "DIVORCED" AND procedures.long_title = "Small-to-small intestinal anastomosis" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
14798,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
564,
1499,
6,
2774,
1947,
834,
8547,
302,
1499,
6,
1246,
1499,
6,
103,
115,
1499,
6,
7285,
1499,
6,
1612,
14... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,... |
In the Class T, what is the total of the 1958 UTA? | CREATE TABLE table_69542 (
"Class" text,
"Type" text,
"Fleet numbers" text,
"Quantity made" real,
"Manufacturer" text,
"Date made" text,
"1958 CI\u00c9" real,
"1958 UTA" real,
"Date withdrawn" text
) | SELECT COUNT("1958 UTA") FROM table_69542 WHERE "Class" = 't' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3951,
5062,
357,
41,
96,
21486,
121,
1499,
6,
96,
25160,
121,
1499,
6,
96,
371,
109,
15,
17,
2302,
121,
1499,
6,
96,
5991,
288,
485,
263,
121,
490,
6,
96,
7296,
76,
871... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
121,
2294,
3449,
412,
3221,
8512,
21680,
953,
834,
3951,
5062,
357,
549,
17444,
427,
96,
21486,
121,
3274,
3,
31,
17,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
How many characters is by Babs Rubenstein? | CREATE TABLE table_10402018_1 (london VARCHAR, us_tour VARCHAR) | SELECT COUNT(london) FROM table_10402018_1 WHERE us_tour = "Babs Rubenstein" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1714,
2445,
9457,
834,
536,
41,
40,
106,
2029,
584,
4280,
28027,
6,
178,
834,
17,
1211,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
571,
186,
2850,
19,
57,
11563,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2847,
17161,
599,
40,
106,
2029,
61,
21680,
953,
834,
1714,
2445,
9457,
834,
536,
549,
17444,
427,
178,
834,
17,
1211,
3274,
96,
279,
14623,
15612,
20207,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the title, credit value, and department name for courses with more than one prerequisite? | CREATE TABLE student (
id text,
name text,
dept_name text,
tot_cred number
)
CREATE TABLE teaches (
id text,
course_id text,
sec_id text,
semester text,
year number
)
CREATE TABLE instructor (
id text,
name text,
dept_name text,
salary number
)
CREATE TABLE classroom (
building text,
room_number text,
capacity number
)
CREATE TABLE time_slot (
time_slot_id text,
day text,
start_hr number,
start_min number,
end_hr number,
end_min number
)
CREATE TABLE prereq (
course_id text,
prereq_id text
)
CREATE TABLE department (
dept_name text,
building text,
budget number
)
CREATE TABLE takes (
id text,
course_id text,
sec_id text,
semester text,
year number,
grade text
)
CREATE TABLE section (
course_id text,
sec_id text,
semester text,
year number,
building text,
room_number text,
time_slot_id text
)
CREATE TABLE advisor (
s_id text,
i_id text
)
CREATE TABLE course (
course_id text,
title text,
dept_name text,
credits number
) | SELECT T1.title, T1.credits, T1.dept_name FROM course AS T1 JOIN prereq AS T2 ON T1.course_id = T2.course_id GROUP BY T2.course_id HAVING COUNT(*) > 1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
1236,
41,
3,
23,
26,
1499,
6,
564,
1499,
6,
20,
102,
17,
834,
4350,
1499,
6,
12,
17,
834,
17216,
381,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
3,
11749,
41,
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,
332,
5411,
21869,
6,
332,
5411,
15547,
7,
6,
332,
5411,
26,
6707,
834,
4350,
21680,
503,
6157,
332,
536,
3,
15355,
3162,
554,
60,
1824,
6157,
332,
357,
9191,
332,
5411,
19221,
834,
23,
26,
3274,
332,
4416,
19221,
... |
What datasets have jitendra malik used | CREATE TABLE writes (
paperid int,
authorid int
)
CREATE TABLE journal (
journalid int,
journalname varchar
)
CREATE TABLE paperfield (
fieldid int,
paperid int
)
CREATE TABLE author (
authorid int,
authorname varchar
)
CREATE TABLE cite (
citingpaperid int,
citedpaperid int
)
CREATE TABLE paperkeyphrase (
paperid int,
keyphraseid int
)
CREATE TABLE venue (
venueid int,
venuename varchar
)
CREATE TABLE keyphrase (
keyphraseid int,
keyphrasename varchar
)
CREATE TABLE field (
fieldid int
)
CREATE TABLE paperdataset (
paperid int,
datasetid int
)
CREATE TABLE dataset (
datasetid int,
datasetname varchar
)
CREATE TABLE paper (
paperid int,
title varchar,
venueid int,
year int,
numciting int,
numcitedby int,
journalid int
) | SELECT DISTINCT paperdataset.datasetid FROM author, paper, paperdataset, writes WHERE author.authorname = 'jitendra malik' AND paper.paperid = paperdataset.paperid AND writes.authorid = author.authorid AND writes.paperid = paper.paperid | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
11858,
41,
1040,
23,
26,
16,
17,
6,
2291,
23,
26,
16,
17,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
6378,
41,
6378,
23,
26,
16,
17,
6,
6378,
4350,
3,
4331,
4059... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1040,
6757,
2244,
5,
6757,
2244,
23,
26,
21680,
2291,
6,
1040,
6,
1040,
6757,
2244,
6,
11858,
549,
17444,
427,
2291,
5,
17415,
4350,
3274,
3,
31,
13272,
12524,
954,
8654,
31,
3430,
1040,
5,
... |
In what Round does Duke have a Pick larger than 9? | CREATE TABLE table_47234 (
"Round" real,
"Pick" real,
"Player" text,
"Position" text,
"School" text
) | SELECT COUNT("Round") FROM table_47234 WHERE "Pick" > '9' AND "School" = 'duke' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4177,
357,
3710,
41,
96,
448,
32,
1106,
121,
490,
6,
96,
345,
3142,
121,
490,
6,
96,
15800,
49,
121,
1499,
6,
96,
345,
32,
7,
4749,
121,
1499,
6,
96,
29364,
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,
2847,
17161,
599,
121,
448,
32,
1106,
8512,
21680,
953,
834,
4177,
357,
3710,
549,
17444,
427,
96,
345,
3142,
121,
2490,
3,
31,
1298,
31,
3430,
96,
29364,
121,
3274,
3,
31,
1259,
1050,
31,
1,
-100,
-100,
-100,
-10... |
Whose Name has a Date of reclassification of 2003-04-01 (merge into shizuoka )? | CREATE TABLE table_name_52 (
name VARCHAR,
date_of_reclassification VARCHAR
) | SELECT name FROM table_name_52 WHERE date_of_reclassification = "2003-04-01 (merge into shizuoka )" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
5373,
41,
564,
584,
4280,
28027,
6,
833,
834,
858,
834,
60,
4057,
2420,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
2645,
7,
15,
5570,
65,
3,
9,
76... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
564,
21680,
953,
834,
4350,
834,
5373,
549,
17444,
427,
833,
834,
858,
834,
60,
4057,
2420,
3274,
96,
23948,
18083,
14772,
41,
935,
397,
139,
3,
5605,
1000,
1825,
9,
3,
61,
121,
1,
-100,
-100,
-100,
-100,
-100,
-1... |
What is the sum of the earnings for rank 3? | CREATE TABLE table_42288 (
"Rank" real,
"Player" text,
"Country" text,
"Earnings( $ )" real,
"Wins" real
) | SELECT SUM("Earnings( $ )") FROM table_42288 WHERE "Rank" = '3' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4165,
357,
4060,
41,
96,
22557,
121,
490,
6,
96,
15800,
49,
121,
1499,
6,
96,
10628,
651,
121,
1499,
6,
96,
427,
291,
29,
53,
7,
599,
1514,
3,
61,
121,
490,
6,
96,
18... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
291,
29,
53,
7,
599,
1514,
3,
61,
8512,
21680,
953,
834,
4165,
357,
4060,
549,
17444,
427,
96,
22557,
121,
3274,
3,
31,
519,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
For those employees who do not work in departments with managers that have ids between 100 and 200, give me the comparison about salary over the job_id , rank by the Y-axis in ascending. | CREATE TABLE departments (
DEPARTMENT_ID decimal(4,0),
DEPARTMENT_NAME varchar(30),
MANAGER_ID decimal(6,0),
LOCATION_ID decimal(4,0)
)
CREATE TABLE regions (
REGION_ID decimal(5,0),
REGION_NAME varchar(25)
)
CREATE TABLE jobs (
JOB_ID varchar(10),
JOB_TITLE varchar(35),
MIN_SALARY decimal(6,0),
MAX_SALARY decimal(6,0)
)
CREATE TABLE countries (
COUNTRY_ID varchar(2),
COUNTRY_NAME varchar(40),
REGION_ID decimal(10,0)
)
CREATE TABLE job_history (
EMPLOYEE_ID decimal(6,0),
START_DATE date,
END_DATE date,
JOB_ID varchar(10),
DEPARTMENT_ID decimal(4,0)
)
CREATE TABLE employees (
EMPLOYEE_ID decimal(6,0),
FIRST_NAME varchar(20),
LAST_NAME varchar(25),
EMAIL varchar(25),
PHONE_NUMBER varchar(20),
HIRE_DATE date,
JOB_ID varchar(10),
SALARY decimal(8,2),
COMMISSION_PCT decimal(2,2),
MANAGER_ID decimal(6,0),
DEPARTMENT_ID decimal(4,0)
)
CREATE TABLE locations (
LOCATION_ID decimal(4,0),
STREET_ADDRESS varchar(40),
POSTAL_CODE varchar(12),
CITY varchar(30),
STATE_PROVINCE varchar(25),
COUNTRY_ID varchar(2)
) | SELECT JOB_ID, SALARY FROM employees WHERE NOT DEPARTMENT_ID IN (SELECT DEPARTMENT_ID FROM departments WHERE MANAGER_ID BETWEEN 100 AND 200) ORDER BY SALARY | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
10521,
41,
3396,
19846,
11810,
834,
4309,
7908,
1982,
599,
8525,
632,
201,
3396,
19846,
11810,
834,
567,
17683,
3,
4331,
4059,
599,
1458,
201,
283,
15610,
17966,
834,
4309,
7908,
1982,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
446,
10539,
834,
4309,
6,
180,
4090,
24721,
21680,
1652,
549,
17444,
427,
4486,
3396,
19846,
11810,
834,
4309,
3388,
41,
23143,
14196,
3396,
19846,
11810,
834,
4309,
21680,
10521,
549,
17444,
427,
283,
15610,
17966,
834,
... |
What is the day and date of game 2? | CREATE TABLE table_name_20 (day VARCHAR, _date VARCHAR, game VARCHAR) | SELECT day, _date FROM table_name_20 WHERE game = "2" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
1755,
41,
1135,
584,
4280,
28027,
6,
3,
834,
5522,
584,
4280,
28027,
6,
467,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
239,
11,
833,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
239,
6,
3,
834,
5522,
21680,
953,
834,
4350,
834,
1755,
549,
17444,
427,
467,
3274,
96,
357,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the position of the player with a pick less than 3 from team san diego? | CREATE TABLE table_66564 (
"Pick" real,
"Team" text,
"Player" text,
"Position" text,
"College" text
) | SELECT "Position" FROM table_66564 WHERE "Pick" < '3' AND "Team" = 'san diego' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3539,
4834,
591,
41,
96,
345,
3142,
121,
490,
6,
96,
18699,
121,
1499,
6,
96,
15800,
49,
121,
1499,
6,
96,
345,
32,
7,
4749,
121,
1499,
6,
96,
9939,
7883,
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,
345,
32,
7,
4749,
121,
21680,
953,
834,
3539,
4834,
591,
549,
17444,
427,
96,
345,
3142,
121,
3,
2,
3,
31,
519,
31,
3430,
96,
18699,
121,
3274,
3,
31,
7,
152,
67,
839,
31,
1,
-100,
-100,
-100,
-100,
-100,
... |
What is the Days, hours, minutes for 21 26 October? | CREATE TABLE table_name_81 (
days VARCHAR,
_hours VARCHAR,
_minutes VARCHAR,
dates VARCHAR
) | SELECT days, _hours, _minutes FROM table_name_81 WHERE dates = "21 – 26 october" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4959,
41,
477,
584,
4280,
28027,
6,
3,
834,
5842,
7,
584,
4280,
28027,
6,
3,
834,
6890,
7,
584,
4280,
28027,
6,
5128,
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,
0,
0,
0,
0... | [
3,
23143,
14196,
477,
6,
3,
834,
5842,
7,
6,
3,
834,
6890,
7,
21680,
953,
834,
4350,
834,
4959,
549,
17444,
427,
5128,
3274,
96,
2658,
3,
104,
2208,
3,
32,
75,
235,
1152,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
How many brandings are there where the Power kW (ERP) is 1kW (29.94kW ERP)? | CREATE TABLE table_73876 (
"Branding" text,
"Callsign" text,
"Ch. #" text,
"Station Type" text,
"Power kW (ERP)" text,
"Location (Transmitter Site)" text
) | SELECT COUNT("Branding") FROM table_73876 WHERE "Power kW (ERP)" = '1kW (29.94kW ERP)' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
940,
3747,
3959,
41,
96,
18304,
727,
53,
121,
1499,
6,
96,
254,
1748,
6732,
121,
1499,
6,
96,
3541,
5,
1713,
121,
1499,
6,
96,
134,
6821,
6632,
121,
1499,
6,
96,
23553,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
121,
18304,
727,
53,
8512,
21680,
953,
834,
940,
3747,
3959,
549,
17444,
427,
96,
23553,
3,
21729,
41,
3316,
345,
61,
121,
3274,
3,
31,
536,
21729,
41,
3166,
5,
4240,
21729,
22568,
61,
31,
1,
-10... |
Show me a bar chart for how many total credits are offered by each department?, order from high to low by the Y-axis. | CREATE TABLE advisor (
s_ID varchar(5),
i_ID varchar(5)
)
CREATE TABLE department (
dept_name varchar(20),
building varchar(15),
budget numeric(12,2)
)
CREATE TABLE student (
ID varchar(5),
name varchar(20),
dept_name varchar(20),
tot_cred numeric(3,0)
)
CREATE TABLE takes (
ID varchar(5),
course_id varchar(8),
sec_id varchar(8),
semester varchar(6),
year numeric(4,0),
grade varchar(2)
)
CREATE TABLE classroom (
building varchar(15),
room_number varchar(7),
capacity numeric(4,0)
)
CREATE TABLE prereq (
course_id varchar(8),
prereq_id varchar(8)
)
CREATE TABLE section (
course_id varchar(8),
sec_id varchar(8),
semester varchar(6),
year numeric(4,0),
building varchar(15),
room_number varchar(7),
time_slot_id varchar(4)
)
CREATE TABLE course (
course_id varchar(8),
title varchar(50),
dept_name varchar(20),
credits numeric(2,0)
)
CREATE TABLE time_slot (
time_slot_id varchar(4),
day varchar(1),
start_hr numeric(2),
start_min numeric(2),
end_hr numeric(2),
end_min numeric(2)
)
CREATE TABLE teaches (
ID varchar(5),
course_id varchar(8),
sec_id varchar(8),
semester varchar(6),
year numeric(4,0)
)
CREATE TABLE instructor (
ID varchar(5),
name varchar(20),
dept_name varchar(20),
salary numeric(8,2)
) | SELECT dept_name, SUM(credits) FROM course GROUP BY dept_name ORDER BY SUM(credits) DESC | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
8815,
41,
3,
7,
834,
4309,
3,
4331,
4059,
15757,
6,
3,
23,
834,
4309,
3,
4331,
4059,
15757,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
3066,
41,
20,
102,
17,
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,
20,
102,
17,
834,
4350,
6,
180,
6122,
599,
15547,
7,
61,
21680,
503,
350,
4630,
6880,
272,
476,
20,
102,
17,
834,
4350,
4674,
11300,
272,
476,
180,
6122,
599,
15547,
7,
61,
309,
25067,
1,
-100,
-100,
-100,
-100,
... |
What is the average number of Byes when there were less than 0 losses and were against 1247? | CREATE TABLE table_75807 (
"Wins" real,
"Byes" real,
"Losses" real,
"Draws" real,
"Against" real
) | SELECT AVG("Byes") FROM table_75807 WHERE "Against" = '1247' AND "Draws" < '0' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3072,
2079,
940,
41,
96,
18455,
7,
121,
490,
6,
96,
279,
10070,
121,
490,
6,
96,
434,
13526,
7,
121,
490,
6,
96,
308,
10936,
7,
121,
490,
6,
96,
20749,
121,
490,
3,
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,
71,
17217,
599,
121,
279,
10070,
8512,
21680,
953,
834,
3072,
2079,
940,
549,
17444,
427,
96,
20749,
121,
3274,
3,
31,
2122,
4177,
31,
3430,
96,
308,
10936,
7,
121,
3,
2,
3,
31,
632,
31,
1,
-100,
-100,
-100,
-10... |
How many viewed the episode gary gets boundaries? | CREATE TABLE table_name_47 (
viewers VARCHAR,
episode VARCHAR
) | SELECT COUNT(viewers) FROM table_name_47 WHERE episode = "gary gets boundaries" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4177,
41,
13569,
584,
4280,
28027,
6,
5640,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
571,
186,
3,
4931,
8,
5640,
5260,
63,
2347,
11814,
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,
2847,
17161,
599,
4576,
277,
61,
21680,
953,
834,
4350,
834,
4177,
549,
17444,
427,
5640,
3274,
96,
1478,
63,
2347,
11814,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
Add up all the Ends columns that have goals smaller than 0. | CREATE TABLE table_name_65 (ends INTEGER, goals INTEGER) | SELECT SUM(ends) FROM table_name_65 WHERE goals < 0 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4122,
41,
989,
7,
3,
21342,
17966,
6,
1766,
3,
21342,
17966,
61,
3,
32102,
32103,
32101,
32103,
2334,
95,
66,
8,
3720,
7,
15752,
24,
43,
1766,
2755,
145,
4097,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
180,
6122,
599,
989,
7,
61,
21680,
953,
834,
4350,
834,
4122,
549,
17444,
427,
1766,
3,
2,
3,
632,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
Name the scientific name for veiled chameleon | CREATE TABLE table_175442_1 (
scientific_name VARCHAR,
common_name VARCHAR
) | SELECT scientific_name FROM table_175442_1 WHERE common_name = "Veiled chameleon" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2517,
5062,
4165,
834,
536,
41,
4290,
834,
4350,
584,
4280,
28027,
6,
1017,
834,
4350,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
5570,
8,
4290,
564,
21,
3,
20... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4290,
834,
4350,
21680,
953,
834,
2517,
5062,
4165,
834,
536,
549,
17444,
427,
1017,
834,
4350,
3274,
96,
553,
15,
699,
26,
3,
17788,
400,
106,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
Which Pick # has a League from of ontario hockey league, a Nationality of united states, and a Team from of brampton battalion? | CREATE TABLE table_62420 (
"Pick #" real,
"Player" text,
"Nationality" text,
"Position" text,
"Team from" text,
"League from" text
) | SELECT COUNT("Pick #") FROM table_62420 WHERE "League from" = 'ontario hockey league' AND "Nationality" = 'united states' AND "Team from" = 'brampton battalion' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4056,
21899,
41,
96,
345,
3142,
1713,
121,
490,
6,
96,
15800,
49,
121,
1499,
6,
96,
24732,
485,
121,
1499,
6,
96,
345,
32,
7,
4749,
121,
1499,
6,
96,
18699,
45,
121,
14... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
121,
345,
3142,
1713,
8512,
21680,
953,
834,
4056,
21899,
549,
17444,
427,
96,
2796,
9,
5398,
45,
121,
3274,
3,
31,
1770,
14414,
16528,
5533,
31,
3430,
96,
24732,
485,
121,
3274,
3,
31,
15129,
15,
... |
Return the name and id of the furniture with the highest market rate. | CREATE TABLE furniture_manufacte (
manufacturer_id number,
furniture_id number,
price_in_dollar number
)
CREATE TABLE manufacturer (
manufacturer_id number,
open_year number,
name text,
num_of_factories number,
num_of_shops number
)
CREATE TABLE furniture (
furniture_id number,
name text,
num_of_component number,
market_rate number
) | SELECT name, furniture_id FROM furniture ORDER BY market_rate DESC LIMIT 1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
1991,
834,
348,
76,
8717,
15,
41,
4818,
834,
23,
26,
381,
6,
1991,
834,
23,
26,
381,
6,
594,
834,
77,
834,
26748,
381,
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,
564,
6,
1991,
834,
23,
26,
21680,
1991,
4674,
11300,
272,
476,
512,
834,
2206,
309,
25067,
8729,
12604,
209,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
What is the sum total of all the years with a bell that weighed 857 kilograms? | CREATE TABLE table_name_40 (year INTEGER, weight__kg_ VARCHAR) | SELECT SUM(year) FROM table_name_40 WHERE weight__kg_ = "857" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2445,
41,
1201,
3,
21342,
17966,
6,
1293,
834,
834,
8711,
834,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
4505,
792,
13,
66,
8,
203,
28,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
180,
6122,
599,
1201,
61,
21680,
953,
834,
4350,
834,
2445,
549,
17444,
427,
1293,
834,
834,
8711,
834,
3274,
96,
927,
3436,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Show the denomination shared by more than one school. | CREATE TABLE school_performance (
school_id number,
school_year text,
class_a text,
class_aa text
)
CREATE TABLE school_details (
school_id number,
nickname text,
colors text,
league text,
class text,
division text
)
CREATE TABLE school (
school_id number,
school text,
location text,
enrollment number,
founded number,
denomination text,
boys_or_girls text,
day_or_boarding text,
year_entered_competition number,
school_colors text
)
CREATE TABLE player (
player_id number,
player text,
team text,
age number,
position text,
school_id number
) | SELECT denomination FROM school GROUP BY denomination HAVING COUNT(*) > 1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
496,
834,
18558,
41,
496,
834,
23,
26,
381,
6,
496,
834,
1201,
1499,
6,
853,
834,
9,
1499,
6,
853,
834,
9,
9,
1499,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
49... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
28730,
21680,
496,
350,
4630,
6880,
272,
476,
28730,
454,
6968,
2365,
2847,
17161,
599,
1935,
61,
2490,
209,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
What is the lane for notes Q, SB and time less than 11.22? | CREATE TABLE table_63941 (
"Rank" real,
"Lane" real,
"Athlete" text,
"Time ( sec )" real,
"Notes" text
) | SELECT SUM("Lane") FROM table_63941 WHERE "Notes" = 'q, sb' AND "Time ( sec )" < '11.22' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3891,
4240,
536,
41,
96,
22557,
121,
490,
6,
96,
434,
152,
15,
121,
490,
6,
96,
188,
189,
1655,
15,
121,
1499,
6,
96,
13368,
41,
4220,
3,
61,
121,
490,
6,
96,
10358,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
434,
152,
15,
8512,
21680,
953,
834,
3891,
4240,
536,
549,
17444,
427,
96,
10358,
15,
7,
121,
3274,
3,
31,
1824,
6,
3,
7,
115,
31,
3430,
96,
13368,
41,
4220,
3,
61,
121,
3,
2,
3,
31,
100... |
Name the number of episode for phyllo dough | CREATE TABLE table_15187735_3 (episode VARCHAR, segment_c VARCHAR) | SELECT COUNT(episode) FROM table_15187735_3 WHERE segment_c = "Phyllo Dough" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
26578,
27697,
2469,
834,
519,
41,
15,
102,
159,
32,
221,
584,
4280,
28027,
6,
5508,
834,
75,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
5570,
8,
381,
13,
5640,
21... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2847,
17161,
599,
15,
102,
159,
32,
221,
61,
21680,
953,
834,
26578,
27697,
2469,
834,
519,
549,
17444,
427,
5508,
834,
75,
3274,
96,
16977,
195,
32,
309,
4607,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
For those employees who was hired before 2002-06-21, a line chart shows the change of manager_id over hire_date | CREATE TABLE departments (
DEPARTMENT_ID decimal(4,0),
DEPARTMENT_NAME varchar(30),
MANAGER_ID decimal(6,0),
LOCATION_ID decimal(4,0)
)
CREATE TABLE countries (
COUNTRY_ID varchar(2),
COUNTRY_NAME varchar(40),
REGION_ID decimal(10,0)
)
CREATE TABLE regions (
REGION_ID decimal(5,0),
REGION_NAME varchar(25)
)
CREATE TABLE locations (
LOCATION_ID decimal(4,0),
STREET_ADDRESS varchar(40),
POSTAL_CODE varchar(12),
CITY varchar(30),
STATE_PROVINCE varchar(25),
COUNTRY_ID varchar(2)
)
CREATE TABLE jobs (
JOB_ID varchar(10),
JOB_TITLE varchar(35),
MIN_SALARY decimal(6,0),
MAX_SALARY decimal(6,0)
)
CREATE TABLE employees (
EMPLOYEE_ID decimal(6,0),
FIRST_NAME varchar(20),
LAST_NAME varchar(25),
EMAIL varchar(25),
PHONE_NUMBER varchar(20),
HIRE_DATE date,
JOB_ID varchar(10),
SALARY decimal(8,2),
COMMISSION_PCT decimal(2,2),
MANAGER_ID decimal(6,0),
DEPARTMENT_ID decimal(4,0)
)
CREATE TABLE job_history (
EMPLOYEE_ID decimal(6,0),
START_DATE date,
END_DATE date,
JOB_ID varchar(10),
DEPARTMENT_ID decimal(4,0)
) | SELECT HIRE_DATE, MANAGER_ID FROM employees WHERE HIRE_DATE < '2002-06-21' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
10521,
41,
3396,
19846,
11810,
834,
4309,
7908,
1982,
599,
8525,
632,
201,
3396,
19846,
11810,
834,
567,
17683,
3,
4331,
4059,
599,
1458,
201,
283,
15610,
17966,
834,
4309,
7908,
1982,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
454,
14132,
834,
308,
6048,
6,
283,
15610,
17966,
834,
4309,
21680,
1652,
549,
17444,
427,
454,
14132,
834,
308,
6048,
3,
2,
3,
31,
24898,
18,
5176,
16539,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
Name the Total which has a Silver larger than 19? | CREATE TABLE table_name_70 (total INTEGER, silver INTEGER) | SELECT MAX(total) FROM table_name_70 WHERE silver > 19 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2518,
41,
235,
1947,
3,
21342,
17966,
6,
4294,
3,
21342,
17966,
61,
3,
32102,
32103,
32101,
32103,
5570,
8,
9273,
84,
65,
3,
9,
5642,
2186,
145,
957,
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,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
4800,
4,
599,
235,
1947,
61,
21680,
953,
834,
4350,
834,
2518,
549,
17444,
427,
4294,
2490,
957,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
What chapter number is Shiqiu? | CREATE TABLE table_1216675_1 (
chapter INTEGER,
pinyin VARCHAR
) | SELECT MIN(chapter) FROM table_1216675_1 WHERE pinyin = "Shiqiu" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2122,
26811,
3072,
834,
536,
41,
5800,
3,
21342,
17966,
6,
4522,
63,
77,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
5800,
381,
19,
4804,
1824,
23,
76,
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,
3,
17684,
599,
524,
6789,
49,
61,
21680,
953,
834,
2122,
26811,
3072,
834,
536,
549,
17444,
427,
4522,
63,
77,
3274,
96,
10499,
23,
1824,
23,
76,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Which name has notes b and the game of tennis? | CREATE TABLE table_name_13 (
name VARCHAR,
sport VARCHAR,
notes VARCHAR
) | SELECT name FROM table_name_13 WHERE sport = "tennis" AND notes = "b" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2368,
41,
564,
584,
4280,
28027,
6,
2600,
584,
4280,
28027,
6,
3358,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
4073,
564,
65,
3358,
3,
115,
11,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
564,
21680,
953,
834,
4350,
834,
2368,
549,
17444,
427,
2600,
3274,
96,
324,
29,
159,
121,
3430,
3358,
3274,
96,
115,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is Title, when Studio is "Embassy Pictures"? | CREATE TABLE table_name_48 (title VARCHAR, studio VARCHAR) | SELECT title FROM table_name_48 WHERE studio = "embassy pictures" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3707,
41,
21869,
584,
4280,
28027,
6,
3100,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
11029,
6,
116,
5929,
19,
96,
17467,
9,
7,
7,
63,
16571,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2233,
21680,
953,
834,
4350,
834,
3707,
549,
17444,
427,
3100,
3274,
96,
30973,
1933,
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 median household income where the per capita is $28,789? | CREATE TABLE table_name_27 (median_household_income VARCHAR, per_capita_income VARCHAR) | SELECT median_household_income FROM table_name_27 WHERE per_capita_income = "$28,789" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2555,
41,
8172,
29,
834,
1840,
6134,
834,
15759,
584,
4280,
28027,
6,
399,
834,
4010,
155,
9,
834,
15759,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
15572,
834,
1840,
6134,
834,
15759,
21680,
953,
834,
4350,
834,
2555,
549,
17444,
427,
399,
834,
4010,
155,
9,
834,
15759,
3274,
96,
3229,
2577,
6,
940,
3914,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What draft pick number did Kentucky get? | CREATE TABLE table_25085059_1 (
pick__number INTEGER,
college VARCHAR
) | SELECT MIN(pick__number) FROM table_25085059_1 WHERE college = "Kentucky" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
11434,
17246,
3390,
834,
536,
41,
1432,
834,
834,
5525,
1152,
3,
21342,
17966,
6,
1900,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
6488,
1432,
381,
410,
134... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3,
17684,
599,
17967,
834,
834,
5525,
1152,
61,
21680,
953,
834,
11434,
17246,
3390,
834,
536,
549,
17444,
427,
1900,
3274,
96,
439,
295,
4636,
63,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Who was the highest pick | CREATE TABLE table_15353123_1 (pick__number INTEGER) | SELECT MIN(pick__number) FROM table_15353123_1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
27025,
4867,
14574,
834,
536,
41,
17967,
834,
834,
5525,
1152,
3,
21342,
17966,
61,
3,
32102,
32103,
32101,
32103,
2645,
47,
8,
2030,
1432,
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,
3,
17684,
599,
17967,
834,
834,
5525,
1152,
61,
21680,
953,
834,
27025,
4867,
14574,
834,
536,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
tell me the number of patients admitted before 2115 who were discharged to skilled nursing facility. | 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 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 COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.discharge_location = "REHAB/DISTINCT PART HOSP" AND demographic.admityear < "2115" | [
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,
549,
17444,
427,
14798,
5,
26,
159,
7993,
834,
14836,
3274,
96,
4386,
5478,
279,
87,
15438,
25424,
6227,
3,
19846,
3,
6299,
... |
What is the Total againsts for the Sant'Anna team with a position number greater than 10? | CREATE TABLE table_39941 (
"Position" real,
"Team" text,
"Points" real,
"Played" real,
"Drawn" real,
"Lost" real,
"Against" real
) | SELECT COUNT("Against") FROM table_39941 WHERE "Team" = 'sant''anna' AND "Position" > '10' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3288,
4240,
536,
41,
96,
345,
32,
7,
4749,
121,
490,
6,
96,
18699,
121,
1499,
6,
96,
22512,
7,
121,
490,
6,
96,
15800,
15,
26,
121,
490,
6,
96,
308,
10936,
29,
121,
4... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
121,
20749,
8512,
21680,
953,
834,
3288,
4240,
536,
549,
17444,
427,
96,
18699,
121,
3274,
3,
31,
7,
288,
31,
31,
10878,
31,
3430,
96,
345,
32,
7,
4749,
121,
2490,
3,
31,
1714,
31,
1,
-100,
-10... |
count the number of patients whose language is russ and discharge location is home? | 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 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 diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
) | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.language = "RUSS" AND demographic.discharge_location = "HOME" | [
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,
549,
17444,
427,
14798,
5,
24925,
3274,
96,
8503,
4256,
121,
3430,
14798,
5,
26,
159,
7993,
834,
14836,
3274,
96,
6299,
4369,... |
What is the sum of credit value of courses with more than one prerequisite for each title? Return a bar chart, and order by the sum credits in desc. | CREATE TABLE classroom (
building varchar(15),
room_number varchar(7),
capacity numeric(4,0)
)
CREATE TABLE section (
course_id varchar(8),
sec_id varchar(8),
semester varchar(6),
year numeric(4,0),
building varchar(15),
room_number varchar(7),
time_slot_id varchar(4)
)
CREATE TABLE time_slot (
time_slot_id varchar(4),
day varchar(1),
start_hr numeric(2),
start_min numeric(2),
end_hr numeric(2),
end_min numeric(2)
)
CREATE TABLE department (
dept_name varchar(20),
building varchar(15),
budget numeric(12,2)
)
CREATE TABLE teaches (
ID varchar(5),
course_id varchar(8),
sec_id varchar(8),
semester varchar(6),
year numeric(4,0)
)
CREATE TABLE student (
ID varchar(5),
name varchar(20),
dept_name varchar(20),
tot_cred numeric(3,0)
)
CREATE TABLE course (
course_id varchar(8),
title varchar(50),
dept_name varchar(20),
credits numeric(2,0)
)
CREATE TABLE advisor (
s_ID varchar(5),
i_ID varchar(5)
)
CREATE TABLE instructor (
ID varchar(5),
name varchar(20),
dept_name varchar(20),
salary numeric(8,2)
)
CREATE TABLE takes (
ID varchar(5),
course_id varchar(8),
sec_id varchar(8),
semester varchar(6),
year numeric(4,0),
grade varchar(2)
)
CREATE TABLE prereq (
course_id varchar(8),
prereq_id varchar(8)
) | SELECT title, SUM(credits) FROM course AS T1 JOIN prereq AS T2 ON T1.course_id = T2.course_id GROUP BY title ORDER BY SUM(credits) DESC | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
4858,
41,
740,
3,
4331,
4059,
599,
1808,
201,
562,
834,
5525,
1152,
3,
4331,
4059,
24358,
6,
2614,
206,
17552,
599,
8525,
632,
61,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2233,
6,
180,
6122,
599,
15547,
7,
61,
21680,
503,
6157,
332,
536,
3,
15355,
3162,
554,
60,
1824,
6157,
332,
357,
9191,
332,
5411,
19221,
834,
23,
26,
3274,
332,
4416,
19221,
834,
23,
26,
350,
4630,
6880,
272,
476... |
A bar chart for what are the number of the titles of all movies that have between 3 and 5 stars?, and sort from low to high by the the number of title. | CREATE TABLE Reviewer (
rID int,
name text
)
CREATE TABLE Movie (
mID int,
title text,
year int,
director text
)
CREATE TABLE Rating (
rID int,
mID int,
stars int,
ratingDate date
) | SELECT title, COUNT(title) FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID WHERE T1.stars BETWEEN 3 AND 5 GROUP BY title ORDER BY COUNT(title) | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
4543,
49,
41,
3,
52,
4309,
16,
17,
6,
564,
1499,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
10743,
41,
3,
51,
4309,
16,
17,
6,
2233,
1499,
6,
215,
16,
17,
6,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2233,
6,
2847,
17161,
599,
21869,
61,
21680,
21662,
6157,
332,
536,
3,
15355,
3162,
10743,
6157,
332,
357,
9191,
332,
5411,
51,
4309,
3274,
332,
4416,
51,
4309,
549,
17444,
427,
332,
5411,
3624,
7,
272,
7969,
518,
2... |
Who was the away team at the game at Punt Road Oval with a crowd larger than 13,000? | CREATE TABLE table_33632 (
"Home team" text,
"Home team score" text,
"Away team" text,
"Away team score" text,
"Venue" text,
"Crowd" real,
"Date" text
) | SELECT "Away team" FROM table_33632 WHERE "Crowd" > '13,000' AND "Venue" = 'punt road oval' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
519,
3420,
2668,
41,
96,
19040,
372,
121,
1499,
6,
96,
19040,
372,
2604,
121,
1499,
6,
96,
188,
1343,
372,
121,
1499,
6,
96,
188,
1343,
372,
2604,
121,
1499,
6,
96,
553,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
188,
1343,
372,
121,
21680,
953,
834,
519,
3420,
2668,
549,
17444,
427,
96,
254,
3623,
26,
121,
2490,
3,
31,
536,
11212,
31,
3430,
96,
553,
35,
76,
15,
121,
3274,
3,
31,
6225,
17,
1373,
17986,
31,
1,
-100,
... |
Who is the runner-up at the Chicago challenge? | CREATE TABLE table_name_68 (runner_s__up VARCHAR, tournament VARCHAR) | SELECT runner_s__up FROM table_name_68 WHERE tournament = "chicago challenge" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3651,
41,
10806,
834,
7,
834,
834,
413,
584,
4280,
28027,
6,
5892,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
2645,
19,
8,
3,
10806,
18,
413,
44,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
3,
10806,
834,
7,
834,
834,
413,
21680,
953,
834,
4350,
834,
3651,
549,
17444,
427,
5892,
3274,
96,
1436,
658,
839,
1921,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What Player is from Iowa State? | CREATE TABLE table_60985 (
"Original NFL team" text,
"Player" text,
"Pos." text,
"College" text,
"Conf." text
) | SELECT "Player" FROM table_60985 WHERE "College" = 'iowa state' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3328,
3916,
755,
41,
96,
667,
3380,
10270,
10439,
372,
121,
1499,
6,
96,
15800,
49,
121,
1499,
6,
96,
345,
32,
7,
535,
1499,
6,
96,
9939,
7883,
121,
1499,
6,
96,
4302,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
15800,
49,
121,
21680,
953,
834,
3328,
3916,
755,
549,
17444,
427,
96,
9939,
7883,
121,
3274,
3,
31,
23,
2381,
9,
538,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the average Week when there were more than 63,866 people in attendance on September 7, 1981? | CREATE TABLE table_40281 (
"Week" real,
"Date" text,
"Opponent" text,
"Result" text,
"Attendance" real
) | SELECT AVG("Week") FROM table_40281 WHERE "Attendance" > '63,866' AND "Date" = 'september 7, 1981' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2445,
2577,
536,
41,
96,
518,
10266,
121,
490,
6,
96,
308,
342,
121,
1499,
6,
96,
667,
102,
9977,
121,
1499,
6,
96,
20119,
121,
1499,
6,
96,
188,
17,
324,
26,
663,
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,
71,
17217,
599,
121,
518,
10266,
8512,
21680,
953,
834,
2445,
2577,
536,
549,
17444,
427,
96,
188,
17,
324,
26,
663,
121,
2490,
3,
31,
3891,
6,
26750,
31,
3430,
96,
308,
342,
121,
3274,
3,
31,
7,
6707,
18247,
79... |
What was the outcome of the match against Nguyen Tien Minh in the Bulgaria Open? | CREATE TABLE table_name_51 (outcome VARCHAR, opponent VARCHAR, tournament VARCHAR) | SELECT outcome FROM table_name_51 WHERE opponent = "nguyen tien minh" AND tournament = "bulgaria open" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
5553,
41,
670,
287,
15,
584,
4280,
28027,
6,
15264,
584,
4280,
28027,
6,
5892,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
6138,
13,
8,
1588... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
6138,
21680,
953,
834,
4350,
834,
5553,
549,
17444,
427,
15264,
3274,
96,
29,
1744,
63,
35,
3,
15945,
3519,
107,
121,
3430,
5892,
3274,
96,
6724,
122,
6286,
539,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
Which dam type was completed in 1961? | CREATE TABLE table_62075 (
"Dam constructed" text,
"Year completed" real,
"Impounded body of water" text,
"Reservoir capacity" text,
"Dam wall height" text,
"Dam type" text
) | SELECT "Dam type" FROM table_62075 WHERE "Year completed" = '1961' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
26898,
3072,
41,
96,
308,
265,
8520,
121,
1499,
6,
96,
476,
2741,
2012,
121,
490,
6,
96,
196,
1167,
14471,
643,
13,
387,
121,
1499,
6,
96,
1649,
3473,
5425,
2614,
121,
14... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
265,
686,
121,
21680,
953,
834,
26898,
3072,
549,
17444,
427,
96,
476,
2741,
2012,
121,
3274,
3,
31,
2294,
4241,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What year was the most recent US Open championship? | CREATE TABLE table_1514559_1 (year INTEGER, championship VARCHAR) | SELECT MAX(year) FROM table_1514559_1 WHERE championship = "US Open" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1808,
20987,
3390,
834,
536,
41,
1201,
3,
21342,
17966,
6,
10183,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
215,
47,
8,
167,
1100,
837,
2384,
10183,
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,
4800,
4,
599,
1201,
61,
21680,
953,
834,
1808,
20987,
3390,
834,
536,
549,
17444,
427,
10183,
3274,
96,
3063,
2384,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
Who had the fastest lap for the circuit magione? | CREATE TABLE table_3677 (
"Round" real,
"Circuit" text,
"Series" text,
"Pole Position" text,
"Fastest Lap" text,
"Winning Driver" text,
"Winning Team" text
) | SELECT "Fastest Lap" FROM table_3677 WHERE "Circuit" = 'Magione' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3420,
4013,
41,
96,
448,
32,
1106,
121,
490,
6,
96,
254,
23,
52,
21560,
121,
1499,
6,
96,
12106,
7,
121,
1499,
6,
96,
8931,
15,
14258,
121,
1499,
6,
96,
371,
9,
7,
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,
96,
371,
9,
7,
4377,
325,
102,
121,
21680,
953,
834,
3420,
4013,
549,
17444,
427,
96,
254,
23,
52,
21560,
121,
3274,
3,
31,
22909,
23,
782,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the time of 12 December 2009 with record start? | CREATE TABLE table_name_81 (
time VARCHAR,
record VARCHAR,
date VARCHAR
) | SELECT time FROM table_name_81 WHERE record = "start" AND date = "12 december 2009" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4959,
41,
97,
584,
4280,
28027,
6,
1368,
584,
4280,
28027,
6,
833,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
97,
13,
586,
1882,
2464,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
97,
21680,
953,
834,
4350,
834,
4959,
549,
17444,
427,
1368,
3274,
96,
10208,
121,
3430,
833,
3274,
96,
2122,
20,
75,
18247,
2464,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the Total Apps listing for Paul Wilson? | CREATE TABLE table_name_78 (total_apps VARCHAR, name VARCHAR) | SELECT total_apps FROM table_name_78 WHERE name = "paul wilson" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3940,
41,
235,
1947,
834,
3096,
7,
584,
4280,
28027,
6,
564,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
9273,
2276,
7,
6437,
21,
1838,
9439... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
792,
834,
3096,
7,
21680,
953,
834,
4350,
834,
3940,
549,
17444,
427,
564,
3274,
96,
102,
9,
83,
3,
210,
173,
739,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
How big is the Venue of Brunswick Street Oval? | CREATE TABLE table_name_47 (crowd INTEGER, venue VARCHAR) | SELECT SUM(crowd) FROM table_name_47 WHERE venue = "brunswick street oval" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4177,
41,
75,
3623,
26,
3,
21342,
17966,
6,
5669,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
571,
600,
19,
8,
29940,
13,
29980,
1887,
411,
2165,
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,
0... | [
3,
23143,
14196,
180,
6122,
599,
75,
3623,
26,
61,
21680,
953,
834,
4350,
834,
4177,
549,
17444,
427,
5669,
3274,
96,
9052,
29,
7,
5981,
2815,
17986,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What is the percentage of yes when there were 218846 yes votes | CREATE TABLE table_256286_61 (_percentage_yes VARCHAR, yes_votes VARCHAR) | SELECT _percentage_yes FROM table_256286_61 WHERE yes_votes = 218846 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1828,
4056,
3840,
834,
4241,
41,
834,
883,
3728,
545,
834,
10070,
584,
4280,
28027,
6,
4273,
834,
1621,
1422,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
3,
834,
883,
3728,
545,
834,
10070,
21680,
953,
834,
1828,
4056,
3840,
834,
4241,
549,
17444,
427,
4273,
834,
1621,
1422,
3274,
1401,
4060,
4448,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
find the average age of patients who had pituitary bleed and stayed in the hospital for 29 days. | 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
)
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
) | SELECT AVG(demographic.age) FROM demographic WHERE demographic.diagnosis = "PITUITARY BLEED" AND demographic.days_stay = "29" | [
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,
71,
17217,
599,
1778,
16587,
5,
545,
61,
21680,
14798,
549,
17444,
427,
14798,
5,
25930,
4844,
159,
3274,
96,
4111,
9968,
3177,
24721,
272,
3765,
2326,
121,
3430,
14798,
5,
1135,
7,
834,
21545,
3274,
96,
3166,
121,
... |
What was the attendance when the VFL played Junction Oval? | CREATE TABLE table_name_58 (crowd VARCHAR, venue VARCHAR) | SELECT COUNT(crowd) FROM table_name_58 WHERE venue = "junction oval" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3449,
41,
75,
3623,
26,
584,
4280,
28027,
6,
5669,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
11364,
116,
8,
584,
10765,
1944,
29092,
411,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2847,
17161,
599,
75,
3623,
26,
61,
21680,
953,
834,
4350,
834,
3449,
549,
17444,
427,
5669,
3274,
96,
6959,
4985,
17986,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
Find out the average age of patients who are 70 years or more that were admitted on or after 2194. | CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
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 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 AVG(demographic.age) FROM demographic WHERE demographic.age >= "70" AND demographic.admityear >= "2194" | [
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,
71,
17217,
599,
1778,
16587,
5,
545,
61,
21680,
14798,
549,
17444,
427,
14798,
5,
545,
2490,
2423,
96,
2518,
121,
3430,
14798,
5,
20466,
17,
1201,
2490,
2423,
96,
2658,
4240,
121,
1,
-100,
-100,
-100,
-100,
-100,
-1... |
Who is the current champion for the event in Beverly, MA, with previous champions of Mike Webb and Nick Fahrenheit? | CREATE TABLE table_40105 (
"Championship" text,
"Current champion(s)" text,
"Previous champion(s)" text,
"Date won" text,
"Location" text
) | SELECT "Current champion(s)" FROM table_40105 WHERE "Location" = 'beverly, ma' AND "Previous champion(s)" = 'mike webb and nick fahrenheit' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2445,
12869,
41,
96,
254,
1483,
12364,
2009,
121,
1499,
6,
96,
254,
450,
5320,
6336,
599,
7,
61,
121,
1499,
6,
96,
10572,
19117,
6336,
599,
7,
61,
121,
1499,
6,
96,
308,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
450,
5320,
6336,
599,
7,
61,
121,
21680,
953,
834,
2445,
12869,
549,
17444,
427,
96,
434,
32,
75,
257,
121,
3274,
3,
31,
346,
624,
120,
6,
954,
31,
3430,
96,
10572,
19117,
6336,
599,
7,
61,
121,
3274,
... |
what is the different between the number of people who attended august 30th and the number of people who attended november 1st | CREATE TABLE table_204_858 (
id number,
"date" text,
"time" text,
"opponent#" text,
"rank#" text,
"site" text,
"tv" text,
"result" text,
"attendance" number
) | SELECT ABS((SELECT "attendance" FROM table_204_858 WHERE "date" = 'august 30') - (SELECT "attendance" FROM table_204_858 WHERE "date" = 'november 1')) | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
26363,
834,
927,
3449,
41,
3,
23,
26,
381,
6,
96,
5522,
121,
1499,
6,
96,
715,
121,
1499,
6,
96,
32,
102,
9977,
4663,
121,
1499,
6,
96,
6254,
4663,
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,
1... | [
3,
23143,
14196,
20798,
599,
599,
23143,
14196,
96,
15116,
663,
121,
21680,
953,
834,
26363,
834,
927,
3449,
549,
17444,
427,
96,
5522,
121,
3274,
3,
31,
402,
17198,
604,
31,
61,
3,
18,
41,
23143,
14196,
96,
15116,
663,
121,
21680,
... |
Which Market/Rank is associated with WCRN calls? | CREATE TABLE table_10333757_1 (market_rank VARCHAR, calls VARCHAR) | SELECT market_rank FROM table_10333757_1 WHERE calls = "WCRN" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1714,
4201,
4118,
3436,
834,
536,
41,
8809,
834,
6254,
584,
4280,
28027,
6,
3088,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
4073,
3611,
87,
22557,
19,
1968,
28,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
512,
834,
6254,
21680,
953,
834,
1714,
4201,
4118,
3436,
834,
536,
549,
17444,
427,
3088,
3274,
96,
10038,
14151,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
which facility hold the most inmates ? | CREATE TABLE table_202_262 (
id number,
"name" text,
"location" text,
"opened" number,
"gender" text,
"security level(s)" text,
"capacity" number
) | SELECT "name" FROM table_202_262 ORDER BY "capacity" DESC LIMIT 1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
19818,
834,
2688,
357,
41,
3,
23,
26,
381,
6,
96,
4350,
121,
1499,
6,
96,
14836,
121,
1499,
6,
96,
26940,
121,
381,
6,
96,
122,
3868,
121,
1499,
6,
96,
19361,
593,
599,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4350,
121,
21680,
953,
834,
19818,
834,
2688,
357,
4674,
11300,
272,
476,
96,
4010,
9,
6726,
121,
309,
25067,
8729,
12604,
209,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
What is the name of the venue when the competition was friendly, with a Result of 2–3? | CREATE TABLE table_name_98 (venue VARCHAR, competition VARCHAR, result VARCHAR) | SELECT venue FROM table_name_98 WHERE competition = "friendly" AND result = "2–3" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3916,
41,
15098,
584,
4280,
28027,
6,
2259,
584,
4280,
28027,
6,
741,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
564,
13,
8,
5669,
116,
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,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
5669,
21680,
953,
834,
4350,
834,
3916,
549,
17444,
427,
2259,
3274,
96,
4905,
121,
3430,
741,
3274,
96,
357,
104,
519,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
What week is a bye week? | CREATE TABLE table_77566 (
"Week" real,
"Date" text,
"Opponent" text,
"Result" text,
"Attendance" text
) | SELECT "Week" FROM table_77566 WHERE "Date" = 'bye' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
940,
3072,
3539,
41,
96,
518,
10266,
121,
490,
6,
96,
308,
342,
121,
1499,
6,
96,
667,
102,
9977,
121,
1499,
6,
96,
20119,
121,
1499,
6,
96,
188,
17,
324,
26,
663,
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,
0... | [
3,
23143,
14196,
96,
518,
10266,
121,
21680,
953,
834,
940,
3072,
3539,
549,
17444,
427,
96,
308,
342,
121,
3274,
3,
31,
969,
15,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
tell me the number of urgent hospital admission patients aged less than 67 years. | 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 WHERE demographic.admission_type = "URGENT" AND demographic.age < "67" | [
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,
549,
17444,
427,
14798,
5,
9,
26,
5451,
834,
6137,
3274,
96,
5905,
517,
6431,
121,
3430,
14798,
5,
545,
3,
2,
96,
3708,
1... |
How many weeks had a game on November 26, 1978, and an attendance higher than 26,248? | CREATE TABLE table_name_88 (
week VARCHAR,
date VARCHAR,
attendance VARCHAR
) | SELECT COUNT(week) FROM table_name_88 WHERE date = "november 26, 1978" AND attendance > 26 OFFSET 248 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4060,
41,
471,
584,
4280,
28027,
6,
833,
584,
4280,
28027,
6,
11364,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
571,
186,
1274,
141,
3,
9,
467,
30,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2847,
17161,
599,
8041,
61,
21680,
953,
834,
4350,
834,
4060,
549,
17444,
427,
833,
3274,
96,
5326,
18247,
13597,
14834,
121,
3430,
11364,
2490,
2208,
3,
15316,
20788,
204,
3707,
1,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Name the result for augustine h. shepperd (j) 100% | CREATE TABLE table_73998 (
"District" text,
"Incumbent" text,
"Party" text,
"First elected" text,
"Result" text,
"Candidates" text
) | SELECT "Result" FROM table_73998 WHERE "Candidates" = 'Augustine H. Shepperd (J) 100%' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
940,
3288,
3916,
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,
1499,
6,
96,
20119,
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,
20119,
121,
21680,
953,
834,
940,
3288,
3916,
549,
17444,
427,
96,
14050,
12416,
6203,
121,
3274,
3,
31,
26579,
630,
454,
5,
451,
8153,
26,
41,
683,
61,
2349,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
is there any microbiological test result since 2104 for patient 031-16123's nasopharynx? | CREATE TABLE cost (
costid number,
uniquepid text,
patienthealthsystemstayid number,
eventtype text,
eventid number,
chargetime time,
cost number
)
CREATE TABLE medication (
medicationid number,
patientunitstayid number,
drugname text,
dosage text,
routeadmin text,
drugstarttime time,
drugstoptime time
)
CREATE TABLE lab (
labid number,
patientunitstayid number,
labname text,
labresult number,
labresulttime time
)
CREATE TABLE diagnosis (
diagnosisid number,
patientunitstayid number,
diagnosisname text,
diagnosistime time,
icd9code text
)
CREATE TABLE microlab (
microlabid number,
patientunitstayid number,
culturesite text,
organism text,
culturetakentime time
)
CREATE TABLE patient (
uniquepid text,
patienthealthsystemstayid number,
patientunitstayid number,
gender text,
age text,
ethnicity text,
hospitalid number,
wardid number,
admissionheight number,
admissionweight number,
dischargeweight number,
hospitaladmittime time,
hospitaladmitsource text,
unitadmittime time,
unitdischargetime time,
hospitaldischargetime time,
hospitaldischargestatus text
)
CREATE TABLE intakeoutput (
intakeoutputid number,
patientunitstayid number,
cellpath text,
celllabel text,
cellvaluenumeric number,
intakeoutputtime time
)
CREATE TABLE allergy (
allergyid number,
patientunitstayid number,
drugname text,
allergyname text,
allergytime time
)
CREATE TABLE treatment (
treatmentid number,
patientunitstayid number,
treatmentname text,
treatmenttime time
)
CREATE TABLE vitalperiodic (
vitalperiodicid number,
patientunitstayid number,
temperature number,
sao2 number,
heartrate number,
respiration number,
systemicsystolic number,
systemicdiastolic number,
systemicmean number,
observationtime time
) | SELECT COUNT(*) FROM microlab WHERE microlab.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '031-16123')) AND microlab.culturesite = 'nasopharynx' AND STRFTIME('%y', microlab.culturetakentime) >= '2104' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
583,
41,
583,
23,
26,
381,
6,
775,
12417,
1499,
6,
1868,
15878,
3734,
21545,
23,
26,
381,
6,
605,
6137,
1499,
6,
605,
23,
26,
381,
6,
1567,
715,
97,
6,
583,
381,
3,
61,
3,
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,
1935,
61,
21680,
2179,
9339,
549,
17444,
427,
2179,
9339,
5,
10061,
15129,
21545,
23,
26,
3388,
41,
23143,
14196,
1868,
5,
10061,
15129,
21545,
23,
26,
21680,
1868,
549,
17444,
427,
1868,
5,
10061,
1... |
Where were the New York Jets visiting? | CREATE TABLE table_name_65 (
stadium VARCHAR,
visiting_team VARCHAR
) | SELECT stadium FROM table_name_65 WHERE visiting_team = "new york jets" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4122,
41,
14939,
584,
4280,
28027,
6,
3644,
834,
11650,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
2840,
130,
8,
368,
1060,
12434,
7,
3644,
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,
14939,
21680,
953,
834,
4350,
834,
4122,
549,
17444,
427,
3644,
834,
11650,
3274,
96,
5534,
25453,
8757,
7,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the category for the premios lo nuestro award? | CREATE TABLE table_name_72 (
category VARCHAR,
award VARCHAR
) | SELECT category FROM table_name_72 WHERE award = "premios lo nuestro" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
5865,
41,
3295,
584,
4280,
28027,
6,
2760,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
3295,
21,
8,
11707,
32,
7,
6899,
206,
15,
6626,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3295,
21680,
953,
834,
4350,
834,
5865,
549,
17444,
427,
2760,
3274,
96,
2026,
51,
23,
32,
7,
6899,
206,
15,
6626,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What is the class of the team that has a behind of +44.780? | CREATE TABLE table_name_18 (class VARCHAR, behind VARCHAR) | SELECT class FROM table_name_18 WHERE behind = "+44.780" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2606,
41,
4057,
584,
4280,
28027,
6,
1187,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
853,
13,
8,
372,
24,
65,
3,
9,
1187,
13,
1768,
591,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
853,
21680,
953,
834,
4350,
834,
2606,
549,
17444,
427,
1187,
3274,
96,
1220,
591,
25211,
2079,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
How many picks did the Chicago Black Hawks get? | CREATE TABLE table_29011 (
"Pick #" real,
"Player" text,
"Position" text,
"Nationality" text,
"NHL team" text,
"College/junior/club team" text
) | SELECT COUNT("Pick #") FROM table_29011 WHERE "NHL team" = 'Chicago Black Hawks' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
23838,
2596,
41,
96,
345,
3142,
1713,
121,
490,
6,
96,
15800,
49,
121,
1499,
6,
96,
345,
32,
7,
4749,
121,
1499,
6,
96,
24732,
485,
121,
1499,
6,
96,
15743,
434,
372,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
121,
345,
3142,
1713,
8512,
21680,
953,
834,
23838,
2596,
549,
17444,
427,
96,
15743,
434,
372,
121,
3274,
3,
31,
3541,
2617,
839,
1589,
12833,
7,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What is the production code of the episode directed by Stacie Lipp? | CREATE TABLE table_2226817_9 (production_code VARCHAR, written_by VARCHAR) | SELECT production_code FROM table_2226817_9 WHERE written_by = "Stacie Lipp" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
26144,
3651,
2517,
834,
1298,
41,
20762,
834,
4978,
584,
4280,
28027,
6,
1545,
834,
969,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
999,
1081,
13,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
999,
834,
4978,
21680,
953,
834,
26144,
3651,
2517,
834,
1298,
549,
17444,
427,
1545,
834,
969,
3274,
96,
134,
17,
9,
6267,
10840,
102,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
How many locations have the callsign DXGH? | CREATE TABLE table_28794440_1 (location VARCHAR, callsign VARCHAR) | SELECT COUNT(location) FROM table_28794440_1 WHERE callsign = "DXGH" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2577,
4440,
3628,
2445,
834,
536,
41,
14836,
584,
4280,
28027,
6,
580,
6732,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
571,
186,
3248,
43,
8,
580,
6732,
309,
4,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2847,
17161,
599,
14836,
61,
21680,
953,
834,
2577,
4440,
3628,
2445,
834,
536,
549,
17444,
427,
580,
6732,
3274,
96,
308,
4,
14100,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
How many starts are there? | CREATE TABLE table_25751 (
"Position" real,
"Driver" text,
"Points" real,
"Starts" real,
"Wins" real,
"Top 5s" real,
"Top 10s" real,
"Winnings ($)" real
) | SELECT MIN("Starts") FROM table_25751 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1828,
3072,
536,
41,
96,
345,
32,
7,
4749,
121,
490,
6,
96,
20982,
52,
121,
1499,
6,
96,
22512,
7,
121,
490,
6,
96,
7681,
17,
7,
121,
490,
6,
96,
18455,
7,
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,
3,
17684,
599,
121,
7681,
17,
7,
8512,
21680,
953,
834,
1828,
3072,
536,
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... |
What is the L2 Cache for Model Number nano u3400 with an Idle Power of 100mw? | CREATE TABLE table_name_10 (l2_cache VARCHAR, idle_power VARCHAR, model_number VARCHAR) | SELECT l2_cache FROM table_name_10 WHERE idle_power = "100mw" AND model_number = "nano u3400" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
1714,
41,
40,
357,
834,
75,
4933,
584,
4280,
28027,
6,
26592,
834,
6740,
584,
4280,
28027,
6,
825,
834,
5525,
1152,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
3,
40,
357,
834,
75,
4933,
21680,
953,
834,
4350,
834,
1714,
549,
17444,
427,
26592,
834,
6740,
3274,
96,
2915,
51,
210,
121,
3430,
825,
834,
5525,
1152,
3274,
96,
29,
152,
32,
3,
76,
519,
5548,
121,
1,
-100,
-1... |
Where is the first day cover cancellation for the 3 April 2008 IIHF World Championships, Quebec City stamp? | CREATE TABLE table_11900773_6 (first_day_cover_cancellation VARCHAR, date_of_issue VARCHAR, theme VARCHAR) | SELECT first_day_cover_cancellation FROM table_11900773_6 WHERE date_of_issue = "3 April 2008" AND theme = "IIHF World Championships, Quebec City" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2596,
7015,
4013,
519,
834,
948,
41,
14672,
834,
1135,
834,
9817,
834,
1608,
8725,
257,
584,
4280,
28027,
6,
833,
834,
858,
834,
13159,
584,
4280,
28027,
6,
3800,
584,
4280,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
166,
834,
1135,
834,
9817,
834,
1608,
8725,
257,
21680,
953,
834,
2596,
7015,
4013,
519,
834,
948,
549,
17444,
427,
833,
834,
858,
834,
13159,
3274,
96,
519,
1186,
2628,
121,
3430,
3800,
3274,
96,
196,
196,
17097,
1... |
What is the Losing bonus, when the value for Points is 43? | CREATE TABLE table_name_61 (
losing_bonus VARCHAR,
points VARCHAR
) | SELECT losing_bonus FROM table_name_61 WHERE points = "43" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4241,
41,
5489,
834,
5407,
302,
584,
4280,
28027,
6,
979,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
3144,
53,
4023,
6,
116,
8,
701,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
5489,
834,
5407,
302,
21680,
953,
834,
4350,
834,
4241,
549,
17444,
427,
979,
3274,
96,
4906,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
Who was the composer of te3rafy? | CREATE TABLE table_28005100_1 (composer VARCHAR, title VARCHAR) | SELECT composer FROM table_28005100_1 WHERE title = "Te3rafy" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
17518,
3076,
2915,
834,
536,
41,
287,
2748,
49,
584,
4280,
28027,
6,
2233,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
2645,
47,
8,
13075,
13,
3,
17,
15,
519,
52,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
13075,
21680,
953,
834,
17518,
3076,
2915,
834,
536,
549,
17444,
427,
2233,
3274,
96,
382,
15,
519,
52,
9,
89,
63,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What are the names of the different artists from Bangladesh who never received a rating higher than a 7? | CREATE TABLE artist (
artist_name text,
country text,
gender text,
preferred_genre text
)
CREATE TABLE files (
f_id number,
artist_name text,
file_size text,
duration text,
formats text
)
CREATE TABLE song (
song_name text,
artist_name text,
country text,
f_id number,
genre_is text,
rating number,
languages text,
releasedate time,
resolution number
)
CREATE TABLE genre (
g_name text,
rating text,
most_popular_in text
) | SELECT DISTINCT artist_name FROM artist WHERE country = "Bangladesh" EXCEPT SELECT DISTINCT artist_name FROM song WHERE rating > 7 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
2377,
41,
2377,
834,
4350,
1499,
6,
684,
1499,
6,
7285,
1499,
6,
6241,
834,
729,
60,
1499,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
2073,
41,
3,
89,
834,
23,
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... | [
3,
23143,
14196,
3,
15438,
25424,
6227,
2377,
834,
4350,
21680,
2377,
549,
17444,
427,
684,
3274,
96,
279,
1468,
14712,
7,
107,
121,
262,
4,
30416,
3,
23143,
14196,
3,
15438,
25424,
6227,
2377,
834,
4350,
21680,
2324,
549,
17444,
427,... |
What did the away team score when playing South Melbourne? | CREATE TABLE table_56397 (
"Home team" text,
"Home team score" text,
"Away team" text,
"Away team score" text,
"Venue" text,
"Crowd" real,
"Date" text
) | SELECT "Away team score" FROM table_56397 WHERE "Home team" = 'south melbourne' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4834,
519,
4327,
41,
96,
19040,
372,
121,
1499,
6,
96,
19040,
372,
2604,
121,
1499,
6,
96,
188,
1343,
372,
121,
1499,
6,
96,
188,
1343,
372,
2604,
121,
1499,
6,
96,
553,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
188,
1343,
372,
2604,
121,
21680,
953,
834,
4834,
519,
4327,
549,
17444,
427,
96,
19040,
372,
121,
3274,
3,
31,
7,
670,
107,
3,
2341,
26255,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What is the total number of Ends Won, when Province is "Saskatchewan", and when Stolen Ends is less than 6? | CREATE TABLE table_name_92 (ends_won VARCHAR, province VARCHAR, stolen_ends VARCHAR) | SELECT COUNT(ends_won) FROM table_name_92 WHERE province = "saskatchewan" AND stolen_ends < 6 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4508,
41,
989,
7,
834,
210,
106,
584,
4280,
28027,
6,
7985,
584,
4280,
28027,
6,
14244,
834,
989,
7,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
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,
2847,
17161,
599,
989,
7,
834,
210,
106,
61,
21680,
953,
834,
4350,
834,
4508,
549,
17444,
427,
7985,
3274,
96,
7,
9,
7,
8682,
1033,
3877,
121,
3430,
14244,
834,
989,
7,
3,
2,
431,
1,
-100,
-100,
-100,
-100,
-10... |
Can you tell me the Goal that has the Result of 2-0? | CREATE TABLE table_43934 (
"Goal" real,
"Date" text,
"Score" text,
"Result" text,
"Competition" text
) | SELECT "Goal" FROM table_43934 WHERE "Result" = '2-0' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
591,
3288,
3710,
41,
96,
6221,
138,
121,
490,
6,
96,
308,
342,
121,
1499,
6,
96,
134,
9022,
121,
1499,
6,
96,
20119,
121,
1499,
6,
96,
5890,
4995,
4749,
121,
1499,
3,
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,
6221,
138,
121,
21680,
953,
834,
591,
3288,
3710,
549,
17444,
427,
96,
20119,
121,
3274,
3,
31,
19423,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Name the polyunsaturated fat with total fat of 100g and monounsaturated fat of 20g (84g in high oleic variety) | CREATE TABLE table_name_96 (
polyunsaturated_fat VARCHAR,
total_fat VARCHAR,
monounsaturated_fat VARCHAR
) | SELECT polyunsaturated_fat FROM table_name_96 WHERE total_fat = "100g" AND monounsaturated_fat = "20g (84g in high oleic variety)" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4314,
41,
4251,
202,
7,
6010,
920,
834,
6589,
584,
4280,
28027,
6,
792,
834,
6589,
584,
4280,
28027,
6,
7414,
202,
7,
6010,
920,
834,
6589,
584,
4280,
28027,
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,
4251,
202,
7,
6010,
920,
834,
6589,
21680,
953,
834,
4350,
834,
4314,
549,
17444,
427,
792,
834,
6589,
3274,
96,
2915,
122,
121,
3430,
7414,
202,
7,
6010,
920,
834,
6589,
3274,
96,
1755,
122,
41,
4608,
122,
16,
30... |
Show all investor details, and count them by a bar chart, sort bars from high to low order please. | CREATE TABLE Purchases (
purchase_transaction_id INTEGER,
purchase_details VARCHAR(255)
)
CREATE TABLE Lots (
lot_id INTEGER,
investor_id INTEGER,
lot_details VARCHAR(255)
)
CREATE TABLE Sales (
sales_transaction_id INTEGER,
sales_details VARCHAR(255)
)
CREATE TABLE Transactions (
transaction_id INTEGER,
investor_id INTEGER,
transaction_type_code VARCHAR(10),
date_of_transaction DATETIME,
amount_of_transaction DECIMAL(19,4),
share_count VARCHAR(40),
other_details VARCHAR(255)
)
CREATE TABLE Investors (
investor_id INTEGER,
Investor_details VARCHAR(255)
)
CREATE TABLE Transactions_Lots (
transaction_id INTEGER,
lot_id INTEGER
)
CREATE TABLE Ref_Transaction_Types (
transaction_type_code VARCHAR(10),
transaction_type_description VARCHAR(80)
) | SELECT Investor_details, COUNT(Investor_details) FROM Investors GROUP BY Investor_details ORDER BY Investor_details DESC | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
14839,
7,
41,
1242,
834,
7031,
4787,
834,
23,
26,
3,
21342,
17966,
6,
1242,
834,
221,
5756,
7,
584,
4280,
28027,
599,
25502,
61,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
16873,
834,
221,
5756,
7,
6,
2847,
17161,
599,
13898,
127,
834,
221,
5756,
7,
61,
21680,
16873,
7,
350,
4630,
6880,
272,
476,
16873,
834,
221,
5756,
7,
4674,
11300,
272,
476,
16873,
834,
221,
5756,
7,
309,
25067,
... |
What is the result for November 25, 2001? | CREATE TABLE table_name_45 (result VARCHAR, date VARCHAR) | SELECT result FROM table_name_45 WHERE date = "november 25, 2001" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2128,
41,
60,
7,
83,
17,
584,
4280,
28027,
6,
833,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
741,
21,
1671,
14105,
4402,
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,
741,
21680,
953,
834,
4350,
834,
2128,
549,
17444,
427,
833,
3274,
96,
5326,
18247,
14105,
4402,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Name the Against which has a Venue of wembley stadium , london? | CREATE TABLE table_59568 (
"Opposing Teams" text,
"Against" real,
"Date" text,
"Venue" text,
"Status" text
) | SELECT MAX("Against") FROM table_59568 WHERE "Venue" = 'wembley stadium , london' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
755,
3301,
3651,
41,
96,
667,
102,
2748,
53,
16651,
121,
1499,
6,
96,
20749,
121,
490,
6,
96,
308,
342,
121,
1499,
6,
96,
553,
35,
76,
15,
121,
1499,
6,
96,
134,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
4800,
4,
599,
121,
20749,
8512,
21680,
953,
834,
755,
3301,
3651,
549,
17444,
427,
96,
553,
35,
76,
15,
121,
3274,
3,
31,
210,
8312,
15,
63,
14939,
3,
6,
3,
40,
106,
2029,
31,
1,
-100,
-100,
-100,
-100,
-100,
... |
Name the height in feet for the player from valparaiso | CREATE TABLE table_name_80 (
height_in_ft VARCHAR,
school_club_team_country VARCHAR
) | SELECT height_in_ft FROM table_name_80 WHERE school_club_team_country = "valparaiso" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2079,
41,
3902,
834,
77,
834,
89,
17,
584,
4280,
28027,
6,
496,
834,
13442,
834,
11650,
834,
17529,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
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,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
3902,
834,
77,
834,
89,
17,
21680,
953,
834,
4350,
834,
2079,
549,
17444,
427,
496,
834,
13442,
834,
11650,
834,
17529,
3274,
96,
2165,
6583,
159,
32,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What was the value in 2011 when value in 2009 was 82,003? | CREATE TABLE table_name_45 (Id VARCHAR) | SELECT 2011 FROM table_name_45 WHERE 2009 = "82,003" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2128,
41,
196,
26,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
701,
16,
2722,
116,
701,
16,
2464,
47,
3,
4613,
6,
1206,
519,
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,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2722,
21680,
953,
834,
4350,
834,
2128,
549,
17444,
427,
2464,
3274,
96,
4613,
6,
1206,
519,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What 7:00 has a 7:30 of w-five? | CREATE TABLE table_67383 (
"7:00" text,
"7:30" text,
"8:00" text,
"8:30" text,
"9:00" text,
"10:00" text
) | SELECT "7:00" FROM table_67383 WHERE "7:30" = 'w-five' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3708,
3747,
519,
41,
96,
18735,
121,
1499,
6,
96,
18078,
121,
1499,
6,
96,
15692,
121,
1499,
6,
96,
927,
10,
1458,
121,
1499,
6,
96,
1298,
10,
1206,
121,
1499,
6,
96,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
18735,
121,
21680,
953,
834,
3708,
3747,
519,
549,
17444,
427,
96,
18078,
121,
3274,
3,
31,
210,
18,
16443,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
get count of the number of hospital visits of patient 021-227292 until 3 years ago. | CREATE TABLE treatment (
treatmentid number,
patientunitstayid number,
treatmentname text,
treatmenttime time
)
CREATE TABLE diagnosis (
diagnosisid number,
patientunitstayid number,
diagnosisname text,
diagnosistime time,
icd9code text
)
CREATE TABLE medication (
medicationid number,
patientunitstayid number,
drugname text,
dosage text,
routeadmin text,
drugstarttime time,
drugstoptime time
)
CREATE TABLE patient (
uniquepid text,
patienthealthsystemstayid number,
patientunitstayid number,
gender text,
age text,
ethnicity text,
hospitalid number,
wardid number,
admissionheight number,
admissionweight number,
dischargeweight number,
hospitaladmittime time,
hospitaladmitsource text,
unitadmittime time,
unitdischargetime time,
hospitaldischargetime time,
hospitaldischargestatus text
)
CREATE TABLE microlab (
microlabid number,
patientunitstayid number,
culturesite text,
organism text,
culturetakentime time
)
CREATE TABLE vitalperiodic (
vitalperiodicid number,
patientunitstayid number,
temperature number,
sao2 number,
heartrate number,
respiration number,
systemicsystolic number,
systemicdiastolic number,
systemicmean number,
observationtime time
)
CREATE TABLE cost (
costid number,
uniquepid text,
patienthealthsystemstayid number,
eventtype text,
eventid number,
chargetime time,
cost number
)
CREATE TABLE lab (
labid number,
patientunitstayid number,
labname text,
labresult number,
labresulttime time
)
CREATE TABLE intakeoutput (
intakeoutputid number,
patientunitstayid number,
cellpath text,
celllabel text,
cellvaluenumeric number,
intakeoutputtime time
)
CREATE TABLE allergy (
allergyid number,
patientunitstayid number,
drugname text,
allergyname text,
allergytime time
) | SELECT COUNT(DISTINCT patient.patienthealthsystemstayid) FROM patient WHERE patient.uniquepid = '021-227292' AND DATETIME(patient.hospitaladmittime) <= DATETIME(CURRENT_TIME(), '-3 year') | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
1058,
41,
1058,
23,
26,
381,
6,
1868,
15129,
21545,
23,
26,
381,
6,
1058,
4350,
1499,
6,
1058,
715,
97,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
8209,
41,
8209,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1868,
5,
10061,
15878,
3734,
21545,
23,
26,
61,
21680,
1868,
549,
17444,
427,
1868,
5,
202,
1495,
12417,
3274,
3,
31,
4305,
9596,
2555,
3166,
357,
31,
3430,
309,
6048,
382,
15382,... |
What is the location of the tournament with more than 6 OWGR points and Ryu Hyun-Woo as the winner? | CREATE TABLE table_name_74 (location VARCHAR, owgr_points VARCHAR, winner VARCHAR) | SELECT location FROM table_name_74 WHERE owgr_points > 6 AND winner = "ryu hyun-woo" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4581,
41,
14836,
584,
4280,
28027,
6,
3,
2381,
122,
52,
834,
2700,
7,
584,
4280,
28027,
6,
4668,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
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,
1128,
21680,
953,
834,
4350,
834,
4581,
549,
17444,
427,
3,
2381,
122,
52,
834,
2700,
7,
2490,
431,
3430,
4668,
3274,
96,
651,
76,
3,
107,
63,
202,
18,
14952,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
Return the claim start date for the claims whose claimed amount is no more than the averag, and count them by a bar chart, and order by the Y-axis in asc. | CREATE TABLE Customers (
Customer_ID INTEGER,
Customer_Details VARCHAR(255)
)
CREATE TABLE Payments (
Payment_ID INTEGER,
Settlement_ID INTEGER,
Payment_Method_Code VARCHAR(255),
Date_Payment_Made DATE,
Amount_Payment INTEGER
)
CREATE TABLE Customer_Policies (
Policy_ID INTEGER,
Customer_ID INTEGER,
Policy_Type_Code CHAR(15),
Start_Date DATE,
End_Date DATE
)
CREATE TABLE Claims (
Claim_ID INTEGER,
Policy_ID INTEGER,
Date_Claim_Made DATE,
Date_Claim_Settled DATE,
Amount_Claimed INTEGER,
Amount_Settled INTEGER
)
CREATE TABLE Settlements (
Settlement_ID INTEGER,
Claim_ID INTEGER,
Date_Claim_Made DATE,
Date_Claim_Settled DATE,
Amount_Claimed INTEGER,
Amount_Settled INTEGER,
Customer_Policy_ID INTEGER
) | SELECT Date_Claim_Made, COUNT(Date_Claim_Made) FROM Claims WHERE Amount_Settled <= (SELECT AVG(Amount_Settled) FROM Claims) ORDER BY COUNT(Date_Claim_Made) | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
16423,
41,
7327,
834,
4309,
3,
21342,
17966,
6,
7327,
834,
2962,
5756,
7,
584,
4280,
28027,
599,
25502,
61,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
12248,
7,
41,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
7678,
834,
254,
521,
603,
834,
329,
9,
221,
6,
2847,
17161,
599,
308,
342,
834,
254,
521,
603,
834,
329,
9,
221,
61,
21680,
4779,
8345,
549,
17444,
427,
71,
11231,
834,
17175,
17,
1361,
3,
2,
2423,
41,
23143,
14... |
What place has Wales as a country? | CREATE TABLE table_name_16 (place VARCHAR, country VARCHAR) | SELECT place FROM table_name_16 WHERE country = "wales" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2938,
41,
4687,
584,
4280,
28027,
6,
684,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
286,
65,
10256,
38,
3,
9,
684,
58,
1,
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,
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... | [
3,
23143,
14196,
286,
21680,
953,
834,
4350,
834,
2938,
549,
17444,
427,
684,
3274,
96,
210,
4529,
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 maximum point for climbers whose country is United Kingdom? | CREATE TABLE climber (
Points INTEGER,
Country VARCHAR
) | SELECT MAX(Points) FROM climber WHERE Country = "United Kingdom" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
8147,
49,
41,
4564,
7,
3,
21342,
17966,
6,
6993,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
2411,
500,
21,
8147,
277,
3,
2544,
684,
19,
907,
6524,
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,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
4800,
4,
599,
22512,
7,
61,
21680,
8147,
49,
549,
17444,
427,
6993,
3274,
96,
5110,
23,
1054,
6524,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Title is the total number where u.s. viewers (million) is 7.56. | CREATE TABLE table_27115960_1 (
title VARCHAR,
us_viewers__million_ VARCHAR
) | SELECT COUNT(title) FROM table_27115960_1 WHERE us_viewers__million_ = "7.56" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2555,
15660,
27699,
834,
536,
41,
2233,
584,
4280,
28027,
6,
178,
834,
4576,
277,
834,
834,
17030,
834,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
11029,
19,
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,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2847,
17161,
599,
21869,
61,
21680,
953,
834,
2555,
15660,
27699,
834,
536,
549,
17444,
427,
178,
834,
4576,
277,
834,
834,
17030,
834,
3274,
96,
15731,
948,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
what is admission location and discharge location of subject id 64208? | 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 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
) | SELECT demographic.admission_location, demographic.discharge_location FROM demographic WHERE demographic.subject_id = "64208" | [
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,
14798,
5,
9,
26,
5451,
834,
14836,
6,
14798,
5,
26,
159,
7993,
834,
14836,
21680,
14798,
549,
17444,
427,
14798,
5,
7304,
11827,
834,
23,
26,
3274,
96,
4389,
23946,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
How many years were there for the 62nd golden globe awards? | CREATE TABLE table_name_29 (
year INTEGER,
awards VARCHAR
) | SELECT SUM(year) FROM table_name_29 WHERE awards = "62nd golden globe awards" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3166,
41,
215,
3,
21342,
17966,
6,
6120,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
571,
186,
203,
130,
132,
21,
8,
3,
4056,
727,
7069,
7895,
6120,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
180,
6122,
599,
1201,
61,
21680,
953,
834,
4350,
834,
3166,
549,
17444,
427,
6120,
3274,
96,
4056,
727,
7069,
7895,
6120,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
What are the names of wrestlers days held less than 100? | CREATE TABLE wrestler (
wrestler_id number,
name text,
reign text,
days_held text,
location text,
event text
)
CREATE TABLE elimination (
elimination_id text,
wrestler_id text,
team text,
eliminated_by text,
elimination_move text,
time text
) | SELECT name FROM wrestler WHERE days_held < 100 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
26033,
52,
41,
26033,
52,
834,
23,
26,
381,
6,
564,
1499,
6,
17367,
1499,
6,
477,
834,
14796,
1499,
6,
1128,
1499,
6,
605,
1499,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
564,
21680,
26033,
52,
549,
17444,
427,
477,
834,
14796,
3,
2,
910,
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,
-1... |
What is the Format of the French Frequency with a Call sign of CKRL-FM? | CREATE TABLE table_name_56 (format VARCHAR, notes VARCHAR, call_sign VARCHAR) | SELECT format FROM table_name_56 WHERE notes = "french" AND call_sign = "ckrl-fm" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4834,
41,
8995,
584,
4280,
28027,
6,
3358,
584,
4280,
28027,
6,
580,
834,
6732,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
12439,
13,
8,
23... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1910,
21680,
953,
834,
4350,
834,
4834,
549,
17444,
427,
3358,
3274,
96,
89,
60,
5457,
121,
3430,
580,
834,
6732,
3274,
96,
2406,
52,
40,
18,
89,
51,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What is the location/state of the Launceston race? | CREATE TABLE table_68361 (
"Race Title" text,
"Circuit" text,
"Location / State" text,
"Date" text,
"Winner" text,
"Team" text
) | SELECT "Location / State" FROM table_68361 WHERE "Race Title" = 'launceston' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3651,
3420,
536,
41,
96,
448,
3302,
11029,
121,
1499,
6,
96,
254,
23,
52,
21560,
121,
1499,
6,
96,
434,
32,
75,
257,
3,
87,
1015,
121,
1499,
6,
96,
308,
342,
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,
434,
32,
75,
257,
3,
87,
1015,
121,
21680,
953,
834,
3651,
3420,
536,
549,
17444,
427,
96,
448,
3302,
11029,
121,
3274,
3,
31,
40,
402,
3772,
4411,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
When was the season finale of a show with season premiere on 12 December 2010? | CREATE TABLE table_67744 (
"Season" real,
"Season Premiere Date" text,
"Season Finale Date" text,
"Winner" text,
"1st Runner Up" text,
"2nd Runner Up" text
) | SELECT "Season Finale Date" FROM table_67744 WHERE "Season Premiere Date" = '12 december 2010' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3708,
4581,
591,
41,
96,
134,
15,
9,
739,
121,
490,
6,
96,
134,
15,
9,
739,
6552,
15,
7678,
121,
1499,
6,
96,
134,
15,
9,
739,
6514,
15,
7678,
121,
1499,
6,
96,
18455... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
6514,
15,
7678,
121,
21680,
953,
834,
3708,
4581,
591,
549,
17444,
427,
96,
134,
15,
9,
739,
6552,
15,
7678,
121,
3274,
3,
31,
2122,
20,
75,
18247,
2735,
31,
1,
-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.