NATURAL_LANG stringlengths 0 446 | SCHEMA stringlengths 27 2.21k | SQL stringlengths 18 453 | input_ids list | attention_mask list | labels list |
|---|---|---|---|---|---|
When dxzb-tv is the call sign what is the power kw? | CREATE TABLE table_23394920_1 (power_kw VARCHAR, callsign VARCHAR) | SELECT power_kw FROM table_23394920_1 WHERE callsign = "DXZB-TV" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
20879,
4240,
27749,
834,
536,
41,
6740,
834,
157,
210,
584,
4280,
28027,
6,
580,
6732,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
366,
3,
26,
226,
172,
115,
18,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
579,
834,
157,
210,
21680,
953,
834,
20879,
4240,
27749,
834,
536,
549,
17444,
427,
580,
6732,
3274,
96,
308,
4,
956,
279,
18,
4562,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What is the nationality of the athlete with a time of 2:12.56? | CREATE TABLE table_name_80 (
nationality VARCHAR,
time VARCHAR
) | SELECT nationality FROM table_name_80 WHERE time = "2:12.56" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2079,
41,
1157,
485,
584,
4280,
28027,
6,
97,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
1157,
485,
13,
8,
17893,
28,
3,
9,
97,
13,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
1157,
485,
21680,
953,
834,
4350,
834,
2079,
549,
17444,
427,
97,
3274,
96,
357,
10,
9368,
4834,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
How many average wins does bruce fleisher have? | CREATE TABLE table_10370 (
"Rank" real,
"Player" text,
"Country" text,
"Earnings( $ )" real,
"Wins" real
) | SELECT AVG("Wins") FROM table_10370 WHERE "Player" = 'bruce fleisher' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1714,
22520,
41,
96,
22557,
121,
490,
6,
96,
15800,
49,
121,
1499,
6,
96,
10628,
651,
121,
1499,
6,
96,
427,
291,
29,
53,
7,
599,
1514,
3,
61,
121,
490,
6,
96,
18455,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
71,
17217,
599,
121,
18455,
7,
8512,
21680,
953,
834,
1714,
22520,
549,
17444,
427,
96,
15800,
49,
121,
3274,
3,
31,
9052,
565,
8079,
1273,
49,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
What's the season number of the episode directed by Dan Attias? | CREATE TABLE table_13755296_1 (
season__number INTEGER,
directed_by VARCHAR
) | SELECT MIN(season__number) FROM table_13755296_1 WHERE directed_by = "Dan Attias" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2368,
3072,
5373,
4314,
834,
536,
41,
774,
834,
834,
5525,
1152,
3,
21342,
17966,
6,
6640,
834,
969,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
31,
7,
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,
9476,
834,
834,
5525,
1152,
61,
21680,
953,
834,
2368,
3072,
5373,
4314,
834,
536,
549,
17444,
427,
6640,
834,
969,
3274,
96,
308,
152,
486,
17,
23,
9,
7,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,... |
Who is the home team in the game where South Melbourne was the away team? | CREATE TABLE table_name_20 (home_team VARCHAR, away_team VARCHAR) | SELECT home_team AS score FROM table_name_20 WHERE away_team = "south melbourne" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
1755,
41,
5515,
834,
11650,
584,
4280,
28027,
6,
550,
834,
11650,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
2645,
19,
8,
234,
372,
16,
8,
467,
213,
10... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
234,
834,
11650,
6157,
2604,
21680,
953,
834,
4350,
834,
1755,
549,
17444,
427,
550,
834,
11650,
3274,
96,
7,
670,
107,
3,
2341,
26255,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
How many numbers of dances for place 1? | CREATE TABLE table_26375386_28 (
number_of_dances VARCHAR,
place VARCHAR
) | SELECT COUNT(number_of_dances) FROM table_26375386_28 WHERE place = 1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2688,
22954,
519,
3840,
834,
2577,
41,
381,
834,
858,
834,
26,
663,
7,
584,
4280,
28027,
6,
286,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
571,
186,
2302,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2847,
17161,
599,
5525,
1152,
834,
858,
834,
26,
663,
7,
61,
21680,
953,
834,
2688,
22954,
519,
3840,
834,
2577,
549,
17444,
427,
286,
3274,
209,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What's the most jim colbert got paid? | CREATE TABLE table_10369 (
"Rank" real,
"Player" text,
"Country" text,
"Earnings( $ )" real,
"Wins" real
) | SELECT MAX("Earnings( $ )") FROM table_10369 WHERE "Player" = 'jim colbert' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
17864,
3951,
41,
96,
22557,
121,
490,
6,
96,
15800,
49,
121,
1499,
6,
96,
10628,
651,
121,
1499,
6,
96,
427,
291,
29,
53,
7,
599,
1514,
3,
61,
121,
490,
6,
96,
18455,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
4800,
4,
599,
121,
427,
291,
29,
53,
7,
599,
1514,
3,
61,
8512,
21680,
953,
834,
17864,
3951,
549,
17444,
427,
96,
15800,
49,
121,
3274,
3,
31,
354,
603,
7632,
7041,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What is the south with ev lindau as the west and svg burgkirchen as the east? | CREATE TABLE table_name_24 (
south VARCHAR,
west VARCHAR,
east VARCHAR
) | SELECT south FROM table_name_24 WHERE west = "ev lindau" AND east = "svg burgkirchen" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2266,
41,
3414,
584,
4280,
28027,
6,
4653,
584,
4280,
28027,
6,
5727,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
3414,
28,
3,
15,
208,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0... | [
3,
23143,
14196,
3414,
21680,
953,
834,
4350,
834,
2266,
549,
17444,
427,
4653,
3274,
96,
15,
208,
3,
9230,
402,
121,
3430,
5727,
3274,
96,
7,
208,
122,
3,
4824,
16089,
29,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What was the date of the tournament with a clay surface and an opponent of Irina Falconi? | CREATE TABLE table_name_43 (
date VARCHAR,
surface VARCHAR,
opponent VARCHAR
) | SELECT date FROM table_name_43 WHERE surface = "clay" AND opponent = "irina falconi" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4906,
41,
833,
584,
4280,
28027,
6,
1774,
584,
4280,
28027,
6,
15264,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
833,
13,
8,
5892,
28,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
833,
21680,
953,
834,
4350,
834,
4906,
549,
17444,
427,
1774,
3274,
96,
4651,
63,
121,
3430,
15264,
3274,
96,
23,
52,
77,
9,
12553,
1018,
23,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
Return a bar chart about the distribution of All_Neutral and All_Games_Percent , rank by the X in ascending. | 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 All_Neutral, All_Games_Percent FROM basketball_match ORDER BY All_Neutral | [
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,
432,
834,
26288,
8792,
6,
432,
834,
23055,
7,
834,
12988,
3728,
21680,
8498,
834,
19515,
4674,
11300,
272,
476,
432,
834,
26288,
8792,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What is the format of the album with a year less than 1992? | CREATE TABLE table_name_58 (format VARCHAR, year INTEGER) | SELECT format FROM table_name_58 WHERE year < 1992 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3449,
41,
8995,
584,
4280,
28027,
6,
215,
3,
21342,
17966,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
1910,
13,
8,
2306,
28,
3,
9,
215,
705,
145,
9047,
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... | [
3,
23143,
14196,
1910,
21680,
953,
834,
4350,
834,
3449,
549,
17444,
427,
215,
3,
2,
9047,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
what is the number of patients whose insurance is private and diagnoses short title is candidal vulvovaginitis? | 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
)
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 WHERE demographic.insurance = "Private" AND diagnoses.short_title = "Candidal vulvovaginitis" | [
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... |
What couple has an average of 17.2? | CREATE TABLE table_20424140_3 (couple VARCHAR, average VARCHAR) | SELECT couple FROM table_20424140_3 WHERE average = "17.2" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
26363,
2266,
22012,
834,
519,
41,
15976,
109,
584,
4280,
28027,
6,
1348,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
1158,
65,
46,
1348,
13,
11030,
357,
58,
1,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
1158,
21680,
953,
834,
26363,
2266,
22012,
834,
519,
549,
17444,
427,
1348,
3274,
96,
536,
25791,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
what is the enrollment for the Cavaliers? | CREATE TABLE table_16432543_3 (enrollment INTEGER, nickname VARCHAR) | SELECT MAX(enrollment) FROM table_16432543_3 WHERE nickname = "Cavaliers" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2938,
4906,
1828,
4906,
834,
519,
41,
35,
4046,
297,
3,
21342,
17966,
6,
24649,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
125,
19,
8,
17938,
21,
8,
17655,
138,
4... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
4800,
4,
599,
35,
4046,
297,
61,
21680,
953,
834,
2938,
4906,
1828,
4906,
834,
519,
549,
17444,
427,
24649,
3274,
96,
254,
9,
2165,
4518,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
what is the number of last names listed that have an english origin ? | CREATE TABLE table_203_573 (
id number,
"name" text,
"rank - 2000" number,
"number" number,
"country of origin" text,
"england - 2001" text
) | SELECT COUNT("name") FROM table_203_573 WHERE "country of origin" = 'england' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
23330,
834,
3436,
519,
41,
3,
23,
26,
381,
6,
96,
4350,
121,
1499,
6,
96,
6254,
3,
18,
2766,
121,
381,
6,
96,
5525,
1152,
121,
381,
6,
96,
17529,
13,
5233,
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,
4350,
8512,
21680,
953,
834,
23330,
834,
3436,
519,
549,
17444,
427,
96,
17529,
13,
5233,
121,
3274,
3,
31,
4606,
40,
232,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What was the date of the Circuit of Indianapolis? | CREATE TABLE table_name_83 (date VARCHAR, circuit VARCHAR) | SELECT date FROM table_name_83 WHERE circuit = "indianapolis" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4591,
41,
5522,
584,
4280,
28027,
6,
4558,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
833,
13,
8,
17007,
13,
23385,
58,
1,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
833,
21680,
953,
834,
4350,
834,
4591,
549,
17444,
427,
4558,
3274,
96,
77,
8603,
9,
15621,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
What position is listed for the nebraska team? | CREATE TABLE table_name_75 (position VARCHAR, school_club_team VARCHAR) | SELECT position FROM table_name_75 WHERE school_club_team = "nebraska" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3072,
41,
4718,
584,
4280,
28027,
6,
496,
834,
13442,
834,
11650,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
1102,
19,
2616,
21,
8,
3,
29,
15,
193... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
1102,
21680,
953,
834,
4350,
834,
3072,
549,
17444,
427,
496,
834,
13442,
834,
11650,
3274,
96,
29,
15,
1939,
10717,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What was the entrant in round 16 were Ferrari was the constructor? | CREATE TABLE table_name_70 (
entrant VARCHAR,
rounds VARCHAR,
constructor VARCHAR
) | SELECT entrant FROM table_name_70 WHERE rounds = "16" AND constructor = "ferrari" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2518,
41,
3,
295,
3569,
584,
4280,
28027,
6,
14419,
584,
4280,
28027,
6,
6774,
127,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
3,
295,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3,
295,
3569,
21680,
953,
834,
4350,
834,
2518,
549,
17444,
427,
14419,
3274,
96,
2938,
121,
3430,
6774,
127,
3274,
96,
1010,
52,
1665,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What was the largest index the year/s forcible rapes numbered 1084? | CREATE TABLE table_27495 (
"Year" real,
"Population" real,
"Index" real,
"Violent" real,
"Property" real,
"Murder" real,
"Forcible rape" real,
"Robbery" real,
"Aggravated assault" real,
"Burglary" real,
"Larceny Theft" real,
"Vehicle Theft" real
) | SELECT MAX("Index") FROM table_27495 WHERE "Forcible rape" = '1084' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2555,
591,
3301,
41,
96,
476,
2741,
121,
490,
6,
96,
27773,
7830,
121,
490,
6,
96,
26267,
226,
121,
490,
6,
96,
553,
23,
32,
6987,
121,
490,
6,
96,
3174,
883,
17,
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,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
4800,
4,
599,
121,
26267,
226,
8512,
21680,
953,
834,
2555,
591,
3301,
549,
17444,
427,
96,
3809,
75,
2317,
3,
5846,
15,
121,
3274,
3,
31,
1714,
4608,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
Show the name of each party and the corresponding number of delegates from that party. Plot them as bar chart. | CREATE TABLE election (
Election_ID int,
Counties_Represented text,
District int,
Delegate text,
Party int,
First_Elected real,
Committee text
)
CREATE TABLE party (
Party_ID int,
Year real,
Party text,
Governor text,
Lieutenant_Governor text,
Comptroller text,
Attorney_General text,
US_Senate text
)
CREATE TABLE county (
County_Id int,
County_name text,
Population real,
Zip_code text
) | SELECT T2.Party, SUM(COUNT(*)) FROM election AS T1 JOIN party AS T2 ON T1.Party = T2.Party_ID GROUP BY T2.Party | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
4356,
41,
19488,
834,
4309,
16,
17,
6,
3,
10628,
725,
834,
1649,
12640,
15,
26,
1499,
6,
3570,
16,
17,
6,
374,
8791,
1499,
6,
3450,
16,
17,
6,
1485,
834,
21543,
15,
26,
490,
6,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
332,
4416,
13725,
63,
6,
180,
6122,
599,
5911,
17161,
599,
1935,
61,
61,
21680,
4356,
6157,
332,
536,
3,
15355,
3162,
1088,
6157,
332,
357,
9191,
332,
5411,
13725,
63,
3274,
332,
4416,
13725,
63,
834,
4309,
350,
463... |
What's the greatest losses for those with more than 13 wins? | CREATE TABLE table_61971 (
"Golden Rivers" text,
"Wins" real,
"Byes" real,
"Losses" real,
"Draws" real,
"Against" real
) | SELECT MAX("Losses") FROM table_61971 WHERE "Wins" > '13' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4241,
4327,
536,
41,
96,
23576,
35,
2473,
7,
121,
1499,
6,
96,
18455,
7,
121,
490,
6,
96,
279,
10070,
121,
490,
6,
96,
434,
13526,
7,
121,
490,
6,
96,
308,
10936,
7,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
4800,
4,
599,
121,
434,
13526,
7,
8512,
21680,
953,
834,
4241,
4327,
536,
549,
17444,
427,
96,
18455,
7,
121,
2490,
3,
31,
2368,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What's the 2007 result when 2003 is a? | CREATE TABLE table_name_83 (Id VARCHAR) | SELECT 2007 FROM table_name_83 WHERE 2003 = "a" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4591,
41,
196,
26,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
31,
7,
8,
4101,
741,
116,
3888,
19,
3,
9,
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,
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,
4101,
21680,
953,
834,
4350,
834,
4591,
549,
17444,
427,
3888,
3274,
96,
9,
121,
1,
-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 Population where the Median House-hold Income is $25,016? | CREATE TABLE table_39543 (
"Rank" real,
"Place" text,
"County" text,
"Per Capita Income" text,
"Median House- hold Income" text,
"Median Family Income" text,
"Population" real,
"Number of Households" real
) | SELECT MIN("Population") FROM table_39543 WHERE "Median House- hold Income" = '$25,016' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
519,
3301,
4906,
41,
96,
22557,
121,
490,
6,
96,
345,
11706,
121,
1499,
6,
96,
10628,
63,
121,
1499,
6,
96,
12988,
4000,
155,
9,
20110,
121,
1499,
6,
96,
24607,
29,
1384,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
27773,
7830,
8512,
21680,
953,
834,
519,
3301,
4906,
549,
17444,
427,
96,
24607,
29,
1384,
18,
1520,
20110,
121,
3274,
3,
31,
3229,
1828,
6,
632,
2938,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What are the distinct cross reference source system codes which are related to the master customer details 'Gottlieb, Becker and Wyman'? | CREATE TABLE customer_master_index (master_customer_id VARCHAR, cmi_details VARCHAR); CREATE TABLE cmi_cross_references (source_system_code VARCHAR, master_customer_id VARCHAR) | SELECT DISTINCT T2.source_system_code FROM customer_master_index AS T1 JOIN cmi_cross_references AS T2 ON T1.master_customer_id = T2.master_customer_id WHERE T1.cmi_details = 'Gottlieb , Becker and Wyman' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
884,
834,
7429,
834,
18288,
41,
7429,
834,
25697,
49,
834,
23,
26,
584,
4280,
28027,
6,
2446,
23,
834,
221,
5756,
7,
584,
4280,
28027,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
33... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
332,
4416,
7928,
834,
3734,
834,
4978,
21680,
884,
834,
7429,
834,
18288,
6157,
332,
536,
3,
15355,
3162,
2446,
23,
834,
11465,
834,
60,
11788,
7,
6157,
332,
357,
9191,
332,
5411,
7429,
834,
2... |
Find the names of stadiums that the most swimmers have been to. | CREATE TABLE event (
id number,
name text,
stadium_id number,
year text
)
CREATE TABLE swimmer (
id number,
name text,
nationality text,
meter_100 number,
meter_200 text,
meter_300 text,
meter_400 text,
meter_500 text,
meter_600 text,
meter_700 text,
time text
)
CREATE TABLE stadium (
id number,
name text,
capacity number,
city text,
country text,
opening_year number
)
CREATE TABLE record (
id number,
result text,
swimmer_id number,
event_id number
) | SELECT t3.name FROM record AS t1 JOIN event AS t2 ON t1.event_id = t2.id JOIN stadium AS t3 ON t3.id = t2.stadium_id GROUP BY t2.stadium_id ORDER BY COUNT(*) DESC LIMIT 1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
605,
41,
3,
23,
26,
381,
6,
564,
1499,
6,
14939,
834,
23,
26,
381,
6,
215,
1499,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
27424,
41,
3,
23,
26,
381,
6,
564,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
17,
5787,
4350,
21680,
1368,
6157,
3,
17,
536,
3,
15355,
3162,
605,
6157,
3,
17,
357,
9191,
3,
17,
5411,
15,
2169,
834,
23,
26,
3274,
3,
17,
4416,
23,
26,
3,
15355,
3162,
14939,
6157,
3,
17,
519,
9191,
3,
... |
What is the least amount in each season? | CREATE TABLE table_29273390_1 (no_in_season INTEGER) | SELECT MIN(no_in_season) FROM table_29273390_1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3166,
2555,
4201,
2394,
834,
536,
41,
29,
32,
834,
77,
834,
9476,
3,
21342,
17966,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
709,
866,
16,
284,
774,
58,
3,
1,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
3,
17684,
599,
29,
32,
834,
77,
834,
9476,
61,
21680,
953,
834,
3166,
2555,
4201,
2394,
834,
536,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the netflix code where the series and episode are 4-11? | CREATE TABLE table_15187735_4 (netflix VARCHAR, series_ep VARCHAR) | SELECT netflix FROM table_15187735_4 WHERE series_ep = "4-11" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
26578,
27697,
2469,
834,
591,
41,
1582,
89,
17591,
584,
4280,
28027,
6,
939,
834,
15,
102,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
3134,
89,
17591,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3134,
89,
17591,
21680,
953,
834,
26578,
27697,
2469,
834,
591,
549,
17444,
427,
939,
834,
15,
102,
3274,
96,
591,
9169,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
What is Country, when Total is less than 148, and when Player is "Gary Player"? | CREATE TABLE table_name_19 (country VARCHAR, total VARCHAR, player VARCHAR) | SELECT country FROM table_name_19 WHERE total < 148 AND player = "gary player" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2294,
41,
17529,
584,
4280,
28027,
6,
792,
584,
4280,
28027,
6,
1959,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
6993,
6,
116,
9273,
19,
705,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
684,
21680,
953,
834,
4350,
834,
2294,
549,
17444,
427,
792,
3,
2,
3,
24748,
3430,
1959,
3274,
96,
1478,
63,
1959,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What is the total average for Rank entries where the Lane listed is smaller than 4 and the Nationality listed is San Marino? | CREATE TABLE table_79305 (
"Rank" real,
"Lane" real,
"Athlete" text,
"Nationality" text,
"Time" real,
"React" real
) | SELECT AVG("Rank") FROM table_79305 WHERE "Lane" < '4' AND "Nationality" = 'san marino' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4440,
26724,
41,
96,
22557,
121,
490,
6,
96,
434,
152,
15,
121,
490,
6,
96,
188,
189,
1655,
15,
121,
1499,
6,
96,
24732,
485,
121,
1499,
6,
96,
13368,
121,
490,
6,
96,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
71,
17217,
599,
121,
22557,
8512,
21680,
953,
834,
4440,
26724,
549,
17444,
427,
96,
434,
152,
15,
121,
3,
2,
3,
31,
591,
31,
3430,
96,
24732,
485,
121,
3274,
3,
31,
7,
152,
3,
12181,
32,
31,
1,
-100,
-100,
-1... |
For the 1999 w210 e-class , 2000 w203 c-class, what is the stroke? | CREATE TABLE table_21021796_1 (
stroke VARCHAR,
applications VARCHAR
) | SELECT stroke FROM table_21021796_1 WHERE applications = "1999 W210 E-Class , 2000 W203 C-Class" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
357,
14388,
2517,
4314,
834,
536,
41,
9529,
584,
4280,
28027,
6,
1564,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
242,
8,
5247,
3,
210,
15239,
3,
15,
18,
4057,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0... | [
3,
23143,
14196,
9529,
21680,
953,
834,
357,
14388,
2517,
4314,
834,
536,
549,
17444,
427,
1564,
3274,
96,
2294,
3264,
549,
15239,
262,
18,
21486,
3,
6,
2766,
549,
23330,
205,
18,
21486,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
How many share values are listed for the episode with a rating/share value of 2.6/8? | CREATE TABLE table_17525955_2 (share VARCHAR, rating VARCHAR) | SELECT COUNT(share) FROM table_17525955_2 WHERE rating / SHARE(18 AS –49) = 2.6 / 8 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2517,
5373,
3390,
3769,
834,
357,
41,
12484,
584,
4280,
28027,
6,
5773,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
571,
186,
698,
2620,
33,
2616,
21,
8,
5640,
28,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2847,
17161,
599,
12484,
61,
21680,
953,
834,
2517,
5373,
3390,
3769,
834,
357,
549,
17444,
427,
5773,
3,
87,
10046,
7451,
599,
2606,
6157,
3,
104,
3647,
61,
3274,
3,
22724,
3,
87,
505,
1,
-100,
-100,
-100,
-100,
... |
What is the total number of Week(s), when Attendance is 61,603? | CREATE TABLE table_name_23 (week VARCHAR, attendance VARCHAR) | SELECT COUNT(week) FROM table_name_23 WHERE attendance = "61,603" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2773,
41,
8041,
584,
4280,
28027,
6,
11364,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
792,
381,
13,
6551,
599,
7,
201,
116,
22497,
663,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2847,
17161,
599,
8041,
61,
21680,
953,
834,
4350,
834,
2773,
549,
17444,
427,
11364,
3274,
96,
4241,
6,
3328,
519,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
How many districts does william b. oliver represent? | CREATE TABLE table_18680 (
"District" text,
"Incumbent" text,
"Party" text,
"First elected" real,
"Result" text,
"Candidates" text
) | SELECT COUNT("District") FROM table_18680 WHERE "Incumbent" = 'William B. Oliver' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
25398,
2079,
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,
308,
23,
20066,
8512,
21680,
953,
834,
25398,
2079,
549,
17444,
427,
96,
1570,
75,
5937,
295,
121,
3274,
3,
31,
518,
1092,
23,
265,
272,
5,
15865,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
... |
get the number of male patients who have unspecified pleural effusion diagnoses. | CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
)
CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
language text,
religion text,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear text
) | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id WHERE demographic.gender = "M" AND diagnoses.long_title = "Unspecified pleural effusion" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
4293,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
447,
26,
1298,
834,
4978,
1499,
6,
710,
834,
21869,
1499,
6,
307,
834,
21869,
1499,
3,
61,
3,
32102,
32103... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
3388,
18206,
3,
15355,
3162,
18730,
7,
9191,
14798,
5,
8399,
51,
834,
23,
26,
3274,
18730,
7,
5,
8399,
51,
834,
23,
26,
5... |
What is the total when the nation is brazil (bra) and bronze is more than 2? | CREATE TABLE table_name_38 (
total INTEGER,
nation VARCHAR,
bronze VARCHAR
) | SELECT SUM(total) FROM table_name_38 WHERE nation = "brazil (bra)" AND bronze > 2 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3747,
41,
792,
3,
21342,
17966,
6,
2982,
584,
4280,
28027,
6,
13467,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
792,
116,
8,
2982,
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,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
180,
6122,
599,
235,
1947,
61,
21680,
953,
834,
4350,
834,
3747,
549,
17444,
427,
2982,
3274,
96,
1939,
702,
40,
41,
1939,
61,
121,
3430,
13467,
2490,
204,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
what is the date when saros is more than 124, the type is total, the magnitude is more than 1.0535 and the time (greatest) is 20:55:28? | CREATE TABLE table_name_21 (
date VARCHAR,
time__greatest_ VARCHAR,
magnitude VARCHAR,
saros VARCHAR,
type VARCHAR
) | SELECT date FROM table_name_21 WHERE saros > 124 AND type = "total" AND magnitude > 1.0535 AND time__greatest_ = "20:55:28" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2658,
41,
833,
584,
4280,
28027,
6,
97,
834,
834,
20288,
222,
834,
584,
4280,
28027,
6,
20722,
584,
4280,
28027,
6,
3,
7,
9,
1859,
584,
4280,
28027,
6,
686,
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,
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,
2658,
549,
17444,
427,
3,
7,
9,
1859,
2490,
3,
22504,
3430,
686,
3274,
96,
235,
1947,
121,
3430,
20722,
2490,
1300,
3076,
2469,
3430,
97,
834,
834,
20288,
222,
834,
3274,
96,
1755,
... |
Which airport has IATA of BKK? | CREATE TABLE table_5955 (
"City" text,
"State/Territory" text,
"Country" text,
"IATA" text,
"ICAO" text,
"Airport" text
) | SELECT "Airport" FROM table_5955 WHERE "IATA" = 'bkk' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3390,
3769,
41,
96,
254,
485,
121,
1499,
6,
96,
134,
4748,
87,
382,
21301,
10972,
121,
1499,
6,
96,
10628,
651,
121,
1499,
6,
96,
196,
19282,
121,
1499,
6,
96,
15038,
667... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
20162,
1493,
121,
21680,
953,
834,
3390,
3769,
549,
17444,
427,
96,
196,
19282,
121,
3274,
3,
31,
115,
8511,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
provide the number of patients who were admitted before the year 2195 had 78659 as the diagnosis icd9 code. | 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 procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
) | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id WHERE demographic.admityear < "2195" AND diagnoses.icd9_code = "78659" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
14798,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
564,
1499,
6,
2774,
1947,
834,
8547,
302,
1499,
6,
1246,
1499,
6,
103,
115,
1499,
6,
7285,
1499,
6,
1612,
14... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
3388,
18206,
3,
15355,
3162,
18730,
7,
9191,
14798,
5,
8399,
51,
834,
23,
26,
3274,
18730,
7,
5,
8399,
51,
834,
23,
26,
5... |
Find the name of the ships that have more than one captain. | CREATE TABLE ship (
name VARCHAR,
ship_id VARCHAR
)
CREATE TABLE captain (
ship_id VARCHAR
) | SELECT t1.name FROM ship AS t1 JOIN captain AS t2 ON t1.ship_id = t2.ship_id GROUP BY t2.ship_id HAVING COUNT(*) > 1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
4383,
41,
564,
584,
4280,
28027,
6,
4383,
834,
23,
26,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
14268,
41,
4383,
834,
23,
26,
584,
4280,
28027,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0... | [
3,
23143,
14196,
3,
17,
5411,
4350,
21680,
4383,
6157,
3,
17,
536,
3,
15355,
3162,
14268,
6157,
3,
17,
357,
9191,
3,
17,
5411,
2009,
834,
23,
26,
3274,
3,
17,
4416,
2009,
834,
23,
26,
350,
4630,
6880,
272,
476,
3,
17,
4416,
20... |
Which location has a capacity larger than 52,000? | CREATE TABLE table_name_94 (location VARCHAR, capacity INTEGER) | SELECT location FROM table_name_94 WHERE capacity > 52 OFFSET 000 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4240,
41,
14836,
584,
4280,
28027,
6,
2614,
3,
21342,
17966,
61,
3,
32102,
32103,
32101,
32103,
4073,
1128,
65,
3,
9,
2614,
2186,
145,
305,
8630,
58,
1,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
1128,
21680,
953,
834,
4350,
834,
4240,
549,
17444,
427,
2614,
2490,
9065,
3,
15316,
20788,
6078,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
other than the united states , what other nationality were the submarines ? | CREATE TABLE table_203_268 (
id number,
"date" text,
"name" text,
"nationality" text,
"tonnage\n(grt)" number,
"fate" text
) | SELECT DISTINCT "nationality" FROM table_203_268 WHERE "nationality" <> 'united states' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
23330,
834,
357,
3651,
41,
3,
23,
26,
381,
6,
96,
5522,
121,
1499,
6,
96,
4350,
121,
1499,
6,
96,
16557,
485,
121,
1499,
6,
96,
17,
106,
9761,
2,
29,
599,
122,
52,
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,
15438,
25424,
6227,
96,
16557,
485,
121,
21680,
953,
834,
23330,
834,
357,
3651,
549,
17444,
427,
96,
16557,
485,
121,
3,
2,
3155,
3,
31,
15129,
15,
26,
2315,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
Who is the president representing the Creuse department? | CREATE TABLE table_name_10 (
président VARCHAR,
départment__or_collectivity_ VARCHAR
) | SELECT président FROM table_name_10 WHERE départment__or_collectivity_ = "creuse" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
1714,
41,
10613,
584,
4280,
28027,
6,
12173,
297,
834,
834,
127,
834,
22153,
10696,
834,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
2645,
19,
8,
2753,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
10613,
21680,
953,
834,
4350,
834,
1714,
549,
17444,
427,
12173,
297,
834,
834,
127,
834,
22153,
10696,
834,
3274,
96,
5045,
1074,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Find the name and partition id for users who tweeted less than twice. | CREATE TABLE user_profiles (
name VARCHAR,
partitionid VARCHAR,
uid VARCHAR
)
CREATE TABLE tweets (
uid VARCHAR
) | SELECT T1.name, T1.partitionid FROM user_profiles AS T1 JOIN tweets AS T2 ON T1.uid = T2.uid GROUP BY T2.uid HAVING COUNT(*) < 2 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
1139,
834,
18816,
7,
41,
564,
584,
4280,
28027,
6,
16540,
23,
26,
584,
4280,
28027,
6,
3,
76,
23,
26,
584,
4280,
28027,
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,
332,
5411,
4350,
6,
332,
5411,
2274,
4749,
23,
26,
21680,
1139,
834,
18816,
7,
6157,
332,
536,
3,
15355,
3162,
10657,
7,
6157,
332,
357,
9191,
332,
5411,
76,
23,
26,
3274,
332,
4416,
76,
23,
26,
350,
4630,
6880,
... |
Who was the Republican candidate against the Democratic candidate Arthur Levitt? | CREATE TABLE table_name_65 (republican_ticket VARCHAR, democratic_ticket VARCHAR) | SELECT republican_ticket FROM table_name_65 WHERE democratic_ticket = "arthur levitt" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4122,
41,
60,
15727,
152,
834,
26639,
584,
4280,
28027,
6,
15053,
834,
26639,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
2645,
47,
8,
8994,
4775,
581,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
20237,
152,
834,
26639,
21680,
953,
834,
4350,
834,
4122,
549,
17444,
427,
15053,
834,
26639,
3274,
96,
10702,
450,
90,
5566,
17,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
Which team had the fastest lap of 1:13.516? | CREATE TABLE table_name_47 (winning_team VARCHAR, fastest_lap VARCHAR) | SELECT winning_team FROM table_name_47 WHERE fastest_lap = "1:13.516" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4177,
41,
8163,
834,
11650,
584,
4280,
28027,
6,
10391,
834,
8478,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
4073,
372,
141,
8,
10391,
14941,
13,
19520,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
3447,
834,
11650,
21680,
953,
834,
4350,
834,
4177,
549,
17444,
427,
10391,
834,
8478,
3274,
96,
536,
10,
536,
9285,
2938,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
Which ceremony has the best lyricist category? | CREATE TABLE table_name_67 (
ceremony VARCHAR,
category VARCHAR
) | SELECT ceremony FROM table_name_67 WHERE category = "best lyricist" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3708,
41,
7252,
584,
4280,
28027,
6,
3295,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
4073,
7252,
65,
8,
200,
3,
120,
2234,
343,
3295,
58,
1,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
7252,
21680,
953,
834,
4350,
834,
3708,
549,
17444,
427,
3295,
3274,
96,
9606,
3,
120,
2234,
343,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
Which college has a Pick # 1, Overall more than one, and Round is 7? | CREATE TABLE table_name_34 (
college VARCHAR,
round VARCHAR,
pick__number VARCHAR,
overall VARCHAR
) | SELECT college FROM table_name_34 WHERE pick__number = 1 AND overall > 1 AND round = 7 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3710,
41,
1900,
584,
4280,
28027,
6,
1751,
584,
4280,
28027,
6,
1432,
834,
834,
5525,
1152,
584,
4280,
28027,
6,
1879,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0... | [
3,
23143,
14196,
1900,
21680,
953,
834,
4350,
834,
3710,
549,
17444,
427,
1432,
834,
834,
5525,
1152,
3274,
209,
3430,
1879,
2490,
209,
3430,
1751,
3274,
489,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Who wrote 'pocket pussy'? | CREATE TABLE table_3663 (
"Series #" real,
"Title" text,
"Directed by" text,
"Written by" text,
"Original air date" text,
"U.S. viewers (millions)" text
) | SELECT "Written by" FROM table_3663 WHERE "Title" = 'Pocket Pussy' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
3420,
3891,
41,
96,
12106,
7,
1713,
121,
490,
6,
96,
382,
155,
109,
121,
1499,
6,
96,
23620,
15,
26,
57,
121,
1499,
6,
96,
24965,
324,
57,
121,
1499,
6,
96,
667,
3380,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
24965,
324,
57,
121,
21680,
953,
834,
3420,
3891,
549,
17444,
427,
96,
382,
155,
109,
121,
3274,
3,
31,
345,
3961,
15,
17,
5004,
7,
7,
63,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
how many films were directed by sridhar after the year 1961 ? | CREATE TABLE table_203_204 (
id number,
"year" number,
"film" text,
"language" text,
"actors" text,
"music" text,
"banner" text,
"note" text
) | SELECT COUNT("film") FROM table_203_204 WHERE "year" > 1961 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
23330,
834,
26363,
41,
3,
23,
26,
381,
6,
96,
1201,
121,
381,
6,
96,
9988,
121,
1499,
6,
96,
24925,
121,
1499,
6,
96,
9,
5317,
7,
121,
1499,
6,
96,
22170,
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,
9988,
8512,
21680,
953,
834,
23330,
834,
26363,
549,
17444,
427,
96,
1201,
121,
2490,
21018,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
What was the grid for suspension time/retired? | CREATE TABLE table_77870 (
"Driver" text,
"Constructor" text,
"Laps" real,
"Time/Retired" text,
"Grid" real
) | SELECT "Grid" FROM table_77870 WHERE "Time/Retired" = 'suspension' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
940,
3940,
2518,
41,
96,
20982,
52,
121,
1499,
6,
96,
4302,
7593,
127,
121,
1499,
6,
96,
3612,
102,
7,
121,
490,
6,
96,
13368,
87,
1649,
11809,
26,
121,
1499,
6,
96,
13... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
13313,
26,
121,
21680,
953,
834,
940,
3940,
2518,
549,
17444,
427,
96,
13368,
87,
1649,
11809,
26,
121,
3274,
3,
31,
7,
302,
3208,
1938,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
how many of the female patients had sdh as the primary disease? | CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
)
CREATE TABLE 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 COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.gender = "F" AND demographic.diagnosis = "SDH" | [
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,
122,
3868,
3274,
96,
371,
121,
3430,
14798,
5,
25930,
4844,
159,
3274,
96,
134,
15538,
121,
1,
-... |
Which Position has an Against of 32, and a Difference of 18, and a Drawn larger than 4? | CREATE TABLE table_40264 (
"Position" real,
"Team" text,
"Points" real,
"Played" real,
"Drawn" real,
"Lost" real,
"Against" real,
"Difference" text
) | SELECT SUM("Position") FROM table_40264 WHERE "Against" = '32' AND "Difference" = '18' AND "Drawn" > '4' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2445,
26755,
41,
96,
345,
32,
7,
4749,
121,
490,
6,
96,
18699,
121,
1499,
6,
96,
22512,
7,
121,
490,
6,
96,
15800,
15,
26,
121,
490,
6,
96,
308,
10936,
29,
121,
490,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
180,
6122,
599,
121,
345,
32,
7,
4749,
8512,
21680,
953,
834,
2445,
26755,
549,
17444,
427,
96,
20749,
121,
3274,
3,
31,
2668,
31,
3430,
96,
308,
99,
11788,
121,
3274,
3,
31,
2606,
31,
3430,
96,
308,
10936,
29,
... |
Which Years in Orlando has a Nationality of united states, and a Player of doug overton? | CREATE TABLE table_name_43 (years_in_orlando VARCHAR, nationality VARCHAR, player VARCHAR) | SELECT years_in_orlando FROM table_name_43 WHERE nationality = "united states" AND player = "doug overton" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4906,
41,
1201,
7,
834,
77,
834,
32,
7721,
32,
584,
4280,
28027,
6,
1157,
485,
584,
4280,
28027,
6,
1959,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
40... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
203,
834,
77,
834,
32,
7721,
32,
21680,
953,
834,
4350,
834,
4906,
549,
17444,
427,
1157,
485,
3274,
96,
15129,
15,
26,
2315,
121,
3430,
1959,
3274,
96,
26,
1063,
122,
147,
17,
106,
121,
1,
-100,
-100,
-100,
-100,... |
Which teams were in the 2006-07 season? | CREATE TABLE table_name_41 (
teams VARCHAR,
season VARCHAR
) | SELECT teams FROM table_name_41 WHERE season = "2006-07" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4853,
41,
2323,
584,
4280,
28027,
6,
774,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
4073,
2323,
130,
16,
8,
3581,
18,
4560,
774,
58,
1,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2323,
21680,
953,
834,
4350,
834,
4853,
549,
17444,
427,
774,
3274,
96,
21196,
18,
4560,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Which nation has total medals under 63, less than 2 silver, more than 2 bronze, and a rank of 8? | CREATE TABLE table_name_69 (
nation VARCHAR,
rank VARCHAR,
bronze VARCHAR,
total VARCHAR,
silver VARCHAR
) | SELECT nation FROM table_name_69 WHERE total < 63 AND silver < 2 AND bronze > 2 AND rank = "8" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3951,
41,
2982,
584,
4280,
28027,
6,
11003,
584,
4280,
28027,
6,
13467,
584,
4280,
28027,
6,
792,
584,
4280,
28027,
6,
4294,
584,
4280,
28027,
3,
61,
3,
32102,
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,
2982,
21680,
953,
834,
4350,
834,
3951,
549,
17444,
427,
792,
3,
2,
3,
3891,
3430,
4294,
3,
2,
204,
3430,
13467,
2490,
204,
3430,
11003,
3274,
96,
927,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What was the winning time in 1984? | CREATE TABLE table_name_99 (time VARCHAR, year VARCHAR) | SELECT time FROM table_name_99 WHERE year = "1984" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3264,
41,
715,
584,
4280,
28027,
6,
215,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
3447,
97,
16,
13480,
58,
1,
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,
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,
97,
21680,
953,
834,
4350,
834,
3264,
549,
17444,
427,
215,
3274,
96,
24151,
20364,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
When Chloe was number 8, Olivia was number 2, Emma was number 1, and Ava was number 4, who was number 5? | CREATE TABLE table_name_76 (
no_5 VARCHAR,
no_4 VARCHAR,
no_1 VARCHAR,
no_8 VARCHAR,
no_2 VARCHAR
) | SELECT no_5 FROM table_name_76 WHERE no_8 = "chloe" AND no_2 = "olivia" AND no_1 = "emma" AND no_4 = "ava" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3959,
41,
150,
834,
755,
584,
4280,
28027,
6,
150,
834,
591,
584,
4280,
28027,
6,
150,
834,
536,
584,
4280,
28027,
6,
150,
834,
927,
584,
4280,
28027,
6,
150,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
150,
834,
755,
21680,
953,
834,
4350,
834,
3959,
549,
17444,
427,
150,
834,
927,
3274,
96,
524,
40,
32,
15,
121,
3430,
150,
834,
357,
3274,
96,
4172,
5907,
121,
3430,
150,
834,
536,
3274,
96,
15,
635,
9,
121,
34... |
What is the earliest year when action was the genre? | CREATE TABLE table_64967 (
"Year" real,
"Game" text,
"Genre" text,
"Platform(s)" text,
"Developer(s)" text
) | SELECT MIN("Year") FROM table_64967 WHERE "Genre" = 'action' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
948,
3647,
3708,
41,
96,
476,
2741,
121,
490,
6,
96,
23055,
121,
1499,
6,
96,
13714,
60,
121,
1499,
6,
96,
10146,
2032,
599,
7,
61,
121,
1499,
6,
96,
2962,
162,
8745,
4... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
3,
17684,
599,
121,
476,
2741,
8512,
21680,
953,
834,
948,
3647,
3708,
549,
17444,
427,
96,
13714,
60,
121,
3274,
3,
31,
4787,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
give me the number of patients discharged to skilled nursing facility who were hospitalized for more than 20 days. | CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
language text,
religion text,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear text
)
CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
) | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.discharge_location = "SNF" AND demographic.days_stay > "20" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
18730,
7,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
3,
447,
26,
1298,
834,
4978,
1499,
6,
710,
834,
21869,
1499,
6,
307,
834,
21869,
1499,
3,
61,
3,
32102,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
549,
17444,
427,
14798,
5,
26,
159,
7993,
834,
14836,
3274,
96,
134,
12619,
121,
3430,
14798,
5,
1135,
7,
834,
21545,
2490,
... |
What meet had a 400m individual medley meet? | CREATE TABLE table_13132 (
"Event" text,
"Time" text,
"Nationality" text,
"Date" text,
"Meet" text,
"Location" text
) | SELECT "Meet" FROM table_13132 WHERE "Event" = '400m individual medley' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
22048,
2668,
41,
96,
427,
2169,
121,
1499,
6,
96,
13368,
121,
1499,
6,
96,
24732,
485,
121,
1499,
6,
96,
308,
342,
121,
1499,
6,
96,
329,
15,
15,
17,
121,
1499,
6,
96,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
329,
15,
15,
17,
121,
21680,
953,
834,
22048,
2668,
549,
17444,
427,
96,
427,
2169,
121,
3274,
3,
31,
5548,
51,
928,
3,
2726,
1306,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
return me the journals, which have papers by ' H. V. Jagadish ' . | CREATE TABLE publication_keyword (
kid int,
pid int
)
CREATE TABLE keyword (
keyword varchar,
kid int
)
CREATE TABLE publication (
abstract varchar,
cid int,
citation_num int,
jid int,
pid int,
reference_num int,
title varchar,
year int
)
CREATE TABLE conference (
cid int,
homepage varchar,
name varchar
)
CREATE TABLE domain (
did int,
name varchar
)
CREATE TABLE writes (
aid int,
pid int
)
CREATE TABLE organization (
continent varchar,
homepage varchar,
name varchar,
oid int
)
CREATE TABLE domain_author (
aid int,
did int
)
CREATE TABLE domain_conference (
cid int,
did int
)
CREATE TABLE domain_keyword (
did int,
kid int
)
CREATE TABLE cite (
cited int,
citing int
)
CREATE TABLE author (
aid int,
homepage varchar,
name varchar,
oid int
)
CREATE TABLE domain_journal (
did int,
jid int
)
CREATE TABLE domain_publication (
did int,
pid int
)
CREATE TABLE journal (
homepage varchar,
jid int,
name varchar
) | SELECT journal.name FROM author, journal, publication, writes WHERE author.name = 'H. V. Jagadish' AND publication.jid = journal.jid AND writes.aid = author.aid AND writes.pid = publication.pid | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
5707,
834,
4397,
6051,
41,
4984,
16,
17,
6,
3,
12417,
16,
17,
3,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
15693,
41,
15693,
3,
4331,
4059,
6,
4984,
16,
17,
3,
61,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
6378,
5,
4350,
21680,
2291,
6,
6378,
6,
5707,
6,
11858,
549,
17444,
427,
2291,
5,
4350,
3274,
3,
31,
566,
5,
584,
5,
21520,
9,
26,
1273,
31,
3430,
5707,
5,
354,
23,
26,
3274,
6378,
5,
354,
23,
26,
3430,
11858,... |
What is To par, when Country is 'United States', and when Player is 'Jay Haas'? | CREATE TABLE table_61998 (
"Place" text,
"Player" text,
"Country" text,
"Score" text,
"To par" text,
"Money ( $ )" real
) | SELECT "To par" FROM table_61998 WHERE "Country" = 'united states' AND "Player" = 'jay haas' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
948,
2294,
3916,
41,
96,
345,
11706,
121,
1499,
6,
96,
15800,
49,
121,
1499,
6,
96,
10628,
651,
121,
1499,
6,
96,
134,
9022,
121,
1499,
6,
96,
3696,
260,
121,
1499,
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,
3696,
260,
121,
21680,
953,
834,
948,
2294,
3916,
549,
17444,
427,
96,
10628,
651,
121,
3274,
3,
31,
15129,
15,
26,
2315,
31,
3430,
96,
15800,
49,
121,
3274,
3,
31,
1191,
63,
4244,
9,
7,
31,
1,
-100,
-100,
... |
What number episode in the series is the episode 'things that fly'? | CREATE TABLE table_18777 (
"Series Number" real,
"Season Number" real,
"Episode Title" text,
"Premiere Date" text,
"Production Code" real
) | SELECT MAX("Series Number") FROM table_18777 WHERE "Episode Title" = 'Things That Fly' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2606,
26225,
41,
96,
12106,
7,
7720,
121,
490,
6,
96,
134,
15,
9,
739,
7720,
121,
490,
6,
96,
427,
102,
159,
32,
221,
11029,
121,
1499,
6,
96,
10572,
2720,
60,
7678,
12... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
12106,
7,
7720,
8512,
21680,
953,
834,
2606,
26225,
549,
17444,
427,
96,
427,
102,
159,
32,
221,
11029,
121,
3274,
3,
31,
8991,
53,
7,
466,
8223,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
Who was the guest on 24.11.07 when the result was 0:1 at 16:00? | CREATE TABLE table_name_25 (guest VARCHAR, time VARCHAR, date VARCHAR, result VARCHAR) | SELECT guest FROM table_name_25 WHERE date = "24.11.07" AND result = "0:1" AND time = "16:00" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
1828,
41,
15991,
17,
584,
4280,
28027,
6,
97,
584,
4280,
28027,
6,
833,
584,
4280,
28027,
6,
741,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
2645,
47,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0... | [
3,
23143,
14196,
3886,
21680,
953,
834,
4350,
834,
1828,
549,
17444,
427,
833,
3274,
96,
2266,
5,
10032,
4560,
121,
3430,
741,
3274,
96,
632,
10,
536,
121,
3430,
97,
3274,
96,
536,
18828,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What was Andretti's finish for the year he had a Buick engine and started 16th? | CREATE TABLE table_41149 (
"Year" real,
"Chassis" text,
"Engine" text,
"Start" text,
"Finish" text
) | SELECT "Finish" FROM table_41149 WHERE "Engine" = 'buick' AND "Start" = '16th' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4853,
24816,
41,
96,
476,
2741,
121,
490,
6,
96,
3541,
6500,
7,
121,
1499,
6,
96,
31477,
121,
1499,
6,
96,
7681,
17,
121,
1499,
6,
96,
371,
77,
1273,
121,
1499,
3,
61,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
371,
77,
1273,
121,
21680,
953,
834,
4853,
24816,
549,
17444,
427,
96,
31477,
121,
3274,
3,
31,
3007,
3142,
31,
3430,
96,
7681,
17,
121,
3274,
3,
31,
2938,
189,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
How many players had a best winning average of 20? | CREATE TABLE table_27533947_1 (games_won VARCHAR, best_winning_average VARCHAR) | SELECT COUNT(games_won) FROM table_27533947_1 WHERE best_winning_average = "20" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2555,
4867,
3288,
4177,
834,
536,
41,
7261,
7,
834,
210,
106,
584,
4280,
28027,
6,
200,
834,
8163,
834,
28951,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
571,
186,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2847,
17161,
599,
7261,
7,
834,
210,
106,
61,
21680,
953,
834,
2555,
4867,
3288,
4177,
834,
536,
549,
17444,
427,
200,
834,
8163,
834,
28951,
3274,
96,
1755,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What is the Russian word for wine glass that contains 4.16 fl. oz.? | CREATE TABLE table_39047 (
"Unit" text,
"Russian" text,
"Translation" text,
"Ratio" text,
"Cubic inches (exact)" text,
"Metric value" text,
"Imperial" text,
"US Customary" text
) | SELECT "Russian" FROM table_39047 WHERE "US Customary" = '4.16 fl. oz.' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
519,
2394,
4177,
41,
96,
5110,
155,
121,
1499,
6,
96,
29613,
29,
121,
1499,
6,
96,
18474,
6105,
121,
1499,
6,
96,
448,
144,
23,
32,
121,
1499,
6,
96,
15784,
15979,
5075,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
29613,
29,
121,
21680,
953,
834,
519,
2394,
4177,
549,
17444,
427,
96,
3063,
6150,
1208,
121,
3274,
3,
31,
7984,
2938,
3,
89,
40,
5,
3,
32,
172,
5,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
Which Points have a Year larger than 1966, and Wins larger than 1? | CREATE TABLE table_name_78 (
points INTEGER,
year VARCHAR,
wins VARCHAR
) | SELECT AVG(points) FROM table_name_78 WHERE year > 1966 AND wins > 1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3940,
41,
979,
3,
21342,
17966,
6,
215,
584,
4280,
28027,
6,
9204,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
4073,
4564,
7,
43,
3,
9,
2929,
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,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
71,
17217,
599,
2700,
7,
61,
21680,
953,
834,
4350,
834,
3940,
549,
17444,
427,
215,
2490,
20658,
3430,
9204,
2490,
209,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
How many years was the trailing votes 25.34% | CREATE TABLE table_1811 (
"Year" real,
"Lok Sabha" text,
"Members of Parliament" text,
"Party Won" text,
"Winners % votes" text,
"Trailing Party" text,
"Trailing Party % votes" text
) | SELECT COUNT("Year") FROM table_1811 WHERE "Trailing Party % votes" = '25.34%' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2606,
2596,
41,
96,
476,
2741,
121,
490,
6,
96,
434,
1825,
11315,
1024,
121,
1499,
6,
96,
329,
18247,
7,
13,
12876,
121,
1499,
6,
96,
13725,
63,
549,
106,
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,
2847,
17161,
599,
121,
476,
2741,
8512,
21680,
953,
834,
2606,
2596,
549,
17444,
427,
96,
9402,
173,
53,
3450,
3,
1454,
11839,
121,
3274,
3,
31,
357,
26627,
5988,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
What is the cmi cross reference id that is related to at least one council tax entry? List the cross reference id and source system code. | CREATE TABLE Council_Tax (cmi_cross_ref_id VARCHAR); CREATE TABLE CMI_Cross_References (cmi_cross_ref_id VARCHAR, source_system_code VARCHAR) | SELECT T1.cmi_cross_ref_id, T1.source_system_code FROM CMI_Cross_References AS T1 JOIN Council_Tax AS T2 ON T1.cmi_cross_ref_id = T2.cmi_cross_ref_id GROUP BY T1.cmi_cross_ref_id HAVING COUNT(*) >= 1 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
2063,
834,
382,
9,
226,
41,
75,
51,
23,
834,
11465,
834,
60,
89,
834,
23,
26,
584,
4280,
28027,
61,
3,
32102,
32103,
32102,
205,
4386,
6048,
332,
17098,
205,
7075,
834,
254,
1859,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
75,
51,
23,
834,
11465,
834,
60,
89,
834,
23,
26,
6,
332,
5411,
7928,
834,
3734,
834,
4978,
21680,
205,
7075,
834,
254,
1859,
7,
834,
1649,
11788,
7,
6157,
332,
536,
3,
15355,
3162,
2063,
834,
382,
9,... |
What is the Rank that has a Venue of bellerive oval , hobart, and a Margin of 115 runs? | CREATE TABLE table_8061 (
"Rank" text,
"Margin" text,
"Opponent" text,
"Venue" text,
"Season" text
) | SELECT "Rank" FROM table_8061 WHERE "Venue" = 'bellerive oval , hobart' AND "Margin" = '115 runs' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2079,
4241,
41,
96,
22557,
121,
1499,
6,
96,
7286,
122,
77,
121,
1499,
6,
96,
667,
102,
9977,
121,
1499,
6,
96,
553,
35,
76,
15,
121,
1499,
6,
96,
134,
15,
9,
739,
12... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
22557,
121,
21680,
953,
834,
2079,
4241,
549,
17444,
427,
96,
553,
35,
76,
15,
121,
3274,
3,
31,
7708,
49,
757,
17986,
3,
6,
3534,
1047,
17,
31,
3430,
96,
7286,
122,
77,
121,
3274,
3,
31,
15660,
3154,
31,
... |
What is the to par of the player with a 73-70-70-65=278 score? | CREATE TABLE table_name_92 (to_par VARCHAR, score VARCHAR) | SELECT to_par FROM table_name_92 WHERE score = 73 - 70 - 70 - 65 = 278 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4508,
41,
235,
834,
1893,
584,
4280,
28027,
6,
2604,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
12,
260,
13,
8,
1959,
28,
3,
9,
3,
4552,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
12,
834,
1893,
21680,
953,
834,
4350,
834,
4508,
549,
17444,
427,
2604,
3274,
3,
4552,
3,
18,
2861,
3,
18,
2861,
3,
18,
7123,
3274,
204,
3940,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What was the final result for Les Aspin? | CREATE TABLE table_1341577_50 (result VARCHAR, incumbent VARCHAR) | SELECT result FROM table_1341577_50 WHERE incumbent = "Les Aspin" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
23747,
1808,
4013,
834,
1752,
41,
60,
7,
83,
17,
584,
4280,
28027,
6,
28406,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
804,
741,
21,
622,
282,
3180,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
741,
21680,
953,
834,
23747,
1808,
4013,
834,
1752,
549,
17444,
427,
28406,
3274,
96,
2796,
7,
282,
3180,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
Tell me the 2008 of 2001 olympic games | CREATE TABLE table_31883 (
"Tournament" text,
"2008" text,
"2009" text,
"2010" text,
"2011" text,
"2012" text
) | SELECT "2008" FROM table_31883 WHERE "2011" = 'olympic games' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
519,
2606,
4591,
41,
96,
382,
1211,
20205,
17,
121,
1499,
6,
96,
16128,
121,
1499,
6,
96,
16660,
121,
1499,
6,
96,
14926,
121,
1499,
6,
96,
13907,
121,
1499,
6,
96,
12172... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
16128,
121,
21680,
953,
834,
519,
2606,
4591,
549,
17444,
427,
96,
13907,
121,
3274,
3,
31,
32,
120,
51,
6174,
1031,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
What was the train destination when it has a calling at Boston, Sleaford, Nottingham Victoria? | CREATE TABLE table_18365784_3 (going_to VARCHAR, calling_at VARCHAR) | SELECT going_to FROM table_18365784_3 WHERE calling_at = "Boston, Sleaford, Nottingham Victoria" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2606,
10402,
3940,
591,
834,
519,
41,
9545,
834,
235,
584,
4280,
28027,
6,
3874,
834,
144,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
2412,
3954,
116,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
352,
834,
235,
21680,
953,
834,
2606,
10402,
3940,
591,
834,
519,
549,
17444,
427,
3874,
834,
144,
3274,
96,
279,
32,
4411,
6,
180,
109,
9,
2590,
6,
26238,
7488,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
What was the engine belonging to Pierluigi Martini with a Tyre of P? | CREATE TABLE table_name_20 (
engine VARCHAR,
tyres VARCHAR,
driver VARCHAR
) | SELECT engine FROM table_name_20 WHERE tyres = "p" AND driver = "pierluigi martini" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
1755,
41,
1948,
584,
4280,
28027,
6,
3,
17,
63,
60,
7,
584,
4280,
28027,
6,
2535,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
363,
47,
8,
1948,
127... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0... | [
3,
23143,
14196,
1948,
21680,
953,
834,
4350,
834,
1755,
549,
17444,
427,
3,
17,
63,
60,
7,
3274,
96,
102,
121,
3430,
2535,
3274,
96,
8343,
2878,
122,
23,
3157,
17,
77,
23,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the most recent year featuring the director Christopher Kulikowski? | CREATE TABLE table_name_89 (year INTEGER, director VARCHAR) | SELECT MAX(year) FROM table_name_89 WHERE director = "christopher kulikowski" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3914,
41,
1201,
3,
21342,
17966,
6,
2090,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
363,
19,
8,
167,
1100,
215,
4767,
8,
2090,
14702,
480,
83,
23,
270... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4800,
4,
599,
1201,
61,
21680,
953,
834,
4350,
834,
3914,
549,
17444,
427,
2090,
3274,
96,
15294,
10775,
49,
3,
10701,
23,
27077,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
How many touchdowns are there that has field goals less than 0 and 0 extra points? | CREATE TABLE table_name_53 (
touchdowns INTEGER,
extra_points VARCHAR,
field_goals VARCHAR
) | SELECT SUM(touchdowns) FROM table_name_53 WHERE extra_points = 0 AND field_goals < 0 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4867,
41,
19396,
7,
3,
21342,
17966,
6,
996,
834,
2700,
7,
584,
4280,
28027,
6,
1057,
834,
839,
5405,
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,
1,
1,
0... | [
3,
23143,
14196,
180,
6122,
599,
17681,
3035,
7,
61,
21680,
953,
834,
4350,
834,
4867,
549,
17444,
427,
996,
834,
2700,
7,
3274,
3,
632,
3430,
1057,
834,
839,
5405,
3,
2,
3,
632,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
what is average age of patients whose days of hospital stay is 11 and year of death is less than 2155? | CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
)
CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
language text,
religion text,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear text
) | SELECT AVG(demographic.age) FROM demographic WHERE demographic.days_stay = "11" AND demographic.dod_year < "2155.0" | [
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,
71,
17217,
599,
1778,
16587,
5,
545,
61,
21680,
14798,
549,
17444,
427,
14798,
5,
1135,
7,
834,
21545,
3274,
96,
2596,
121,
3430,
14798,
5,
26,
32,
26,
834,
1201,
3,
2,
96,
357,
1808,
20734,
121,
1,
-100,
-100,
... |
Who directed 'loathe and marriage'? | CREATE TABLE table_2563 (
"Series #" real,
"Season #" real,
"Title" text,
"Directed by" text,
"Written by" text,
"Original air date" text
) | SELECT "Directed by" FROM table_2563 WHERE "Title" = 'Loathe and Marriage' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
1828,
3891,
41,
96,
12106,
7,
1713,
121,
490,
6,
96,
134,
15,
9,
739,
1713,
121,
490,
6,
96,
382,
155,
109,
121,
1499,
6,
96,
23620,
15,
26,
57,
121,
1499,
6,
96,
249... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
23620,
15,
26,
57,
121,
21680,
953,
834,
1828,
3891,
549,
17444,
427,
96,
382,
155,
109,
121,
3274,
3,
31,
434,
32,
9,
532,
11,
26741,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
For those records from the products and each product's manufacturer, draw a bar chart about the distribution of name and the average of code , and group by attribute name, and show y axis in desc 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.Name, T1.Code FROM Products AS T1 JOIN Manufacturers AS T2 ON T1.Manufacturer = T2.Code GROUP BY T2.Name 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,
23954,
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,
332,
4416,
2... |
List the name of all customers sorted by their account balance in ascending order. | CREATE TABLE customer (
cust_name VARCHAR,
acc_bal VARCHAR
) | SELECT cust_name FROM customer ORDER BY acc_bal | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
884,
41,
123,
7,
17,
834,
4350,
584,
4280,
28027,
6,
3,
6004,
834,
3849,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
6792,
8,
564,
13,
66,
722,
3,
14504,
57,
70,
905,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
123,
7,
17,
834,
4350,
21680,
884,
4674,
11300,
272,
476,
3,
6004,
834,
3849,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
When was an average speed of 81.388 mph recorded? | CREATE TABLE table_2266976_1 (
date VARCHAR,
average_speed__mph_ VARCHAR
) | SELECT date FROM table_2266976_1 WHERE average_speed__mph_ = "81.388" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
357,
2688,
3951,
3959,
834,
536,
41,
833,
584,
4280,
28027,
6,
1348,
834,
9993,
834,
834,
7656,
834,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
366,
47,
46,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
833,
21680,
953,
834,
357,
2688,
3951,
3959,
834,
536,
549,
17444,
427,
1348,
834,
9993,
834,
834,
7656,
834,
3274,
96,
927,
13606,
4060,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
How many bronzes for nations with over 22 golds and ranked under 2? | CREATE TABLE table_name_66 (
bronze INTEGER,
gold VARCHAR,
rank VARCHAR
) | SELECT MAX(bronze) FROM table_name_66 WHERE gold > 22 AND rank < 2 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3539,
41,
13467,
3,
21342,
17966,
6,
2045,
584,
4280,
28027,
6,
11003,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
571,
186,
13467,
7,
21,
9352,
28,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
4800,
4,
599,
13711,
776,
61,
21680,
953,
834,
4350,
834,
3539,
549,
17444,
427,
2045,
2490,
1630,
3430,
11003,
3,
2,
204,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the most recent season where the Denim Demons placed 3rd? | CREATE TABLE table_31267 (
"Season" real,
"Apocalypstix" text,
"Denim Demons" text,
"Sake Tuyas" text,
"Toxic Shocks" text
) | SELECT MAX("Season") FROM table_31267 WHERE "Denim Demons" = '3rd' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
519,
2122,
3708,
41,
96,
134,
15,
9,
739,
121,
490,
6,
96,
188,
10496,
9,
120,
102,
2248,
226,
121,
1499,
6,
96,
308,
35,
603,
15782,
29,
7,
121,
1499,
6,
96,
134,
9,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
4800,
4,
599,
121,
134,
15,
9,
739,
8512,
21680,
953,
834,
519,
2122,
3708,
549,
17444,
427,
96,
308,
35,
603,
15782,
29,
7,
121,
3274,
3,
31,
519,
52,
26,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
count the number of times patient 004-34394 had cultures - surgical specimen procedures during the last hospital encounter. | CREATE TABLE patient (
uniquepid text,
patienthealthsystemstayid number,
patientunitstayid number,
gender text,
age text,
ethnicity text,
hospitalid number,
wardid number,
admissionheight number,
admissionweight number,
dischargeweight number,
hospitaladmittime time,
hospitaladmitsource text,
unitadmittime time,
unitdischargetime time,
hospitaldischargetime time,
hospitaldischargestatus text
)
CREATE TABLE lab (
labid number,
patientunitstayid number,
labname text,
labresult number,
labresulttime time
)
CREATE TABLE vitalperiodic (
vitalperiodicid number,
patientunitstayid number,
temperature number,
sao2 number,
heartrate number,
respiration number,
systemicsystolic number,
systemicdiastolic number,
systemicmean number,
observationtime time
)
CREATE TABLE treatment (
treatmentid number,
patientunitstayid number,
treatmentname text,
treatmenttime time
)
CREATE TABLE allergy (
allergyid number,
patientunitstayid number,
drugname text,
allergyname text,
allergytime time
)
CREATE TABLE intakeoutput (
intakeoutputid number,
patientunitstayid number,
cellpath text,
celllabel text,
cellvaluenumeric number,
intakeoutputtime time
)
CREATE TABLE microlab (
microlabid number,
patientunitstayid number,
culturesite text,
organism text,
culturetakentime time
)
CREATE TABLE medication (
medicationid number,
patientunitstayid number,
drugname text,
dosage text,
routeadmin text,
drugstarttime time,
drugstoptime time
)
CREATE TABLE diagnosis (
diagnosisid number,
patientunitstayid number,
diagnosisname text,
diagnosistime time,
icd9code text
)
CREATE TABLE cost (
costid number,
uniquepid text,
patienthealthsystemstayid number,
eventtype text,
eventid number,
chargetime time,
cost number
) | SELECT COUNT(*) FROM treatment WHERE treatment.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '004-34394' AND NOT patient.hospitaldischargetime IS NULL ORDER BY patient.hospitaladmittime DESC LIMIT 1)) AND treatment.treatmentname = 'cultures - surgical specimen' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
1868,
41,
775,
12417,
1499,
6,
1868,
15878,
3734,
21545,
23,
26,
381,
6,
1868,
15129,
21545,
23,
26,
381,
6,
7285,
1499,
6,
1246,
1499,
6,
11655,
485,
1499,
6,
2833,
23,
26,
381,
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,
2847,
17161,
599,
1935,
61,
21680,
1058,
549,
17444,
427,
1058,
5,
10061,
15129,
21545,
23,
26,
3388,
41,
23143,
14196,
1868,
5,
10061,
15129,
21545,
23,
26,
21680,
1868,
549,
17444,
427,
1868,
5,
10061,
15878,
3734,
... |
What is the total number of assists of the player with 0 goals, more than 1 points, and more than 0 pims? | CREATE TABLE table_46377 (
"Name" text,
"Pld." real,
"Goals" real,
"Assists" real,
"Points" real,
"Pims" real
) | SELECT COUNT("Assists") FROM table_46377 WHERE "Goals" = '0' AND "Points" > '1' AND "Pims" > '0' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4448,
519,
4013,
41,
96,
23954,
121,
1499,
6,
96,
345,
40,
26,
535,
490,
6,
96,
6221,
5405,
121,
490,
6,
96,
188,
7,
7,
343,
7,
121,
490,
6,
96,
22512,
7,
121,
490,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
121,
188,
7,
7,
343,
7,
8512,
21680,
953,
834,
4448,
519,
4013,
549,
17444,
427,
96,
6221,
5405,
121,
3274,
3,
31,
632,
31,
3430,
96,
22512,
7,
121,
2490,
3,
31,
536,
31,
3430,
96,
345,
603,
... |
which Score has a Partnering of dmitry tursunov? | CREATE TABLE table_name_63 (score VARCHAR, partnering VARCHAR) | SELECT score FROM table_name_63 WHERE partnering = "dmitry tursunov" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3891,
41,
7,
9022,
584,
4280,
28027,
6,
3,
26361,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
84,
17763,
65,
3,
9,
5793,
53,
13,
3,
26,
1538,
651,
3,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2604,
21680,
953,
834,
4350,
834,
3891,
549,
17444,
427,
3,
26361,
3274,
96,
26,
1538,
651,
3,
2905,
7,
76,
5326,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
Parts Plus sponsors what driver? | CREATE TABLE table_name_21 (
driver_s_ VARCHAR,
primary_sponsor_s_ VARCHAR
) | SELECT driver_s_ FROM table_name_21 WHERE primary_sponsor_s_ = "parts plus" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2658,
41,
2535,
834,
7,
834,
584,
4280,
28027,
6,
2329,
834,
7,
5041,
7,
127,
834,
7,
834,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
2733,
7,
247... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2535,
834,
7,
834,
21680,
953,
834,
4350,
834,
2658,
549,
17444,
427,
2329,
834,
7,
5041,
7,
127,
834,
7,
834,
3274,
96,
2274,
7,
303,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
Name the sepal lengh when sepal width is 2.9 and petal width 1.3 | CREATE TABLE table_10477224_1 (sepal_length VARCHAR, sepal_width VARCHAR, petal_width VARCHAR) | SELECT sepal_length FROM table_10477224_1 WHERE sepal_width = "2.9" AND petal_width = "1.3" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
15442,
4013,
24622,
834,
536,
41,
7,
15,
6459,
834,
19457,
584,
4280,
28027,
6,
142,
6459,
834,
12018,
189,
584,
4280,
28027,
6,
158,
1947,
834,
12018,
189,
584,
4280,
28027,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
142,
6459,
834,
19457,
21680,
953,
834,
15442,
4013,
24622,
834,
536,
549,
17444,
427,
142,
6459,
834,
12018,
189,
3274,
96,
27297,
121,
3430,
158,
1947,
834,
12018,
189,
3274,
96,
13606,
121,
1,
-100,
-100,
-100,
-10... |
I want the time/retired for grid of 17 | CREATE TABLE table_53462 (
"Driver" text,
"Constructor" text,
"Laps" real,
"Time/Retired" text,
"Grid" real
) | SELECT "Time/Retired" FROM table_53462 WHERE "Grid" = '17' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4867,
4448,
357,
41,
96,
20982,
52,
121,
1499,
6,
96,
4302,
7593,
127,
121,
1499,
6,
96,
3612,
102,
7,
121,
490,
6,
96,
13368,
87,
1649,
11809,
26,
121,
1499,
6,
96,
13... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
13368,
87,
1649,
11809,
26,
121,
21680,
953,
834,
4867,
4448,
357,
549,
17444,
427,
96,
13313,
26,
121,
3274,
3,
31,
2517,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
Who was the artist for the year of the snake? | CREATE TABLE table_name_76 (
artist VARCHAR,
theme VARCHAR
) | SELECT artist FROM table_name_76 WHERE theme = "year of the snake" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
3959,
41,
2377,
584,
4280,
28027,
6,
3800,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
2645,
47,
8,
2377,
21,
8,
215,
13,
8,
17599,
58,
1,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2377,
21680,
953,
834,
4350,
834,
3959,
549,
17444,
427,
3800,
3274,
96,
1201,
13,
8,
17599,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
Can you tell me the Score that has the Home team of townsville crocodiles? | CREATE TABLE table_name_24 (score VARCHAR, home_team VARCHAR) | SELECT score FROM table_name_24 WHERE home_team = "townsville crocodiles" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2266,
41,
7,
9022,
584,
4280,
28027,
6,
234,
834,
11650,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
1072,
25,
817,
140,
8,
17763,
24,
65,
8,
1210,
372,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2604,
21680,
953,
834,
4350,
834,
2266,
549,
17444,
427,
234,
834,
11650,
3274,
96,
3540,
9727,
3,
2771,
509,
26,
699,
7,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
For the Australian Open, in 2007 the result was A, but what was the result in 2012? | CREATE TABLE table_12134 (
"Tournament" text,
"2006" text,
"2007" text,
"2008" text,
"2009" text,
"2011" text,
"2012" text
) | SELECT "2012" FROM table_12134 WHERE "2007" = 'a' AND "Tournament" = 'australian open' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2122,
23747,
41,
96,
382,
1211,
20205,
17,
121,
1499,
6,
96,
21196,
121,
1499,
6,
96,
20615,
121,
1499,
6,
96,
16128,
121,
1499,
6,
96,
16660,
121,
1499,
6,
96,
13907,
12... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
12172,
121,
21680,
953,
834,
2122,
23747,
549,
17444,
427,
96,
20615,
121,
3274,
3,
31,
9,
31,
3430,
96,
382,
1211,
20205,
17,
121,
3274,
3,
31,
402,
3109,
9928,
539,
31,
1,
-100,
-100,
-100,
-100,
-100,
-100,... |
Return a pie chart on how many regions were affected by each storm? | CREATE TABLE storm (
Storm_ID int,
Name text,
Dates_active text,
Max_speed int,
Damage_millions_USD real,
Number_Deaths int
)
CREATE TABLE affected_region (
Region_id int,
Storm_ID int,
Number_city_affected real
)
CREATE TABLE region (
Region_id int,
Region_code text,
Region_name text
) | SELECT Name, COUNT(*) FROM storm AS T1 JOIN affected_region AS T2 ON T1.Storm_ID = T2.Storm_ID GROUP BY T1.Storm_ID | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
5536,
41,
16133,
834,
4309,
16,
17,
6,
5570,
1499,
6,
7678,
7,
834,
6645,
1499,
6,
5370,
834,
9993,
16,
17,
6,
26135,
834,
17030,
7,
834,
23492,
490,
6,
7720,
834,
2962,
9,
189,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
5570,
6,
2847,
17161,
599,
1935,
61,
21680,
5536,
6157,
332,
536,
3,
15355,
3162,
4161,
834,
18145,
6157,
332,
357,
9191,
332,
5411,
134,
17,
127,
51,
834,
4309,
3274,
332,
4416,
134,
17,
127,
51,
834,
4309,
350,
... |
Who got the gold in seoul before 2002? | CREATE TABLE table_name_53 (
gold VARCHAR,
year VARCHAR,
location VARCHAR
) | SELECT gold FROM table_name_53 WHERE year < 2002 AND location = "seoul" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
4867,
41,
2045,
584,
4280,
28027,
6,
215,
584,
4280,
28027,
6,
1128,
584,
4280,
28027,
3,
61,
3,
32102,
32103,
32101,
32103,
2645,
530,
8,
2045,
16,
142,
7115,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
3,
23143,
14196,
2045,
21680,
953,
834,
4350,
834,
4867,
549,
17444,
427,
215,
3,
2,
4407,
3430,
1128,
3274,
96,
7,
15,
7115,
121,
1,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
What is the decimal value when the memory map and byte string are standard, and the max memory is 512? | CREATE TABLE table_name_19 (
decimal VARCHAR,
max_memory__kwords_ VARCHAR,
byte_string VARCHAR,
memory_map VARCHAR
) | SELECT decimal FROM table_name_19 WHERE byte_string = "standard" AND memory_map = "standard" AND max_memory__kwords_ = 512 | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
4350,
834,
2294,
41,
7908,
1982,
584,
4280,
28027,
6,
9858,
834,
526,
2528,
63,
834,
834,
157,
6051,
7,
834,
584,
4280,
28027,
6,
3,
17770,
834,
16099,
584,
4280,
28027,
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,
7908,
1982,
21680,
953,
834,
4350,
834,
2294,
549,
17444,
427,
3,
17770,
834,
16099,
3274,
96,
16020,
121,
3430,
2594,
834,
11576,
3274,
96,
16020,
121,
3430,
9858,
834,
526,
2528,
63,
834,
834,
157,
6051,
7,
834,
3... |
Which stage had a Points Classification of Francesco Moser and a general classification of Bernard Hinault? | CREATE TABLE table_54225 (
"Stage" text,
"Winner" text,
"General classification" text,
"Points classification" text,
"Trofeo Fast Team" text
) | SELECT "Stage" FROM table_54225 WHERE "Points classification" = 'francesco moser' AND "General classification" = 'bernard hinault' | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
5062,
20489,
41,
96,
134,
6505,
121,
1499,
6,
96,
18455,
687,
121,
1499,
6,
96,
20857,
13774,
121,
1499,
6,
96,
22512,
7,
13774,
121,
1499,
6,
96,
382,
52,
858,
15,
32,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
96,
134,
6505,
121,
21680,
953,
834,
5062,
20489,
549,
17444,
427,
96,
22512,
7,
13774,
121,
3274,
3,
31,
89,
5219,
3523,
3,
3972,
49,
31,
3430,
96,
20857,
13774,
121,
3274,
3,
31,
1152,
29,
986,
3811,
10335,
31,
... |
what is the number of home health care discharge patients who were admitted before 2197? | CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
language text,
religion text,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE 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.discharge_location = "HOME HEALTH CARE" AND demographic.admityear < "2197" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
14798,
41,
1426,
834,
23,
26,
1499,
6,
141,
51,
834,
23,
26,
1499,
6,
564,
1499,
6,
2774,
1947,
834,
8547,
302,
1499,
6,
1246,
1499,
6,
103,
115,
1499,
6,
7285,
1499,
6,
1612,
14... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
3,
23143,
14196,
2847,
17161,
599,
15438,
25424,
6227,
14798,
5,
7304,
11827,
834,
23,
26,
61,
21680,
14798,
549,
17444,
427,
14798,
5,
26,
159,
7993,
834,
14836,
3274,
96,
6299,
4369,
3,
6021,
4090,
4611,
3,
22443,
121,
3430,
14798,
... |
Where is scott starr from? | CREATE TABLE table_11677691_6 (hometown VARCHAR, player VARCHAR) | SELECT hometown FROM table_11677691_6 WHERE player = "Scott Starr" | [
32100,
32103,
32102,
205,
4386,
6048,
332,
17098,
953,
834,
2596,
3708,
3959,
4729,
834,
948,
41,
5515,
3540,
584,
4280,
28027,
6,
1959,
584,
4280,
28027,
61,
3,
32102,
32103,
32101,
32103,
2840,
19,
3,
7,
10405,
2213,
52,
45,
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,
22295,
21680,
953,
834,
2596,
3708,
3959,
4729,
834,
948,
549,
17444,
427,
1959,
3274,
96,
134,
10405,
2042,
52,
121,
1,
-100,
-100,
-100,
-100,
-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.