instruction
stringlengths
0
1.06k
input
stringlengths
11
5.3k
response
stringlengths
2
4.44k
Who had the high points while Dirk Nowitzki (13) had the high rebounds?
CREATE TABLE table_17288869_7 (high_points VARCHAR,high_rebounds VARCHAR)
SELECT high_points FROM table_17288869_7 WHERE high_rebounds = "Dirk Nowitzki (13)"
what is the only series listed in 2007-2008 ?
CREATE TABLE table_203_198 (id number,"season" text,"series" text,"team" text,"races" number,"wins" number,"poles" number,"fast laps" number,"points" number,"pos." text)
SELECT "series" FROM table_203_198 WHERE "season" = '2007-08'
What is the rank of Manuel Cortina Mart nez?
CREATE TABLE table_65023 ("Rank" real,"Athletes" text,"Country" text,"Time" text,"Notes" text)
SELECT "Rank" FROM table_65023 WHERE "Athletes" = 'manuel cortina martínez'
Where was there a school founded in 1927?
CREATE TABLE table_2064747_1 (location_s_ VARCHAR,founded VARCHAR)
SELECT location_s_ FROM table_2064747_1 WHERE founded = 1927
Name the chinese traditional for
CREATE TABLE table_22701 ("Album#" text,"English Title" text,"Chinese (Traditional)" text,"Chinese (Simplified)" text,"Release date" text,"Label" text)
SELECT "Chinese (Traditional)" FROM table_22701 WHERE "Chinese (Simplified)" = '美丽人生'
how many high points where date is february 19
CREATE TABLE table_20010140_10 (high_points VARCHAR,date VARCHAR)
SELECT COUNT(high_points) FROM table_20010140_10 WHERE date = "February 19"
in what competition did this competitor place the same as he did at the 1984 olympic games ?
CREATE TABLE table_204_780 (id number,"year" number,"competition" text,"venue" text,"position" text,"notes" text)
SELECT "competition" FROM table_204_780 WHERE "year" <> 1984 AND "position" = (SELECT "position" FROM table_204_780 WHERE "year" = 1984)
What method had Adriano Martins as an opponent and a time of 5:00?
CREATE TABLE table_name_36 (method VARCHAR,time VARCHAR,opponent VARCHAR)
SELECT method FROM table_name_36 WHERE time = "5:00" AND opponent = "adriano martins"
Bar chart x axis meter 500 y axis meter_100
CREATE TABLE stadium (ID int,name text,Capacity int,City text,Country text,Opening_year int)CREATE TABLE swimmer (ID int,name text,Nationality text,meter_100 real,meter_200 text,meter_300 text,meter_400 text,meter_500 text,meter_600 text,meter_700 text,Time text)CREATE TABLE event (ID int,Name text,Stadium_ID int,Year ...
SELECT meter_500, meter_100 FROM swimmer
What is the most points earlier than 1953 with a Ferrari 375/50 chassis?
CREATE TABLE table_name_22 (points INTEGER,year VARCHAR,chassis VARCHAR)
SELECT MAX(points) FROM table_name_22 WHERE year < 1953 AND chassis = "ferrari 375/50"
What is the total of 2013 with 6th?
CREATE TABLE table_68541 ("2001" text,"2004" text,"2009" text,"2013" text,"Total" real)
SELECT MAX("Total") FROM table_68541 WHERE "2013" = '6th'
What is the smallest grid for driver of juan pablo montoya?
CREATE TABLE table_53287 ("Driver" text,"Constructor" text,"Laps" real,"Time/Retired" text,"Grid" real)
SELECT MIN("Grid") FROM table_53287 WHERE "Driver" = 'juan pablo montoya'
Who was in local affairs in 2012-2013?
CREATE TABLE table_name_9 (local_affairs VARCHAR,year VARCHAR)
SELECT local_affairs FROM table_name_9 WHERE year = "2012-2013"
How many parties of the time they left office, binning the left office time into Year interval, and then split by the minister's name, sort in desc by the y-axis.
CREATE TABLE party_events (Event_ID int,Event_Name text,Party_ID int,Member_in_charge_ID int)CREATE TABLE region (Region_ID int,Region_name text,Date text,Label text,Format text,Catalogue text)CREATE TABLE party (Party_ID int,Minister text,Took_office text,Left_office text,Region_ID int,Party_name text)CREATE TABLE mem...
SELECT Left_office, COUNT(Left_office) FROM party GROUP BY Minister ORDER BY COUNT(Left_office) DESC
how many patients stayed in hospital for more than 6 days and were diagnosed with orthostatic hypertension?
CREATE TABLE prescriptions (subject_id text,hadm_id text,icustay_id text,drug_type text,drug text,formulary_drug_cd text,route text,drug_dose text)CREATE TABLE diagnoses (subject_id text,hadm_id text,icd9_code text,short_title text,long_title text)CREATE TABLE demographic (subject_id text,hadm_id text,name text,marital...
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id WHERE demographic.days_stay > "6" AND diagnoses.short_title = "Orthostatic hypotension"
Name the least game for january 29
CREATE TABLE table_73520 ("Game" real,"Date" text,"Team" text,"Score" text,"High points" text,"High rebounds" text,"High assists" text,"Location Attendance" text,"Record" text)
SELECT MIN("Game") FROM table_73520 WHERE "Date" = 'January 29'
What is the lowest Perigee with a Launch date of 1970-08-26?
CREATE TABLE table_name_30 (perigee__km_ INTEGER,launch_date VARCHAR)
SELECT MIN(perigee__km_) FROM table_name_30 WHERE launch_date = "1970-08-26"
What is the position for sail number aus 03?
CREATE TABLE table_3315 ("Position" real,"Sail number" text,"Yacht" text,"State/country" text,"Yacht type" text,"LOA (Metres)" text,"Skipper" text,"Corrected time d:hh:mm:ss" text)
SELECT MIN("Position") FROM table_3315 WHERE "Sail number" = 'AUS 03'
What is the largest number of cars per set that is less than 9?
CREATE TABLE table_name_30 (number INTEGER,cars_per_set INTEGER)
SELECT MAX(number) FROM table_name_30 WHERE cars_per_set < 9
Show the facility codes of apartments with more than 4 bedrooms.
CREATE TABLE view_unit_status (apt_id number,apt_booking_id number,status_date time,available_yn others)CREATE TABLE apartment_facilities (apt_id number,facility_code text)CREATE TABLE apartment_bookings (apt_booking_id number,apt_id number,guest_id number,booking_status_code text,booking_start_date time,booking_end_da...
SELECT T1.facility_code FROM apartment_facilities AS T1 JOIN apartments AS T2 ON T1.apt_id = T2.apt_id WHERE T2.bedroom_count > 4
Who left a seat open for the district of connecticut at-large
CREATE TABLE table_224844_4 (vacator VARCHAR,district VARCHAR)
SELECT vacator FROM table_224844_4 WHERE district = "Connecticut At-large"
When mithuna is the international alphabet of sanskrit transliteration what is the ruling planet?
CREATE TABLE table_22513 ("Number" real,"Sanskrit" text,"International Alphabet of Sanskrit Transliteration" text,"Sanskrit gloss" text,"Western name" text,"Greek" text,"Gloss" text,"Tattva (Element)" text,"Quality" text,"Ruling Planet" text)
SELECT "Ruling Planet" FROM table_22513 WHERE "International Alphabet of Sanskrit Transliteration" = 'Mithuna'
Who is the player when the bbi is 5/27?
CREATE TABLE table_29385 ("Player" text,"Team" text,"Matches" real,"Overs" text,"Wickets" real,"Average" text,"Economy" text,"BBI" text,"4wi" real,"5wi" real)
SELECT "Player" FROM table_29385 WHERE "BBI" = '5/27'
For those employees who did not have any job in the past, show me about the distribution of hire_date and the sum of salary bin hire_date by time in a bar chart, list in desc by the Y please.
CREATE TABLE employees (EMPLOYEE_ID decimal(6,0),FIRST_NAME varchar(20),LAST_NAME varchar(25),EMAIL varchar(25),PHONE_NUMBER varchar(20),HIRE_DATE date,JOB_ID varchar(10),SALARY decimal(8,2),COMMISSION_PCT decimal(2,2),MANAGER_ID decimal(6,0),DEPARTMENT_ID decimal(4,0))CREATE TABLE regions (REGION_ID decimal(5,0),REGIO...
SELECT HIRE_DATE, SUM(SALARY) FROM employees WHERE NOT EMPLOYEE_ID IN (SELECT EMPLOYEE_ID FROM job_history) ORDER BY SUM(SALARY) DESC
which jurisdiction is listed the most ?
CREATE TABLE table_204_87 (id number,"courthouse" text,"city" text,"street address" text,"jurisdiction" text,"dates of use" text,"named for" text)
SELECT "jurisdiction" FROM table_204_87 GROUP BY "jurisdiction" ORDER BY COUNT(*) DESC LIMIT 1
What office did Henry Hagner run for on the prohibition ticket?
CREATE TABLE table_name_31 (office VARCHAR,prohibition_ticket VARCHAR)
SELECT office FROM table_name_31 WHERE prohibition_ticket = "henry hagner"
Bar chart x axis name y axis the number of name, show in descending by the Y-axis please.
CREATE TABLE Manufacturers (Code INTEGER,Name VARCHAR(255),Headquarter VARCHAR(255),Founder VARCHAR(255),Revenue REAL)CREATE TABLE Products (Code INTEGER,Name VARCHAR(255),Price DECIMAL,Manufacturer INTEGER)
SELECT Name, COUNT(Name) FROM Products GROUP BY Name ORDER BY COUNT(Name) DESC
Which college is present in the hometown of Crete, Illinois?
CREATE TABLE table_11677691_9 (college VARCHAR,hometown VARCHAR)
SELECT college FROM table_11677691_9 WHERE hometown = "Crete, Illinois"
had patient 031-3355 been given a electrolyte administration - oral procedure since 2103?
CREATE TABLE allergy (allergyid number,patientunitstayid number,drugname text,allergyname text,allergytime time)CREATE TABLE lab (labid number,patientunitstayid number,labname text,labresult number,labresulttime time)CREATE TABLE treatment (treatmentid number,patientunitstayid number,treatmentname text,treatmenttime ti...
SELECT COUNT(*) > 0 FROM treatment WHERE treatment.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '031-3355')) AND treatment.treatmentname = 'electrolyte administration - oral...
what is the monthly minimum amount of indwelling catheter that patient 002-52932 had until 03/22/2104?
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 microlab (microlabid number,patientunitstayid number,culturesite text,orga...
SELECT MIN(intakeoutput.cellvaluenumeric) FROM intakeoutput WHERE intakeoutput.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '002-52932')) AND intakeoutput.celllabel = 'indwe...
What's the ARWU ranking that has the int' student review of 144, a median rank of less than 10, and 2000 Singapore Asiaweek of none?
CREATE TABLE table_50749 ("2010 ARWU Rankings" text,"2010 QS World Rankings" text,"2010 QS Asian Rankings" text,"2010 eduniversal Rankings" text,"2009 QS Asian Rankings: Int\u2019l faculty review" text,"2009 QS Asian Rankings: Int\u2019l student review" real,"2000 Singapore \u201cAsiaweek\u201d Rankings" text,"Universi...
SELECT "2010 ARWU Rankings" FROM table_50749 WHERE "2000 Singapore \u201cAsiaweek\u201d Rankings" = 'none' AND "Median ranks" < '10' AND "2009 QS Asian Rankings: Int\u2019l student review" = '144'
Which National team has a Club of arsenal, and Apps smaller than 4, and a Year of 2010?
CREATE TABLE table_13250 ("National team" text,"Club" text,"Year" text,"Apps" real,"Goals" real)
SELECT "National team" FROM table_13250 WHERE "Club" = 'arsenal' AND "Apps" < '4' AND "Year" = '2010'
How many people attended the game that had the Clippers as visiting team?
CREATE TABLE table_name_47 (attendance VARCHAR,visitor VARCHAR)
SELECT attendance FROM table_name_47 WHERE visitor = "clippers"
What was his position when he garnered 38 points?
CREATE TABLE table_27778 ("Season" real,"Series" text,"Team" text,"Races" real,"Wins" real,"Poles" real,"F/Laps" real,"Podiums" real,"Points" text,"Position" text)
SELECT "Position" FROM table_27778 WHERE "Points" = '38'
How many sitting politicians were originally elected in 1972?
CREATE TABLE table_1341663_11 (incumbent VARCHAR,first_elected VARCHAR)
SELECT COUNT(incumbent) FROM table_1341663_11 WHERE first_elected = 1972
how many episodes had their original airdate in february ?
CREATE TABLE table_201_24 (id number,"episode number" number,"original airdate" text,"title" text,"disc" number,"description" text)
SELECT COUNT("episode number") FROM table_201_24 WHERE "original airdate" = 2
Tell me the tournament for score in the final of 1 6, 3 6
CREATE TABLE table_32050 ("Outcome" text,"Date" text,"Tournament" text,"Surface" text,"Partner" text,"Opponents in the final" text,"Score in the final" text)
SELECT "Tournament" FROM table_32050 WHERE "Score in the final" = '1–6, 3–6'
is there a flight from BOSTON to ATLANTA which leaves BOSTON in the afternoon and arrives close to 5pm
CREATE TABLE time_interval (period text,begin_time int,end_time int)CREATE TABLE restriction (restriction_code text,advance_purchase int,stopovers text,saturday_stay_required text,minimum_stay int,maximum_stay int,application text,no_discounts text)CREATE TABLE days (days_code varchar,day_name varchar)CREATE TABLE flig...
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.arrival_time <= 1715 AND flight.arrival_time >= 1645) AND CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'ATLANTA' AND flight.to...
DENVER to ATLANTA
CREATE TABLE restriction (restriction_code text,advance_purchase int,stopovers text,saturday_stay_required text,minimum_stay int,maximum_stay int,application text,no_discounts text)CREATE TABLE flight_stop (flight_id int,stop_number int,stop_days text,stop_airport text,arrival_time int,arrival_airline text,arrival_flig...
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 CITY_0.city_code = AIRPORT_SERVICE_0.city_code AND CITY_0.city_name = 'DENVER' AND CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'ATLANTA...
how many roles did this actor have before 2010 ?
CREATE TABLE table_204_729 (id number,"year" text,"show" text,"role" text,"channel" text,"notes" text)
SELECT COUNT("role") FROM table_204_729 WHERE "year" < 2010
What was the location of the competition with a Rank-Final of 1st and a Score-Qualifying under 28.975?
CREATE TABLE table_13729 ("Year" real,"Competition Description" text,"Location" text,"Apparatus" text,"Rank-Final" text,"Score-Final" real,"Rank-Qualifying" text,"Score-Qualifying" real)
SELECT "Location" FROM table_13729 WHERE "Rank-Final" = '1st' AND "Score-Qualifying" < '28.975'
Class of d, and a Frequency MHz smaller than 107.7, and a ERP W smaller than 232 has what call sign?
CREATE TABLE table_name_24 (call_sign VARCHAR,erp_w VARCHAR,class VARCHAR,frequency_mhz VARCHAR)
SELECT call_sign FROM table_name_24 WHERE class = "d" AND frequency_mhz < 107.7 AND erp_w < 232
how many procedures for ddavp injection are performed since 6 years ago?
CREATE TABLE intakeoutput (intakeoutputid number,patientunitstayid number,cellpath text,celllabel text,cellvaluenumeric number,intakeoutputtime time)CREATE TABLE treatment (treatmentid number,patientunitstayid number,treatmentname text,treatmenttime time)CREATE TABLE diagnosis (diagnosisid number,patientunitstayid numb...
SELECT COUNT(*) FROM treatment WHERE treatment.treatmentname = 'ddavp injection' AND DATETIME(treatment.treatmenttime) >= DATETIME(CURRENT_TIME(), '-6 year')
What begin has victoria as the state/territory and a ICA0 of ymml?
CREATE TABLE table_name_18 (begin VARCHAR,state_territory VARCHAR,icao VARCHAR)
SELECT begin FROM table_name_18 WHERE state_territory = "victoria" AND icao = "ymml"
what is diagnoses long title of diagnoses icd9 code 7756?
CREATE TABLE procedures (subject_id text,hadm_id text,icd9_code text,short_title text,long_title text)CREATE TABLE diagnoses (subject_id text,hadm_id text,icd9_code text,short_title text,long_title text)CREATE TABLE lab (subject_id text,hadm_id text,itemid text,charttime text,flag text,value_unit text,label text,fluid ...
SELECT diagnoses.long_title FROM diagnoses WHERE diagnoses.icd9_code = "7756"
Most viewed posts for tag.
CREATE TABLE Users (Id number,Reputation number,CreationDate time,DisplayName text,LastAccessDate time,WebsiteUrl text,Location text,AboutMe text,Views number,UpVotes number,DownVotes number,ProfileImageUrl text,EmailHash text,AccountId number)CREATE TABLE ReviewTaskResultTypes (Id number,Name text,Description text)CRE...
SELECT ViewCount, Score, ((Score + 0.0) / (ViewCount + 0.0)) AS Strength, Title, Tags FROM Posts INNER JOIN PostTags ON PostTags.PostId = Posts.Id WHERE PostTags.TagId = 1 AND ((Score + 0.0) / (ViewCount + 0.0)) > 0.00724 ORDER BY ViewCount DESC LIMIT 50
Return the decor of the room named 'Recluse and defiance'.
CREATE TABLE rooms (roomid text,roomname text,beds number,bedtype text,maxoccupancy number,baseprice number,decor text)CREATE TABLE reservations (code number,room text,checkin text,checkout text,rate number,lastname text,firstname text,adults number,kids number)
SELECT decor FROM rooms WHERE roomname = "Recluse and defiance"
What team was the opponent on 09/20/1975?
CREATE TABLE table_41050 ("Date" text,"Opponent" text,"Location" text,"Result" text,"Attendance" real)
SELECT "Opponent" FROM table_41050 WHERE "Date" = '09/20/1975'
What are the names of the technicians and how many machines are they assigned to repair, show from high to low by the x axis.
CREATE TABLE technician (technician_id real,Name text,Team text,Starting_Year real,Age int)CREATE TABLE machine (Machine_ID int,Making_Year int,Class text,Team text,Machine_series text,value_points real,quality_rank int)CREATE TABLE repair (repair_ID int,name text,Launch_Date text,Notes text)CREATE TABLE repair_assignm...
SELECT Name, COUNT(*) FROM repair_assignment AS T1 JOIN technician AS T2 ON T1.technician_id = T2.technician_id GROUP BY T2.Name ORDER BY Name DESC
what was the last type of the hospital admission of patient 60136 since 2105?
CREATE TABLE admissions (row_id number,subject_id number,hadm_id number,admittime time,dischtime time,admission_type text,admission_location text,discharge_location text,insurance text,language text,marital_status text,ethnicity text,age number)CREATE TABLE transfers (row_id number,subject_id number,hadm_id number,icus...
SELECT admissions.admission_type FROM admissions WHERE admissions.subject_id = 60136 AND STRFTIME('%y', admissions.admittime) >= '2105' ORDER BY admissions.admittime DESC LIMIT 1
An extremely noisy query for finding users who hate SO.
CREATE TABLE Badges (Id number,UserId number,Name text,Date time,Class number,TagBased boolean)CREATE TABLE PostTypes (Id number,Name text)CREATE TABLE ReviewTasks (Id number,ReviewTaskTypeId number,CreationDate time,DeletionDate time,ReviewTaskStateId number,PostId number,SuggestedEditId number,CompletedByReviewTaskId...
SELECT * FROM Users WHERE (AboutMe LIKE '%rude%' OR AboutMe LIKE '%belittle%') AND (AboutMe LIKE '%Stack Overflow%' OR AboutMe LIKE '%StackOverflow%' OR AboutMe LIKE '%stack overflow%' OR AboutMe LIKE '%stackoverflow%')
What is the best time for a rusport driver with a qual 2 time of 1:10.166?
CREATE TABLE table_34673 ("Name" text,"Team" text,"Qual 1" text,"Qual 2" text,"Best" real)
SELECT MAX("Best") FROM table_34673 WHERE "Team" = 'rusport' AND "Qual 2" = '1:10.166'
Return the average age across all artists.
CREATE TABLE volume (volume_id number,volume_issue text,issue_date text,weeks_on_top number,song text,artist_id number)CREATE TABLE artist (artist_id number,artist text,age number,famous_title text,famous_release_date text)CREATE TABLE music_festival (id number,music_festival text,date_of_ceremony text,category text,vo...
SELECT AVG(age) FROM artist
Tell me the name of the staff in charge of the attraction called 'US museum'.
CREATE TABLE tourist_attractions (tourist_attraction_id number,attraction_type_code text,location_id number,how_to_get_there text,name text,description text,opening_hours text,other_details text)CREATE TABLE photos (photo_id number,tourist_attraction_id number,name text,description text,filename text,other_details text...
SELECT T1.name FROM staff AS T1 JOIN tourist_attractions AS T2 ON T1.tourist_attraction_id = T2.tourist_attraction_id WHERE T2.name = "US museum"
What round had a result of 6 7 (6 8) , 1 6?
CREATE TABLE table_60479 ("Edition" text,"Round" text,"Date" text,"Surface" text,"Opponent" text,"Result" text)
SELECT "Round" FROM table_60479 WHERE "Result" = '6–7 (6–8) , 1–6'
What is the original air date for 'Oliver's Jaded Past'?
CREATE TABLE table_17551 ("No. in series" real,"No. in season" real,"Title" text,"Directed by" text,"Written by" text,"Original air date" text,"Production code" real)
SELECT "Original air date" FROM table_17551 WHERE "Title" = 'Oliver''s Jaded Past'
how many patients whose gender is f and diagnoses short title is lap surg convert to open?
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 ...
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id WHERE demographic.gender = "F" AND diagnoses.short_title = "Lap surg convert to open"
What was the score of the Jeff Tarango game?
CREATE TABLE table_33171 ("Date" text,"Tournament" text,"Surface" text,"Partner" text,"Opponents in the final" text,"Score" text)
SELECT "Score" FROM table_33171 WHERE "Partner" = 'jeff tarango'
give the number of patients under the age of41 who had the procedure for insertion of drug-eluting coronary artery stent(s).
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 ...
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN procedures ON demographic.hadm_id = procedures.hadm_id WHERE demographic.age < "41" AND procedures.long_title = "Insertion of drug-eluting coronary artery stent(s)"
what is the venue when the score is 1 goal and the date is october 11, 1997?
CREATE TABLE table_name_96 (venue VARCHAR,score VARCHAR,date VARCHAR)
SELECT venue FROM table_name_96 WHERE score = "1 goal" AND date = "october 11, 1997"
Name the time for entries being 907
CREATE TABLE table_3258 ("Date" text,"Time (ET)" text,"Event #" real,"Event" text,"Winner" text,"Prize" text,"Entries" text,"Prize Pool" text,"Elapsed Time" text)
SELECT "Time (ET)" FROM table_3258 WHERE "Entries" = '907'
Find the first names of all professors in the Accounting department who is teaching some course and the class room.
CREATE TABLE professor (emp_num number,dept_code text,prof_office text,prof_extension text,prof_high_degree text)CREATE TABLE employee (emp_num number,emp_lname text,emp_fname text,emp_initial text,emp_jobcode text,emp_hiredate time,emp_dob time)CREATE TABLE department (dept_code text,dept_name text,school_code text,em...
SELECT T2.emp_fname, T1.class_room FROM class AS T1 JOIN employee AS T2 ON T1.prof_num = T2.emp_num JOIN professor AS T3 ON T2.emp_num = T3.emp_num JOIN department AS T4 ON T4.dept_code = T3.dept_code WHERE T4.dept_name = 'Accounting'
What branch of government was the term that ended on January 3, 2001?
CREATE TABLE table_224672_2 (type VARCHAR,term_ended VARCHAR)
SELECT type FROM table_224672_2 WHERE term_ended = "January 3, 2001"
count the number of patients whose primary disease is s/p fall and year of death is less than or equal to 2112?
CREATE TABLE lab (subject_id text,hadm_id text,itemid text,charttime text,flag text,value_unit text,label text,fluid text)CREATE TABLE procedures (subject_id text,hadm_id text,icd9_code text,short_title text,long_title text)CREATE TABLE prescriptions (subject_id text,hadm_id text,icustay_id text,drug_type text,drug tex...
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.diagnosis = "S/P FALL" AND demographic.dod_year <= "2112.0"
Which CHE classes do n't meet on Friday ?
CREATE TABLE ta (campus_job_id int,student_id int,location varchar)CREATE TABLE comment_instructor (instructor_id int,student_id int,score int,comment_text varchar)CREATE TABLE offering_instructor (offering_instructor_id int,offering_id int,instructor_id int)CREATE TABLE semester (semester_id int,semester varchar,year ...
SELECT DISTINCT course.department, course.name, course.number FROM course INNER JOIN course_offering ON course.course_id = course_offering.course_id INNER JOIN semester ON semester.semester_id = course_offering.semester WHERE course_offering.friday = 'N' AND course.department = 'CHE' AND semester.semester = 'WN' AND se...
Name the replaced by when outgoing manager is kent nielsen
CREATE TABLE table_1574 ("Team" text,"Outgoing manager" text,"Manner of departure" text,"Date of vacancy" text,"Replaced by" text,"Date of appointment" text,"Position in table" text)
SELECT "Replaced by" FROM table_1574 WHERE "Outgoing manager" = 'Kent Nielsen'
Find out the number of government insurance patients who had a lactate lab test.
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 ...
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.insurance = "Government" AND lab.label = "Lactate"
what's player with position being forward and current club being real madrid
CREATE TABLE table_17875 ("No" real,"Player" text,"Height" text,"Position" text,"Year born" real,"Current Club" text)
SELECT "Player" FROM table_17875 WHERE "Position" = 'Forward' AND "Current Club" = 'Real Madrid'
What are the maximum and minimum number of transit passengers of all aiports.
CREATE TABLE airport_aircraft (id number,airport_id number,aircraft_id number)CREATE TABLE pilot (pilot_id number,name text,age number)CREATE TABLE match (round number,location text,country text,date text,fastest_qualifying text,winning_pilot text,winning_aircraft text)CREATE TABLE airport (airport_id number,airport_na...
SELECT MAX(transit_passengers), MIN(transit_passengers) FROM airport
Who was the writer for the episode originally airing on March 1, 2004?
CREATE TABLE table_26396 ("Series #" real,"Season #" real,"Title" text,"Directed by" text,"Written by" text,"Original air date" text)
SELECT "Written by" FROM table_26396 WHERE "Original air date" = 'March 1, 2004'
How many different product types are there?
CREATE TABLE products_booked (booking_id number,product_id number,returned_yn text,returned_late_yn text,booked_count number,booked_amount number)CREATE TABLE products_for_hire (product_id number,product_type_code text,daily_hire_cost number,product_name text,product_description text)CREATE TABLE view_product_availabil...
SELECT COUNT(DISTINCT product_type_code) FROM products_for_hire
What team played in the Bundesliga league with an Away record of 2-1?
CREATE TABLE table_name_6 (teams VARCHAR,league VARCHAR,away VARCHAR)
SELECT teams FROM table_name_6 WHERE league = "bundesliga" AND away = "2-1"
questions from 2010.01.01 to 2010 10.10.
CREATE TABLE PostTypes (Id number,Name text)CREATE TABLE Users (Id number,Reputation number,CreationDate time,DisplayName text,LastAccessDate time,WebsiteUrl text,Location text,AboutMe text,Views number,UpVotes number,DownVotes number,ProfileImageUrl text,EmailHash text,AccountId number)CREATE TABLE PostTags (PostId nu...
SELECT * FROM Posts WHERE CreationDate >= '2010-01-01 00:00:00' AND CreationDate < '2010-01-10 00:00:00' AND PostTypeId = 2 ORDER BY CreationDate DESC
what was the name of a drug patient 28048 was last prescribed until 51 months ago?
CREATE TABLE chartevents (row_id number,subject_id number,hadm_id number,icustay_id number,itemid number,charttime time,valuenum number,valueuom text)CREATE TABLE diagnoses_icd (row_id number,subject_id number,hadm_id number,icd9_code text,charttime time)CREATE TABLE outputevents (row_id number,subject_id number,hadm_i...
SELECT prescriptions.drug FROM prescriptions WHERE prescriptions.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 28048) AND DATETIME(prescriptions.startdate) <= DATETIME(CURRENT_TIME(), '-51 month') ORDER BY prescriptions.startdate DESC LIMIT 1
What was Jimmy Jones' rank when the matches were smaller than 285?
CREATE TABLE table_40650 ("Rank" real,"Name" text,"Years" text,"Matches" real,"Goals" real)
SELECT MAX("Rank") FROM table_40650 WHERE "Name" = 'jimmy jones' AND "Matches" < '285'
What movie did dana wynter , mel ferrer , theodore bikel star in?
CREATE TABLE table_26032940_2 (movie_title_and_year VARCHAR,main_cast VARCHAR)
SELECT movie_title_and_year FROM table_26032940_2 WHERE main_cast = "Dana Wynter , Mel Ferrer , Theodore Bikel"
What is the low silver total for switzerland with over 0 golds?
CREATE TABLE table_name_30 (silver INTEGER,gold VARCHAR,nation VARCHAR)
SELECT MIN(silver) FROM table_name_30 WHERE gold > 0 AND nation = "switzerland"
When marshmallow cookies is segment b what episode is it on netflix?
CREATE TABLE table_1195 ("Series Ep." text,"Episode" real,"Netflix" text,"Segment A" text,"Segment B" text,"Segment C" text,"Segment D" text)
SELECT "Netflix" FROM table_1195 WHERE "Segment B" = 'Marshmallow Cookies'
What is the average Draws, when Goal Difference is greater than -3, when Goals Against is 30, and when Points is greater than 45?
CREATE TABLE table_name_97 (draws INTEGER,points VARCHAR,goal_difference VARCHAR,goals_against VARCHAR)
SELECT AVG(draws) FROM table_name_97 WHERE goal_difference > -3 AND goals_against = 30 AND points > 45
What is the smallest amount of matches?
CREATE TABLE table_27268238_4 (matches INTEGER)
SELECT MIN(matches) FROM table_27268238_4
What is the model of the engine d5244 t7?
CREATE TABLE table_16828 ("Model name" text,"Power (ps)" real,"Torque (Nm@rpm)" text,"Displacement (cm\u00b3)" real,"Engine code" text,"Comment" text)
SELECT "Model name" FROM table_16828 WHERE "Engine code" = 'D5244 T7'
What is the total number of users on StackOverflow.
CREATE TABLE ReviewTaskStates (Id number,Name text,Description text)CREATE TABLE ReviewTaskResults (Id number,ReviewTaskId number,ReviewTaskResultTypeId number,CreationDate time,RejectionReasonId number,Comment text)CREATE TABLE Comments (Id number,PostId number,Score number,Text text,CreationDate time,UserDisplayName ...
SELECT * FROM Users WHERE DisplayName = 'BalusC'
What Score in the final has a Surface of hard, a Championship of washington, d.c. , u.s., and an Opponent in the final of ivan lendl?
CREATE TABLE table_61361 ("Outcome" text,"Date" real,"Championship" text,"Surface" text,"Opponent in the final" text,"Score in the final" text)
SELECT "Score in the final" FROM table_61361 WHERE "Surface" = 'hard' AND "Championship" = 'washington, d.c. , u.s.' AND "Opponent in the final" = 'ivan lendl'
Who are answering the same questions as me? List those users that have answered at least two questions which I have also answered. List those users that have answered at least two questions which I have also answered
CREATE TABLE PendingFlags (Id number,FlagTypeId number,PostId number,CreationDate time,CloseReasonTypeId number,CloseAsOffTopicReasonTypeId number,DuplicateOfQuestionId number,BelongsOnBaseHostAddress text)CREATE TABLE CloseAsOffTopicReasonTypes (Id number,IsUniversal boolean,InputTitle text,MarkdownInputGuidance text,...
SELECT COUNT(DISTINCT myAnswer.ParentId) AS QuestionCount, otherAnswer.OwnerUserId AS "user_link" FROM Posts AS myAnswer, Posts AS otherAnswer WHERE otherAnswer.OwnerUserId != @MyUserId AND myAnswer.OwnerUserId = @MyUserId AND myAnswer.ParentId = otherAnswer.ParentId AND otherAnswer.PostTypeId = 2 AND myAnswer.PostType...
What week #(s featured sara bareilles as the original artist?
CREATE TABLE table_24423 ("Week #" text,"Theme" text,"Song choice" text,"Original artist" text,"Order #" text,"Result" text)
SELECT "Week #" FROM table_24423 WHERE "Original artist" = 'Sara Bareilles'
With a tonnage of 225 what is the ship type?
CREATE TABLE table_name_93 (ship_type VARCHAR,tonnage VARCHAR)
SELECT ship_type FROM table_name_93 WHERE tonnage = "225"
How many minutes were played when there were 18 points and the opponent was Chicago Bulls?
CREATE TABLE table_77142 ("Blocks" text,"Opponent" text,"Home/Away" text,"Minutes played" real,"Points" real,"Rebounds" real,"Assists" real)
SELECT COUNT("Minutes played") FROM table_77142 WHERE "Points" = '18' AND "Opponent" = 'chicago bulls'
Find the number of web accelerators used for each Operating system, show from high to low by the total number.
CREATE TABLE browser (id int,name text,market_share real)CREATE TABLE accelerator_compatible_browser (accelerator_id int,browser_id int,compatible_since_year int)CREATE TABLE Web_client_accelerator (id int,name text,Operating_system text,Client text,Connection text)
SELECT Operating_system, COUNT(*) FROM Web_client_accelerator GROUP BY Operating_system ORDER BY COUNT(*) DESC
what city is the toamasina airport in?
CREATE TABLE table_33922 ("City" text,"Country" text,"IATA" text,"ICAO" text,"Airport" text)
SELECT "City" FROM table_33922 WHERE "Airport" = 'toamasina airport'
What date was the match on a clay surface against Andrea Hlav kov ?
CREATE TABLE table_69752 ("Outcome" text,"Date" text,"Tournament" text,"Surface" text,"Opponent" text,"Score" text)
SELECT "Date" FROM table_69752 WHERE "Surface" = 'clay' AND "Opponent" = 'andrea hlaváčková'
What is the most recent year that the Mineola Twins was nominated for outstanding actress in a play and a Drama Desk award?
CREATE TABLE table_name_54 (year INTEGER,award VARCHAR,nominated_work VARCHAR,category VARCHAR)
SELECT MAX(year) FROM table_name_54 WHERE nominated_work = "the mineola twins" AND category = "outstanding actress in a play" AND award = "drama desk award"
which driver and co driver have the most points ?
CREATE TABLE table_203_644 (id number,"pos." number,"driver" text,"co-driver" text,"car" text,"time" text,"difference" text,"points" number)
SELECT "driver", "co-driver" FROM table_203_644 ORDER BY "points" DESC LIMIT 1
When was the first performance with a replacement cast?
CREATE TABLE table_67438 ("Status" text,"Name" text,"First Performance" text,"Last Performance" text,"Style" text)
SELECT "First Performance" FROM table_67438 WHERE "Status" = 'replacement cast'
What company constructed the car with more than 0 laps and shows 5 for grid?
CREATE TABLE table_54727 ("Driver" text,"Constructor" text,"Laps" real,"Time/Retired" text,"Grid" real)
SELECT "Constructor" FROM table_54727 WHERE "Laps" > '0' AND "Grid" = '5'
what is the top five most common procedures that followed in the same hospital encounter for patients who received mechanical ventilation - pressure controlled until 2104?
CREATE TABLE cost (costid number,uniquepid text,patienthealthsystemstayid number,eventtype text,eventid number,chargetime time,cost number)CREATE TABLE diagnosis (diagnosisid number,patientunitstayid number,diagnosisname text,diagnosistime time,icd9code text)CREATE TABLE lab (labid number,patientunitstayid number,labna...
SELECT t3.treatmentname FROM (SELECT t2.treatmentname, DENSE_RANK() OVER (ORDER BY COUNT(*) DESC) AS c1 FROM (SELECT patient.uniquepid, treatment.treatmenttime, patient.patienthealthsystemstayid FROM treatment JOIN patient ON treatment.patientunitstayid = patient.patientunitstayid WHERE treatment.treatmentname = 'mecha...
what is admission location and procedure short title of subject name dominga garvin?
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 diagnoses (subject_id text,hadm_id text,icd9_code text,sho...
SELECT demographic.admission_location, procedures.short_title FROM demographic INNER JOIN procedures ON demographic.hadm_id = procedures.hadm_id WHERE demographic.name = "Dominga Garvin"
In what division was there a population density in km2 of 1,604.3 in 2011?
CREATE TABLE table_26498 ("Administrative division" text,"Area (km\u00b2) 2011**" text,"Population 2001 Census (Adjusted)" real,"Population 2011 Census (Adjusted)" real,"Population density (/km\u00b2 2011)" text)
SELECT "Administrative division" FROM table_26498 WHERE "Population density (/km\u00b2 2011)" = '1,604.3'
What venue is in Long Beach?
CREATE TABLE table_name_73 (venue VARCHAR,city VARCHAR)
SELECT venue FROM table_name_73 WHERE city = "long beach"
Which Birth has a Became Duchess of 17 april 1711 husband's ascension?
CREATE TABLE table_37214 ("Name" text,"Birth" text,"Marriage" text,"Became Duchess" text,"Ceased to be Duchess" text,"Death" text,"Spouse" text)
SELECT "Birth" FROM table_37214 WHERE "Became Duchess" = '17 april 1711 husband''s ascension'
which other author , besides lewis carroll , has won the kurt maschler award twice ?
CREATE TABLE table_203_788 (id number,"year" number,"author" text,"illustrator" text,"title" text,"publisher" text)
SELECT "author" FROM table_203_788 WHERE "author" <> 'lewis carroll' GROUP BY "author" HAVING COUNT(*) = 2