Unnamed: 0
int64
0
3k
text
stringlengths
74
2.32k
2,600
###HUMAN: What's the lowest total when there's less than 16 bronze and more than 6 silver?, ###ASSISTANT: SELECT MIN(total) FROM table_name_13 WHERE bronze < 16 AND silver > 6
2,601
###HUMAN: What is the award type for all Lowe awards?, ###ASSISTANT: SELECT "Award" FROM table_69966 WHERE "Name" = 'lowe'
2,602
###HUMAN: What was the reading score in the year the science score was 96.13?, ###ASSISTANT: SELECT "Reading" FROM table_27576 WHERE "Science" = '96.13'
2,603
###HUMAN: What Mayor is from the KRF Party?, ###ASSISTANT: SELECT "Mayor" FROM table_35421 WHERE "Party" = 'krf'
2,604
###HUMAN: which township in pope county , arkansas has the smallest population ?, ###ASSISTANT: SELECT "township" FROM table_203_510 ORDER BY "population" LIMIT 1
2,605
###HUMAN: What Australian sound is equivalent to e / /?, ###ASSISTANT: SELECT "Australian" FROM table_59742 WHERE "Short vowels" = 'e /ɛ/'
2,606
###HUMAN: For the attribute All_Neutral and ACC_Percent, show their proportion by a pie chart., ###ASSISTANT: SELECT All_Neutral, ACC_Percent FROM basketball_match
2,607
###HUMAN: What is the winning score of the match with a margin of 3 strokes?, ###ASSISTANT: SELECT winning_score FROM table_name_39 WHERE margin = "3 strokes"
2,608
###HUMAN: What is the minimum number of opponents?, ###ASSISTANT: SELECT MIN("Opponents") FROM table_73057
2,609
###HUMAN: what is the monthly maximum of the weight of patient 012-58944 during the first hospital visit?, ###ASSISTANT: SELECT MAX(patient.admissionweight) FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '012-58944' AND NOT patient.hospitaldischargetime IS NULL ORDER BY patient.hospitaladmittime LIMIT 1) AND NOT patient.admissionweight IS NULL GROUP BY STRFTIME('%y-%m', patient.unitadmittime)
2,610
###HUMAN: What two players had the highest rebounds for the October 14 game?, ###ASSISTANT: SELECT "High rebounds" FROM table_74185 WHERE "Date" = 'October 14'
2,611
###HUMAN: What pole position did 2006 gehl championship finale have?, ###ASSISTANT: SELECT "Pole position" FROM table_45447 WHERE "Race Name" = '2006 gehl championship finale'
2,612
###HUMAN: What is the Away captain with a Venue that is old trafford?, ###ASSISTANT: SELECT "Away captain" FROM table_7302 WHERE "Venue" = 'old trafford'
2,613
###HUMAN: Name the title for production code 2t6908, ###ASSISTANT: SELECT title FROM table_18569389_1 WHERE production_code = "2T6908"
2,614
###HUMAN: What is the intergiro classification of stage 21?, ###ASSISTANT: SELECT intergiro_classification FROM table_12261926_2 WHERE stage = 21
2,615
###HUMAN: Give the minimum age of patients whose admission type is urgent and were born before the year 2175., ###ASSISTANT: SELECT MIN(demographic.age) FROM demographic WHERE demographic.admission_type = "URGENT" AND demographic.dob_year > "2175"
2,616
###HUMAN: show me the latest flight on wednesday from ATLANTA to WASHINGTON, ###ASSISTANT: SELECT DISTINCT flight.flight_id FROM airport_service AS AIRPORT_SERVICE_0, airport_service AS AIRPORT_SERVICE_1, city AS CITY_0, city AS CITY_1, date_day, days, flight WHERE ((CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'WASHINGTON' AND date_day.day_number = 23 AND date_day.month_number = 4 AND date_day.year = 1991 AND days.day_name = date_day.day_name AND flight.flight_days = days.days_code AND flight.to_airport = AIRPORT_SERVICE_1.airport_code) AND CITY_0.city_code = AIRPORT_SERVICE_0.city_code AND CITY_0.city_name = 'ATLANTA' AND flight.from_airport = AIRPORT_SERVICE_0.airport_code) AND flight.departure_time = (SELECT MAX(FLIGHTalias1.departure_time) FROM airport_service AS AIRPORT_SERVICEalias2, airport_service AS AIRPORT_SERVICEalias3, city AS CITYalias2, city AS CITYalias3, date_day AS DATE_DAYalias1, days AS DAYSalias1, flight AS FLIGHTalias1 WHERE (CITYalias3.city_code = AIRPORT_SERVICEalias3.city_code AND CITYalias3.city_name = 'WASHINGTON' AND DATE_DAYalias1.day_number = 23 AND DATE_DAYalias1.month_number = 4 AND DATE_DAYalias1.year = 1991 AND DAYSalias1.day_name = DATE_DAYalias1.day_name AND FLIGHTalias1.flight_days = DAYSalias1.days_code AND FLIGHTalias1.to_airport = AIRPORT_SERVICEalias3.airport_code) AND CITYalias2.city_code = AIRPORT_SERVICEalias2.city_code AND CITYalias2.city_name = 'ATLANTA' AND FLIGHTalias1.from_airport = AIRPORT_SERVICEalias2.airport_code)
2,617
###HUMAN: A bar chart about what are the memories and carriers of phones?, and order by the Y-axis in descending., ###ASSISTANT: SELECT Carrier, SUM(Memory_in_G) FROM phone GROUP BY Carrier ORDER BY SUM(Memory_in_G) DESC
2,618
###HUMAN: how many patients admitted before 2155 are diagnosed with other specified gastritis, with hemorrhage?, ###ASSISTANT: SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id WHERE demographic.admityear < "2155" AND diagnoses.long_title = "Other specified gastritis, with hemorrhage"
2,619
###HUMAN: What is the B Score when the total is more than 16.125, and position is 3rd?, ###ASSISTANT: SELECT SUM("B Score") FROM table_65946 WHERE "Total" > '16.125' AND "Position" = '3rd'
2,620
###HUMAN: Which country had a place of t1, as well as a score of 72-68-70-73=283?, ###ASSISTANT: SELECT "Country" FROM table_50932 WHERE "Place" = 't1' AND "Score" = '72-68-70-73=283'
2,621
###HUMAN: what is the name of first visitor on this chart ?, ###ASSISTANT: SELECT "visitor" FROM table_204_557 WHERE id = 1
2,622
###HUMAN: Which team played Footscray?, ###ASSISTANT: SELECT "Away team" FROM table_11606 WHERE "Home team" = 'footscray'
2,623
###HUMAN: What are the processors supported by a ddr2 memory and the nforce 550 model?, ###ASSISTANT: SELECT "Processors Supported" FROM table_39045 WHERE "Memory" = 'ddr2' AND "Model" = 'nforce 550'
2,624
###HUMAN: Questions with answers, but no accepted answer., ###ASSISTANT: SELECT Id AS "post_link", AnswerCount FROM Posts WHERE PostTypeId = 1 AND AcceptedAnswerId IS NULL AND OwnerUserId = '##UserId:int##'
2,625
###HUMAN: What is the party when the constituency is 1. Chennai North?, ###ASSISTANT: SELECT "Party" FROM table_25286 WHERE "Constituency" = '1. Chennai North'
2,626
###HUMAN: Which Losses have a Wimmera FL of minyip murtoa?, ###ASSISTANT: SELECT AVG(losses) FROM table_name_35 WHERE wimmera_fl = "minyip murtoa"
2,627
###HUMAN: Among patients whose birth year is before 2107, how many of them belonged to black/african american ethnic origin?, ###ASSISTANT: SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.ethnicity = "BLACK/AFRICAN AMERICAN" AND demographic.dob_year < "2107"
2,628
###HUMAN: Who did they play on August 12?, ###ASSISTANT: SELECT "Opponent" FROM table_79956 WHERE "Date" = 'august 12'
2,629
###HUMAN: Provide me the list of patients on base drug prescription who havea hospital stay greater than three days., ###ASSISTANT: SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE demographic.days_stay > "3" AND prescriptions.drug_type = "BASE"
2,630
###HUMAN: What year did Elf Team Tyrrell have 39 points and a Tyrrell 007 Chassis?, ###ASSISTANT: SELECT SUM(year) FROM table_name_75 WHERE entrant = "elf team tyrrell" AND points = "39" AND chassis = "tyrrell 007"
2,631
###HUMAN: Venue of Pepsi arena involved what club?, ###ASSISTANT: SELECT "Club" FROM table_36909 WHERE "Venue" = 'pepsi arena'
2,632
###HUMAN: What is Graham Gooch's nationality?, ###ASSISTANT: SELECT nationality FROM table_name_87 WHERE player = "graham gooch"
2,633
###HUMAN: Which Player has a To par of 2, and a Country of wales?, ###ASSISTANT: SELECT "Player" FROM table_60735 WHERE "To par" = '–2' AND "Country" = 'wales'
2,634
###HUMAN: how much was patient 20898's body weight last measured in this month?, ###ASSISTANT: SELECT chartevents.valuenum FROM chartevents WHERE chartevents.icustay_id IN (SELECT icustays.icustay_id FROM icustays WHERE icustays.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 20898)) AND chartevents.itemid IN (SELECT d_items.itemid FROM d_items WHERE d_items.label = 'admit wt' AND d_items.linksto = 'chartevents') AND DATETIME(chartevents.charttime, 'start of month') = DATETIME(CURRENT_TIME(), 'start of month', '-0 month') ORDER BY chartevents.charttime DESC LIMIT 1
2,635
###HUMAN: How many different counts for won points does Flavia Pennetta have?, ###ASSISTANT: SELECT COUNT("Points won") FROM table_3813 WHERE "Player" = 'Flavia Pennetta'
2,636
###HUMAN: How many documents are created in each day? Bin the document date by year interval with a line chart., ###ASSISTANT: SELECT Document_Date, COUNT(Document_Date) FROM Ref_Document_Types AS T1 JOIN Documents AS T2 ON T1.Document_Type_Code = T2.Document_Type_Code
2,637
###HUMAN: When was the loan started when the coutry is eng, the loan club is sunderland and the end source is south wales echo?, ###ASSISTANT: SELECT "Started" FROM table_46421 WHERE "Country" = 'eng' AND "Loan Club" = 'sunderland' AND "End Source" = 'south wales echo'
2,638
###HUMAN: what is the name of the episode when the number of spectators was 5.60 millions?, ###ASSISTANT: SELECT "Title" FROM table_25663 WHERE "Viewers (millions)" = '5.60'
2,639
###HUMAN: When did the episode title 'Duet For One' air?, ###ASSISTANT: SELECT "Original air date" FROM table_16360 WHERE "Title" = 'Duet for One'
2,640
###HUMAN: how many patients had the drug code acet650r?, ###ASSISTANT: SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE prescriptions.formulary_drug_cd = "ACET650R"
2,641
###HUMAN: until 2104, what was the monthly minimum weight of patient 22517?, ###ASSISTANT: SELECT MIN(chartevents.valuenum) FROM chartevents WHERE chartevents.icustay_id IN (SELECT icustays.icustay_id FROM icustays WHERE icustays.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 22517)) AND chartevents.itemid IN (SELECT d_items.itemid FROM d_items WHERE d_items.label = 'admit wt' AND d_items.linksto = 'chartevents') AND STRFTIME('%y', chartevents.charttime) <= '2104' GROUP BY STRFTIME('%y-%m', chartevents.charttime)
2,642
###HUMAN: What was the decision of the game when Montreal was the home team?, ###ASSISTANT: SELECT decision FROM table_name_90 WHERE home = "montreal"
2,643
###HUMAN: What is the 2004 that has a of grand slam tournaments in2006 ?, ###ASSISTANT: SELECT "2004" FROM table_40489 WHERE "2006" = 'grand slam tournaments'
2,644
###HUMAN: Which divisions have 565 as the number of winning tickets?, ###ASSISTANT: SELECT "Divisions" FROM table_23618 WHERE "Number of winning tickets" = '565'
2,645
###HUMAN: Average score per hundred views., ###ASSISTANT: WITH counts_cte AS (SELECT LAST_DATE_OF_MONTH(p.CreationDate) AS Cmonth, SUM(Score) AS Score, SUM(ViewCount) AS Views FROM Posts AS p WHERE PostTypeId = 1 GROUP BY LAST_DATE_OF_MONTH(p.CreationDate)) SELECT Cmonth, 100 * (CAST(Score AS FLOAT)) / (CAST(Views AS FLOAT)) AS "score_per_view" FROM counts_cte ORDER BY Cmonth
2,646
###HUMAN: WHAT IS THE BUDGET FOR THE INCREDIBLES?, ###ASSISTANT: SELECT budget FROM table_name_28 WHERE film = "the incredibles"
2,647
###HUMAN: What's the average year for the name aida-wedo dorsa with a diameter less than 450?, ###ASSISTANT: SELECT AVG("Year named") FROM table_46408 WHERE "Name" = 'aida-wedo dorsa' AND "Diameter (km)" < '450'
2,648
###HUMAN: how many patients during this year have received a sodium, urine test?, ###ASSISTANT: SELECT COUNT(DISTINCT admissions.subject_id) FROM admissions WHERE admissions.hadm_id IN (SELECT labevents.hadm_id FROM labevents WHERE labevents.itemid IN (SELECT d_labitems.itemid FROM d_labitems WHERE d_labitems.label = 'sodium, urine') AND DATETIME(labevents.charttime, 'start of year') = DATETIME(CURRENT_TIME(), 'start of year', '-0 year'))
2,649
###HUMAN: What is the total sum of the goals at competitions with more than 10 draws?, ###ASSISTANT: SELECT SUM("Goals for") FROM table_43363 WHERE "Drawn" > '10'
2,650
###HUMAN: Which actor from Serbia was nominated for best actor in a supporting role?, ###ASSISTANT: SELECT actors_name FROM table_10236830_4 WHERE nomination = "Best Actor in a Supporting Role" AND country = "Serbia"
2,651
###HUMAN: Who wrote the episode that originally aired on March 1, 1998?, ###ASSISTANT: SELECT written_by FROM table_name_42 WHERE original_airdate = "march 1, 1998"
2,652
###HUMAN: With a works number of 40864 for the builder of Baldwin Locomotive Works, the number listed is?, ###ASSISTANT: SELECT number FROM table_name_15 WHERE builder = "baldwin locomotive works" AND works_number = 40864
2,653
###HUMAN: Who was the incumbent when henry e. barbour ran?, ###ASSISTANT: SELECT candidates FROM table_1342379_5 WHERE incumbent = "Henry E. Barbour"
2,654
###HUMAN: Show the number of departments created in different year and bin creation time by year in a line chart, and I want to rank in ascending by the x-axis., ###ASSISTANT: SELECT Creation, COUNT(Creation) FROM department ORDER BY Creation
2,655
###HUMAN: Which venue was used 11 february 1996?, ###ASSISTANT: SELECT venue FROM table_name_45 WHERE date = "11 february 1996"
2,656
###HUMAN: What is the total number of seats with gavin duffy in series 4?, ###ASSISTANT: SELECT COUNT("Seat") FROM table_12149 WHERE "Series 4" = 'gavin duffy'
2,657
###HUMAN: what is the number of patients whose marital status is single and primary disease is hypoxia?, ###ASSISTANT: SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.marital_status = "SINGLE" AND demographic.diagnosis = "HYPOXIA"
2,658
###HUMAN: Which driver won at the Sachsenring circuit?, ###ASSISTANT: SELECT winning_driver FROM table_1140114_5 WHERE circuit = "Sachsenring"
2,659
###HUMAN: NoSQL datastore questions by year., ###ASSISTANT: SELECT Tags.TagName, YEAR(DATE(Posts.CreationDate)) AS year, COUNT(Posts.Id) FROM Tags, PostTags, Posts WHERE Tags.TagName IN ('cassandra') AND Tags.Id = PostTags.TagId AND PostTags.PostId = Posts.Id AND Posts.CreationDate > '2013-01-01' AND Posts.CreationDate < '2021-01-01' GROUP BY Tags.TagName, YEAR(DATE(Posts.CreationDate)) ORDER BY Tags.TagName, year DESC
2,660
###HUMAN: How many opponents did the Sun Devils play when they scored 41 points?, ###ASSISTANT: SELECT COUNT("Opponent") FROM table_2401 WHERE "Sun Devils points" = '41'
2,661
###HUMAN: what was the highest three diagnosis, which had the highest three year mortality rate?, ###ASSISTANT: SELECT d_icd_diagnoses.short_title FROM d_icd_diagnoses WHERE d_icd_diagnoses.icd9_code IN (SELECT t4.icd9_code FROM (SELECT t3.icd9_code, DENSE_RANK() OVER (ORDER BY t3.c1 DESC) AS c2 FROM (SELECT t2.icd9_code, 100 - SUM(CASE WHEN patients.dod IS NULL THEN 1 WHEN STRFTIME('%j', patients.dod) - STRFTIME('%j', t2.charttime) > 3 * 365 THEN 1 ELSE 0 END) * 100 / COUNT(*) AS c1 FROM (SELECT t1.subject_id, t1.icd9_code, t1.charttime FROM (SELECT admissions.subject_id, diagnoses_icd.icd9_code, diagnoses_icd.charttime FROM diagnoses_icd JOIN admissions ON diagnoses_icd.hadm_id = admissions.hadm_id GROUP BY admissions.subject_id, diagnoses_icd.icd9_code HAVING MIN(diagnoses_icd.charttime) = diagnoses_icd.charttime) AS t1 WHERE STRFTIME('%j', CURRENT_TIME()) - STRFTIME('%j', t1.charttime) > 3 * 365) AS t2 JOIN patients ON t2.subject_id = patients.subject_id GROUP BY t2.icd9_code) AS t3) AS t4 WHERE t4.c2 <= 3)
2,662
###HUMAN: Name the agg for seba united, ###ASSISTANT: SELECT agg FROM table_name_12 WHERE team_1 = "seba united"
2,663
###HUMAN: What was the attendance when the score was 88-98?, ###ASSISTANT: SELECT attendance FROM table_name_20 WHERE score = "88-98"
2,664
###HUMAN: What is the name of the race on 16 september?, ###ASSISTANT: SELECT "Race Name" FROM table_77933 WHERE "Date" = '16 september'
2,665
###HUMAN: Which nationality is the player from the Philadelphia Flyers?, ###ASSISTANT: SELECT nationality FROM table_1473672_3 WHERE nhl_team = "Philadelphia Flyers"
2,666
###HUMAN: What was the minimum OTL amount?, ###ASSISTANT: SELECT MIN("OTL") FROM table_1961
2,667
###HUMAN: Select All Javascript Questions and Accepted answers., ###ASSISTANT: SELECT QPosts.ViewCount, QPosts.LastActivityDate, QPosts.Title, QPosts.Id, QPosts.Body, QPosts.AcceptedAnswerId AS "answer Id", APosts.Body FROM Posts AS QPosts, Posts AS APosts, PostTags WHERE (QPosts.Id = PostTags.PostId) AND (PostTags.TagId = 3) AND (QPosts.PostTypeId = 1) AND APosts.Id = QPosts.AcceptedAnswerId LIMIT 20000
2,668
###HUMAN: Who is the lead for the team with Nkeiruka Ezekh as second?, ###ASSISTANT: SELECT lead FROM table_name_59 WHERE second = "nkeiruka ezekh"
2,669
###HUMAN: what were the three most commonly prescribed medications during a year before for patients who were also prescribed with methylprednisolone sodium succ at the same time?, ###ASSISTANT: SELECT t3.drug FROM (SELECT t2.drug, DENSE_RANK() OVER (ORDER BY COUNT(*) DESC) AS c1 FROM (SELECT admissions.subject_id, prescriptions.startdate FROM prescriptions JOIN admissions ON prescriptions.hadm_id = admissions.hadm_id WHERE prescriptions.drug = 'methylprednisolone sodium succ' AND DATETIME(prescriptions.startdate, 'start of year') = DATETIME(CURRENT_TIME(), 'start of year', '-1 year')) AS t1 JOIN (SELECT admissions.subject_id, prescriptions.drug, prescriptions.startdate FROM prescriptions JOIN admissions ON prescriptions.hadm_id = admissions.hadm_id WHERE DATETIME(prescriptions.startdate, 'start of year') = DATETIME(CURRENT_TIME(), 'start of year', '-1 year')) AS t2 ON t1.subject_id = t2.subject_id WHERE DATETIME(t1.startdate) = DATETIME(t2.startdate) GROUP BY t2.drug) AS t3 WHERE t3.c1 <= 3
2,670
###HUMAN: what is age and days of hospital stay of subject name michelle medina?, ###ASSISTANT: SELECT demographic.age, demographic.days_stay FROM demographic WHERE demographic.name = "Michelle Medina"
2,671
###HUMAN: pm flights leaving SAN FRANCISCO arriving BOSTON, ###ASSISTANT: SELECT DISTINCT flight.flight_id FROM airport_service AS AIRPORT_SERVICE_0, airport_service AS AIRPORT_SERVICE_1, city AS CITY_0, city AS CITY_1, flight WHERE ((flight.departure_time <= 2359 AND flight.departure_time >= 1200) AND CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'BOSTON' AND flight.to_airport = AIRPORT_SERVICE_1.airport_code) AND CITY_0.city_code = AIRPORT_SERVICE_0.city_code AND CITY_0.city_name = 'SAN FRANCISCO' AND flight.from_airport = AIRPORT_SERVICE_0.airport_code
2,672
###HUMAN: What year was stage 8 reached?, ###ASSISTANT: SELECT year FROM table_name_54 WHERE stages = "8"
2,673
###HUMAN: what is marital status and age of subject name orville ford?, ###ASSISTANT: SELECT demographic.marital_status, demographic.age FROM demographic WHERE demographic.name = "Orville Ford"
2,674
###HUMAN: What amount of points for were there when there was 52 points?, ###ASSISTANT: SELECT points_for FROM table_13399573_3 WHERE points = "52"
2,675
###HUMAN: What position did the draft pick going to saskatchewan play?, ###ASSISTANT: SELECT position FROM table_28059992_5 WHERE cfl_team = "Saskatchewan"
2,676
###HUMAN: What season features writer Michael Poryes?, ###ASSISTANT: SELECT "Season #" FROM table_72254 WHERE "Written by" = 'Michael Poryes'
2,677
###HUMAN: Name the sum of frequency will call sign of k259aw, ###ASSISTANT: SELECT SUM(frequency_mhz) FROM table_name_67 WHERE call_sign = "k259aw"
2,678
###HUMAN: Name the operator with berths more than 1 and depth of 12.5-15.5, ###ASSISTANT: SELECT operator FROM table_name_81 WHERE berths > 1 AND depth__m_ = "12.5-15.5"
2,679
###HUMAN: Which claim processing stage has the most claims? Show the claim status name., ###ASSISTANT: SELECT t2.claim_status_name FROM claims_processing AS t1 JOIN claims_processing_stages AS t2 ON t1.claim_stage_id = t2.claim_stage_id GROUP BY t1.claim_stage_id ORDER BY COUNT(*) DESC LIMIT 1
2,680
###HUMAN: acute or poorly controlled medical illness: blood pressure > 180 mmhg systolic or 100 mmhg diastolic; myocardial infarction within 6 months; uncompensated congestive heart failure ( nyha class iii or iv ) , severe renal, hepatic or gastrointestinal disease that could alter drug pharmacokinetics; blood glucose > 180 mg / dl on repeated testing at entry into study or need for insulin therapy, ###ASSISTANT: SELECT * FROM table_train_135 WHERE systolic_blood_pressure_sbp > 180 OR diastolic_blood_pressure_dbp > 100 OR myocardial_infarction = 1 OR heart_disease = 1 OR renal_disease = 1 OR hepatic_disease = 1 OR gastrointestinal_disease = 1 OR blood_glucose > 180
2,681
###HUMAN: Besides a general elective , would RCSSCI 396 fulfill any requirements ?, ###ASSISTANT: SELECT DISTINCT program_course.category FROM course, program_course WHERE course.department = 'RCSSCI' AND course.number = 396 AND program_course.course_id = course.course_id
2,682
###HUMAN: give me the number of patients whose insurance is government and admission location is emergency room admit?, ###ASSISTANT: SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.insurance = "Government" AND demographic.admission_location = "EMERGENCY ROOM ADMIT"
2,683
###HUMAN: Return a bar chart on how many students are older than 20 in each dorm?, and I want to rank in ascending by the Y., ###ASSISTANT: SELECT dorm_name, COUNT(*) FROM Student AS T1 JOIN Lives_in AS T2 ON T1.stuid = T2.stuid JOIN Dorm AS T3 ON T3.dormid = T2.dormid WHERE T1.Age > 20 GROUP BY T3.dorm_name ORDER BY COUNT(*)
2,684
###HUMAN: give me the flights on tuesday from LOS ANGELES to PITTSBURGH, ###ASSISTANT: SELECT DISTINCT flight.flight_id FROM airport_service AS AIRPORT_SERVICE_0, airport_service AS AIRPORT_SERVICE_1, city AS CITY_0, city AS CITY_1, date_day, days, flight WHERE (CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'PITTSBURGH' AND date_day.day_number = 22 AND date_day.month_number = 3 AND date_day.year = 1991 AND days.day_name = date_day.day_name AND flight.flight_days = days.days_code AND flight.to_airport = AIRPORT_SERVICE_1.airport_code) AND CITY_0.city_code = AIRPORT_SERVICE_0.city_code AND CITY_0.city_name = 'LOS ANGELES' AND flight.from_airport = AIRPORT_SERVICE_0.airport_code
2,685
###HUMAN: How many draws did Mortlake have when the losses were more than 5?, ###ASSISTANT: SELECT COUNT(draws) FROM table_name_94 WHERE losses > 5 AND club = "mortlake"
2,686
###HUMAN: How many themes are there where the order # is 9?, ###ASSISTANT: SELECT COUNT("Theme") FROM table_28505 WHERE "Order #" = '9'
2,687
###HUMAN: what is the first tournament listed ?, ###ASSISTANT: SELECT "tournament" FROM table_204_328 WHERE id = 1
2,688
###HUMAN: provide the number of patients whose ethnicity is hispanic or latino and procedure short title is ptca?, ###ASSISTANT: SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN procedures ON demographic.hadm_id = procedures.hadm_id WHERE demographic.ethnicity = "HISPANIC OR LATINO" AND procedures.short_title = "PTCA"
2,689
###HUMAN: how many patients under the age of 83 stayed in the hospital for atleast a day?, ###ASSISTANT: SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.age < "83" AND demographic.days_stay > "0"
2,690
###HUMAN: Which Incumbent has a District of massachusetts 8?, ###ASSISTANT: SELECT incumbent FROM table_name_47 WHERE district = "massachusetts 8"
2,691
###HUMAN: Which state spent the most revenue towards schools and whats the state average score, ###ASSISTANT: SELECT T2.state, T3.average_scale_score FROM finrev_fed_key_17 AS T2 JOIN finrev_fed_17 AS T1 ON T1.state_code = T2.state_code JOIN ndecoreexcel_math_grade8 AS T3 ON T2.state = T3.state GROUP BY T2.state ORDER BY SUM(T1.t_fed_rev) DESC LIMIT 1
2,692
###HUMAN: Name the courses that are worth 16 credits ., ###ASSISTANT: SELECT DISTINCT name, number FROM course WHERE credits = 16 AND department = 'EECS'
2,693
###HUMAN: How may draws did libertad have?, ###ASSISTANT: SELECT COUNT(draws) FROM table_14889048_2 WHERE team = "Libertad"
2,694
###HUMAN: how many female patients had the procedure short title parent infus nutrit sub?, ###ASSISTANT: SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN procedures ON demographic.hadm_id = procedures.hadm_id WHERE demographic.gender = "F" AND procedures.short_title = "Parent infus nutrit sub"
2,695
###HUMAN: Give me the number of the dates when the max temperature was higher than 85, and display from high to low by the Y., ###ASSISTANT: SELECT date, COUNT(date) FROM weather WHERE max_temperature_f > 85 ORDER BY COUNT(date) DESC
2,696
###HUMAN: patient 006-98330's potassium last measured on the first hospital visit is less than the first value measured on the first hospital visit?, ###ASSISTANT: SELECT (SELECT lab.labresult FROM lab WHERE lab.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '006-98330' AND NOT patient.hospitaldischargetime IS NULL ORDER BY patient.hospitaladmittime LIMIT 1)) AND lab.labname = 'potassium' ORDER BY lab.labresulttime DESC LIMIT 1) < (SELECT lab.labresult FROM lab WHERE lab.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '006-98330' AND NOT patient.hospitaldischargetime IS NULL ORDER BY patient.hospitaladmittime LIMIT 1)) AND lab.labname = 'potassium' ORDER BY lab.labresulttime LIMIT 1)
2,697
###HUMAN: what is 2010 when 2006 is 3r?, ###ASSISTANT: SELECT "2010" FROM table_47843 WHERE "2006" = '3r'
2,698
###HUMAN: What is the highest silver that has 57 as the total, with a bronze greater than 20?, ###ASSISTANT: SELECT MAX("Silver") FROM table_63028 WHERE "Total" = '57' AND "Bronze" > '20'
2,699
###HUMAN: Visualize the total smallest rating of different movie title using a pie chart., ###ASSISTANT: SELECT T2.title, SUM(MIN(T1.stars)) FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID GROUP BY T2.title