instruction
stringlengths
151
7.46k
output
stringlengths
2
4.44k
source
stringclasses
26 values
CREATE TABLE table_73023 ( "Japanese Title" text, "Romaji Title" text, "TV Station" text, "Time Frame" text, "Starring Actors" text, "Theme Song(s)" text, "Episodes" real, "Average Ratings" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- ...
SELECT "Japanese Title" FROM table_73023 WHERE "Average Ratings" = '11.6%'
wikisql
CREATE TABLE table_203_489 ( id number, "year" number, "title" text, "system" text, "developer" text, "publisher" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- what is the total amount of games activision developed ?
SELECT COUNT("title") FROM table_203_489 WHERE "developer" = 'activision'
squall
CREATE TABLE Product_Characteristics ( product_id INTEGER, characteristic_id INTEGER, product_characteristic_value VARCHAR(50) ) CREATE TABLE Ref_Product_Categories ( product_category_code VARCHAR(15), product_category_description VARCHAR(80), unit_of_measure VARCHAR(20) ) CREATE TABLE Ref_Cha...
SELECT product_category_description, COUNT(product_category_description) FROM Ref_Product_Categories AS T1 JOIN Products AS T2 ON T1.product_category_code = T2.product_category_code WHERE T2.product_description LIKE '%t%' GROUP BY product_category_description ORDER BY product_category_description
nvbench
CREATE TABLE table_45663 ( "Rank" real, "Title" text, "Studio" text, "Director(s)" text, "Worldwide Gross" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What rank has skyfall as the title?
SELECT "Rank" FROM table_45663 WHERE "Title" = 'skyfall'
wikisql
CREATE TABLE company ( Company_ID int, Rank int, Company text, Headquarters text, Main_Industry text, Sales_billion real, Profits_billion real, Assets_billion real, Market_Value real ) CREATE TABLE gas_station ( Station_ID int, Open_Year int, Location text, Manager_N...
SELECT Headquarters, COUNT(Headquarters) FROM company GROUP BY Headquarters ORDER BY COUNT(Headquarters)
nvbench
CREATE TABLE table_45625 ( "Date" text, "H/A/N" text, "Opponent" text, "Score" text, "Record" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the Score of the game against Philadelphia 76ers?
SELECT "Score" FROM table_45625 WHERE "Opponent" = 'philadelphia 76ers'
wikisql
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 lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.days_stay > "15" AND lab.label = "Calcium, Urine"
mimicsql_data
CREATE TABLE table_name_63 ( power__kw_ VARCHAR, coverage VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the power in kW corresponding to the station that covers General Santos?
SELECT power__kw_ FROM table_name_63 WHERE coverage = "general santos"
sql_create_context
CREATE TABLE table_34682 ( "Player" text, "Touchdowns" real, "Extra points" real, "Field goals" real, "Points" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- How many Field goals have Touchdowns smaller than 3, and a Player of willis ward, and an Ex...
SELECT SUM("Field goals") FROM table_34682 WHERE "Touchdowns" < '3' AND "Player" = 'willis ward' AND "Extra points" < '0'
wikisql
CREATE TABLE t_kc24 ( MED_SAFE_PAY_ID text, OVERALL_CD_ORG text, OVERALL_CD_PERSON text, MED_CLINIC_ID text, REF_SLT_FLG number, CLINIC_SLT_DATE time, COMP_ID text, PERSON_ID text, FLX_MED_ORG_ID text, INSU_TYPE text, MED_AMOUT number, PER_ACC_PAY number, OVE_PAY numb...
SELECT AVG(IN_HOSP_DAYS) FROM t_kc21 WHERE MED_SER_ORG_NO = '9922597' AND IN_HOSP_DATE BETWEEN '2013-02-02' AND '2021-11-09'
css
CREATE TABLE field ( fieldid int ) CREATE TABLE dataset ( datasetid int, datasetname varchar ) CREATE TABLE author ( authorid int, authorname varchar ) CREATE TABLE venue ( venueid int, venuename varchar ) CREATE TABLE paperfield ( fieldid int, paperid int ) CREATE TABLE paperda...
SELECT DISTINCT COUNT(cite.citedpaperid) FROM author, cite, paper, writes WHERE author.authorname = 'alex snoeren' AND paper.paperid = cite.citedpaperid AND writes.authorid = author.authorid AND writes.paperid = paper.paperid
scholar
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 ) -- Using valid SQLite, answer the following questions for the...
SELECT T1.Price, T1.Code FROM Products AS T1 JOIN Manufacturers AS T2 ON T1.Manufacturer = T2.Code GROUP BY Founder
nvbench
CREATE TABLE table_train_55 ( "id" int, "ejection_fraction_ef" int, "systolic_dysfunction" bool, "language" string, "valvular_dysfunction" bool, "consent" bool, "heart_disease" bool, "left_bundle_branch_block" bool, "trauma" bool, "pericardial_disease" bool, "complete_fluid_c...
SELECT * FROM table_train_55 WHERE consent = 0 OR language <> 'english'
criteria2sql
CREATE TABLE code_description ( code varchar, description text ) CREATE TABLE time_zone ( time_zone_code text, time_zone_name text, hours_from_gmt int ) CREATE TABLE restriction ( restriction_code text, advance_purchase int, stopovers text, saturday_stay_required text, minimum_...
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 = 'PHILADELPHIA' AND CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'S...
atis
CREATE TABLE procedures ( subject_id text, hadm_id text, icd9_code text, short_title text, long_title text ) CREATE TABLE lab ( subject_id text, hadm_id text, itemid text, charttime text, flag text, value_unit text, label text, fluid text ) CREATE TABLE demographic ...
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.admission_type = "EMERGENCY" AND lab.itemid = "51256"
mimicsql_data
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 ) C...
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE demographic.dob_year < "2080" AND prescriptions.formulary_drug_cd = "POSA200L"
mimicsql_data
CREATE TABLE table_74640 ( "Home team" text, "Home team score" text, "Away team" text, "Away team score" text, "Venue" text, "Crowd" real, "Date" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What was the venue where Fitzroy played as the h...
SELECT "Venue" FROM table_74640 WHERE "Home team" = 'fitzroy'
wikisql
CREATE TABLE jybgb ( BBCJBW text, BBDM text, BBMC text, BBZT number, BGDH text, BGJGDM text, BGJGMC text, BGRGH text, BGRQ time, BGRXM text, BGSJ time, CJRQ time, JSBBRQSJ time, JSBBSJ time, JYBBH text, JYJGMC text, JYJSGH text, JYJSQM text, JY...
SELECT jybgb.BBDM, jybgb.BBMC, jybgb.BBZT FROM jybgb WHERE jybgb.BGDH = '83703766909'
css
CREATE TABLE hz_info ( KH text, KLX number, YLJGDM text, RYBH text ) CREATE TABLE mzjzjlb ( YLJGDM text, JZLSH text, KH text, KLX number, MJZH text, HZXM text, NLS number, NLY number, ZSEBZ number, JZZTDM number, JZZTMC text, JZJSSJ time, TXBZ number,...
(SELECT jybgb.KSBM, jybgb.KSMC FROM person_info JOIN hz_info JOIN mzjzjlb JOIN jybgb ON person_info.RYBH = hz_info.RYBH AND hz_info.YLJGDM = mzjzjlb.YLJGDM AND hz_info.KH = mzjzjlb.KH AND hz_info.KLX = mzjzjlb.KLX AND mzjzjlb.YLJGDM = jybgb.YLJGDM_MZJZJLB AND mzjzjlb.JZLSH = jybgb.JZLSH_MZJZJLB WHERE person_info.XM = '...
css
CREATE TABLE medication ( medicationid number, patientunitstayid number, drugname text, dosage text, routeadmin text, drugstarttime time, drugstoptime time ) CREATE TABLE patient ( uniquepid text, patienthealthsystemstayid number, patientunitstayid number, gender text, a...
SELECT COUNT(*) FROM intakeoutput WHERE intakeoutput.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '005-9883')) AND intakeoutput.cellpath LIKE '%intake%' AND intakeoutput.cel...
eicu
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 procedures ( ...
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN procedures ON demographic.hadm_id = procedures.hadm_id WHERE demographic.admission_type = "EMERGENCY" AND procedures.long_title = "Aortography"
mimicsql_data
CREATE TABLE table_54891 ( "Year" real, "Place" text, "Event" text, "Performance" text, "Age (years)" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the year when the performance is 60.73m and the age (years) is more than 45?
SELECT COUNT("Year") FROM table_54891 WHERE "Performance" = '60.73m' AND "Age (years)" > '45'
wikisql
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 microlab ( microlabid number, ...
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 = '025-27850')) AND treatment.treatmentname = 'oxygen therapy (40% to 60%) - fa...
eicu
CREATE TABLE table_64701 ( "Player" text, "Matches" text, "Runs" text, "Balls" text, "Strike Rate" text, "Average" text, "100s" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- With 10 as matches, and 469 runs, what is the strike rate?
SELECT "Strike Rate" FROM table_64701 WHERE "Matches" = '10' AND "Runs" = '469'
wikisql
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 ...
SELECT MAX(labevents.valuenum) FROM labevents WHERE labevents.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 64983) AND labevents.itemid IN (SELECT d_labitems.itemid FROM d_labitems WHERE d_labitems.label = 'po2') AND DATETIME(labevents.charttime, 'start of year') = DATETIME(CURRENT...
mimic_iii
CREATE TABLE allergy ( allergyid number, patientunitstayid number, drugname text, allergyname text, allergytime time ) CREATE TABLE patient ( uniquepid text, patienthealthsystemstayid number, patientunitstayid number, gender text, age text, ethnicity text, hospitalid num...
SELECT vitalperiodic.observationtime FROM vitalperiodic WHERE vitalperiodic.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '003-33922')) AND NOT vitalperiodic.systemicsystolic...
eicu
CREATE TABLE table_10811 ( "Round" text, "Opponent" text, "Date" text, "Venue" text, "Competition" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- what round saw wakefield trinity wildcats u21 as the opponenet at belle vue?
SELECT "Round" FROM table_10811 WHERE "Opponent" = 'wakefield trinity wildcats u21' AND "Venue" = 'belle vue'
wikisql
CREATE TABLE writes ( paperid int, authorid int ) CREATE TABLE journal ( journalid int, journalname varchar ) CREATE TABLE field ( fieldid int ) CREATE TABLE dataset ( datasetid int, datasetname varchar ) CREATE TABLE author ( authorid int, authorname varchar ) CREATE TABLE pape...
SELECT DISTINCT COUNT(1) FROM author AS AUTHOR_0, author AS AUTHOR_1, writes AS WRITES_0, writes AS WRITES_1 WHERE AUTHOR_0.authorname = 'Dan Suciu' AND AUTHOR_1.authorname = 'Magdalena Balazinska' AND WRITES_0.authorid = AUTHOR_0.authorid AND WRITES_1.authorid = AUTHOR_1.authorid AND WRITES_1.paperid = WRITES_0.paperi...
scholar
CREATE TABLE PostsWithDeleted ( Id number, PostTypeId number, AcceptedAnswerId number, ParentId number, CreationDate time, DeletionDate time, Score number, ViewCount number, Body text, OwnerUserId number, OwnerDisplayName text, LastEditorUserId number, LastEditorDispl...
SELECT MONTH(CURRENT_TIMESTAMP())
sede
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,...
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE prescriptions.formulary_drug_cd = "PHOS250"
mimicsql_data
CREATE TABLE music_festival ( RESULT VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the most common result of the music festival?
SELECT RESULT FROM music_festival GROUP BY RESULT ORDER BY COUNT(*) DESC LIMIT 1
sql_create_context
CREATE TABLE Reservations ( Code INTEGER, Room TEXT, CheckIn TEXT, CheckOut TEXT, Rate REAL, LastName TEXT, FirstName TEXT, Adults INTEGER, Kids INTEGER ) CREATE TABLE Rooms ( RoomId TEXT, roomName TEXT, beds INTEGER, bedType TEXT, maxOccupancy INTEGER, baseP...
SELECT decor, COUNT(decor) FROM Rooms WHERE bedType = 'King' GROUP BY decor
nvbench
CREATE TABLE airline ( airline_code varchar, airline_name text, note text ) CREATE TABLE time_zone ( time_zone_code text, time_zone_name text, hours_from_gmt int ) CREATE TABLE compartment_class ( compartment varchar, class_type varchar ) CREATE TABLE fare_basis ( fare_basis_code ...
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 = 'SEATTLE' AND CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'DENVE...
atis
CREATE TABLE mzjzjlb ( HXPLC number, HZXM text, JLSJ time, JZJSSJ time, JZKSBM text, JZKSMC text, JZKSRQ time, JZLSH text, JZZDBM text, JZZDSM text, JZZTDM number, JZZTMC text, KH text, KLX number, MJZH text, ML number, MZZYZDZZBM text, MZZYZDZZMC ...
SELECT * FROM person_info JOIN hz_info JOIN mzjzjlb JOIN jyjgzbb ON person_info.RYBH = hz_info.RYBH AND hz_info.YLJGDM = mzjzjlb.YLJGDM AND hz_info.KH = mzjzjlb.KH AND hz_info.KLX = mzjzjlb.KLX AND mzjzjlb.YLJGDM = jyjgzbb.jybgb_YLJGDM_MZJZJLB AND mzjzjlb.JZLSH = jyjgzbb.jybgb_JZLSH_MZJZJLB WHERE person_info.XM = '郑自珍'...
css
CREATE TABLE actor ( Actor_ID int, Name text, Musical_ID int, Character text, Duration text, age int ) CREATE TABLE musical ( Musical_ID int, Name text, Year int, Award text, Category text, Nominee text, Result text ) -- Using valid SQLite, answer the following que...
SELECT Duration, COUNT(Duration) FROM actor GROUP BY Duration
nvbench
CREATE TABLE table_name_9 ( laps INTEGER, qual VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- How many laps did Duke Nelson complete when his qualifying time was 136.498?
SELECT MAX(laps) FROM table_name_9 WHERE qual = "136.498"
sql_create_context
CREATE TABLE d_labitems ( row_id number, itemid number, label text ) CREATE TABLE labevents ( row_id number, subject_id number, hadm_id number, itemid number, charttime time, valuenum number, valueuom text ) CREATE TABLE d_icd_diagnoses ( row_id number, icd9_code text, ...
SELECT t1.startdate FROM (SELECT admissions.subject_id, prescriptions.startdate FROM prescriptions JOIN admissions ON prescriptions.hadm_id = admissions.hadm_id WHERE prescriptions.drug = 'd5w' AND admissions.subject_id = 19175 AND DATETIME(prescriptions.startdate, 'start of month') = DATETIME(CURRENT_TIME(), 'start of...
mimic_iii
CREATE TABLE d_icd_procedures ( row_id number, icd9_code text, short_title text, long_title text ) CREATE TABLE prescriptions ( row_id number, subject_id number, hadm_id number, startdate time, enddate time, drug text, dose_val_rx text, dose_unit_rx text, route text ...
SELECT DISTINCT cost.cost FROM cost WHERE cost.event_type = 'labevents' AND cost.event_id IN (SELECT labevents.row_id FROM labevents WHERE labevents.itemid IN (SELECT d_labitems.itemid FROM d_labitems WHERE d_labitems.label = 'bilirubin, total, pleural'))
mimic_iii
CREATE TABLE table_20010140_10 ( location_attendance VARCHAR, record VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- state the number of location attendance where record is 15 10 (5 7)
SELECT COUNT(location_attendance) FROM table_20010140_10 WHERE record = "15–10 (5–7)"
sql_create_context
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 ...
SELECT d_icd_procedures.short_title FROM d_icd_procedures WHERE d_icd_procedures.icd9_code IN (SELECT procedures_icd.icd9_code FROM procedures_icd WHERE procedures_icd.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 25796 AND NOT admissions.dischtime IS NULL ORDER BY admissions.admit...
mimic_iii
CREATE TABLE table_name_75 ( publication VARCHAR, country VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Which publication happened in the UK?
SELECT publication FROM table_name_75 WHERE country = "uk"
sql_create_context
CREATE TABLE table_name_55 ( played INTEGER, team VARCHAR, losses VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Which Played has a Team of cerro cor , and Losses larger than 4?
SELECT AVG(played) FROM table_name_55 WHERE team = "cerro corá" AND losses > 4
sql_create_context
CREATE TABLE t_kc21 ( MED_CLINIC_ID text, OVERALL_CD_ORG text, OVERALL_CD_PERSON text, COMP_ID text, PERSON_ID text, PERSON_NM text, IDENTITY_CARD text, SOC_SRT_CARD text, PERSON_SEX number, PERSON_AGE number, IN_HOSP_DATE time, OUT_HOSP_DATE time, DIFF_PLACE_FLG numb...
SELECT MED_SER_ORG_NO FROM t_kc21 WHERE PERSON_ID = '04369427' AND MED_CLINIC_ID IN (SELECT MED_CLINIC_ID FROM t_kc22 WHERE SOC_SRT_DIRE_NM = '拉莫三嗪片')
css
CREATE TABLE table_17507 ( "Overall Pick #" real, "AFL Team" text, "Player" text, "Position" text, "College" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Which college did Dennis Byrd come from?
SELECT "College" FROM table_17507 WHERE "Player" = 'Dennis Byrd'
wikisql
CREATE TABLE table_3377 ( "Skip (Club)" text, "W" real, "L" real, "PF" real, "PA" real, "Ends Won" real, "Ends Lost" real, "Blank Ends" real, "Stolen Ends" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the PA when skip (club...
SELECT MIN("PA") FROM table_3377 WHERE "Skip (Club)" = 'Mary-Anne Arsenault (NSCA)'
wikisql
CREATE TABLE gsi ( course_offering_id int, student_id int ) CREATE TABLE course_tags_count ( course_id int, clear_grading int, pop_quiz int, group_projects int, inspirational int, long_lectures int, extra_credit int, few_tests int, good_feedback int, tough_tests int, ...
SELECT DISTINCT num_enrolled FROM course WHERE department = 'EECS' AND number = 445
advising
CREATE TABLE table_name_63 ( nationality___opponent VARCHAR, competition VARCHAR, result VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Name the Nationality / Opponent of the Competition of welsh rugby union challenge trophy and a Result of 38-29?
SELECT nationality___opponent FROM table_name_63 WHERE competition = "welsh rugby union challenge trophy" AND result = "38-29"
sql_create_context
CREATE TABLE mzjzjlb ( HXPLC number, HZXM text, JLSJ time, JZJSSJ time, JZKSBM text, JZKSMC text, JZKSRQ time, JZLSH text, JZZDBM text, JZZDSM text, JZZTDM number, JZZTMC text, KH text, KLX number, MJZH text, ML number, MZZYZDZZBM text, MZZYZDZZMC ...
SELECT person_info.XM FROM person_info JOIN hz_info JOIN mzjzjlb JOIN jybgb ON person_info.RYBH = hz_info.RYBH AND hz_info.YLJGDM = mzjzjlb.YLJGDM AND hz_info.KH = mzjzjlb.KH AND hz_info.KLX = mzjzjlb.KLX AND mzjzjlb.YLJGDM = jybgb.YLJGDM_MZJZJLB AND mzjzjlb.JZLSH = jybgb.JZLSH_MZJZJLB WHERE jybgb.BGDH = '24571107359'
css
CREATE TABLE keyphrase ( keyphraseid int, keyphrasename varchar ) CREATE TABLE paperkeyphrase ( paperid int, keyphraseid int ) CREATE TABLE paper ( paperid int, title varchar, venueid int, year int, numciting int, numcitedby int, journalid int ) CREATE TABLE paperfield ( ...
SELECT DISTINCT COUNT(DISTINCT writes.paperid) FROM author, writes WHERE author.authorname = 'samia razaq' AND writes.authorid = author.authorid
scholar
CREATE TABLE t_kc21 ( MED_CLINIC_ID text, OVERALL_CD_ORG text, OVERALL_CD_PERSON text, COMP_ID text, PERSON_ID text, PERSON_NM text, IDENTITY_CARD text, SOC_SRT_CARD text, PERSON_SEX number, PERSON_AGE number, IN_HOSP_DATE time, OUT_HOSP_DATE time, DIFF_PLACE_FLG numb...
SELECT SUM(MED_AMOUT) FROM t_kc21 WHERE PERSON_ID = '43928583' AND CLINIC_TYPE = '门诊'
css
CREATE TABLE gsi ( course_offering_id int, student_id int ) CREATE TABLE course_tags_count ( course_id int, clear_grading int, pop_quiz int, group_projects int, inspirational int, long_lectures int, extra_credit int, few_tests int, good_feedback int, tough_tests int, ...
SELECT DISTINCT semester.semester, semester.year FROM semester INNER JOIN course_offering ON semester.semester_id = course_offering.semester INNER JOIN course ON course.course_id = course_offering.course_id WHERE course.name LIKE '%Developmental Disturbances of Childhood%' AND semester.semester_id > (SELECT SEMESTERali...
advising
CREATE TABLE table_78732 ( "Date" text, "Airline" text, "Aircraft type" text, "Registration" text, "People on board" real, "Fatalities" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- How many fatalities shows for the lockheed l-1049g?
SELECT SUM("Fatalities") FROM table_78732 WHERE "Aircraft type" = 'lockheed l-1049g'
wikisql
CREATE TABLE locations ( LOCATION_ID decimal(4,0), STREET_ADDRESS varchar(40), POSTAL_CODE varchar(12), CITY varchar(30), STATE_PROVINCE varchar(25), COUNTRY_ID varchar(2) ) CREATE TABLE employees ( EMPLOYEE_ID decimal(6,0), FIRST_NAME varchar(20), LAST_NAME varchar(25), EMAIL v...
SELECT HIRE_DATE, SUM(MANAGER_ID) FROM employees WHERE FIRST_NAME LIKE '%D%' OR FIRST_NAME LIKE '%S%' ORDER BY SUM(MANAGER_ID)
nvbench
CREATE TABLE table_name_30 ( region VARCHAR, venue VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What region is William R. Johnson Coliseum in?
SELECT region FROM table_name_30 WHERE venue = "william r. johnson coliseum"
sql_create_context
CREATE TABLE table_44851 ( "Round" real, "Pick" real, "Overall" real, "Name" text, "Position" text, "College" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the highest pick of scott turner, who has a round greater than 2?
SELECT MAX("Pick") FROM table_44851 WHERE "Round" > '2' AND "Name" = 'scott turner'
wikisql
CREATE TABLE table_38725 ( "Date" text, "City" text, "Opponent" text, "Results\u00b9" text, "Type of game" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Who did Yugoslavia play against that led to a result of 2:3?
SELECT "Opponent" FROM table_38725 WHERE "Results\u00b9" = '2:3'
wikisql
CREATE TABLE t_kc24 ( ACCOUNT_DASH_DATE time, ACCOUNT_DASH_FLG number, CASH_PAY number, CIVIL_SUBSIDY number, CKC102 number, CLINIC_ID text, CLINIC_SLT_DATE time, COMP_ID text, COM_ACC_PAY number, COM_PAY number, DATA_ID text, ENT_ACC_PAY number, ENT_PAY number, F...
SELECT MIN(t_kc24.MED_AMOUT), MAX(t_kc24.MED_AMOUT) FROM t_kc24 WHERE t_kc24.MED_CLINIC_ID IN (SELECT t_kc24.MED_CLINIC_ID FROM t_kc24 WHERE t_kc24.t_kc21_MED_SER_ORG_NO = '8058667' AND t_kc24.t_kc21_IN_DIAG_DIS_NM = '非器质性睡眠障碍')
css
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 ) -- Using valid SQLite, answer the following questions for the...
SELECT T1.Name, T1.Manufacturer FROM Products AS T1 JOIN Manufacturers AS T2 ON T1.Manufacturer = T2.Code GROUP BY Founder, T1.Name ORDER BY T1.Name DESC
nvbench
CREATE TABLE table_name_85 ( theme VARCHAR, original_artist VARCHAR, week__number VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the Theme when the Original artist was carole king, and a Week # shows hollywood?
SELECT theme FROM table_name_85 WHERE original_artist = "carole king" AND week__number = "hollywood"
sql_create_context
CREATE TABLE table_25703_1 ( death_2012 VARCHAR, death_2013 VARCHAR, january_september_2013 VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What are the death/2012 number when death/2013 is 140 and January September 2013 is Moscow Oblast?
SELECT death_2012 FROM table_25703_1 WHERE death_2013 = 140 AND january_september_2013 = "Moscow Oblast"
sql_create_context
CREATE TABLE fare_basis ( fare_basis_code text, booking_class text, class_type text, premium text, economy text, discounted text, night text, season text, basis_days text ) CREATE TABLE restriction ( restriction_code text, advance_purchase int, stopovers text, saturd...
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 = 'BOSTON' AND CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'WASHING...
atis
CREATE TABLE table_name_62 ( city VARCHAR, home_arena VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Which city includes the Target Center arena?
SELECT city FROM table_name_62 WHERE home_arena = "target center"
sql_create_context
CREATE TABLE ReviewTaskResults ( Id number, ReviewTaskId number, ReviewTaskResultTypeId number, CreationDate time, RejectionReasonId number, Comment text ) CREATE TABLE PendingFlags ( Id number, FlagTypeId number, PostId number, CreationDate time, CloseReasonTypeId number, ...
SELECT e.PostId AS "post_link", p.Score, e.CreationDate AS "undeletion_date", p.Body FROM PostHistory AS e INNER JOIN Posts AS p ON e.PostId = p.Id WHERE p.PostTypeId = 2 AND p.Score < 0 AND e.PostHistoryTypeId = 13 ORDER BY e.CreationDate DESC
sede
CREATE TABLE table_name_16 ( rides VARCHAR, bonus_pts VARCHAR, total_points VARCHAR, rider VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- How many rides did it take Ray Day to get 274 points in total with less than 3 bonus points?
SELECT COUNT(rides) FROM table_name_16 WHERE total_points < 274 AND rider = "ray day" AND bonus_pts > 3
sql_create_context
CREATE TABLE t_kc21 ( CLINIC_ID text, CLINIC_TYPE text, COMP_ID text, DATA_ID text, DIFF_PLACE_FLG number, FERTILITY_STS number, FLX_MED_ORG_ID text, HOSP_LEV number, HOSP_STS number, IDENTITY_CARD text, INPT_AREA_BED text, INSURED_IDENTITY number, INSURED_STS text, ...
SELECT t_kc21.OUT_DIAG_DOC_CD, t_kc21.OUT_DIAG_DOC_NM FROM t_kc21 WHERE t_kc21.PERSON_NM = '章俊晤' AND t_kc21.IN_HOSP_DATE BETWEEN '2000-09-18' AND '2013-10-16' GROUP BY t_kc21.OUT_DIAG_DOC_CD ORDER BY COUNT(*) DESC LIMIT 1
css
CREATE TABLE airports ( city VARCHAR, country VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- How many airports are there per city in the United States? Order the cities by decreasing number of airports.
SELECT COUNT(*), city FROM airports WHERE country = 'United States' GROUP BY city ORDER BY COUNT(*) DESC
sql_create_context
CREATE TABLE table_name_80 ( player VARCHAR, score VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is Player, when Score is '68-71=139'?
SELECT player FROM table_name_80 WHERE score = 68 - 71 = 139
sql_create_context
CREATE TABLE table_80190 ( "City" text, "Country" text, "IATA" text, "ICAO" text, "Airport" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What city is fuhlsb ttel airport in?
SELECT "City" FROM table_80190 WHERE "Airport" = 'fuhlsbüttel airport'
wikisql
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, ...
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE diagnoses.icd9_code = "7291" AND prescriptions.drug_type = "MAIN"
mimicsql_data
CREATE TABLE train ( Train_ID int, Train_Num text, Name text, From text, Arrival text, Railway_ID int ) CREATE TABLE manager ( Manager_ID int, Name text, Country text, Working_year_starts text, Age int, Level int ) CREATE TABLE railway_manage ( Railway_ID int, M...
SELECT T1.Location, T1.Railway_ID FROM railway AS T1 JOIN train AS T2 ON T1.Railway_ID = T2.Railway_ID
nvbench
CREATE TABLE cost ( row_id number, subject_id number, hadm_id number, event_type text, event_id number, chargetime time, cost number ) CREATE TABLE d_icd_procedures ( row_id number, icd9_code text, short_title text, long_title text ) CREATE TABLE admissions ( row_id num...
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 = 'glucose, body fluid') AND DATETIME(labevents.charttime, 'start of year') = DATETIME(CURRENT_TIME...
mimic_iii
CREATE TABLE table_13336122_3 ( title VARCHAR, directed_by VARCHAR, no_in_series VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What's the title of the episode directed by David von Ancken, with a episode number bigger than 16.0?
SELECT title FROM table_13336122_3 WHERE directed_by = "David Von Ancken" AND no_in_series > 16.0
sql_create_context
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, ...
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN procedures ON demographic.hadm_id = procedures.hadm_id WHERE demographic.diagnosis = "T5 FRACTURE" AND procedures.icd9_code = "8105"
mimicsql_data
CREATE TABLE table_1341568_34 ( district VARCHAR, party VARCHAR, elected VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- In how many districts was the democratic incumbent elected in 1974?
SELECT COUNT(district) FROM table_1341568_34 WHERE party = "Democratic" AND elected = 1974
sql_create_context
CREATE TABLE t_kc24 ( MED_SAFE_PAY_ID text, OVERALL_CD_ORG text, OVERALL_CD_PERSON text, MED_CLINIC_ID text, REF_SLT_FLG number, CLINIC_SLT_DATE time, COMP_ID text, PERSON_ID text, FLX_MED_ORG_ID text, INSU_TYPE text, MED_AMOUT number, PER_ACC_PAY number, OVE_PAY numb...
SELECT MED_CLINIC_ID FROM t_kc21 WHERE PERSON_ID = '11103457' AND NOT MED_CLINIC_ID IN (SELECT MED_CLINIC_ID FROM t_kc22 WHERE AMOUNT > 9690.79)
css
CREATE TABLE table_204_793 ( id number, "call-sign" text, "location" text, "rf" number, "psip" number, "programming" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- is the rf for wivm ld 39 or 29 ?
SELECT "rf" FROM table_204_793 WHERE "rf" IN (39, 29) AND "call-sign" = 'wivm-ld'
squall
CREATE TABLE area ( course_id int, area varchar ) CREATE TABLE ta ( campus_job_id int, student_id int, location varchar ) CREATE TABLE course ( course_id int, name varchar, department varchar, number varchar, credits varchar, advisory_requirement varchar, enforced_requi...
SELECT DISTINCT course.department, course.name, course.number FROM course, course_offering, program, program_course, semester WHERE course.course_id = course_offering.course_id AND program_course.category LIKE '%ULCS%' AND program_course.course_id = course.course_id AND program.name LIKE '%CS-LSA%' AND program.program_...
advising
CREATE TABLE table_68144 ( "Year" text, "Start" text, "Qual" text, "Rank" text, "Finish" text, "Laps" real ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the finish when there was more than 192 laps and a qual of 135.736?
SELECT "Finish" FROM table_68144 WHERE "Laps" > '192' AND "Qual" = '135.736'
wikisql
CREATE TABLE table_name_89 ( opponent VARCHAR, attendance INTEGER ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Who is the opponent of the match with an attendance larger than 59,000?
SELECT opponent FROM table_name_89 WHERE attendance > 59 OFFSET 000
sql_create_context
CREATE TABLE table_name_83 ( score VARCHAR, opponent_in_the_final VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What was the score for the opponent against Katerina Maleeva in the final?
SELECT score FROM table_name_83 WHERE opponent_in_the_final = "katerina maleeva"
sql_create_context
CREATE TABLE table_name_73 ( player VARCHAR, school_club_team VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- Who is the player for the School/Club team in Georgia?
SELECT player FROM table_name_73 WHERE school_club_team = "georgia"
sql_create_context
CREATE TABLE ReviewTaskTypes ( Id number, Name text, Description text ) CREATE TABLE Votes ( Id number, PostId number, VoteTypeId number, UserId number, CreationDate time, BountyAmount number ) CREATE TABLE PostTags ( PostId number, TagId number ) CREATE TABLE ReviewTaskSt...
SELECT U2.* FROM Users AS U1 JOIN Users AS U2 ON U1.Location = U2.Location WHERE 1 = 1 AND U1.DisplayName = 'jyparask' AND U1.Reputation <= U2.Reputation ORDER BY U2.Reputation DESC, U2.DisplayName
sede
CREATE TABLE table_39339 ( "Rank" real, "Country/Territory" text, "Miss World" real, "1st Runner-up" real, "2nd Runner-up" real, "3rd Runner-up" real, "4th Runner-up" real, "5th Runner-up" real, "6th Runner-up" real, "Semifinalists" real, "Total" real ) -- Using valid SQLit...
SELECT SUM("6th Runner-up") FROM table_39339 WHERE "2nd Runner-up" > '4' AND "Country/Territory" = 'israel' AND "4th Runner-up" < '0'
wikisql
CREATE TABLE table_203_815 ( id number, "pick #" number, "nfl team" text, "player" text, "position" text, "college" text ) -- Using valid SQLite, answer the following questions for the tables provided above. -- how many guards were picked ?
SELECT COUNT(*) FROM table_203_815 WHERE "position" = 'guard'
squall
CREATE TABLE table_name_84 ( home_team VARCHAR, away_team VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- When the Away team was hawthorn, what's the Home team?
SELECT home_team FROM table_name_84 WHERE away_team = "hawthorn"
sql_create_context
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 lab ( subject_id text, hadm_id text, ...
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN procedures ON demographic.hadm_id = procedures.hadm_id INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE procedures.icd9_code = "5732" AND prescriptions.route = "IM"
mimicsql_data
CREATE TABLE d_icd_diagnoses ( row_id number, icd9_code text, short_title text, long_title text ) CREATE TABLE icustays ( row_id number, subject_id number, hadm_id number, icustay_id number, first_careunit text, last_careunit text, first_wardid number, last_wardid number...
SELECT 24 * (STRFTIME('%j', CURRENT_TIME()) - STRFTIME('%j', inputevents_cv.charttime)) FROM inputevents_cv WHERE inputevents_cv.icustay_id IN (SELECT icustays.icustay_id FROM icustays WHERE icustays.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 6170) AND icustays.outtime IS NULL) ...
mimic_iii
CREATE TABLE table_67076 ( "Competition" text, "1993\u2013 94" text, "1994\u2013 95" text, "1995\u2013 96" text, "1996\u2013 97" text, "1997\u2013 98" text, "1998\u2013 99" text, "1999\u2013 2000" text, "2000\u2013 01" text, "2001\u2013 02" text, "2002\u2013 03" text, "20...
SELECT "1999\u2013 2000" FROM table_67076 WHERE "1993\u2013 94" = 'did not participate'
wikisql
CREATE TABLE COURSE ( CRS_CODE varchar(10), DEPT_CODE varchar(10), CRS_DESCRIPTION varchar(35), CRS_CREDIT float(8) ) CREATE TABLE DEPARTMENT ( DEPT_CODE varchar(10), DEPT_NAME varchar(30), SCHOOL_CODE varchar(8), EMP_NUM int, DEPT_ADDRESS varchar(20), DEPT_EXTENSION varchar(4) ...
SELECT DEPT_ADDRESS, COUNT(*) FROM STUDENT AS T1 JOIN DEPARTMENT AS T2 ON T1.DEPT_CODE = T2.DEPT_CODE GROUP BY T1.DEPT_CODE ORDER BY COUNT(*) DESC LIMIT 3
nvbench
CREATE TABLE producer ( pid int, gender text, name text, nationality text, birth_city text, birth_year int ) CREATE TABLE copyright ( id int, msid int, cid int ) CREATE TABLE writer ( wid int, gender text, name text, nationality text, birth_city text, birth_...
SELECT name FROM actor WHERE birth_city = 'Milan'
imdb
CREATE TABLE table_203_322 ( id number, "club" text, "played" number, "won" number, "drawn" number, "lost" number, "points for" number, "points against" number, "bonus points" number, "points" number ) -- Using valid SQLite, answer the following questions for the tables provide...
SELECT "club" FROM table_203_322 WHERE "points" <= 50
squall
CREATE TABLE flight_fare ( flight_id int, fare_id 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 compartment_class ...
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, fare, flight, flight_fare WHERE ((CITY_0.city_code = AIRPORT_SERVICE_0.city_code AND CITY_0.city_name = 'CLEVELAND' AND CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CIT...
atis
CREATE TABLE d_icd_diagnoses ( row_id number, icd9_code text, short_title text, long_title text ) CREATE TABLE procedures_icd ( row_id number, subject_id number, hadm_id number, icd9_code text, charttime time ) CREATE TABLE patients ( row_id number, subject_id number, g...
SELECT COUNT(DISTINCT t1.subject_id) FROM (SELECT admissions.subject_id, procedures_icd.charttime FROM procedures_icd JOIN admissions ON procedures_icd.hadm_id = admissions.hadm_id WHERE procedures_icd.icd9_code = (SELECT d_icd_procedures.icd9_code FROM d_icd_procedures WHERE d_icd_procedures.short_title = 'hemodialysi...
mimic_iii
CREATE TABLE table_name_81 ( time_retired VARCHAR, grid VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the time/retired for the driver with 16 grids?
SELECT time_retired FROM table_name_81 WHERE grid = 16
sql_create_context
CREATE TABLE table_name_74 ( episode_title VARCHAR, presenter VARCHAR ) -- Using valid SQLite, answer the following questions for the tables provided above. -- What is the episode title of the episode with Ben Okri as the presenter?
SELECT episode_title FROM table_name_74 WHERE presenter = "ben okri"
sql_create_context
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 te...
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.diagnosis = "CORONARY ARTERY DISEASE" AND demographic.admityear < "2195"
mimicsql_data
CREATE TABLE PostFeedback ( Id number, PostId number, IsAnonymous boolean, VoteTypeId number, CreationDate time ) CREATE TABLE ReviewRejectionReasons ( Id number, Name text, Description text, PostTypeId number ) CREATE TABLE PostHistoryTypes ( Id number, Name text ) CREATE...
SELECT TagName FROM Tags GROUP BY TagName LIMIT 10
sede
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 ( Scho...
SELECT ACC_Percent, All_Games_Percent FROM basketball_match GROUP BY Team_Name
nvbench
CREATE TABLE allergy ( allergyid number, patientunitstayid number, drugname text, allergyname text, allergytime time ) CREATE TABLE vitalperiodic ( vitalperiodicid number, patientunitstayid number, temperature number, sao2 number, heartrate number, respiration number, sy...
SELECT vitalperiodic.observationtime FROM vitalperiodic WHERE vitalperiodic.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '028-55503')) AND NOT vitalperiodic.sao2 IS NULL AND...
eicu
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(...
SELECT JOB_ID, SUM(SALARY) FROM employees WHERE SALARY BETWEEN 8000 AND 12000 AND COMMISSION_PCT <> "null" OR DEPARTMENT_ID <> 40 GROUP BY JOB_ID ORDER BY JOB_ID
nvbench