instruction stringlengths 151 7.46k | output stringlengths 2 4.44k | source stringclasses 26
values |
|---|---|---|
CREATE TABLE table_name_88 (
matches VARCHAR,
strike_rate VARCHAR,
balls VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Can you tell me the total number of Matched that has the Strike Rate smallet than 152.3, and the Balls of 395?
| SELECT COUNT(matches) FROM table_name_88 WHERE strike_rate < 152.3 AND balls = 395 | sql_create_context |
CREATE TABLE table_name_13 (
memory VARCHAR,
release_date VARCHAR,
socket VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the memory when release date is January 2010 and socket is BGA-1288?
| SELECT memory FROM table_name_13 WHERE release_date = "january 2010" AND socket = "bga-1288" | sql_create_context |
CREATE TABLE countries (
COUNTRY_ID varchar(2),
COUNTRY_NAME varchar(40),
REGION_ID decimal(10,0)
)
CREATE TABLE employees (
EMPLOYEE_ID decimal(6,0),
FIRST_NAME varchar(20),
LAST_NAME varchar(25),
EMAIL varchar(25),
PHONE_NUMBER varchar(20),
HIRE_DATE date,
JOB_ID varchar(10),
... | SELECT HIRE_DATE, DEPARTMENT_ID FROM employees WHERE FIRST_NAME LIKE '%D%' OR FIRST_NAME LIKE '%S%' | nvbench |
CREATE TABLE regions (
REGION_ID decimal(5,0),
REGION_NAME varchar(25)
)
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),
CO... | SELECT JOB_ID, AVG(SALARY) FROM employees WHERE NOT EMPLOYEE_ID IN (SELECT EMPLOYEE_ID FROM job_history) GROUP BY JOB_ID ORDER BY AVG(SALARY) | nvbench |
CREATE TABLE table_name_72 (
overall INTEGER,
round VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was round 7's lowest overall?
| SELECT MIN(overall) FROM table_name_72 WHERE round = 7 | sql_create_context |
CREATE TABLE table_name_3 (
attendance VARCHAR,
result VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Tell me the total number of attendance for result of l 18-6
| SELECT COUNT(attendance) FROM table_name_3 WHERE result = "l 18-6" | sql_create_context |
CREATE TABLE inputevents_cv (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime time,
itemid number,
amount number
)
CREATE TABLE admissions (
row_id number,
subject_id number,
hadm_id number,
admittime time,
dischtime time,
admission_typ... | SELECT AVG(t1.c1) FROM (SELECT SUM(cost.cost) AS c1 FROM cost WHERE cost.hadm_id IN (SELECT procedures_icd.hadm_id FROM procedures_icd WHERE procedures_icd.icd9_code = (SELECT d_icd_procedures.icd9_code FROM d_icd_procedures WHERE d_icd_procedures.short_title = 'remove skull tongs')) GROUP BY cost.hadm_id) AS t1 | mimic_iii |
CREATE TABLE table_name_81 (
country VARCHAR,
year VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the country for 2002
| SELECT country FROM table_name_81 WHERE year = 2002 | sql_create_context |
CREATE TABLE county (
County_Id int,
County_name text,
Population real,
Zip_code text
)
CREATE TABLE party (
Party_ID int,
Year real,
Party text,
Governor text,
Lieutenant_Governor text,
Comptroller text,
Attorney_General text,
US_Senate text
)
CREATE TABLE election (
... | SELECT T2.Party, SUM(COUNT(*)) FROM election AS T1 JOIN party AS T2 ON T1.Party = T2.Party_ID GROUP BY T2.Party | nvbench |
CREATE TABLE contacts (
contact_id number,
customer_id number,
gender text,
first_name text,
last_name text,
contact_phone text
)
CREATE TABLE order_items (
order_item_id number,
order_id number,
product_id number,
order_quantity text
)
CREATE TABLE addresses (
address_id n... | SELECT MIN(product_price), MAX(product_price), AVG(product_price) FROM products | spider |
CREATE TABLE table_60293 (
"Pick #" real,
"Player" text,
"Position" text,
"Nationality" text,
"NHL team" text,
"College/junior/club team" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What college/junior/club team is a left wing from Canada?
| SELECT "College/junior/club team" FROM table_60293 WHERE "Position" = 'left wing' AND "Nationality" = 'canada' | wikisql |
CREATE TABLE airport_service (
city_code varchar,
airport_code varchar,
miles_distant int,
direction varchar,
minutes_distant int
)
CREATE TABLE equipment_sequence (
aircraft_code_sequence varchar,
aircraft_code varchar
)
CREATE TABLE flight_stop (
flight_id int,
stop_number int,
... | 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 = 'BALTIMORE' AND CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'PHIL... | atis |
CREATE TABLE table_name_2 (
driver VARCHAR,
constructor VARCHAR,
location VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the name of the driver of the vehicle constructed by Bugatti in Anfa?
| SELECT driver FROM table_name_2 WHERE constructor = "bugatti" AND location = "anfa" | sql_create_context |
CREATE TABLE wdmzjzjlb (
HXPLC number,
HZXM text,
JLSJ time,
JZJSSJ time,
JZKSBM text,
JZKSMC text,
JZKSRQ time,
JZLSH number,
JZZDBM text,
JZZDSM text,
JZZTDM number,
JZZTMC text,
KH text,
KLX number,
MJZH text,
ML number,
MZZYZDZZBM text,
MZZYZDZ... | SELECT * FROM hz_info JOIN wdmzjzjlb JOIN jybgb JOIN jyjgzbb ON hz_info.YLJGDM = wdmzjzjlb.YLJGDM AND hz_info.KH = wdmzjzjlb.KH AND hz_info.KLX = wdmzjzjlb.KLX AND wdmzjzjlb.YLJGDM = jybgb.YLJGDM_MZJZJLB AND wdmzjzjlb.JZLSH = jybgb.JZLSH_MZJZJLB AND jybgb.YLJGDM = jyjgzbb.YLJGDM AND jybgb.BGDH = jyjgzbb.BGDH WHERE hz_i... | css |
CREATE TABLE CloseAsOffTopicReasonTypes (
Id number,
IsUniversal boolean,
InputTitle text,
MarkdownInputGuidance text,
MarkdownPostOwnerGuidance text,
MarkdownPrivilegedUserGuidance text,
MarkdownConcensusDescription text,
CreationDate time,
CreationModeratorId number,
ApprovalDa... | SELECT p.ParentId AS "post_link", COUNT(p.Id) FROM Posts AS p INNER JOIN Posts AS parent ON parent.Id = p.ParentId WHERE p.PostTypeId = 2 AND LENGTH(p.Body) <= 200 AND (p.Body LIKE '%hank%') AND parent.AcceptedAnswerId IS NULL GROUP BY p.ParentId HAVING COUNT(p.Id) > 1 ORDER BY COUNT(p.Id) DESC | sede |
CREATE TABLE table_67333 (
"Club" text,
"Australian Marquee" text,
"International Marquee" text,
"Junior Marquee player" text,
"Captain" text,
"Vice-Captain" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What club captain is John Hutchinson in?... | SELECT "Club" FROM table_67333 WHERE "Captain" = 'john hutchinson' | wikisql |
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 outputevents (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime ... | SELECT (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 = 7742 AND NOT admissions.dischtime IS NULL ORDER BY admissions.admittime DESC LIMIT 1)) AND cha... | mimic_iii |
CREATE TABLE table_28183 (
"Country" text,
"Name of bullion coin" text,
"Fineness" text,
"Denominations (Gold weight)" text,
"Years of mintage" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many catagories for denominations does Austria have?
| SELECT COUNT("Denominations (Gold weight)") FROM table_28183 WHERE "Country" = 'Austria' | wikisql |
CREATE TABLE table_56548 (
"Position" real,
"Club" text,
"Played" real,
"Points" text,
"Wins" real,
"Draws" real,
"Losses" real,
"Goals for" real,
"Goals against" real,
"Goal Difference" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.... | SELECT MIN("Played") FROM table_56548 WHERE "Club" = 'ue figueres' AND "Goal Difference" > '16' | wikisql |
CREATE TABLE d_icd_diagnoses (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE inputevents_cv (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime time,
itemid number,
amount number
)
CREATE TABLE labevents (
r... | SELECT DISTINCT cost.cost FROM cost WHERE cost.event_type = 'diagnoses_icd' AND cost.event_id IN (SELECT diagnoses_icd.row_id FROM diagnoses_icd WHERE diagnoses_icd.icd9_code = (SELECT d_icd_diagnoses.icd9_code FROM d_icd_diagnoses WHERE d_icd_diagnoses.short_title = 'wbc disease nec')) | mimic_iii |
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 diagnoses.short_title, diagnoses.long_title FROM diagnoses WHERE diagnoses.icd9_code = "4239" | mimicsql_data |
CREATE TABLE table_8953 (
"District" real,
"Incumbent" text,
"2008 Status" text,
"Democratic" text,
"Republican" text,
"Independent Green" text,
"Libertarian" text,
"Other Party" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who was the... | SELECT "Other Party" FROM table_8953 WHERE "Democratic" = 'rick boucher' | wikisql |
CREATE TABLE table_22597626_2 (
score_in_the_final VARCHAR,
partner VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the final score if the partner is Woodforde?
| SELECT score_in_the_final FROM table_22597626_2 WHERE partner = "Woodforde" | sql_create_context |
CREATE TABLE table_name_85 (
score VARCHAR,
home_team VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the score of the game where the home team was the cairns taipans?
| SELECT score FROM table_name_85 WHERE home_team = "cairns taipans" | 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 * FROM jyjgzbb WHERE jyjgzbb.JCZBMC = (SELECT jyjgzbb.JCZBMC FROM jyjgzbb WHERE jyjgzbb.JYZBLSH = '63779804585') AND jyjgzbb.JCZBJGDW = (SELECT jyjgzbb.JCZBJGDW FROM jyjgzbb WHERE jyjgzbb.JYZBLSH = '63779804585') AND jyjgzbb.JCZBJGDL > (SELECT jyjgzbb.JCZBJGDL FROM jyjgzbb WHERE jyjgzbb.JYZBLSH = '63779804585') | css |
CREATE TABLE table_1342256_11 (
candidates VARCHAR,
first_elected VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Who ran for the House in the 1924 election?
| SELECT candidates FROM table_1342256_11 WHERE first_elected = 1924 | sql_create_context |
CREATE TABLE ReviewTaskResults (
Id number,
ReviewTaskId number,
ReviewTaskResultTypeId number,
CreationDate time,
RejectionReasonId number,
Comment text
)
CREATE TABLE ReviewTaskTypes (
Id number,
Name text,
Description text
)
CREATE TABLE Tags (
Id number,
TagName text,
... | SELECT P.Score, P.Id AS "post_link" FROM Posts AS P JOIN Comments AS C ON C.PostId = P.Id WHERE (P.Body LIKE '%' + '##Query:string?Lattice##' + '%' OR P.Title LIKE '%' + '##Query:string?Lattice##' + '%') AND (P.PostTypeId = 1 OR P.PostTypeId = 2) AND (P.Body LIKE '%<img src%' OR C.Text LIKE '%<img src%' OR C.Text LIKE ... | sede |
CREATE TABLE table_33295 (
"Week" real,
"Date" text,
"Opponent" text,
"Result" text,
"Attendance" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the larges week for the date august 9, 1968 and less than 64,020 in attendance?
| SELECT MAX("Week") FROM table_33295 WHERE "Date" = 'august 9, 1968' AND "Attendance" < '64,020' | wikisql |
CREATE TABLE t_kc22 (
MED_EXP_DET_ID text,
OVERALL_CD_ORG text,
OVERALL_CD_PERSON text,
MED_CLINIC_ID text,
MED_EXP_BILL_ID text,
SOC_SRT_DIRE_CD text,
SOC_SRT_DIRE_NM text,
DIRE_TYPE number,
CHA_ITEM_LEV number,
MED_INV_ITEM_TYPE text,
MED_DIRE_CD text,
MED_DIRE_NM text,... | SELECT SUM(QTY), SUM(AMOUNT) FROM t_kc22 WHERE SOC_SRT_DIRE_CD = '979661' AND STA_DATE BETWEEN '2009-01-01' AND '2013-04-30' | css |
CREATE TABLE job_history (
EMPLOYEE_ID decimal(6,0),
START_DATE date,
END_DATE date,
JOB_ID varchar(10),
DEPARTMENT_ID decimal(4,0)
)
CREATE TABLE regions (
REGION_ID decimal(5,0),
REGION_NAME varchar(25)
)
CREATE TABLE countries (
COUNTRY_ID varchar(2),
COUNTRY_NAME varchar(40),
... | SELECT EMPLOYEE_ID, COMMISSION_PCT FROM employees WHERE HIRE_DATE < '2002-06-21' | nvbench |
CREATE TABLE table_name_20 (
tournament VARCHAR,
date VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which tournament was held on July 13, 2008?
| SELECT tournament FROM table_name_20 WHERE date = "july 13, 2008" | sql_create_context |
CREATE TABLE TRANSACTIONS (
share_count INTEGER
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the total share of transactions?
| SELECT SUM(share_count) FROM TRANSACTIONS | sql_create_context |
CREATE TABLE fare (
fare_id int,
from_airport varchar,
to_airport varchar,
fare_basis_code text,
fare_airline text,
restriction_code text,
one_direction_cost int,
round_trip_cost int,
round_trip_required varchar
)
CREATE TABLE time_zone (
time_zone_code text,
time_zone_name ... | 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 = 'BOSTON' AND date_day.day_number = 27 AND date_day.month_number = 8 AND d... | atis |
CREATE TABLE ReviewTaskResults (
Id number,
ReviewTaskId number,
ReviewTaskResultTypeId number,
CreationDate time,
RejectionReasonId number,
Comment text
)
CREATE TABLE PostsWithDeleted (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate ti... | SELECT PostId AS "post_link", Text, CreationDate FROM Comments WHERE Text LIKE '%i.stack.imgur.com%' | sede |
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 t... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.language = "RUSS" AND demographic.discharge_location = "HOME" | mimicsql_data |
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 diagnosis (
diagn... | SELECT patient.hospitaladmitsource FROM patient WHERE patient.uniquepid = '015-56556' ORDER BY patient.hospitaladmittime DESC LIMIT 1 | eicu |
CREATE TABLE table_name_99 (
frequency__mhz_ INTEGER,
call_letters VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Frequency (MHz) that has a Call letters of krmd-fm has what sum?
| SELECT SUM(frequency__mhz_) FROM table_name_99 WHERE call_letters = "krmd-fm" | sql_create_context |
CREATE TABLE table_name_92 (
coach VARCHAR,
big_ten VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the Coach with a Big Ten that is 3rd (278)?
| SELECT coach FROM table_name_92 WHERE big_ten = "3rd (278)" | 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 prescriptions (
subject_id text,
hadm_id... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.admission_location = "TRANSFER FROM HOSP/EXTRAM" AND demographic.admityear < "2166" | mimicsql_data |
CREATE TABLE table_name_87 (
result VARCHAR,
date VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what is the result on 9 october 2012?
| SELECT result FROM table_name_87 WHERE date = "9 october 2012" | sql_create_context |
CREATE TABLE table_16446652_1 (
season VARCHAR,
treasurer VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- How many seasons was Dave Reid treasurer?
| SELECT COUNT(season) FROM table_16446652_1 WHERE treasurer = "Dave Reid" | sql_create_context |
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 COUNT(*) FROM t_kc21 WHERE t_kc21.MED_SER_ORG_NO = '4499382' AND t_kc21.IN_HOSP_DATE BETWEEN '2000-05-06' AND '2017-04-10' AND t_kc21.CLINIC_TYPE = '购药' | css |
CREATE TABLE table_44995 (
"Place" text,
"Player" text,
"Country" text,
"Score" text,
"To par" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What's the score of Lee Janzen in T4 place?
| SELECT "Score" FROM table_44995 WHERE "Place" = 't4' AND "Player" = 'lee janzen' | wikisql |
CREATE TABLE Student_Course_Registrations (
student_id INTEGER,
course_id INTEGER,
registration_date DATETIME
)
CREATE TABLE Addresses (
address_id INTEGER,
line_1 VARCHAR(80),
line_2 VARCHAR(80),
city VARCHAR(50),
zip_postcode CHAR(20),
state_province_county VARCHAR(50),
countr... | SELECT last_name, COUNT(last_name) FROM People GROUP BY last_name | nvbench |
CREATE TABLE table_name_39 (
round VARCHAR,
competition VARCHAR,
club VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which round is the UEFA Cup Compeition and the Kolkheti-1913 Poti Cub?
| SELECT round FROM table_name_39 WHERE competition = "uefa cup" AND club = "kolkheti-1913 poti" | sql_create_context |
CREATE TABLE table_78813 (
"Election" text,
"1st Member" text,
"1st Party" text,
"2nd Member" text,
"2nd Party" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What's the party of 2nd member arthur divett hayter when the 1st party is conservative?
| SELECT "2nd Party" FROM table_78813 WHERE "1st Party" = 'conservative' AND "2nd Member" = 'arthur divett hayter' | wikisql |
CREATE TABLE table_name_7 (
bowling VARCHAR,
player VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was Min Patel's bowling?
| SELECT bowling FROM table_name_7 WHERE player = "min patel" | sql_create_context |
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 t... | 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.long_title = "Observation for suspected infectious condition" AND prescriptions.drug_type = "MAIN" | mimicsql_data |
CREATE TABLE school (
School_ID int,
Grade text,
School text,
Location text,
Type text
)
CREATE TABLE driver (
Driver_ID int,
Name text,
Party text,
Home_city text,
Age int
)
CREATE TABLE school_bus (
School_ID int,
Driver_ID int,
Years_Working int,
If_full_time... | SELECT Type, COUNT(*) FROM school_bus AS T1 JOIN school AS T2 ON T1.School_ID = T2.School_ID GROUP BY T2.Type ORDER BY COUNT(*) | nvbench |
CREATE TABLE table_13549 (
"Team" text,
"Outgoing manager" text,
"Manner of departure" text,
"Date of vacancy" text,
"Replaced by" text,
"Date of appointment" text,
"Position in table" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- who is th... | SELECT "Replaced by" FROM table_13549 WHERE "Team" = 'bournemouth' AND "Outgoing manager" = 'kevin bond' | wikisql |
CREATE TABLE shop (
Shop_ID int,
Shop_Name text,
Location text,
Open_Date text,
Open_Year int
)
CREATE TABLE stock (
Shop_ID int,
Device_ID int,
Quantity int
)
CREATE TABLE device (
Device_ID int,
Device text,
Carrier text,
Package_Version text,
Applications text,
... | SELECT Carrier, COUNT(Carrier) FROM stock AS T1 JOIN device AS T2 ON T1.Device_ID = T2.Device_ID JOIN shop AS T3 ON T1.Shop_ID = T3.Shop_ID GROUP BY Carrier | nvbench |
CREATE TABLE table_39353 (
"Date" text,
"Tournament" text,
"Location" text,
"Winner" text,
"Score" text,
"1st prize ( $ )" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Which winner had a location of Iowa?
| SELECT "Winner" FROM table_39353 WHERE "Location" = 'iowa' | wikisql |
CREATE TABLE labevents (
row_id number,
subject_id number,
hadm_id number,
itemid number,
charttime time,
valuenum number,
valueuom text
)
CREATE TABLE d_labitems (
row_id number,
itemid number,
label text
)
CREATE TABLE prescriptions (
row_id number,
subject_id number,... | SELECT AVG(t1.c1) FROM (SELECT SUM(cost.cost) AS c1 FROM cost WHERE cost.hadm_id IN (SELECT prescriptions.hadm_id FROM prescriptions WHERE prescriptions.drug = 'epinephrine hcl') AND DATETIME(cost.chargetime, 'start of year') = DATETIME(CURRENT_TIME(), 'start of year', '-0 year') GROUP BY cost.hadm_id) AS t1 | mimic_iii |
CREATE TABLE table_27079 (
"Year" real,
"Engine" text,
"Power" text,
"Torque" text,
"Transmission" text,
"0\u2013100km/h (60mph)" text,
"Top speed" text,
"CO2" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- when 0 100km/h (60mph) is 5.8 ... | SELECT "Torque" FROM table_27079 WHERE "0\u2013100km/h (60mph)" = '5.8 seconds (5.5)' | wikisql |
CREATE TABLE table_26269 (
"Local Government Area" text,
"Type" text,
"Major Town" text,
"Land Area (km\u00b2)" text,
"Pop. 2006" real,
"Density km \u22122" real,
"Towns" real,
"Est." real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What w... | SELECT "Pop. 2006" FROM table_26269 WHERE "Major Town" = 'Coober Pedy' | wikisql |
CREATE TABLE cost (
costid number,
uniquepid text,
patienthealthsystemstayid number,
eventtype text,
eventid number,
chargetime time,
cost number
)
CREATE TABLE microlab (
microlabid number,
patientunitstayid number,
culturesite text,
organism text,
culturetakentime time... | SELECT SUM(cost.cost) FROM cost WHERE cost.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '008-26792') AND STRFTIME('%y', cost.chargetime) <= '2104' | eicu |
CREATE TABLE d_icd_diagnoses (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE inputevents_cv (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime time,
itemid number,
amount number
)
CREATE TABLE labevents (
r... | SELECT COUNT(DISTINCT t1.subject_id) FROM (SELECT admissions.subject_id, COUNT(*) AS c1 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 = 'pericardiocentesis') ... | mimic_iii |
CREATE TABLE table_name_49 (
week INTEGER,
result VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What's the average Week with the Result l 23 3?
| SELECT AVG(week) FROM table_name_49 WHERE result = "l 23–3" | sql_create_context |
CREATE TABLE table_16387653_1 (
home_team VARCHAR,
away_team VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What did the home team score against Richmond?
| SELECT home_team AS score FROM table_16387653_1 WHERE away_team = "Richmond" | 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 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 procedures ON demographic.hadm_id = procedures.hadm_id WHERE procedures.short_title = "Inj/inf platelet inhibit" | mimicsql_data |
CREATE TABLE table_203_292 (
id number,
"payload type (pt)" text,
"name" text,
"type" text,
"no. of channels" text,
"clock rate (hz)" text,
"frame size (ms)" text,
"default packet size (ms)" text,
"description" text,
"references" text
)
-- Using valid SQLite, answer the followi... | SELECT "type" FROM table_203_292 WHERE "type" <> 'audio' | squall |
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 jybgb.BBCJBW FROM hz_info JOIN mzjzjlb JOIN jybgb ON 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 hz_info.person_info_XM = '郑和璧' AND jybgb.BGRQ BETWEEN '2017-09-16' AND '2018-05-10... | 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 T2.Headquarter, T1.Code FROM Products AS T1 JOIN Manufacturers AS T2 ON T1.Manufacturer = T2.Code GROUP BY T2.Headquarter ORDER BY T1.Code | nvbench |
CREATE TABLE catalog_contents_additional_attributes (
catalog_entry_id number,
catalog_level_number number,
attribute_id number,
attribute_value text
)
CREATE TABLE catalog_structure (
catalog_level_number number,
catalog_id number,
catalog_level_name text
)
CREATE TABLE catalogs (
cat... | SELECT DISTINCT (catalog_entry_name) FROM catalog_contents | spider |
CREATE TABLE table_14984078_1 (
date VARCHAR,
week VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was the game date in week 13?
| SELECT date FROM table_14984078_1 WHERE week = 13 | sql_create_context |
CREATE TABLE table_50899 (
"Team" text,
"Coach" text,
"Home Ground" text,
"Location" text,
"Founded" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the location of South Adelaide?
| SELECT "Location" FROM table_50899 WHERE "Team" = 'south adelaide' | wikisql |
CREATE TABLE table_name_67 (
total_enrollment VARCHAR,
institution_name VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is Howard Payne University's total enrollment?
| SELECT total_enrollment FROM table_name_67 WHERE institution_name = "howard payne university" | sql_create_context |
CREATE TABLE table_13725 (
"Protocol" text,
"Power Line" text,
"Radio-Frequency" text,
"Open Source?" text,
"Needs Neutral Wire?" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Does it need neutral wire when the power line and open source are no?
| SELECT "Needs Neutral Wire?" FROM table_13725 WHERE "Power Line" = 'no' AND "Open Source?" = 'no' | wikisql |
CREATE TABLE Has_Allergy (
StuID INTEGER,
Allergy VARCHAR(20)
)
CREATE TABLE Allergy_Type (
Allergy VARCHAR(20),
AllergyType VARCHAR(20)
)
CREATE TABLE Student (
StuID INTEGER,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER... | SELECT Sex, AVG(Age) FROM Student GROUP BY Sex ORDER BY AVG(Age) DESC | nvbench |
CREATE TABLE table_name_53 (
series VARCHAR,
date VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what series was on may 14
| SELECT series FROM table_name_53 WHERE date = "may 14" | sql_create_context |
CREATE TABLE diagnoses_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
CREATE TABLE cost (
row_id number,
subject_id number,
hadm_id number,
event_type text,
event_id number,
chargetime time,
cost number
)
CREATE TABLE labevents ... | SELECT SUM(prescriptions.dose_val_rx) FROM prescriptions WHERE prescriptions.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 26995 AND NOT admissions.dischtime IS NULL ORDER BY admissions.admittime LIMIT 1) AND prescriptions.drug = 'hydromorphone (dilaudid)' | mimic_iii |
CREATE TABLE table_203_67 (
id number,
"place" number,
"team" text,
"played" number,
"won" number,
"draw" number,
"lost" number,
"goals\nscored" number,
"goals\nconceded" number,
"+/-" number,
"points" number
)
-- Using valid SQLite, answer the following questions for the t... | SELECT "team" FROM table_203_67 WHERE "points" > 30 AND "team" <> 'c.d. fas' | squall |
CREATE TABLE d_icd_procedures (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE inputevents_cv (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime time,
itemid number,
amount number
)
CREATE TABLE cost (
row_i... | SELECT admissions.insurance FROM admissions WHERE admissions.subject_id = 44625 AND NOT admissions.dischtime IS NULL ORDER BY admissions.admittime DESC LIMIT 1 | mimic_iii |
CREATE TABLE Ref_Locations (
Location_Code CHAR(15),
Location_Name VARCHAR(255),
Location_Description VARCHAR(255)
)
CREATE TABLE All_Documents (
Document_ID INTEGER,
Date_Stored DATETIME,
Document_Type_Code CHAR(15),
Document_Name CHAR(255),
Document_Description CHAR(255),
Other_De... | SELECT Role_Code, COUNT(*) FROM Employees GROUP BY Role_Code | nvbench |
CREATE TABLE table_name_84 (
height VARCHAR,
name VARCHAR,
built VARCHAR,
rank VARCHAR,
floors VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is Height, when Rank is less than 20, when Floors is greater than 9, when Built is 2005, and when N... | SELECT height FROM table_name_84 WHERE rank < 20 AND floors > 9 AND built = 2005 AND name = "the edge (c)" | sql_create_context |
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_id number,
icustay_id number,
charttime time,
itemid number,
value number
)
CREATE TABLE d_... | 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 = 14467) AND icustays.outtime IS NULL)... | mimic_iii |
CREATE TABLE table_name_91 (
state VARCHAR,
host VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What state is the University of Tennessee located in?
| SELECT state FROM table_name_91 WHERE host = "university of tennessee" | sql_create_context |
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 t... | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE lab.label = "Iron" | mimicsql_data |
CREATE TABLE Street_Markets (
Market_ID INTEGER,
Market_Details VARCHAR(255)
)
CREATE TABLE Hotels (
hotel_id INTEGER,
star_rating_code CHAR(15),
pets_allowed_yn CHAR(1),
price_range real,
other_hotel_details VARCHAR(255)
)
CREATE TABLE Visitors (
Tourist_ID INTEGER,
Tourist_Detail... | SELECT T1.Name, T1.Tourist_Attraction_ID FROM Tourist_Attractions AS T1 JOIN Visits AS T2 ON T1.Tourist_Attraction_ID = T2.Tourist_Attraction_ID ORDER BY T1.Name DESC | nvbench |
CREATE TABLE Faculty_Participates_in (
FacID INTEGER,
actid INTEGER
)
CREATE TABLE Student (
StuID INTEGER,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE TABLE Activity (
actid INTEGER,
a... | SELECT Sex, COUNT(*) FROM Faculty GROUP BY Sex ORDER BY Sex DESC | nvbench |
CREATE TABLE table_69674 (
"Order" text,
"Minister" text,
"Party" text,
"Prime Minister" text,
"Title" text,
"Term start" text,
"Term end" text,
"Term in office" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What was Parker Moloney's pa... | SELECT "Party" FROM table_69674 WHERE "Minister" = 'parker moloney' AND "Title" = 'minister for markets' | wikisql |
CREATE TABLE table_1342379_23 (
district VARCHAR,
candidates VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- what's the district with candidates being john e. rankin (d) unopposed
| SELECT district FROM table_1342379_23 WHERE candidates = "John E. Rankin (D) Unopposed" | sql_create_context |
CREATE TABLE cite (
citingpaperid int,
citedpaperid int
)
CREATE TABLE keyphrase (
keyphraseid int,
keyphrasename varchar
)
CREATE TABLE paperfield (
fieldid int,
paperid int
)
CREATE TABLE paperdataset (
paperid int,
datasetid int
)
CREATE TABLE paperkeyphrase (
paperid int,
... | SELECT DISTINCT paper.paperid FROM keyphrase, paper, paperkeyphrase WHERE keyphrase.keyphrasename = 'character recognition' AND paperkeyphrase.keyphraseid = keyphrase.keyphraseid AND paper.paperid = paperkeyphrase.paperid AND paper.year < 2010 | scholar |
CREATE TABLE table_10122 (
"Rank" real,
"Nation" text,
"Gold" real,
"Silver" real,
"Bronze" real,
"Total" real
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- For ranks over 2 with Golds over 6 and Silvers over 5 what would be the lowest qualifying To... | SELECT MIN("Total") FROM table_10122 WHERE "Gold" > '6' AND "Rank" > '2' AND "Silver" > '5' | wikisql |
CREATE TABLE microlab (
microlabid number,
patientunitstayid number,
culturesite text,
organism text,
culturetakentime time
)
CREATE TABLE diagnosis (
diagnosisid number,
patientunitstayid number,
diagnosisname text,
diagnosistime time,
icd9code text
)
CREATE TABLE allergy (
... | SELECT t1.diagnosisname FROM (SELECT diagnosis.diagnosisname, DENSE_RANK() OVER (ORDER BY COUNT(*) DESC) AS c1 FROM diagnosis WHERE diagnosis.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.age BETWEEN 40 AND 49) AND STRFTIME('%y', diagnosis.diagnosistime) = '2104' GROUP BY diagnosis.d... | eicu |
CREATE TABLE mzb (
CLINIC_ID 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,
INSU_TYPE text,
IN... | SELECT COUNT(*) FROM qtb WHERE qtb.MED_SER_ORG_NO = '1301404' AND qtb.IN_HOSP_DATE BETWEEN '2010-11-10' AND '2017-09-26' AND qtb.INSURED_STS = '未就业' AND qtb.MED_AMOUT >= 5083.93 UNION SELECT COUNT(*) FROM gyb WHERE gyb.MED_SER_ORG_NO = '1301404' AND gyb.IN_HOSP_DATE BETWEEN '2010-11-10' AND '2017-09-26' AND gyb.INSURED... | css |
CREATE TABLE table_name_52 (
game INTEGER,
date VARCHAR
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- What is the game number held on May 20?
| SELECT AVG(game) FROM table_name_52 WHERE date = "may 20" | sql_create_context |
CREATE TABLE t_kc22 (
AMOUNT number,
CHA_ITEM_LEV number,
DATA_ID text,
DIRE_TYPE number,
DOSE_FORM text,
DOSE_UNIT text,
EACH_DOSAGE text,
EXP_OCC_DATE time,
FLX_MED_ORG_ID text,
FXBZ number,
HOSP_DOC_CD text,
HOSP_DOC_NM text,
MED_CLINIC_ID text,
MED_DIRE_CD tex... | SELECT qtb.MED_CLINIC_ID FROM qtb WHERE qtb.PERSON_NM = '吕格菲' AND NOT qtb.MED_CLINIC_ID IN (SELECT t_kc22.MED_CLINIC_ID FROM t_kc22 WHERE t_kc22.AMOUNT >= 2770.51) UNION SELECT gyb.MED_CLINIC_ID FROM gyb WHERE gyb.PERSON_NM = '吕格菲' AND NOT gyb.MED_CLINIC_ID IN (SELECT t_kc22.MED_CLINIC_ID FROM t_kc22 WHERE t_kc22.AMOUN... | css |
CREATE TABLE procedures_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
CREATE TABLE diagnoses_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
CREATE TABLE cost (
row_id number,
subject_id... | SELECT COUNT(DISTINCT admissions.subject_id) FROM admissions WHERE admissions.hadm_id IN (SELECT procedures_icd.hadm_id FROM procedures_icd WHERE procedures_icd.icd9_code = (SELECT d_icd_procedures.icd9_code FROM d_icd_procedures WHERE d_icd_procedures.short_title = 'atrial cardioversion') AND STRFTIME('%y', procedures... | mimic_iii |
CREATE TABLE cost (
costid number,
uniquepid text,
patienthealthsystemstayid number,
eventtype text,
eventid number,
chargetime time,
cost number
)
CREATE TABLE vitalperiodic (
vitalperiodicid number,
patientunitstayid number,
temperature number,
sao2 number,
heartrate n... | 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 = '035-166') AND NOT patient.unitdischargetime IS NULL... | eicu |
CREATE TABLE table_204_964 (
id number,
"team" text,
"seasons" number,
"games" number,
"wins" number,
"ties" number,
"losses" number,
"goals\nfor" number,
"goals\nagainst" number,
"goal\ndiff" number,
"points" number
)
-- Using valid SQLite, answer the following questions f... | SELECT "team" FROM table_204_964 WHERE "team" <> 'montreal canadiens' AND "seasons" = (SELECT "seasons" FROM table_204_964 WHERE "team" = 'montreal canadiens') | squall |
CREATE TABLE Suppliers (
supplier_id INTEGER,
supplier_name VARCHAR(80),
supplier_phone VARCHAR(80)
)
CREATE TABLE Order_Items (
order_item_id INTEGER,
order_id INTEGER,
product_id INTEGER
)
CREATE TABLE Products (
product_id INTEGER,
product_type_code VARCHAR(10),
product_name VAR... | SELECT product_type_code, MAX(product_price) FROM Products GROUP BY product_type_code ORDER BY product_type_code DESC | nvbench |
CREATE TABLE table_74006 (
"District" text,
"Incumbent" text,
"Party" text,
"First elected" real,
"Result" text,
"Candidates" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- Name the least first elected
| SELECT MIN("First elected") FROM table_74006 | wikisql |
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 Team_Name, School_ID FROM basketball_match ORDER BY School_ID DESC | nvbench |
CREATE TABLE flight_leg (
flight_id int,
leg_number int,
leg_flight int
)
CREATE TABLE compartment_class (
compartment varchar,
class_type varchar
)
CREATE TABLE time_interval (
period text,
begin_time int,
end_time int
)
CREATE TABLE flight_stop (
flight_id int,
stop_number i... | 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, fare_basis, flight, flight_fare WHERE ((CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'NEW YORK' AND fare_basis.class_type = 'COACH' AND fare.fa... | atis |
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 lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.insurance = "Government" AND lab.label = "Ammonia" | mimicsql_data |
CREATE TABLE zzmzjzjlb (
HXPLC number,
HZXM text,
JLSJ time,
JZJSSJ time,
JZKSBM text,
JZKSMC text,
JZKSRQ time,
JZLSH number,
JZZDBM text,
JZZDSM text,
JZZTDM number,
JZZTMC text,
KH text,
KLX number,
MJZH text,
ML number,
MZZYZDZZBM text,
MZZYZDZ... | SELECT (SELECT COUNT(*) FROM hz_info JOIN zzmzjzjlb ON hz_info.YLJGDM = zzmzjzjlb.YLJGDM AND hz_info.KH = zzmzjzjlb.KH AND hz_info.KLX = zzmzjzjlb.KLX WHERE hz_info.RYBH = '12922014' AND zzmzjzjlb.JZKSRQ BETWEEN '2017-03-21' AND '2018-10-30' UNION SELECT COUNT(*) FROM hz_info JOIN fzzmzjzjlb ON hz_info.YLJGDM = fzzmzjz... | css |
CREATE TABLE table_73751 (
"Character" text,
"English version" text,
"Laserdisc edition" text,
"Buena Vista edition" text,
"Special edition" text
)
-- Using valid SQLite, answer the following questions for the tables provided above.
-- who is the character where the special edition is koichi saka... | SELECT "Character" FROM table_73751 WHERE "Special edition" = 'Koichi Sakaguchi' | wikisql |
CREATE TABLE SuggestedEdits (
Id number,
PostId number,
CreationDate time,
ApprovalDate time,
RejectionDate time,
OwnerUserId number,
Comment text,
Text text,
Title text,
Tags text,
RevisionGUID other
)
CREATE TABLE PostFeedback (
Id number,
PostId number,
IsAnon... | SELECT * FROM SuggestedEditVotes WHERE UserId = @UserId | sede |
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 MAX(demographic.days_stay) FROM demographic WHERE demographic.diagnosis = "PITUITARY BLEED" | mimicsql_data |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.