NATURAL_LANG stringlengths 0 446 | SCHEMA stringlengths 27 2.21k | SQL stringlengths 18 453 | input_ids list | attention_mask list | labels list |
|---|---|---|---|---|---|
For those records from the products and each product's manufacturer, give me the comparison about the average of code over the headquarter , and group by attribute headquarter, and could you list Y from high to low order? | CREATE TABLE Products (
Code INTEGER,
Name VARCHAR(255),
Price DECIMAL,
Manufacturer INTEGER
)
CREATE TABLE Manufacturers (
Code INTEGER,
Name VARCHAR(255),
Headquarter VARCHAR(255),
Founder VARCHAR(255),
Revenue REAL
) | SELECT T2.Headquarter, T1.Code FROM Products AS T1 JOIN Manufacturers AS T2 ON T1.Manufacturer = T2.Code GROUP BY T2.Headquarter ORDER BY T1.Code DESC | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
7554,
41,
3636,
3,
21342,
17966,
6,
5570,
584,
4280,
28027,
599,
25502,
201,
5312,
3396,
254,
26330,
434,
6,
15248,
3,
21342,
17966,
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,
332,
4416,
3845,
9,
26,
19973,
6,
332,
5411,
22737,
21680,
7554,
6157,
332,
536,
3,
15355,
3162,
15248,
7,
6157,
332,
357,
9191,
332,
5411,
7296,
76,
8717,
450,
49,
3274,
332,
4416,
22737,
350,
4630,
6880,
272,
476,... |
Which Draws have Losses larger than 16, and a Season larger than 1966? | CREATE TABLE table_name_53 (draws INTEGER, losses VARCHAR, season VARCHAR) | SELECT SUM(draws) FROM table_name_53 WHERE losses > 16 AND season > 1966 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4867,
41,
19489,
7,
3,
21342,
17966,
6,
8467,
584,
4280,
28027,
6,
774,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
4073,
19183,
7,
43,
3144,
2260,
2186,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
180,
6122,
599,
19489,
7,
61,
21680,
953,
834,
4350,
834,
4867,
549,
17444,
427,
8467,
2490,
898,
3430,
774,
2490,
20658,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
For those employees who was hired before 2002-06-21, give me the comparison about the average of department_id over the job_id , and group by attribute job_id, rank in asc by the y-axis. | 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 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 job_history (
EMPLOYEE_ID decimal(6,0),
START_DATE date,
END_DATE date,
JOB_ID varchar(10),
DEPARTMENT_ID decimal(4,0)
)
CREATE TABLE departments (
DEPARTMENT_ID decimal(4,0),
DEPARTMENT_NAME varchar(30),
MANAGER_ID decimal(6,0),
LOCATION_ID decimal(4,0)
)
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)
) | SELECT JOB_ID, AVG(DEPARTMENT_ID) FROM employees WHERE HIRE_DATE < '2002-06-21' GROUP BY JOB_ID ORDER BY AVG(DEPARTMENT_ID) | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
1652,
41,
262,
5244,
5017,
476,
5080,
834,
4309,
7908,
1982,
599,
11071,
632,
201,
30085,
834,
567,
17683,
3,
4331,
4059,
599,
1755,
201,
301,
12510,
834,
567,
17683,
3,
4331,
4059,
59... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
71,
17217,
599,
5596,
19846,
11810,
834,
4309,
61,
21680,
1652,
549,
17444,
427,
454,
14132,
834,
308,
6048,
3,
2,
3,
31,
24898,
18,
5176,
16539,
31,
350,
4630,
6880,
272,
476,
446,
10539,
... |
who writes for ICML and Science ( New York , N.Y. ) | CREATE TABLE field (
fieldid int
)
CREATE TABLE paper (
paperid int,
title varchar,
venueid int,
year int,
numciting int,
numcitedby int,
journalid int
)
CREATE TABLE dataset (
datasetid int,
datasetname varchar
)
CREATE TABLE paperkeyphrase (
paperid int,
keyphraseid int
)
CREATE TABLE paperfield (
fieldid int,
paperid int
)
CREATE TABLE journal (
journalid int,
journalname varchar
)
CREATE TABLE writes (
paperid int,
authorid int
)
CREATE TABLE author (
authorid int,
authorname varchar
)
CREATE TABLE paperdataset (
paperid int,
datasetid int
)
CREATE TABLE cite (
citingpaperid int,
citedpaperid int
)
CREATE TABLE venue (
venueid int,
venuename varchar
)
CREATE TABLE keyphrase (
keyphraseid int,
keyphrasename varchar
) | SELECT DISTINCT writes.authorid FROM paper, venue, writes WHERE venue.venueid = paper.venueid AND venue.venuename IN ('ICML', 'Science ( New York , N.Y. )') AND writes.paperid = paper.paperid GROUP BY writes.authorid HAVING COUNT(DISTINCT venue.venueid) = 2 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
1057,
41,
1057,
23,
26,
16,
17,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
1040,
41,
1040,
23,
26,
16,
17,
6,
2233,
3,
4331,
4059,
6,
5669,
23,
26,
16,
17,
6,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
3,
15438,
25424,
6227,
11858,
5,
17415,
23,
26,
21680,
1040,
6,
5669,
6,
11858,
549,
17444,
427,
5669,
5,
15098,
23,
26,
3274,
1040,
5,
15098,
23,
26,
3430,
5669,
5,
15098,
4350,
3388,
41,
31,
4666,
6858,
31,
6,
... |
What is the number of patients less than 79 years who had a joint fluid lab test done? | 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 COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.age < "79" AND lab.fluid = "Joint Fluid" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
7744,
7,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
23,
1071,
21545,
834,
23,
26,
1499,
6,
2672,
834,
6137,
1499,
6,
2672,
1499,
6,
5403,
651,
834,
26,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
3388,
18206,
3,
15355,
3162,
7690,
9191,
14798,
5,
8399,
51,
834,
23,
26,
3274,
7690,
5,
8399,
51,
834,
23,
26,
549,
17444,... |
What date did the team play on week 8? | CREATE TABLE table_24278858_2 (date VARCHAR, week VARCHAR) | SELECT date FROM table_24278858_2 WHERE week = 8 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2266,
2555,
4060,
3449,
834,
357,
41,
5522,
584,
4280,
28027,
6,
471,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
833,
410,
8,
372,
577,
30,
471,
505,
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,
833,
21680,
953,
834,
2266,
2555,
4060,
3449,
834,
357,
549,
17444,
427,
471,
3274,
505,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Which Record has a Result of l 13 30? | CREATE TABLE table_name_29 (
record VARCHAR,
result VARCHAR
) | SELECT record FROM table_name_29 WHERE result = "l 13–30" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3166,
41,
1368,
584,
4280,
28027,
6,
741,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
4073,
11392,
65,
3,
9,
3,
20119,
13,
3,
40,
1179,
604,
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,
1368,
21680,
953,
834,
4350,
834,
3166,
549,
17444,
427,
741,
3274,
96,
40,
1179,
104,
1458,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What are the drivers' last names and id who had 11 pit stops and participated in more than 5 race results? | CREATE TABLE drivers (surname VARCHAR, driverid VARCHAR); CREATE TABLE results (driverid VARCHAR); CREATE TABLE pitstops (driverid VARCHAR) | SELECT T1.surname, T1.driverid FROM drivers AS T1 JOIN pitstops AS T2 ON T1.driverid = T2.driverid GROUP BY T1.driverid HAVING COUNT(*) = 11 INTERSECT SELECT T1.surname, T1.driverid FROM drivers AS T1 JOIN results AS T2 ON T1.driverid = T2.driverid GROUP BY T1.driverid HAVING COUNT(*) > 5 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
3863,
41,
3042,
4350,
584,
4280,
28027,
6,
1262,
4055,
584,
4280,
28027,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
772,
41,
13739,
4055,
584,
4280,
28027,
61,
3,
32102,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
332,
5411,
3042,
4350,
6,
332,
5411,
13739,
4055,
21680,
3863,
6157,
332,
536,
3,
15355,
3162,
7688,
7618,
7,
6157,
332,
357,
9191,
332,
5411,
13739,
4055,
3274,
332,
4416,
13739,
4055,
350,
4630,
6880,
272,
476,
332,... |
What was the date for renato ferreira? | CREATE TABLE table_name_9 (date VARCHAR, opponent VARCHAR) | SELECT date FROM table_name_9 WHERE opponent = "renato ferreira" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
1298,
41,
5522,
584,
4280,
28027,
6,
15264,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
833,
21,
3,
1536,
9,
235,
25007,
15809,
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,
833,
21680,
953,
834,
4350,
834,
1298,
549,
17444,
427,
15264,
3274,
96,
1536,
9,
235,
25007,
15809,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What date was the visiting team of Los Angeles Rams, earlier than 1958? | CREATE TABLE table_name_58 (date VARCHAR, visiting_team VARCHAR, year VARCHAR) | SELECT date FROM table_name_58 WHERE visiting_team = "los angeles rams" AND year < 1958 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3449,
41,
5522,
584,
4280,
28027,
6,
3644,
834,
11650,
584,
4280,
28027,
6,
215,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
833,
47,
8,
3644,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
833,
21680,
953,
834,
4350,
834,
3449,
549,
17444,
427,
3644,
834,
11650,
3274,
96,
2298,
11831,
15,
7,
3,
2375,
7,
121,
3430,
215,
3,
2,
22306,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
How many number of screenings have an opening film of the journey of vaan nguyen? | CREATE TABLE table_18220102_1 (
number_of_screening VARCHAR,
opening_film VARCHAR
) | SELECT COUNT(number_of_screening) FROM table_18220102_1 WHERE opening_film = "The Journey of Vaan Nguyen" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2606,
357,
14926,
357,
834,
536,
41,
381,
834,
858,
834,
8527,
53,
584,
4280,
28027,
6,
2101,
834,
9988,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
571,
186,
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,
0... | [
3,
23143,
14196,
2847,
17161,
599,
5525,
1152,
834,
858,
834,
8527,
53,
61,
21680,
953,
834,
2606,
357,
14926,
357,
834,
536,
549,
17444,
427,
2101,
834,
9988,
3274,
96,
634,
20709,
13,
2964,
152,
445,
1744,
63,
35,
121,
1,
-100,
... |
Name who wrote the episode by lawrence trilling | CREATE TABLE table_27504682_1 (written_by VARCHAR, directed_by VARCHAR) | SELECT written_by FROM table_27504682_1 WHERE directed_by = "Lawrence Trilling" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
357,
9979,
4448,
4613,
834,
536,
41,
14973,
834,
969,
584,
4280,
28027,
6,
6640,
834,
969,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
5570,
113,
2832,
8,
5640,
57,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1545,
834,
969,
21680,
953,
834,
357,
9979,
4448,
4613,
834,
536,
549,
17444,
427,
6640,
834,
969,
3274,
96,
3612,
210,
52,
1433,
2702,
12013,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What percentage of people were opposed to the candidate based on the Time Poll poll that showed 6% of people were unsure? | CREATE TABLE table_name_22 (oppose VARCHAR, poll_source VARCHAR, unsure VARCHAR) | SELECT oppose FROM table_name_22 WHERE poll_source = "time poll" AND unsure = "6%" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2884,
41,
28236,
7,
15,
584,
4280,
28027,
6,
5492,
834,
7928,
584,
4280,
28027,
6,
3,
20305,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
5294,
13,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
10720,
15,
21680,
953,
834,
4350,
834,
2884,
549,
17444,
427,
5492,
834,
7928,
3274,
96,
715,
5492,
121,
3430,
3,
20305,
3274,
96,
6370,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What member of the current Broadway cast plays the character played by Constantine Maroulis from the original Broadway cast? | CREATE TABLE table_2066 (
"Role" text,
"Original Broadway Cast" text,
"Current Broadway Cast" text,
"Original Toronto Cast" text,
"First National Tour Cast" text,
"Original Australian Cast" text,
"Original West End Cast" text,
"Current West End Cast" text,
"Second National Tour Cast" text,
"Second National Tour Year 2" text
) | SELECT "Current Broadway Cast" FROM table_2066 WHERE "Original Broadway Cast" = 'Constantine Maroulis' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1755,
3539,
41,
96,
448,
32,
109,
121,
1499,
6,
96,
667,
3380,
10270,
17963,
11583,
121,
1499,
6,
96,
254,
450,
5320,
17963,
11583,
121,
1499,
6,
96,
667,
3380,
10270,
7030... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
17963,
11583,
121,
21680,
953,
834,
1755,
3539,
549,
17444,
427,
96,
667,
3380,
10270,
17963,
11583,
121,
3274,
3,
31,
4302,
5627,
4070,
1571,
7115,
159,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the current status of the person named Nicholls? | CREATE TABLE table_79921 (
"Name" text,
"Country" text,
"Status" text,
"Transfer window" text,
"Transfer fee" text,
"Source" text
) | SELECT "Status" FROM table_79921 WHERE "Name" = 'nicholls' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
940,
3264,
2658,
41,
96,
23954,
121,
1499,
6,
96,
10628,
651,
121,
1499,
6,
96,
134,
17,
144,
302,
121,
1499,
6,
96,
18474,
1010,
2034,
121,
1499,
6,
96,
18474,
1010,
257... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
17,
144,
302,
121,
21680,
953,
834,
940,
3264,
2658,
549,
17444,
427,
96,
23954,
121,
3274,
3,
31,
2532,
2831,
40,
7,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What position is Sal Martinez? | CREATE TABLE table_name_32 (position VARCHAR, player VARCHAR) | SELECT position FROM table_name_32 WHERE player = "sal martinez" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2668,
41,
4718,
584,
4280,
28027,
6,
1959,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
1102,
19,
5158,
26906,
58,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
1102,
21680,
953,
834,
4350,
834,
2668,
549,
17444,
427,
1959,
3274,
96,
7,
138,
3157,
4070,
172,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
male or female patient between the age of 12 and 17 years inclusive at time of entry into study ( i.e. | CREATE TABLE table_train_197 (
"id" int,
"dyscrasia" bool,
"gender" string,
"bleeding" int,
"hemoglobin_a1c_hba1c" float,
"diabetic" string,
"body_mass_index_bmi" float,
"age" float,
"NOUSE" float
) | SELECT * FROM table_train_197 WHERE (gender = 'male' OR gender = 'female') AND (age >= 12 AND age <= 17) | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
9719,
834,
27181,
41,
96,
23,
26,
121,
16,
17,
6,
96,
26,
63,
7,
75,
19867,
9,
121,
3,
12840,
40,
6,
96,
122,
3868,
121,
6108,
6,
96,
27779,
53,
121,
16,
17,
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,
1429,
21680,
953,
834,
9719,
834,
27181,
549,
17444,
427,
41,
122,
3868,
3274,
3,
31,
13513,
31,
4674,
7285,
3274,
3,
31,
89,
15,
13513,
31,
61,
3430,
41,
545,
2490,
2423,
586,
3430,
1246,
3,
2,
2423,
1003,
61,
... |
Find the building, room number, semester and year of all courses offered by Psychology department sorted by course titles. | CREATE TABLE classroom (
building text,
room_number text,
capacity number
)
CREATE TABLE student (
id text,
name text,
dept_name text,
tot_cred number
)
CREATE TABLE takes (
id text,
course_id text,
sec_id text,
semester text,
year number,
grade text
)
CREATE TABLE instructor (
id text,
name text,
dept_name text,
salary number
)
CREATE TABLE section (
course_id text,
sec_id text,
semester text,
year number,
building text,
room_number text,
time_slot_id text
)
CREATE TABLE course (
course_id text,
title text,
dept_name text,
credits number
)
CREATE TABLE advisor (
s_id text,
i_id text
)
CREATE TABLE teaches (
id text,
course_id text,
sec_id text,
semester text,
year 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 department (
dept_name text,
building text,
budget number
)
CREATE TABLE prereq (
course_id text,
prereq_id text
) | SELECT T2.building, T2.room_number, T2.semester, T2.year FROM course AS T1 JOIN section AS T2 ON T1.course_id = T2.course_id WHERE T1.dept_name = 'Psychology' ORDER BY T1.title | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
4858,
41,
740,
1499,
6,
562,
834,
5525,
1152,
1499,
6,
2614,
381,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
1236,
41,
3,
23,
26,
1499,
6,
564,
1499,
6,
20,
102,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4416,
10905,
6,
332,
4416,
3082,
834,
5525,
1152,
6,
332,
4416,
7,
15,
526,
1370,
6,
332,
4416,
1201,
21680,
503,
6157,
332,
536,
3,
15355,
3162,
1375,
6157,
332,
357,
9191,
332,
5411,
19221,
834,
23,
26,
327... |
What are all of the order # where authentic artist is maroon 5 | CREATE TABLE table_26250227_1 (order__number VARCHAR, original_artist VARCHAR) | SELECT order__number FROM table_26250227_1 WHERE original_artist = "Maroon 5" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2688,
11434,
357,
2555,
834,
536,
41,
9397,
834,
834,
5525,
1152,
584,
4280,
28027,
6,
926,
834,
1408,
343,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
33,
66,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
455,
834,
834,
5525,
1152,
21680,
953,
834,
2688,
11434,
357,
2555,
834,
536,
549,
17444,
427,
926,
834,
1408,
343,
3274,
96,
7286,
32,
106,
3,
17395,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
give the primary disease of tracy farmer. | 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
)
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 demographic.diagnosis FROM demographic WHERE demographic.name = "Tracy Farmer" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
7690,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
2118,
23,
26,
1499,
6,
5059,
715,
1499,
6,
5692,
1499,
6,
701,
834,
15129,
1499,
6,
3783,
1499,
6,
5798,
1499... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
14798,
5,
25930,
4844,
159,
21680,
14798,
549,
17444,
427,
14798,
5,
4350,
3274,
96,
9402,
75,
63,
4990,
49,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
How many figures are given for the New Democratic for the polling range May 11 31, 2010? | CREATE TABLE table_24778847_2 (
new_democratic VARCHAR,
date_of_polling VARCHAR
) | SELECT COUNT(new_democratic) FROM table_24778847_2 WHERE date_of_polling = "May 11–31, 2010" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2266,
4013,
4060,
4177,
834,
357,
41,
126,
834,
23319,
447,
584,
4280,
28027,
6,
833,
834,
858,
834,
3233,
697,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
571,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0... | [
3,
23143,
14196,
2847,
17161,
599,
5534,
834,
23319,
447,
61,
21680,
953,
834,
2266,
4013,
4060,
4177,
834,
357,
549,
17444,
427,
833,
834,
858,
834,
3233,
697,
3274,
96,
15881,
850,
104,
3341,
6,
2735,
121,
1,
-100,
-100,
-100,
-10... |
What was the date of the game with a decision of Niittymaki and when the Flyers had a record of 30–21–5? | CREATE TABLE table_name_26 (date VARCHAR, decision VARCHAR, record VARCHAR) | SELECT date FROM table_name_26 WHERE decision = "niittymaki" AND record = "30–21–5" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2688,
41,
5522,
584,
4280,
28027,
6,
1357,
584,
4280,
28027,
6,
1368,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
833,
13,
8,
467,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
833,
21680,
953,
834,
4350,
834,
2688,
549,
17444,
427,
1357,
3274,
96,
29,
23,
17132,
51,
11259,
121,
3430,
1368,
3274,
96,
1458,
104,
2658,
104,
17395,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What did Ku Hyo-Jin rank? | CREATE TABLE table_67042 (
"Rank" real,
"Lane" real,
"Name" text,
"Nationality" text,
"Time" text
) | SELECT COUNT("Rank") FROM table_67042 WHERE "Name" = 'ku hyo-jin' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3708,
6348,
357,
41,
96,
22557,
121,
490,
6,
96,
434,
152,
15,
121,
490,
6,
96,
23954,
121,
1499,
6,
96,
24732,
485,
121,
1499,
6,
96,
13368,
121,
1499,
3,
61,
3,
32102... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2847,
17161,
599,
121,
22557,
8512,
21680,
953,
834,
3708,
6348,
357,
549,
17444,
427,
96,
23954,
121,
3274,
3,
31,
2729,
3,
107,
63,
32,
18,
354,
77,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
Name of byron geis, and a Weight smaller than 195 involves what average number? | CREATE TABLE table_name_63 (number INTEGER, name VARCHAR, weight VARCHAR) | SELECT AVG(number) FROM table_name_63 WHERE name = "byron geis" AND weight < 195 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3891,
41,
5525,
1152,
3,
21342,
17966,
6,
564,
584,
4280,
28027,
6,
1293,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
5570,
13,
57,
52,
106,
873,
159,
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,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
71,
17217,
599,
5525,
1152,
61,
21680,
953,
834,
4350,
834,
3891,
549,
17444,
427,
564,
3274,
96,
969,
52,
106,
873,
159,
121,
3430,
1293,
3,
2,
3,
22464,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
stimulated or basal c _ peptide > 0.3 ng / ml. | CREATE TABLE table_train_239 (
"id" int,
"basal_c_peptide" float,
"body_weight" float,
"renal_disease" bool,
"creatinine_clearance_cl" float,
"serum_creatinine" float,
"stimulated" bool,
"body_mass_index_bmi" float,
"NOUSE" float
) | SELECT * FROM table_train_239 WHERE stimulated = 1 OR basal_c_peptide > 0.3 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
9719,
834,
357,
3288,
41,
96,
23,
26,
121,
16,
17,
6,
96,
4883,
138,
834,
75,
834,
21826,
15,
121,
3,
12660,
6,
96,
6965,
834,
9378,
121,
3,
12660,
6,
96,
1536,
138,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
1429,
21680,
953,
834,
9719,
834,
357,
3288,
549,
17444,
427,
14954,
26,
3274,
209,
4674,
3905,
138,
834,
75,
834,
21826,
15,
2490,
3,
19997,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
How many parties won the election in the Louisiana 5 district? | CREATE TABLE table_18403 (
"District" text,
"Incumbent" text,
"Party" text,
"First elected" real,
"Result" text,
"Candidates" text
) | SELECT COUNT("Party") FROM table_18403 WHERE "District" = 'Louisiana 5' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
25987,
4928,
41,
96,
308,
23,
20066,
121,
1499,
6,
96,
1570,
75,
5937,
295,
121,
1499,
6,
96,
13725,
63,
121,
1499,
6,
96,
25171,
8160,
121,
490,
6,
96,
20119,
121,
1499,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
121,
13725,
63,
8512,
21680,
953,
834,
25987,
4928,
549,
17444,
427,
96,
308,
23,
20066,
121,
3274,
3,
31,
28365,
13662,
305,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
what is the date when ramon sessions (8) had the high assists, richard jefferson (29) had the high points and the score was w 107–78 (ot)? | CREATE TABLE table_name_32 (date VARCHAR, score VARCHAR, high_assists VARCHAR, high_points VARCHAR) | SELECT date FROM table_name_32 WHERE high_assists = "ramon sessions (8)" AND high_points = "richard jefferson (29)" AND score = "w 107–78 (ot)" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2668,
41,
5522,
584,
4280,
28027,
6,
2604,
584,
4280,
28027,
6,
306,
834,
6500,
7,
17,
7,
584,
4280,
28027,
6,
306,
834,
2700,
7,
584,
4280,
28027,
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,
833,
21680,
953,
834,
4350,
834,
2668,
549,
17444,
427,
306,
834,
6500,
7,
17,
7,
3274,
96,
2375,
106,
3975,
3,
28007,
121,
3430,
306,
834,
2700,
7,
3274,
96,
3723,
986,
528,
7010,
739,
4743,
11728,
121,
3430,
260... |
For those employees who do not work in departments with managers that have ids between 100 and 200, give me the comparison about employee_id over the email , and I want to order X-axis in descending order. | CREATE TABLE departments (
DEPARTMENT_ID decimal(4,0),
DEPARTMENT_NAME varchar(30),
MANAGER_ID decimal(6,0),
LOCATION_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 job_history (
EMPLOYEE_ID decimal(6,0),
START_DATE date,
END_DATE date,
JOB_ID varchar(10),
DEPARTMENT_ID decimal(4,0)
)
CREATE TABLE countries (
COUNTRY_ID varchar(2),
COUNTRY_NAME varchar(40),
REGION_ID decimal(10,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)
)
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)
) | SELECT EMAIL, EMPLOYEE_ID FROM employees WHERE NOT DEPARTMENT_ID IN (SELECT DEPARTMENT_ID FROM departments WHERE MANAGER_ID BETWEEN 100 AND 200) ORDER BY EMAIL DESC | [
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,
3,
20211,
3502,
6,
262,
5244,
5017,
476,
5080,
834,
4309,
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,
156... |
Score of 2-1, and a Competition of pl, and a Date of december 22, 2006 had what opponents? | CREATE TABLE table_name_84 (
opponents VARCHAR,
date VARCHAR,
score VARCHAR,
competition VARCHAR
) | SELECT opponents FROM table_name_84 WHERE score = "2-1" AND competition = "pl" AND date = "december 22, 2006" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4608,
41,
16383,
584,
4280,
28027,
6,
833,
584,
4280,
28027,
6,
2604,
584,
4280,
28027,
6,
2259,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
17763,
13,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
16383,
21680,
953,
834,
4350,
834,
4608,
549,
17444,
427,
2604,
3274,
96,
17234,
121,
3430,
2259,
3274,
96,
102,
40,
121,
3430,
833,
3274,
96,
221,
75,
18247,
12889,
3581,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
... |
provide the number of patients whose year of birth is less than 2109 and item id is 50902? | 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 COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.dob_year < "2109" AND lab.itemid = "50902" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
7744,
7,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
23,
1071,
21545,
834,
23,
26,
1499,
6,
2672,
834,
6137,
1499,
6,
2672,
1499,
6,
5403,
651,
834,
26,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
3388,
18206,
3,
15355,
3162,
7690,
9191,
14798,
5,
8399,
51,
834,
23,
26,
3274,
7690,
5,
8399,
51,
834,
23,
26,
549,
17444,... |
total destinations that been ended as of 2009 | CREATE TABLE table_203_323 (
id number,
"city" text,
"country" text,
"airport" text,
"begin" number,
"end" number
) | SELECT COUNT("city") FROM table_203_323 WHERE "end" <= 2009 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
23330,
834,
2668,
519,
41,
3,
23,
26,
381,
6,
96,
6726,
121,
1499,
6,
96,
17529,
121,
1499,
6,
96,
2256,
1493,
121,
1499,
6,
96,
346,
122,
77,
121,
381,
6,
96,
989,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0... | [
3,
23143,
14196,
2847,
17161,
599,
121,
6726,
8512,
21680,
953,
834,
23330,
834,
2668,
519,
549,
17444,
427,
96,
989,
121,
3,
2,
2423,
2464,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What team has a pick larger than 30, when the college is saginaw valley state? | CREATE TABLE table_63735 (
"Pick" real,
"Team" text,
"Player" text,
"Position" text,
"College" text
) | SELECT "Team" FROM table_63735 WHERE "Pick" > '30' AND "College" = 'saginaw valley state' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3891,
940,
2469,
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,
18699,
121,
21680,
953,
834,
3891,
940,
2469,
549,
17444,
427,
96,
345,
3142,
121,
2490,
3,
31,
1458,
31,
3430,
96,
9939,
7883,
121,
3274,
3,
31,
7,
9,
19604,
210,
10645,
538,
31,
1,
-100,
-100,
-100,
-100,
... |
What Position has a Round that's larger than 21? | CREATE TABLE table_name_86 (position VARCHAR, round INTEGER) | SELECT position FROM table_name_86 WHERE round > 21 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3840,
41,
4718,
584,
4280,
28027,
6,
1751,
3,
21342,
17966,
61,
3,
32102,
32103,
32101,
32103,
363,
14258,
65,
3,
9,
9609,
24,
31,
7,
2186,
145,
1401,
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,
1102,
21680,
953,
834,
4350,
834,
3840,
549,
17444,
427,
1751,
2490,
1401,
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... |
How many patients younger than 89 years were admitted to the hospital before 2195? | 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 COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.age < "89" AND demographic.admityear < "2195" | [
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,
545,
3,
2,
96,
3914,
121,
3430,
14798,
5,
20466,
17,
1201,
3,
2,
96,
2658,
3301,
121,
1,
-100,... |
what is the nationality of the ship appam? | CREATE TABLE table_name_24 (nationality VARCHAR, ship VARCHAR) | SELECT nationality FROM table_name_24 WHERE ship = "appam" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2266,
41,
16557,
485,
584,
4280,
28027,
6,
4383,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
125,
19,
8,
1157,
485,
13,
8,
4383,
1120,
265,
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,
1157,
485,
21680,
953,
834,
4350,
834,
2266,
549,
17444,
427,
4383,
3274,
96,
3096,
265,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is United States total in the year(s) won of 2000 , 2005 , 2006? | CREATE TABLE table_name_1 (total INTEGER, country VARCHAR, year_s__won VARCHAR) | SELECT MIN(total) FROM table_name_1 WHERE country = "united states" AND year_s__won = "2000 , 2005 , 2006" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
536,
41,
235,
1947,
3,
21342,
17966,
6,
684,
584,
4280,
28027,
6,
215,
834,
7,
834,
834,
210,
106,
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,
0... | [
3,
23143,
14196,
3,
17684,
599,
235,
1947,
61,
21680,
953,
834,
4350,
834,
536,
549,
17444,
427,
684,
3274,
96,
15129,
15,
26,
2315,
121,
3430,
215,
834,
7,
834,
834,
210,
106,
3274,
96,
13527,
3,
6,
3105,
3,
6,
3581,
121,
1,
... |
Name the revenue for eps being 8.9 | CREATE TABLE table_18304259_1 (revenue__£million_ VARCHAR, earnings_per_share__p_ VARCHAR) | SELECT revenue__£million_ FROM table_18304259_1 WHERE earnings_per_share__p_ = "8.9" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2606,
1458,
4165,
3390,
834,
536,
41,
60,
15098,
834,
834,
19853,
17030,
834,
584,
4280,
28027,
6,
8783,
834,
883,
834,
12484,
834,
834,
102,
834,
584,
4280,
28027,
61,
3,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
3751,
834,
834,
19853,
17030,
834,
21680,
953,
834,
2606,
1458,
4165,
3390,
834,
536,
549,
17444,
427,
8783,
834,
883,
834,
12484,
834,
834,
102,
834,
3274,
96,
927,
5,
1298,
121,
1,
-100,
-100,
-100,
-100,
-100,
-1... |
What's the Issue Date for an Eric Prydz song with a no available Download information? | CREATE TABLE table_name_89 (issue_date VARCHAR, download VARCHAR, artist VARCHAR) | SELECT issue_date FROM table_name_89 WHERE download = "no available" AND artist = "eric prydz" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3914,
41,
13159,
834,
5522,
584,
4280,
28027,
6,
946,
584,
4280,
28027,
6,
2377,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
31,
7,
8,
13235,
7678,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
962,
834,
5522,
21680,
953,
834,
4350,
834,
3914,
549,
17444,
427,
946,
3274,
96,
29,
32,
347,
121,
3430,
2377,
3274,
96,
15,
2234,
4880,
63,
26,
172,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
what is the number of patients whose gender is f and days of hospital stay is greater than 23? | 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 procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
) | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.gender = "F" AND demographic.days_stay > "23" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
7690,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
2118,
23,
26,
1499,
6,
5059,
715,
1499,
6,
5692,
1499,
6,
701,
834,
15129,
1499,
6,
3783,
1499,
6,
5798,
1499... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
549,
17444,
427,
14798,
5,
122,
3868,
3274,
96,
371,
121,
3430,
14798,
5,
1135,
7,
834,
21545,
2490,
96,
2773,
121,
1,
-100... |
What Opponent has an Attendance that is 26,880? | CREATE TABLE table_40859 (
"Week" real,
"Date" text,
"Opponent" text,
"Result" text,
"Attendance" text
) | SELECT "Opponent" FROM table_40859 WHERE "Attendance" = '26,880' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2445,
927,
3390,
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,
96,
667,
102,
9977,
121,
21680,
953,
834,
2445,
927,
3390,
549,
17444,
427,
96,
188,
17,
324,
26,
663,
121,
3274,
3,
31,
2688,
6,
927,
2079,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
A bar chart groups the lot details, and computes the number of each lot details. | CREATE TABLE Purchases (
purchase_transaction_id INTEGER,
purchase_details VARCHAR(255)
)
CREATE TABLE Transactions_Lots (
transaction_id INTEGER,
lot_id INTEGER
)
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 Ref_Transaction_Types (
transaction_type_code VARCHAR(10),
transaction_type_description VARCHAR(80)
) | SELECT lot_details, COUNT(lot_details) FROM Lots GROUP BY lot_details | [
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,
418,
834,
221,
5756,
7,
6,
2847,
17161,
599,
3171,
834,
221,
5756,
7,
61,
21680,
14868,
350,
4630,
6880,
272,
476,
418,
834,
221,
5756,
7,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
When is the last week that has a result of a w 34-21? | CREATE TABLE table_name_10 (week INTEGER, result VARCHAR) | SELECT MAX(week) FROM table_name_10 WHERE result = "w 34-21" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
1714,
41,
8041,
3,
21342,
17966,
6,
741,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
366,
19,
8,
336,
471,
24,
65,
3,
9,
741,
13,
3,
9,
3,
210,
6154... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4800,
4,
599,
8041,
61,
21680,
953,
834,
4350,
834,
1714,
549,
17444,
427,
741,
3274,
96,
210,
6154,
16539,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
How many incumbents are there in the georgia 8 district when the party is democratic? | CREATE TABLE table_2146 (
"District" text,
"Incumbent" text,
"Party" text,
"First elected" real,
"Result" text,
"Candidates" text
) | SELECT COUNT("Incumbent") FROM table_2146 WHERE "Party" = 'Democratic' AND "District" = 'Georgia 8' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2658,
4448,
41,
96,
308,
23,
20066,
121,
1499,
6,
96,
1570,
75,
5937,
295,
121,
1499,
6,
96,
13725,
63,
121,
1499,
6,
96,
25171,
8160,
121,
490,
6,
96,
20119,
121,
1499,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
121,
1570,
75,
5937,
295,
8512,
21680,
953,
834,
2658,
4448,
549,
17444,
427,
96,
13725,
63,
121,
3274,
3,
31,
19679,
447,
31,
3430,
96,
308,
23,
20066,
121,
3274,
3,
31,
517,
15,
1677,
23,
9,
... |
When did Orville H. Browning (r) succeed? | CREATE TABLE table_26648 (
"State (class)" text,
"Vacator" text,
"Reason for change" text,
"Successor" text,
"Date of successors formal installation" text
) | SELECT "Date of successors formal installation" FROM table_26648 WHERE "Successor" = 'Orville H. Browning (R)' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
357,
3539,
3707,
41,
96,
134,
4748,
41,
4057,
61,
121,
1499,
6,
96,
25203,
1016,
121,
1499,
6,
96,
1649,
9,
739,
21,
483,
121,
1499,
6,
96,
134,
17431,
24901,
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,
308,
342,
13,
22261,
7,
4727,
2545,
121,
21680,
953,
834,
357,
3539,
3707,
549,
17444,
427,
96,
134,
17431,
24901,
121,
3274,
3,
31,
7395,
1420,
454,
5,
3899,
53,
41,
448,
61,
31,
1,
-100,
-100,
-100,
-100,
... |
count the number of widow patients who have been diagnosed with late effect of unspecified injury. | CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
language text,
religion text,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear text
)
CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
) | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id WHERE demographic.marital_status = "WIDOWED" AND diagnoses.short_title = "Late effect injury NOS" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
18730,
7,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
447,
26,
1298,
834,
4978,
1499,
6,
710,
834,
21869,
1499,
6,
307,
834,
21869,
1499,
3,
61,
3,
32102,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
3388,
18206,
3,
15355,
3162,
18730,
7,
9191,
14798,
5,
8399,
51,
834,
23,
26,
3274,
18730,
7,
5,
8399,
51,
834,
23,
26,
5... |
Where is the airport located that has a 98.9% in use capacity? | CREATE TABLE table_name_51 (
location VARCHAR,
capacity_in_use VARCHAR
) | SELECT location FROM table_name_51 WHERE capacity_in_use = "98.9%" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
5553,
41,
1128,
584,
4280,
28027,
6,
2614,
834,
77,
834,
1074,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
2840,
19,
8,
3761,
1069,
24,
65,
3,
9,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
1128,
21680,
953,
834,
4350,
834,
5553,
549,
17444,
427,
2614,
834,
77,
834,
1074,
3274,
96,
3916,
5,
7561,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
Draw a bar chart about the distribution of meter_700 and ID , and order in asc by the names. | CREATE TABLE stadium (
ID int,
name text,
Capacity int,
City text,
Country text,
Opening_year int
)
CREATE TABLE event (
ID int,
Name text,
Stadium_ID int,
Year text
)
CREATE TABLE record (
ID int,
Result text,
Swimmer_ID int,
Event_ID int
)
CREATE TABLE swimmer (
ID int,
name text,
Nationality text,
meter_100 real,
meter_200 text,
meter_300 text,
meter_400 text,
meter_500 text,
meter_600 text,
meter_700 text,
Time text
) | SELECT meter_700, ID FROM swimmer ORDER BY meter_700 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
14939,
41,
4699,
16,
17,
6,
564,
1499,
6,
4000,
9,
6726,
16,
17,
6,
896,
1499,
6,
6993,
1499,
6,
20360,
834,
1201,
16,
17,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
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,
3,
4401,
834,
9295,
6,
4699,
21680,
27424,
4674,
11300,
272,
476,
3,
4401,
834,
9295,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
NAME THE OVERALL FOR THE OMAHA (USHL) CLUB TEAM | CREATE TABLE table_17202 (
"Round" real,
"Overall" real,
"Player" text,
"Position" text,
"Nationality" text,
"Club team" text
) | SELECT MIN("Overall") FROM table_17202 WHERE "Club team" = 'Omaha (USHL)' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2517,
19818,
41,
96,
448,
32,
1106,
121,
490,
6,
96,
23847,
1748,
121,
490,
6,
96,
15800,
49,
121,
1499,
6,
96,
345,
32,
7,
4749,
121,
1499,
6,
96,
24732,
485,
121,
149... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
3,
17684,
599,
121,
23847,
1748,
8512,
21680,
953,
834,
2517,
19818,
549,
17444,
427,
96,
254,
11158,
372,
121,
3274,
3,
31,
667,
51,
9,
1024,
41,
3063,
13641,
61,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What was the winning score in the tournament, ending with Birdie Kim as a runner-up? | CREATE TABLE table_1940012_2 (winning_score VARCHAR, runner_s__up VARCHAR) | SELECT winning_score FROM table_1940012_2 WHERE runner_s__up = "Birdie Kim" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2294,
5548,
2122,
834,
357,
41,
8163,
834,
7,
9022,
584,
4280,
28027,
6,
3,
10806,
834,
7,
834,
834,
413,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
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,
3447,
834,
7,
9022,
21680,
953,
834,
2294,
5548,
2122,
834,
357,
549,
17444,
427,
3,
10806,
834,
7,
834,
834,
413,
3274,
96,
279,
23,
52,
2498,
6777,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What is the smallest numbered episode in the series listed? | CREATE TABLE table_27547668_3 (_number INTEGER) | SELECT MIN(_number) FROM table_27547668_3 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2555,
5062,
3959,
3651,
834,
519,
41,
834,
5525,
1152,
3,
21342,
17966,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
3,
17924,
3,
22412,
5640,
16,
8,
939,
2616,
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,
3,
17684,
599,
834,
5525,
1152,
61,
21680,
953,
834,
2555,
5062,
3959,
3651,
834,
519,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What's the earliest year the new york giants lost at new meadowlands stadium? | CREATE TABLE table_name_31 (
year INTEGER,
loser VARCHAR,
location VARCHAR
) | SELECT MIN(year) FROM table_name_31 WHERE loser = "new york giants" AND location = "new meadowlands stadium" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3341,
41,
215,
3,
21342,
17966,
6,
2615,
52,
584,
4280,
28027,
6,
1128,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
31,
7,
8,
3,
16454,
215,
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,
3,
17684,
599,
1201,
61,
21680,
953,
834,
4350,
834,
3341,
549,
17444,
427,
2615,
52,
3274,
96,
5534,
25453,
6079,
7,
121,
3430,
1128,
3274,
96,
5534,
140,
9,
15198,
6347,
14939,
121,
1,
-100,
-100,
-100,
-100,
-100... |
Whose attendance was the highest when the team played Arsenal? | CREATE TABLE table_name_95 (
attendance INTEGER,
opponent VARCHAR
) | SELECT MAX(attendance) FROM table_name_95 WHERE opponent = "arsenal" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3301,
41,
11364,
3,
21342,
17966,
6,
15264,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
2645,
7,
15,
11364,
47,
8,
2030,
116,
8,
372,
1944,
22358,
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,
4800,
4,
599,
15116,
663,
61,
21680,
953,
834,
4350,
834,
3301,
549,
17444,
427,
15264,
3274,
96,
291,
7,
35,
138,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What are the years on the Jazz for the player who is a combo forward? | CREATE TABLE table_11537 (
"Player" text,
"Nationality" text,
"Position" text,
"Years for Jazz" text,
"School/Club Team" text
) | SELECT "Years for Jazz" FROM table_11537 WHERE "Position" = 'combo forward' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
15660,
4118,
41,
96,
15800,
49,
121,
1499,
6,
96,
24732,
485,
121,
1499,
6,
96,
345,
32,
7,
4749,
121,
1499,
6,
96,
476,
2741,
7,
21,
12313,
121,
1499,
6,
96,
29364,
87... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
476,
2741,
7,
21,
12313,
121,
21680,
953,
834,
15660,
4118,
549,
17444,
427,
96,
345,
32,
7,
4749,
121,
3274,
3,
31,
9763,
32,
1039,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
For what episode was the rating/share for 18-49 at 2.8/8 | CREATE TABLE table_25391981_20 (episode VARCHAR, rating VARCHAR) | SELECT episode FROM table_25391981_20 WHERE rating / SHARE(18 AS –49) = 2.8 / 8 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1828,
3288,
2294,
4959,
834,
1755,
41,
15,
102,
159,
32,
221,
584,
4280,
28027,
6,
5773,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
242,
125,
5640,
47,
8,
5773,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
5640,
21680,
953,
834,
1828,
3288,
2294,
4959,
834,
1755,
549,
17444,
427,
5773,
3,
87,
10046,
7451,
599,
2606,
6157,
3,
104,
3647,
61,
3274,
3,
19419,
3,
87,
505,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the fewest number of wins in the chart for Ayrton Senna? | CREATE TABLE table_name_1 (wins INTEGER, driver VARCHAR) | SELECT MIN(wins) FROM table_name_1 WHERE driver = "ayrton senna" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
536,
41,
3757,
7,
3,
21342,
17966,
6,
2535,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
360,
222,
381,
13,
9204,
16,
8,
5059,
21,
71,
63,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3,
17684,
599,
3757,
7,
61,
21680,
953,
834,
4350,
834,
536,
549,
17444,
427,
2535,
3274,
96,
9,
63,
17330,
3,
7,
35,
29,
9,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
how many first elected with district being north carolina 2 | CREATE TABLE table_1341930_33 (first_elected VARCHAR, district VARCHAR) | SELECT COUNT(first_elected) FROM table_1341930_33 WHERE district = "North Carolina 2" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
23747,
2294,
1458,
834,
4201,
41,
14672,
834,
19971,
584,
4280,
28027,
6,
3939,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
149,
186,
166,
8160,
28,
3939,
271,
3457,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2847,
17161,
599,
14672,
834,
19971,
61,
21680,
953,
834,
23747,
2294,
1458,
834,
4201,
549,
17444,
427,
3939,
3274,
96,
22969,
5089,
204,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What rank does the Singapore Cup of 0 (1) have? | CREATE TABLE table_44857 (
"Rank" real,
"Name" text,
"S-League" text,
"Singapore Cup" text,
"Singapore League Cup" text,
"AFC Cup" text,
"Total" text
) | SELECT MAX("Rank") FROM table_44857 WHERE "Singapore Cup" = '0 (1)' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
591,
3707,
3436,
41,
96,
22557,
121,
490,
6,
96,
23954,
121,
1499,
6,
96,
134,
18,
2796,
9,
5398,
121,
1499,
6,
96,
134,
53,
9,
21642,
3802,
121,
1499,
6,
96,
134,
53,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
22557,
8512,
21680,
953,
834,
591,
3707,
3436,
549,
17444,
427,
96,
134,
53,
9,
21642,
3802,
121,
3274,
3,
31,
632,
5637,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
what is the name when the type is freighter, nationality is united kingdom on 3 may 1940? | CREATE TABLE table_8467 (
"Name" text,
"Type" text,
"Nationality" text,
"Date" text,
"Displacement" text
) | SELECT "Name" FROM table_8467 WHERE "Type" = 'freighter' AND "Nationality" = 'united kingdom' AND "Date" = '3 may 1940' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4608,
3708,
41,
96,
23954,
121,
1499,
6,
96,
25160,
121,
1499,
6,
96,
24732,
485,
121,
1499,
6,
96,
308,
342,
121,
1499,
6,
96,
23664,
11706,
297,
121,
1499,
3,
61,
3,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
23954,
121,
21680,
953,
834,
4608,
3708,
549,
17444,
427,
96,
25160,
121,
3274,
3,
31,
89,
60,
2632,
49,
31,
3430,
96,
24732,
485,
121,
3274,
3,
31,
15129,
15,
26,
14740,
31,
3430,
96,
308,
342,
121,
3274,
3... |
What is Team when Qual 1 is 1:20.139? | CREATE TABLE table_49034 (
"Name" text,
"Team" text,
"Qual 1" text,
"Qual 2" text,
"Best" text
) | SELECT "Team" FROM table_49034 WHERE "Qual 1" = '1:20.139' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
591,
2394,
3710,
41,
96,
23954,
121,
1499,
6,
96,
18699,
121,
1499,
6,
96,
5991,
138,
209,
121,
1499,
6,
96,
5991,
138,
204,
121,
1499,
6,
96,
17278,
121,
1499,
3,
61,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0... | [
3,
23143,
14196,
96,
18699,
121,
21680,
953,
834,
591,
2394,
3710,
549,
17444,
427,
96,
5991,
138,
209,
121,
3274,
3,
31,
536,
10,
1755,
5,
24090,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Group by all acc road, show the school id and All_Games_Percent in a scatter plot. | CREATE TABLE basketball_match (
Team_ID int,
School_ID int,
Team_Name text,
ACC_Regular_Season text,
ACC_Percent text,
ACC_Home text,
ACC_Road text,
All_Games text,
All_Games_Percent int,
All_Home text,
All_Road text,
All_Neutral text
)
CREATE TABLE university (
School_ID int,
School text,
Location text,
Founded real,
Affiliation text,
Enrollment real,
Nickname text,
Primary_conference text
) | SELECT School_ID, ACC_Percent FROM basketball_match GROUP BY ACC_Road | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
8498,
834,
19515,
41,
2271,
834,
4309,
16,
17,
6,
1121,
834,
4309,
16,
17,
6,
2271,
834,
23954,
1499,
6,
3,
14775,
834,
17748,
4885,
834,
134,
15,
9,
739,
1499,
6,
3,
14775,
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,
1121,
834,
4309,
6,
3,
14775,
834,
12988,
3728,
21680,
8498,
834,
19515,
350,
4630,
6880,
272,
476,
3,
14775,
834,
448,
32,
9,
26,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
A bar chart showing how many representatives in each party. | CREATE TABLE representative (
Representative_ID int,
Name text,
State text,
Party text,
Lifespan text
)
CREATE TABLE election (
Election_ID int,
Representative_ID int,
Date text,
Votes real,
Vote_Percent real,
Seats real,
Place real
) | SELECT Party, COUNT(Party) FROM representative GROUP BY Party | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
6978,
41,
13517,
834,
4309,
16,
17,
6,
5570,
1499,
6,
1015,
1499,
6,
3450,
1499,
6,
2330,
7,
2837,
1499,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
4356,
41,
19488,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3450,
6,
2847,
17161,
599,
13725,
63,
61,
21680,
6978,
350,
4630,
6880,
272,
476,
3450,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What scores happened on February 9? | CREATE TABLE table_73551 (
"Game" real,
"Date" text,
"Opponent" text,
"Score" text,
"Location" text,
"Attendance" real,
"Record" text,
"Points" real
) | SELECT "Score" FROM table_73551 WHERE "Date" = 'February 9' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4552,
3769,
536,
41,
96,
23055,
121,
490,
6,
96,
308,
342,
121,
1499,
6,
96,
667,
102,
9977,
121,
1499,
6,
96,
134,
9022,
121,
1499,
6,
96,
434,
32,
75,
257,
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,
134,
9022,
121,
21680,
953,
834,
4552,
3769,
536,
549,
17444,
427,
96,
308,
342,
121,
3274,
3,
31,
31122,
668,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
have a bmi of less than the 90 percentile for age. | CREATE TABLE table_train_215 (
"id" int,
"hemoglobin_a1c_hba1c" float,
"hgba1c" float,
"estimated_glomerular_filtration_rate_egfr" int,
"kidney_disease" bool,
"body_mass_index_bmi" float,
"age" float,
"NOUSE" float
) | SELECT * FROM table_train_215 WHERE body_mass_index_bmi < 90 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
9719,
834,
357,
1808,
41,
96,
23,
26,
121,
16,
17,
6,
96,
6015,
32,
14063,
77,
834,
9,
536,
75,
834,
107,
115,
9,
536,
75,
121,
3,
12660,
6,
96,
107,
122,
115,
9,
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,
1429,
21680,
953,
834,
9719,
834,
357,
1808,
549,
17444,
427,
643,
834,
2754,
7,
834,
18288,
834,
115,
51,
23,
3,
2,
2777,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
What is the lowest value for Draws, when South West DFL is "Tyrendarra", and when Byes is greater than 0? | CREATE TABLE table_name_68 (draws INTEGER, south_west_dfl VARCHAR, byes VARCHAR) | SELECT MIN(draws) FROM table_name_68 WHERE south_west_dfl = "tyrendarra" AND byes > 0 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3651,
41,
19489,
7,
3,
21342,
17966,
6,
3414,
834,
12425,
834,
26,
89,
40,
584,
4280,
28027,
6,
57,
15,
7,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
3,
17684,
599,
19489,
7,
61,
21680,
953,
834,
4350,
834,
3651,
549,
17444,
427,
3414,
834,
12425,
834,
26,
89,
40,
3274,
96,
17,
63,
1536,
26,
10116,
121,
3430,
57,
15,
7,
2490,
3,
632,
1,
-100,
-100,
-100,
-100... |
Who was the celebrity who exited on day 13? | CREATE TABLE table_name_35 (celebrity VARCHAR, exited VARCHAR) | SELECT celebrity FROM table_name_35 WHERE exited = "day 13" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2469,
41,
75,
400,
2160,
17,
63,
584,
4280,
28027,
6,
7189,
15,
26,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
2645,
47,
8,
17086,
113,
7189,
15,
26,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
17086,
21680,
953,
834,
4350,
834,
2469,
549,
17444,
427,
7189,
15,
26,
3274,
96,
1135,
1179,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
Which Tournament has a 2009 of q1, and a 2008 of 1r? | CREATE TABLE table_name_28 (
tournament VARCHAR
) | SELECT tournament FROM table_name_28 WHERE 2009 = "q1" AND 2008 = "1r" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2577,
41,
5892,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
4073,
20502,
65,
3,
9,
2464,
13,
3,
1824,
4347,
11,
3,
9,
2628,
13,
209,
52,
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,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
5892,
21680,
953,
834,
4350,
834,
2577,
549,
17444,
427,
2464,
3274,
96,
1824,
536,
121,
3430,
2628,
3274,
96,
536,
52,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
Score of 108-85 is what lowest game? | CREATE TABLE table_5181 (
"Game" real,
"Date" text,
"Opponent" text,
"Score" text,
"Location" text,
"Record" text
) | SELECT MIN("Game") FROM table_5181 WHERE "Score" = '108-85' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
5553,
4959,
41,
96,
23055,
121,
490,
6,
96,
308,
342,
121,
1499,
6,
96,
667,
102,
9977,
121,
1499,
6,
96,
134,
9022,
121,
1499,
6,
96,
434,
32,
75,
257,
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,
3,
17684,
599,
121,
23055,
8512,
21680,
953,
834,
5553,
4959,
549,
17444,
427,
96,
134,
9022,
121,
3274,
3,
31,
16169,
18,
4433,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
Which name has a Lane of 7? | CREATE TABLE table_69880 (
"Rank" real,
"Lane" real,
"Name" text,
"Nationality" text,
"Time" text
) | SELECT "Name" FROM table_69880 WHERE "Lane" = '7' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3951,
927,
2079,
41,
96,
22557,
121,
490,
6,
96,
434,
152,
15,
121,
490,
6,
96,
23954,
121,
1499,
6,
96,
24732,
485,
121,
1499,
6,
96,
13368,
121,
1499,
3,
61,
3,
32102... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
96,
23954,
121,
21680,
953,
834,
3951,
927,
2079,
549,
17444,
427,
96,
434,
152,
15,
121,
3274,
3,
31,
940,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
What was the latest year that a Bardahl entrant had a Kurtis Kraft 500c chassis with no more than 0 points? | CREATE TABLE table_15040 (
"Year" real,
"Entrant" text,
"Chassis" text,
"Engine" text,
"Points" real
) | SELECT MAX("Year") FROM table_15040 WHERE "Chassis" = 'kurtis kraft 500c' AND "Entrant" = 'bardahl' AND "Points" < '0' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
12278,
2445,
41,
96,
476,
2741,
121,
490,
6,
96,
16924,
3569,
121,
1499,
6,
96,
3541,
6500,
7,
121,
1499,
6,
96,
31477,
121,
1499,
6,
96,
22512,
7,
121,
490,
3,
61,
3,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
4800,
4,
599,
121,
476,
2741,
8512,
21680,
953,
834,
12278,
2445,
549,
17444,
427,
96,
3541,
6500,
7,
121,
3274,
3,
31,
10923,
17,
159,
3,
11326,
2899,
75,
31,
3430,
96,
16924,
3569,
121,
3274,
3,
31,
1047,
26,
... |
How many flaps are there for the team march 3 racing (1-4) top speed racing team (5-12)? | CREATE TABLE table_25740774_1 (
f_laps VARCHAR,
team VARCHAR
) | SELECT COUNT(f_laps) FROM table_25740774_1 WHERE team = "March 3 Racing (1-4) Top Speed Racing team (5-12)" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1828,
4581,
4560,
4581,
834,
536,
41,
3,
89,
834,
8478,
7,
584,
4280,
28027,
6,
372,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
571,
186,
23050,
7,
33,
132,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0... | [
3,
23143,
14196,
2847,
17161,
599,
89,
834,
8478,
7,
61,
21680,
953,
834,
1828,
4581,
4560,
4581,
834,
536,
549,
17444,
427,
372,
3274,
96,
25019,
220,
16046,
41,
22840,
61,
2224,
9913,
16046,
372,
9209,
5947,
61,
121,
1,
-100,
-100... |
Show all distinct location names. | CREATE TABLE LOCATIONS (Location_Name VARCHAR) | SELECT DISTINCT Location_Name FROM LOCATIONS | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
3,
5017,
18911,
22164,
41,
434,
32,
75,
257,
834,
23954,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
3111,
66,
6746,
1128,
3056,
5,
1,
0,
0,
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,
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,
0... | [
3,
23143,
14196,
3,
15438,
25424,
6227,
10450,
834,
23954,
21680,
3,
5017,
18911,
22164,
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,
... |
Name the opponent for 12 may 2008 | CREATE TABLE table_21067 (
"Match" real,
"Date" text,
"Opponent" text,
"Venue" text,
"Result" text,
"Turbine goals" text,
"Attendance" real,
"Report" text
) | SELECT "Opponent" FROM table_21067 WHERE "Date" = '12 May 2008' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
15239,
3708,
41,
96,
329,
14547,
121,
490,
6,
96,
308,
342,
121,
1499,
6,
96,
667,
102,
9977,
121,
1499,
6,
96,
553,
35,
76,
15,
121,
1499,
6,
96,
20119,
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,
667,
102,
9977,
121,
21680,
953,
834,
15239,
3708,
549,
17444,
427,
96,
308,
342,
121,
3274,
3,
31,
2122,
932,
2628,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
What was Phil Mickelson's score to par? | CREATE TABLE table_name_20 (
to_par VARCHAR,
player VARCHAR
) | SELECT to_par FROM table_name_20 WHERE player = "phil mickelson" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
1755,
41,
12,
834,
1893,
584,
4280,
28027,
6,
1959,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8188,
25665,
3573,
106,
31,
7,
2604,
12,
260... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
12,
834,
1893,
21680,
953,
834,
4350,
834,
1755,
549,
17444,
427,
1959,
3274,
96,
18118,
1337,
15259,
739,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the maximum number of blocks where rebounds equal 35? | CREATE TABLE table_19722664_5 (blocks INTEGER, rebounds VARCHAR) | SELECT MAX(blocks) FROM table_19722664_5 WHERE rebounds = 35 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2294,
5865,
2688,
4389,
834,
755,
41,
10734,
7,
3,
21342,
17966,
6,
3,
23768,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
2411,
381,
13,
6438,
213,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
4800,
4,
599,
10734,
7,
61,
21680,
953,
834,
2294,
5865,
2688,
4389,
834,
755,
549,
17444,
427,
3,
23768,
3274,
3097,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Which school/club team has a player named Mark Sanford? | CREATE TABLE table_20092 (
"Name" text,
"Position" text,
"Number" real,
"School/Club Team" text,
"Season" text,
"Acquisition via" text
) | SELECT "School/Club Team" FROM table_20092 WHERE "Name" = 'Mark Sanford' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
16660,
357,
41,
96,
23954,
121,
1499,
6,
96,
345,
32,
7,
4749,
121,
1499,
6,
96,
567,
5937,
49,
121,
490,
6,
96,
29364,
87,
254,
11158,
2271,
121,
1499,
6,
96,
134,
15,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
29364,
87,
254,
11158,
2271,
121,
21680,
953,
834,
16660,
357,
549,
17444,
427,
96,
23954,
121,
3274,
3,
31,
19762,
1051,
2590,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
which station is located in edmonton | CREATE TABLE table_72496 (
"City" text,
"Station" text,
"Year acquired" real,
"Primary programming source" text,
"Other programming sources" text,
"Current status" text
) | SELECT "Station" FROM table_72496 WHERE "City" = 'Edmonton' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
940,
2266,
4314,
41,
96,
254,
485,
121,
1499,
6,
96,
134,
6821,
121,
1499,
6,
96,
476,
2741,
7347,
121,
490,
6,
96,
7855,
51,
1208,
6020,
1391,
121,
1499,
6,
96,
667,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
134,
6821,
121,
21680,
953,
834,
940,
2266,
4314,
549,
17444,
427,
96,
254,
485,
121,
3274,
3,
31,
427,
26,
4662,
106,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What stadium is located in Halifax? | CREATE TABLE table_name_48 (
stadium VARCHAR,
city VARCHAR
) | SELECT stadium FROM table_name_48 WHERE city = "halifax" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3707,
41,
14939,
584,
4280,
28027,
6,
690,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
14939,
19,
1069,
16,
31150,
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,
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,
14939,
21680,
953,
834,
4350,
834,
3707,
549,
17444,
427,
690,
3274,
96,
3828,
23,
11517,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What were the total Pints after 1957? | CREATE TABLE table_70884 (
"Year" real,
"Entrant" text,
"Chassis" text,
"Engine" text,
"Points" real
) | SELECT SUM("Points") FROM table_70884 WHERE "Year" > '1957' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2518,
4060,
591,
41,
96,
476,
2741,
121,
490,
6,
96,
16924,
3569,
121,
1499,
6,
96,
3541,
6500,
7,
121,
1499,
6,
96,
31477,
121,
1499,
6,
96,
22512,
7,
121,
490,
3,
61,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0... | [
3,
23143,
14196,
180,
6122,
599,
121,
22512,
7,
8512,
21680,
953,
834,
2518,
4060,
591,
549,
17444,
427,
96,
476,
2741,
121,
2490,
3,
31,
2294,
3436,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
What is the high silver total for nations with 3 golds and under 5 bronzes? | CREATE TABLE table_name_61 (silver INTEGER, gold VARCHAR, bronze VARCHAR) | SELECT MAX(silver) FROM table_name_61 WHERE gold = 3 AND bronze < 5 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4241,
41,
7,
173,
624,
3,
21342,
17966,
6,
2045,
584,
4280,
28027,
6,
13467,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
306,
4294,
792,
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,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
4800,
4,
599,
7,
173,
624,
61,
21680,
953,
834,
4350,
834,
4241,
549,
17444,
427,
2045,
3274,
220,
3430,
13467,
3,
2,
305,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
What is the first name of each student who is not allergic to any type of food? Count them in a bar chart, and list x-axis in ascending order please. | CREATE TABLE Has_Allergy (
StuID INTEGER,
Allergy VARCHAR(20)
)
CREATE TABLE Student (
StuID INTEGER,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE TABLE Allergy_Type (
Allergy VARCHAR(20),
AllergyType VARCHAR(20)
) | SELECT Fname, COUNT(Fname) FROM Student WHERE NOT StuID IN (SELECT T1.StuID FROM Has_Allergy AS T1 JOIN Allergy_Type AS T2 ON T1.Allergy = T2.Allergy WHERE T2.AllergyType = "food") GROUP BY Fname ORDER BY Fname | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
4498,
834,
6838,
49,
122,
63,
41,
3,
13076,
4309,
3,
21342,
17966,
6,
432,
49,
122,
63,
584,
4280,
28027,
599,
1755,
61,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
377,
4350,
6,
2847,
17161,
599,
371,
4350,
61,
21680,
6341,
549,
17444,
427,
4486,
3,
13076,
4309,
3388,
41,
23143,
14196,
332,
5411,
13076,
4309,
21680,
4498,
834,
6838,
49,
122,
63,
6157,
332,
536,
3,
15355,
3162,
... |
I want the points difference for points of 14 | CREATE TABLE table_name_29 (points_difference VARCHAR, points VARCHAR) | SELECT points_difference FROM table_name_29 WHERE points = 14 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3166,
41,
2700,
7,
834,
26,
99,
11788,
584,
4280,
28027,
6,
979,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
27,
241,
8,
979,
1750,
21,
979,
13,
968,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
979,
834,
26,
99,
11788,
21680,
953,
834,
4350,
834,
3166,
549,
17444,
427,
979,
3274,
968,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What position is associated with a Time of 20:39.171? | CREATE TABLE table_name_42 (
pos INTEGER,
time VARCHAR
) | SELECT AVG(pos) FROM table_name_42 WHERE time = "20:39.171" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4165,
41,
3,
2748,
3,
21342,
17966,
6,
97,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
1102,
19,
1968,
28,
3,
9,
2900,
13,
460,
10,
3288,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
71,
17217,
599,
2748,
61,
21680,
953,
834,
4350,
834,
4165,
549,
17444,
427,
97,
3274,
96,
1755,
10,
3288,
5,
2517,
536,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
How many patients diagnosed with crn ath atlg vn bps grft had abnormal/delta lab test results. | CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
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 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 diagnoses ON demographic.hadm_id = diagnoses.hadm_id INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE diagnoses.short_title = "Crn ath atlg vn bps grft" AND lab.flag = "delta" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
7744,
7,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
23,
1071,
21545,
834,
23,
26,
1499,
6,
2672,
834,
6137,
1499,
6,
2672,
1499,
6,
5403,
651,
834,
26,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
3388,
18206,
3,
15355,
3162,
18730,
7,
9191,
14798,
5,
8399,
51,
834,
23,
26,
3274,
18730,
7,
5,
8399,
51,
834,
23,
26,
3... |
What was the event when su rez ( tri ) w 16 6 was round of 32? | CREATE TABLE table_27294107_11 (
event VARCHAR,
round_of_32 VARCHAR
) | SELECT event FROM table_27294107_11 WHERE round_of_32 = "Suárez ( TRI ) W 16–6" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2555,
357,
4240,
18057,
834,
2596,
41,
605,
584,
4280,
28027,
6,
1751,
834,
858,
834,
2668,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
605,
116,
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,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
605,
21680,
953,
834,
2555,
357,
4240,
18057,
834,
2596,
549,
17444,
427,
1751,
834,
858,
834,
2668,
3274,
96,
134,
76,
2975,
2638,
41,
3,
16840,
3,
61,
549,
898,
104,
948,
121,
1,
-100,
-100,
-100,
-100,
-100,
-1... |
what is the minimum age of patients whose gender is female and ethnicity is black/haitian? | 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 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
) | SELECT MIN(demographic.age) FROM demographic WHERE demographic.gender = "F" AND demographic.ethnicity = "BLACK/HAITIAN" | [
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,
3,
17684,
599,
1778,
16587,
5,
545,
61,
21680,
14798,
549,
17444,
427,
14798,
5,
122,
3868,
3274,
96,
371,
121,
3430,
14798,
5,
15,
189,
2532,
485,
3274,
96,
8775,
15339,
87,
5478,
3177,
21758,
121,
1,
-100,
-100,
... |
What time has a Set 3 of 25 16? | CREATE TABLE table_name_14 (
time VARCHAR,
set_3 VARCHAR
) | SELECT time FROM table_name_14 WHERE set_3 = "25–16" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2534,
41,
97,
584,
4280,
28027,
6,
356,
834,
519,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
97,
65,
3,
9,
2821,
220,
13,
944,
898,
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,
97,
21680,
953,
834,
4350,
834,
2534,
549,
17444,
427,
356,
834,
519,
3274,
96,
1828,
104,
2938,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
What is the name of the episode that had 9.89 million U.S. viewers? | CREATE TABLE table_24648983_1 (title VARCHAR, us_viewers__million_ VARCHAR) | SELECT title FROM table_24648983_1 WHERE us_viewers__million_ = "9.89" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2266,
4389,
3914,
4591,
834,
536,
41,
21869,
584,
4280,
28027,
6,
178,
834,
4576,
277,
834,
834,
17030,
834,
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,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2233,
21680,
953,
834,
2266,
4389,
3914,
4591,
834,
536,
549,
17444,
427,
178,
834,
4576,
277,
834,
834,
17030,
834,
3274,
96,
8797,
3914,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
What is the Total of the Player with a To par of 4? | CREATE TABLE table_name_8 (total VARCHAR, to_par VARCHAR) | SELECT COUNT(total) FROM table_name_8 WHERE to_par = 4 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
927,
41,
235,
1947,
584,
4280,
28027,
6,
12,
834,
1893,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
9273,
13,
8,
12387,
28,
3,
9,
304,
260... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2847,
17161,
599,
235,
1947,
61,
21680,
953,
834,
4350,
834,
927,
549,
17444,
427,
12,
834,
1893,
3274,
314,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
Network of nbc is what digital channel? | CREATE TABLE table_name_31 (
digital_channel VARCHAR,
network VARCHAR
) | SELECT digital_channel FROM table_name_31 WHERE network = "nbc" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3341,
41,
1125,
834,
19778,
584,
4280,
28027,
6,
1229,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
3426,
13,
3,
29,
115,
75,
19,
125,
1125,
4245,
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,
1125,
834,
19778,
21680,
953,
834,
4350,
834,
3341,
549,
17444,
427,
1229,
3274,
96,
29,
115,
75,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
Return a scatter chart about the correlation between CID and DNO . | CREATE TABLE Enrolled_in (
StuID INTEGER,
CID VARCHAR(7),
Grade VARCHAR(2)
)
CREATE TABLE Faculty (
FacID INTEGER,
Lname VARCHAR(15),
Fname VARCHAR(15),
Rank VARCHAR(15),
Sex VARCHAR(1),
Phone INTEGER,
Room VARCHAR(5),
Building VARCHAR(13)
)
CREATE TABLE Student (
StuID INTEGER,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE TABLE Member_of (
FacID INTEGER,
DNO INTEGER,
Appt_Type VARCHAR(15)
)
CREATE TABLE Course (
CID VARCHAR(7),
CName VARCHAR(40),
Credits INTEGER,
Instructor INTEGER,
Days VARCHAR(5),
Hours VARCHAR(11),
DNO INTEGER
)
CREATE TABLE Gradeconversion (
lettergrade VARCHAR(2),
gradepoint FLOAT
)
CREATE TABLE Department (
DNO INTEGER,
Division VARCHAR(2),
DName VARCHAR(25),
Room VARCHAR(5),
Building VARCHAR(13),
DPhone INTEGER
)
CREATE TABLE Minor_in (
StuID INTEGER,
DNO INTEGER
) | SELECT CID, DNO FROM Course ORDER BY Credits | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
695,
10671,
834,
77,
41,
3,
13076,
4309,
3,
21342,
17966,
6,
205,
4309,
584,
4280,
28027,
24358,
6,
13027,
584,
4280,
28027,
16426,
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,
205,
4309,
6,
309,
7400,
21680,
8670,
4674,
11300,
272,
476,
6529,
7,
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,
... |
What is the average wins of a team with more than 0 ples and less than 3 podiums? | CREATE TABLE table_name_12 (wins INTEGER, poles VARCHAR, podiums VARCHAR) | SELECT AVG(wins) FROM table_name_12 WHERE poles > 0 AND podiums < 3 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2122,
41,
3757,
7,
3,
21342,
17966,
6,
11148,
7,
584,
4280,
28027,
6,
22828,
7,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
1348,
9204,
13,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0... | [
3,
23143,
14196,
71,
17217,
599,
3757,
7,
61,
21680,
953,
834,
4350,
834,
2122,
549,
17444,
427,
11148,
7,
2490,
3,
632,
3430,
22828,
7,
3,
2,
220,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
what was the last year that no competition was held at the australian open ? | CREATE TABLE table_203_719 (
id number,
"year" number,
"australian open" text,
"french open" text,
"wimbledon" text,
"us open" text
) | SELECT MAX("year") FROM table_203_719 WHERE "australian open" = 'no competition' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
23330,
834,
940,
2294,
41,
3,
23,
26,
381,
6,
96,
1201,
121,
381,
6,
96,
402,
3109,
9928,
539,
121,
1499,
6,
96,
89,
60,
5457,
539,
121,
1499,
6,
96,
210,
603,
2296,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1201,
8512,
21680,
953,
834,
23330,
834,
940,
2294,
549,
17444,
427,
96,
402,
3109,
9928,
539,
121,
3274,
3,
31,
29,
32,
2259,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the title of the film with production number 1553, directed by Friz Freleng? | CREATE TABLE table_name_10 (title VARCHAR, director VARCHAR, production_number VARCHAR) | SELECT title FROM table_name_10 WHERE director = "friz freleng" AND production_number = 1553 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
1714,
41,
21869,
584,
4280,
28027,
6,
2090,
584,
4280,
28027,
6,
999,
834,
5525,
1152,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
2233,
13,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2233,
21680,
953,
834,
4350,
834,
1714,
549,
17444,
427,
2090,
3274,
96,
89,
13266,
2515,
400,
1725,
121,
3430,
999,
834,
5525,
1152,
3274,
627,
4867,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
How many years was the pageant miss globe international and delegate was karen loren medrano agustin? | CREATE TABLE table_1825751_14 (
year VARCHAR,
pageant VARCHAR,
delegate VARCHAR
) | SELECT COUNT(year) FROM table_1825751_14 WHERE pageant = "Miss Globe International" AND delegate = "Karen Loren Medrano Agustin" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2606,
1828,
3072,
536,
834,
2534,
41,
215,
584,
4280,
28027,
6,
543,
288,
584,
4280,
28027,
6,
20,
8791,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
571,
186,
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,
2847,
17161,
599,
1201,
61,
21680,
953,
834,
2606,
1828,
3072,
536,
834,
2534,
549,
17444,
427,
543,
288,
3274,
96,
329,
159,
7,
20790,
1331,
121,
3430,
20,
8791,
3274,
96,
439,
9,
1536,
8410,
35,
8067,
2002,
32,
... |
Which week's game was attended by 33,057 people? | CREATE TABLE table_name_48 (week VARCHAR, attendance VARCHAR) | SELECT week FROM table_name_48 WHERE attendance = "33,057" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3707,
41,
8041,
584,
4280,
28027,
6,
11364,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
4073,
471,
31,
7,
467,
47,
5526,
57,
5400,
6,
632,
3436,
151,
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,
471,
21680,
953,
834,
4350,
834,
3707,
549,
17444,
427,
11364,
3274,
96,
4201,
6,
632,
3436,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
which health insurance does the patient morgan mcgee have? | 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 demographic.insurance FROM demographic WHERE demographic.name = "Morgan Mcgee" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
4293,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
447,
26,
1298,
834,
4978,
1499,
6,
710,
834,
21869,
1499,
6,
307,
834,
21869,
1499,
3,
61,
3,
32102,
32103... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
14798,
5,
29441,
21680,
14798,
549,
17444,
427,
14798,
5,
4350,
3274,
96,
329,
11127,
3038,
397,
15,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Which Rank has a Silver of 1, and a Gold of 0, and a Nation of austria? | CREATE TABLE table_name_13 (rank VARCHAR, nation VARCHAR, silver VARCHAR, gold VARCHAR) | SELECT rank FROM table_name_13 WHERE silver = 1 AND gold = 0 AND nation = "austria" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2368,
41,
6254,
584,
4280,
28027,
6,
2982,
584,
4280,
28027,
6,
4294,
584,
4280,
28027,
6,
2045,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
4073,
3,
2255... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
11003,
21680,
953,
834,
4350,
834,
2368,
549,
17444,
427,
4294,
3274,
209,
3430,
2045,
3274,
3,
632,
3430,
2982,
3274,
96,
402,
23387,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
Which Poles have a position of 4th? | CREATE TABLE table_name_63 (
poles VARCHAR,
position VARCHAR
) | SELECT poles FROM table_name_63 WHERE position = "4th" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3891,
41,
11148,
7,
584,
4280,
28027,
6,
1102,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
4073,
19418,
7,
43,
3,
9,
1102,
13,
314,
189,
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,
11148,
7,
21680,
953,
834,
4350,
834,
3891,
549,
17444,
427,
1102,
3274,
96,
591,
189,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
How many professors are teaching class with code ACCT-211? | CREATE TABLE CLASS (PROF_NUM VARCHAR, CRS_CODE VARCHAR) | SELECT COUNT(DISTINCT PROF_NUM) FROM CLASS WHERE CRS_CODE = "ACCT-211" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
3,
31598,
41,
17618,
371,
834,
567,
6122,
584,
4280,
28027,
6,
205,
5249,
834,
5911,
5596,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
571,
186,
5812,
7,
33,
2119,
853,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
6828,
371,
834,
567,
6122,
61,
21680,
3,
31598,
549,
17444,
427,
205,
5249,
834,
5911,
5596,
3274,
96,
14775,
382,
18,
27278,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
What did the away team score when playing South Melbourne? | CREATE TABLE table_name_44 (away_team VARCHAR, home_team VARCHAR) | SELECT away_team AS score FROM table_name_44 WHERE home_team = "south melbourne" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3628,
41,
8006,
834,
11650,
584,
4280,
28027,
6,
234,
834,
11650,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
410,
8,
550,
372,
2604,
116,
1556,
1013... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
550,
834,
11650,
6157,
2604,
21680,
953,
834,
4350,
834,
3628,
549,
17444,
427,
234,
834,
11650,
3274,
96,
7,
670,
107,
3,
2341,
26255,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.