context stringlengths 11 9.12k | question stringlengths 0 1.06k | SQL stringlengths 2 4.44k | source stringclasses 28
values |
|---|---|---|---|
CREATE TABLE table_5985 (
"Year" text,
"Sports" text,
"Competitors" text,
"Gold" text,
"Silver" text,
"Bronze" text,
"Total" text
) | In the Year Yugoslavia won 1 Silver, how many Gold medals did they win? | SELECT "Gold" FROM table_5985 WHERE "Silver" = '1' | wikisql |
CREATE TABLE regions (
REGION_ID decimal(5,0),
REGION_NAME varchar(25)
)
CREATE TABLE countries (
COUNTRY_ID varchar(2),
COUNTRY_NAME varchar(40),
REGION_ID decimal(10,0)
)
CREATE TABLE jobs (
JOB_ID varchar(10),
JOB_TITLE varchar(35),
MIN_SALARY decimal(6,0),
MAX_SALARY decimal(6,... | For those employees who was hired before 2002-06-21, show me about the correlation between salary and commission_pct in a scatter chart. | SELECT SALARY, COMMISSION_PCT FROM employees WHERE HIRE_DATE < '2002-06-21' | nvbench |
CREATE TABLE table_71742 (
"Position" text,
"Name" text,
"Party" text,
"First elected" real,
"District" text
) | Tell me the name for first elected more than 1988 and district of mason | SELECT "Name" FROM table_71742 WHERE "First elected" > '1988' AND "District" = 'mason' | wikisql |
CREATE TABLE table_name_29 (
circuit VARCHAR,
championship VARCHAR
) | What circuit is the Sprint Cup series championship? | SELECT circuit FROM table_name_29 WHERE championship = "sprint cup series" | sql_create_context |
CREATE TABLE table_34733 (
"Team" text,
"Stadium" text,
"Capacity" real,
"Highest" real,
"Lowest" real,
"Average" real
) | Average larger than 450, and a Capacity smaller than 5,177, and a Stadium of ochilview park is what sum of the highest? | SELECT SUM("Highest") FROM table_34733 WHERE "Average" > '450' AND "Capacity" < '5,177' AND "Stadium" = 'ochilview park' | wikisql |
CREATE TABLE table_name_88 (
country VARCHAR,
name VARCHAR
) | What country has chunkath, mohan verghese as the name? | SELECT country FROM table_name_88 WHERE name = "chunkath, mohan verghese" | sql_create_context |
CREATE TABLE table_46611 (
"Class" text,
"Part 1" text,
"Part 2" text,
"Part 3" text,
"Part 4" text,
"Verb meaning" text
) | What is the class when the verb meaning is to nourish, to grow? | SELECT "Class" FROM table_46611 WHERE "Verb meaning" = 'to nourish, to grow' | wikisql |
CREATE TABLE table_203_99 (
id number,
"season" number,
"date" text,
"driver" text,
"team" text,
"chassis" text,
"engine" text,
"race distance\nlaps" number,
"race distance\nmiles (km)" text,
"race time" text,
"average speed\n(mph)" number,
"report" text
) | how many times did s bastien bourdais win the champ car world series between 2005 and 2007 ? | SELECT COUNT(*) FROM table_203_99 WHERE "season" >= 2005 AND "season" <= 2007 AND "driver" = 'sebastien bourdais' | squall |
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... | give me the number of patients whose death status is 0 and diagnoses icd9 code is 5768? | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id WHERE demographic.expire_flag = "0" AND diagnoses.icd9_code = "5768" | mimicsql_data |
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,
... | what is the number of patients less than 56 years who have hyperglycemia primary disease? | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.diagnosis = "HYPERGLYCEMIA" AND demographic.age < "56" | mimicsql_data |
CREATE TABLE table_name_33 (
lost VARCHAR,
played INTEGER
) | What's the number of losses where played was less than 17? | SELECT COUNT(lost) FROM table_name_33 WHERE played < 17 | sql_create_context |
CREATE TABLE table_21855 (
"Episode" real,
"Original title" text,
"Directed by" text,
"Written by" text,
"Original airdate" text,
"Duration" text,
"Viewership" text
) | Who was the director when the writer was John Sullivan? | SELECT "Directed by" FROM table_21855 WHERE "Written by" = 'John Sullivan' | wikisql |
CREATE TABLE table_25933764_1 (
w INTEGER,
locale VARCHAR,
Ontario VARCHAR
) | If the locale is Ontario, what is the W minimum? | SELECT MIN(w) FROM table_25933764_1 WHERE locale = Ontario | sql_create_context |
CREATE TABLE table_name_16 (
record VARCHAR,
method VARCHAR
) | What was the record when the method of resolution was KO? | SELECT record FROM table_name_16 WHERE method = "ko" | sql_create_context |
CREATE TABLE table_204_395 (
id number,
"year" number,
"competition" text,
"venue" text,
"position" text,
"notes" text
) | what is the name of the last competition ? | SELECT "competition" FROM table_204_395 ORDER BY "year" DESC LIMIT 1 | squall |
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... | 按金额降序列出在医疗就诊17965658456中去除金额最低的药品后患者被开出的药品编码、药品名称和金额都有哪些? | SELECT t_kc22.SOC_SRT_DIRE_CD, t_kc22.SOC_SRT_DIRE_NM, t_kc22.AMOUNT FROM t_kc22 WHERE t_kc21_t_kc22.MED_CLINIC_ID = '17965658456' AND t_kc22.AMOUNT > (SELECT MIN(t_kc22.AMOUNT) FROM t_kc22 JOIN t_kc21_t_kc22 JOIN t_kc21 ON t_kc21_t_kc22.MED_EXP_DET_ID = t_kc22.MED_EXP_DET_ID AND t_kc21_t_kc22.MED_CLINIC_ID = t_kc21.ME... | css |
CREATE TABLE table_30133_3 (
gap_from_thailand_as_of_2012__times_ VARCHAR,
economy VARCHAR
) | What was the gap from Thailand as of 2012 for China? | SELECT gap_from_thailand_as_of_2012__times_ FROM table_30133_3 WHERE economy = "China" | sql_create_context |
CREATE TABLE course (
course_id int,
name varchar,
department varchar,
number varchar,
credits varchar,
advisory_requirement varchar,
enforced_requirement varchar,
description varchar,
num_semesters int,
num_enrolled int,
has_discussion varchar,
has_lab varchar,
has_p... | To take CEE 621 and 611 , what prerequisites are necessary ? | SELECT DISTINCT COURSE_0.department, COURSE_0.name, COURSE_0.number FROM course AS COURSE_0, course AS COURSE_1, course_prerequisite WHERE (COURSE_1.number = 621 OR COURSE_1.number = 611) AND COURSE_0.course_id = course_prerequisite.pre_course_id AND COURSE_1.course_id = course_prerequisite.course_id AND COURSE_1.depar... | advising |
CREATE TABLE zyjzjlb (
YLJGDM text,
JZLSH text,
MZJZLSH text,
KH text,
KLX number,
HZXM text,
WDBZ number,
RYDJSJ time,
RYTJDM number,
RYTJMC text,
JZKSDM text,
JZKSMC text,
RZBQDM text,
RZBQMC text,
RYCWH text,
CYKSDM text,
CYKSMC text,
CYBQDM tex... | 这位患者54994299以前有哪些住院诊断结果咋样啊? | SELECT zyjzjlb.ZYZDBM, zyjzjlb.ZYZDMC FROM hz_info JOIN zyjzjlb ON hz_info.YLJGDM = zyjzjlb.YLJGDM AND hz_info.KH = zyjzjlb.KH AND hz_info.KLX = zyjzjlb.KLX WHERE hz_info.RYBH = '54994299' | css |
CREATE TABLE d_icd_procedures (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE cost (
row_id number,
subject_id number,
hadm_id number,
event_type text,
event_id number,
chargetime time,
cost number
)
CREATE TABLE diagnoses_icd (
row_id ... | what is the daily minimum value of patient 1902's phosphate since 2104? | SELECT MIN(labevents.valuenum) FROM labevents WHERE labevents.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 1902) AND labevents.itemid IN (SELECT d_labitems.itemid FROM d_labitems WHERE d_labitems.label = 'phosphate') AND STRFTIME('%y', labevents.charttime) >= '2104' GROUP BY STRFT... | mimic_iii |
CREATE TABLE medication (
medicationid number,
patientunitstayid number,
drugname text,
dosage text,
routeadmin text,
drugstarttime time,
drugstoptime time
)
CREATE TABLE allergy (
allergyid number,
patientunitstayid number,
drugname text,
allergyname text,
allergytime t... | when was the last time that patient 006-81423 got a indwelling catheter output on the last icu visit? | SELECT intakeoutput.intakeoutputtime FROM intakeoutput WHERE intakeoutput.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '006-81423') AND NOT patient.unitdischargetime IS NULL... | eicu |
CREATE TABLE View_Unit_Status (
apt_id INTEGER,
apt_booking_id INTEGER,
status_date DATETIME,
available_yn BIT
)
CREATE TABLE Apartments (
apt_id INTEGER,
building_id INTEGER,
apt_type_code CHAR(15),
apt_number CHAR(10),
bathroom_count INTEGER,
bedroom_count INTEGER,
room_co... | What are dates of birth of all the guests whose gender is 'Male', and count them by a line chart, and I want to show by the x-axis from high to low. | SELECT date_of_birth, COUNT(date_of_birth) FROM Guests WHERE gender_code = "Male" ORDER BY date_of_birth DESC | nvbench |
CREATE TABLE PendingFlags (
Id number,
FlagTypeId number,
PostId number,
CreationDate time,
CloseReasonTypeId number,
CloseAsOffTopicReasonTypeId number,
DuplicateOfQuestionId number,
BelongsOnBaseHostAddress text
)
CREATE TABLE CloseAsOffTopicReasonTypes (
Id number,
IsUniversa... | Number of answers in past 30 days. | SELECT COUNT(*) FROM Posts WHERE PostTypeId IN (2) AND CreationDate >= DATEADD(DAY, -30, GETDATE()) | sede |
CREATE TABLE table_name_50 (
home VARCHAR,
record VARCHAR
) | Which Home has a Record of 11 14 4? | SELECT home FROM table_name_50 WHERE record = "11–14–4" | sql_create_context |
CREATE TABLE table_2053 (
"Index" real,
"Ozone, Running 8 hourly mean (\u03bcg/m 3 )" text,
"Nitrogen Dioxide, Hourly mean (\u03bcg/m 3 )" text,
"Sulphur Dioxide, 15 minute mean (\u03bcg/m 3 )" text,
"PM10 Particles, 24 hour mean (\u03bcg/m 3 )" text,
"PM2.5 Particles, 24 hour mean (\u03bcg/m 3 ... | What's the number of pm10 particles when sulphur dioxide is at 266-354? | SELECT "PM10 Particles, 24 hour mean (\u03bcg/m 3 )" FROM table_2053 WHERE "Sulphur Dioxide, 15 minute mean (\u03bcg/m 3 )" = '266-354' | wikisql |
CREATE TABLE table_name_11 (
opponent VARCHAR,
date VARCHAR,
city VARCHAR,
time VARCHAR
) | What team was opponen in baltimore, at 2:00pm, on 4/06/08? | SELECT opponent FROM table_name_11 WHERE city = "baltimore" AND time = "2:00pm" AND date = "4/06/08" | 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... | what number of patients have diagnosis short title as rec depr psych-psychotic and drug route as po/ng? | 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.short_title = "Rec depr psych-psychotic" AND prescriptions.route = "PO/NG" | mimicsql_data |
CREATE TABLE class_of_service (
booking_class varchar,
rank int,
class_description text
)
CREATE TABLE airline (
airline_code varchar,
airline_name text,
note text
)
CREATE TABLE code_description (
code varchar,
description text
)
CREATE TABLE flight_stop (
flight_id int,
stop... | could you please give me the round trip fare from DENVER to ATLANTA | SELECT DISTINCT fare.fare_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 = 'DENVER' AND CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_... | atis |
CREATE TABLE table_16799784_4 (
year_named VARCHAR,
name VARCHAR
) | How many schools are named otafuku tholi? | SELECT COUNT(year_named) FROM table_16799784_4 WHERE name = "Otafuku Tholi" | sql_create_context |
CREATE TABLE Rating (
rID int,
mID int,
stars int,
ratingDate date
)
CREATE TABLE Movie (
mID int,
title text,
year int,
director text
)
CREATE TABLE Reviewer (
rID int,
name text
) | Visualize the title and and the total star rating of the movie using a bar chart. | SELECT title, SUM(stars) FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID GROUP BY title | nvbench |
CREATE TABLE batting (
player_id text,
year number,
stint number,
team_id text,
league_id text,
g number,
ab number,
r number,
h number,
double number,
triple number,
hr number,
rbi number,
sb number,
cs number,
bb number,
so number,
ibb number,
... | Find the average height of the players who belong to the college called 'Yale University'. | SELECT AVG(T1.height) FROM player AS T1 JOIN player_college AS T2 ON T1.player_id = T2.player_id JOIN college AS T3 ON T3.college_id = T2.college_id WHERE T3.name_full = 'Yale University' | spider |
CREATE TABLE table_31403 (
"Rank" real,
"Country/Territory" text,
"Miss International" real,
"1st Runner-up" real,
"2nd Runner-up" real,
"3rd Runner-up" real,
"4th Runner-up" real,
"Semifinalists" real,
"Total" real
) | How many women from Uruguay has become third runner-up in this pageant? | SELECT MAX("3rd Runner-up") FROM table_31403 WHERE "Country/Territory" = 'Uruguay' | wikisql |
CREATE TABLE allergy (
allergyid number,
patientunitstayid number,
drugname text,
allergyname text,
allergytime time
)
CREATE TABLE diagnosis (
diagnosisid number,
patientunitstayid number,
diagnosisname text,
diagnosistime time,
icd9code text
)
CREATE TABLE vitalperiodic (
... | whats the first height of patient 008-40862 in 12/this year? | SELECT patient.admissionheight FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '008-40862') AND NOT patient.admissionheight IS NULL AND DATETIME(patient.unitadmittime, 'start of year') = DATETIME(CURRENT_TIME(), 'start of year', '-... | eicu |
CREATE TABLE table_name_42 (
host_country___countries VARCHAR,
silver VARCHAR,
bronze VARCHAR
) | What was the host country when the silver was [[|]] (2) and bronze is czechoslovakia (3)? | SELECT host_country___countries FROM table_name_42 WHERE silver = "[[|]] (2)" AND bronze = "czechoslovakia (3)" | sql_create_context |
CREATE TABLE table_55451 (
"Team" text,
"Class" text,
"Day 1" text,
"Day 2" text,
"Behind" text
) | For the team that had 4:05.096, what was their day 2? | SELECT "Day 2" FROM table_55451 WHERE "Day 1" = '4:05.096' | wikisql |
CREATE TABLE microbiologyevents (
row_id number,
subject_id number,
hadm_id number,
charttime time,
spec_type_desc text,
org_name text
)
CREATE TABLE outputevents (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
charttime time,
itemid number,
va... | what was the name of the last intake that patient 15821 on the last intensive care unit visit had? | SELECT d_items.label FROM d_items WHERE d_items.itemid IN (SELECT inputevents_cv.itemid 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 = 15821) AND NOT icustays.outtime IS N... | mimic_iii |
CREATE TABLE table_29743928_4 (
shutouts INTEGER
) | What is the lowest overall amount of shutouts? | SELECT MIN(shutouts) FROM table_29743928_4 | sql_create_context |
CREATE TABLE code_description (
code varchar,
description text
)
CREATE TABLE airport_service (
city_code varchar,
airport_code varchar,
miles_distant int,
direction varchar,
minutes_distant int
)
CREATE TABLE class_of_service (
booking_class varchar,
rank int,
class_descriptio... | round trip FIRST class fares NEW YORK to MIAMI | SELECT DISTINCT fare.fare_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_0.city_code = AIRPORT_SERVICE_0.city_code AND CITY_0.city_name = 'NEW YORK' AND CITY_1.city_code = AIRPORT_SERVICE_1.city_code A... | atis |
CREATE TABLE SuggestedEditVotes (
Id number,
SuggestedEditId number,
UserId number,
VoteTypeId number,
CreationDate time,
TargetUserId number,
TargetRepChange number
)
CREATE TABLE PostNoticeTypes (
Id number,
ClassId number,
Name text,
Body text,
IsHidden boolean,
P... | Analysing User Activity Over Time. | SELECT COUNT(*) AS "Users Joined", TIME_TO_STR('creationdate', '%-mONT%-H') AS "Month", TIME_TO_STR('creationdate', '%YEAR') AS "Year" FROM Users GROUP BY TIME_TO_STR('creationdate', '%YEAR'), TIME_TO_STR('creationdate', '%-mONT%-H') ORDER BY TIME_TO_STR('creationdate', '%YEAR'), TIME_TO_STR('creationdate', '%-mONT%-H'... | sede |
CREATE TABLE table_59963 (
"Week 1" text,
"Week 2" text,
"Week 3" text,
"Week 4" text,
"Week 5" text,
"Week 6" text,
"Week 7" text,
"Week 8" text,
"Week 9" text,
"Week 10 FINAL" text
) | Which Week 3 has a Week 9 of ejected (day 3)? | SELECT "Week 3" FROM table_59963 WHERE "Week 9" = 'ejected (day 3)' | wikisql |
CREATE TABLE table_27264 (
"Air date" text,
"Reward" text,
"Immunity" text,
"Eliminated" text,
"Vote" text,
"Finish" text
) | How many entries are there for vote when the air date was 15 november 1997? | SELECT COUNT("Vote") FROM table_27264 WHERE "Air date" = '15 November 1997' | wikisql |
CREATE TABLE Assessment_Notes (
notes_id INTEGER,
student_id INTEGER,
teacher_id INTEGER,
date_of_notes DATETIME,
text_of_notes VARCHAR(255),
other_details VARCHAR(255)
)
CREATE TABLE Ref_Incident_Type (
incident_type_code VARCHAR(10),
incident_type_description VARCHAR(80)
)
CREATE TAB... | Show the number of date of notes from each date of notes, could you display by the Y in descending? | SELECT date_of_notes, COUNT(date_of_notes) FROM Assessment_Notes ORDER BY COUNT(date_of_notes) DESC | nvbench |
CREATE TABLE Comments (
Id number,
PostId number,
Score number,
Text text,
CreationDate time,
UserDisplayName text,
UserId number,
ContentLicense text
)
CREATE TABLE Badges (
Id number,
UserId number,
Name text,
Date time,
Class number,
TagBased boolean
)
CREATE... | Get Posts by Tags (with order). | SELECT * FROM Posts WHERE Tags = '<domain-driven-design>' | sede |
CREATE TABLE table_12166 (
"Tournament" text,
"2010" text,
"2011" text,
"2012" text,
"2013" text
) | In which tournament was the 2012 result 1r and the 2013 result 3r? | SELECT "Tournament" FROM table_12166 WHERE "2012" = '1r' AND "2013" = '3r' | wikisql |
CREATE TABLE election (
Election_ID int,
Counties_Represented text,
District int,
Delegate text,
Party int,
First_Elected real,
Committee text
)
CREATE TABLE party (
Party_ID int,
Year real,
Party text,
Governor text,
Lieutenant_Governor text,
Comptroller text,
A... | Show the name of each county along with the corresponding number of delegates from that county with a pie chart. | SELECT County_name, COUNT(*) FROM county AS T1 JOIN election AS T2 ON T1.County_Id = T2.District GROUP BY T1.County_Id | nvbench |
CREATE TABLE table_66095 (
"Pinn. Rank" real,
"Std. Rank" real,
"Name" text,
"Pinnacle height ft (m)" text,
"Standard height ft (m)" text,
"Floors" real,
"Year" real
) | Which Floors have a Pinnacle height ft (m) of 995 (303), and an Std Rank larger than 6? | SELECT MAX("Floors") FROM table_66095 WHERE "Pinnacle height ft (m)" = '995 (303)' AND "Std. Rank" > '6' | wikisql |
CREATE TABLE table_name_70 (
city INTEGER,
total VARCHAR,
borough VARCHAR
) | What average city has a total less than 2, with a borough greater than 0? | SELECT AVG(city) FROM table_name_70 WHERE total < 2 AND borough > 0 | sql_create_context |
CREATE TABLE Documents (
project_id VARCHAR
) | Show project ids and the number of documents in each project. | SELECT project_id, COUNT(*) FROM Documents GROUP BY project_id | sql_create_context |
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)
)
CREATE TABLE PROFESSOR (
EMP_NUM int,
DEPT_CODE varchar(10),
PROF_OFFICE varchar(50),
PROF_EXTENSION varchar(4),
... | How many sections does each course has Visualize by bar chart, could you display in ascending by the X-axis please? | SELECT CRS_CODE, COUNT(*) FROM CLASS GROUP BY CRS_CODE ORDER BY CRS_CODE | nvbench |
CREATE TABLE transfers (
row_id number,
subject_id number,
hadm_id number,
icustay_id number,
eventtype text,
careunit text,
wardid number,
intime time,
outtime time
)
CREATE TABLE d_items (
row_id number,
itemid number,
label text,
linksto text
)
CREATE TABLE chart... | how many patients were diagnosed with cardiomyopath in oth dis and not readmitted within 2 months since 2 years ago? | SELECT (SELECT COUNT(DISTINCT t1.subject_id) FROM (SELECT admissions.subject_id, diagnoses_icd.charttime FROM diagnoses_icd JOIN admissions ON diagnoses_icd.hadm_id = admissions.hadm_id WHERE diagnoses_icd.icd9_code = (SELECT d_icd_diagnoses.icd9_code FROM d_icd_diagnoses WHERE d_icd_diagnoses.short_title = 'cardiomyop... | mimic_iii |
CREATE TABLE table_name_72 (
reserved_for___sc___st__none_ VARCHAR,
constituency_number VARCHAR
) | What was reserved in the district that has 169 constituents? | SELECT reserved_for___sc___st__none_ FROM table_name_72 WHERE constituency_number = "169" | sql_create_context |
CREATE TABLE table_48727 (
"Driver" text,
"Team" text,
"Laps" real,
"Time/Retired" text,
"Grid" real,
"Points" real
) | If a team has a grid of over 8 with less than 4 points, what's the team name? | SELECT "Team" FROM table_48727 WHERE "Grid" > '8' AND "Points" < '4' | wikisql |
CREATE TABLE table_67715 (
"Res." text,
"Record" text,
"Opponent" text,
"Method" text,
"Event" text,
"Round" text,
"Location" text
) | Which opponent has the event Jungle Fight 6? | SELECT "Opponent" FROM table_67715 WHERE "Event" = 'jungle fight 6' | wikisql |
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... | what is the number of patients whose year of birth is less than 2089 and lab test fluid is blood? | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.dob_year < "2089" AND lab.fluid = "Blood" | mimicsql_data |
CREATE TABLE table_67091 (
"Season" text,
"League" text,
"Rank" real,
"Games" real,
"Points" real,
"Manager" text,
"Top Scorer" text,
"Goals" real
) | Name the least rank when games are more than 34 and the season is 2009-10 | SELECT MIN("Rank") FROM table_67091 WHERE "Games" > '34' AND "Season" = '2009-10' | wikisql |
CREATE TABLE fgwyjzb (
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,
... | 00738240365被医疗就诊的病情描述是什么? | SELECT gwyjzb.MAIN_COND_DES FROM gwyjzb WHERE gwyjzb.MED_CLINIC_ID = '00738240365' UNION SELECT fgwyjzb.MAIN_COND_DES FROM fgwyjzb WHERE fgwyjzb.MED_CLINIC_ID = '00738240365' | css |
CREATE TABLE jobs (
JOB_ID varchar(10),
JOB_TITLE varchar(35),
MIN_SALARY decimal(6,0),
MAX_SALARY decimal(6,0)
)
CREATE TABLE departments (
DEPARTMENT_ID decimal(4,0),
DEPARTMENT_NAME varchar(30),
MANAGER_ID decimal(6,0),
LOCATION_ID decimal(4,0)
)
CREATE TABLE regions (
REGION_ID... | For those employees who do not work in departments with managers that have ids between 100 and 200, show me about the distribution of job_id and salary in a bar chart. | SELECT JOB_ID, SALARY FROM employees WHERE NOT DEPARTMENT_ID IN (SELECT DEPARTMENT_ID FROM departments WHERE MANAGER_ID BETWEEN 100 AND 200) | nvbench |
CREATE TABLE table_train_169 (
"id" int,
"leukocytes" int,
"hemoglobin_a1c_hba1c" float,
"urine_albumin_excretion" int,
"estimated_glomerular_filtration_rate_egfr" int,
"glucola_beverage_gct" int,
"age" float,
"NOUSE" float
) | screening urine albumin excretion < 300 mg / gmcr | SELECT * FROM table_train_169 WHERE urine_albumin_excretion < 300 | criteria2sql |
CREATE TABLE PostFeedback (
Id number,
PostId number,
IsAnonymous boolean,
VoteTypeId number,
CreationDate time
)
CREATE TABLE ReviewTaskStates (
Id number,
Name text,
Description text
)
CREATE TABLE PostsWithDeleted (
Id number,
PostTypeId number,
AcceptedAnswerId number,
... | Sort users by great answer badge counts. | SELECT COUNT(UserId), COUNT(DISTINCT UserId) FROM Badges WHERE Name = 'Great Answer' | sede |
CREATE TABLE PostTags (
PostId number,
TagId number
)
CREATE TABLE PostsWithDeleted (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
ViewCount number,
Body text,
OwnerUserId number,
OwnerDis... | question for a dask tag. | SELECT *, Tags, CreationDate, LastActivityDate, AnswerCount, PostTypeId FROM Posts WHERE Tags LIKE '%dask%' ORDER BY ParentId, Id | sede |
CREATE TABLE jyjgzbb (
BGDH text,
BGRQ time,
CKZFWDX text,
CKZFWSX number,
CKZFWXX number,
JCFF text,
JCRGH text,
JCRXM text,
JCXMMC text,
JCZBDM text,
JCZBJGDL number,
JCZBJGDW text,
JCZBJGDX text,
JCZBMC text,
JLDW text,
JYRQ time,
JYZBLSH text,
... | 找出蒋宏畅在医院7067838的住院记录中,入院科室名不带有骨科的就诊记录 | SELECT * FROM person_info JOIN hz_info JOIN zyjzjlb ON person_info.RYBH = hz_info.RYBH AND hz_info.YLJGDM = zyjzjlb.YLJGDM AND hz_info.KH = zyjzjlb.KH AND hz_info.KLX = zyjzjlb.KLX WHERE person_info.XM = '蒋宏畅' AND hz_info.YLJGDM = '7067838' AND NOT zyjzjlb.JZKSMC LIKE '%骨科%' | css |
CREATE TABLE zyjzjlb (
CYBQDM text,
CYBQMC text,
CYCWH text,
CYKSDM text,
CYKSMC text,
CYSJ time,
CYZTDM number,
HZXM text,
JZKSDM text,
JZKSMC text,
JZLSH text,
KH text,
KLX number,
MZBMLX number,
MZJZLSH text,
MZZDBM text,
MZZDMC text,
MZZYZDZZBM... | 患者36425103在门诊诊断为由于使用阿片类药引起的精神病性障碍的触珠蛋白的结果定量还有单位都是多少呢? | SELECT jyjgzbb.JCZBJGDL, jyjgzbb.JCZBJGDW FROM hz_info JOIN mzjzjlb JOIN jybgb JOIN jyjgzbb JOIN jybgb_jyjgzbb 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 AND jybgb.YLJGDM = jybgb_jyjgzbb.Y... | css |
CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
language text,
religion text,
... | provide the number of patients whose admission location is emergency room admit and diagnoses icd9 code is 4580? | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id WHERE demographic.admission_location = "EMERGENCY ROOM ADMIT" AND diagnoses.icd9_code = "4580" | mimicsql_data |
CREATE TABLE table_name_54 (
years_in_assembly VARCHAR,
residence VARCHAR
) | What were the San Francisco resident's years in assembly? | SELECT years_in_assembly FROM table_name_54 WHERE residence = "san francisco" | sql_create_context |
CREATE TABLE table_204_655 (
id number,
"year" number,
"winner" text,
"album" text,
"other finalists" text
) | what was the earliest winner ? | SELECT "winner" FROM table_204_655 ORDER BY "year" LIMIT 1 | squall |
CREATE TABLE table_name_84 (
location VARCHAR,
name VARCHAR
) | Where has a Name of zhongornis? | SELECT location FROM table_name_84 WHERE name = "zhongornis" | sql_create_context |
CREATE TABLE person_info (
CSD text,
CSRQ time,
GJDM text,
GJMC text,
JGDM text,
JGMC text,
MZDM text,
MZMC text,
RYBH text,
XBDM number,
XBMC text,
XLDM text,
XLMC text,
XM text,
ZYLBDM text,
ZYMC text
)
CREATE TABLE jyjgzbb (
BGDH text,
BGRQ tim... | 查询医疗机构2057773在07年3月15之后,住院就诊记录中有多少入院登记 | SELECT COUNT(*) FROM wdmzjzjlb WHERE wdmzjzjlb.YLJGDM = '2057773' AND wdmzjzjlb.RYDJSJ > '2007-03-15' UNION SELECT COUNT(*) FROM bdmzjzjlb WHERE bdmzjzjlb.YLJGDM = '2057773' AND bdmzjzjlb.RYDJSJ > '2007-03-15' | css |
CREATE TABLE table_name_30 (
attendance INTEGER,
week VARCHAR
) | What is the lowest attendance with week 14? | SELECT MIN(attendance) FROM table_name_30 WHERE week = 14 | sql_create_context |
CREATE TABLE requirement (
requirement_id int,
requirement varchar,
college varchar
)
CREATE TABLE ta (
campus_job_id int,
student_id int,
location varchar
)
CREATE TABLE program_requirement (
program_id int,
category varchar,
min_credit int,
additional_req varchar
)
CREATE TA... | Who would be the teacher this Spring-Summer for FILMVID 302 ? | SELECT DISTINCT instructor.name FROM course INNER JOIN course_offering ON course.course_id = course_offering.course_id INNER JOIN offering_instructor ON offering_instructor.offering_id = course_offering.offering_id INNER JOIN instructor ON offering_instructor.instructor_id = instructor.instructor_id INNER JOIN semester... | advising |
CREATE TABLE table_11206787_5 (
stadium VARCHAR,
team VARCHAR
) | What is the stadium for alloa athletic? | SELECT stadium FROM table_11206787_5 WHERE team = "Alloa Athletic" | sql_create_context |
CREATE TABLE table_name_70 (
score VARCHAR,
date VARCHAR,
away_team VARCHAR
) | What is the score of the game against away team exeter city on 10 jan 1990? | SELECT score FROM table_name_70 WHERE date = "10 jan 1990" AND away_team = "exeter city" | sql_create_context |
CREATE TABLE patient (
uniquepid text,
patienthealthsystemstayid number,
patientunitstayid number,
gender text,
age text,
ethnicity text,
hospitalid number,
wardid number,
admissionheight number,
admissionweight number,
dischargeweight number,
hospitaladmittime time,
... | count the number of times patient 015-46307 has had output (ml)-chest tube #1 pleural left anterior;lower outputs until 12/25/2105. | 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 = '015-46307')) AND intakeoutput.cellpath LIKE '%output%' AND intakeoutput.ce... | eicu |
CREATE TABLE playlisttrack (
playlistid number,
trackid number
)
CREATE TABLE album (
albumid number,
title text,
artistid number
)
CREATE TABLE genre (
genreid number,
name text
)
CREATE TABLE mediatype (
mediatypeid number,
name text
)
CREATE TABLE invoiceline (
invoiceline... | Find the average millisecond length of Latin and Pop tracks. | SELECT AVG(milliseconds) FROM genre AS T1 JOIN track AS T2 ON T1.genreid = T2.genreid WHERE T1.name = "Latin" OR T1.name = "Pop" | spider |
CREATE TABLE table_11358 (
"Year" real,
"Organization" text,
"Award" text,
"Work" text,
"Result" text
) | Where Award is newcomer actress, what is the work? | SELECT "Work" FROM table_11358 WHERE "Award" = 'newcomer actress' | wikisql |
CREATE TABLE table_1140117_5 (
date VARCHAR,
race_name VARCHAR
) | Which date did the race name XII Pau Grand Prix take place on? | SELECT date FROM table_1140117_5 WHERE race_name = "XII Pau Grand Prix" | sql_create_context |
CREATE TABLE d_icd_procedures (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE patients (
row_id number,
subject_id number,
gender text,
dob time,
dod time
)
CREATE TABLE admissions (
row_id number,
subject_id number,
hadm_id number,
... | what are the five most commonly taken specimen tests until 3 years ago for patients who were previously diagnosed with deliver-single liveborn during the same month? | SELECT t3.spec_type_desc FROM (SELECT t2.spec_type_desc, DENSE_RANK() OVER (ORDER BY COUNT(*) DESC) AS c1 FROM (SELECT admissions.subject_id, diagnoses_icd.charttime FROM diagnoses_icd JOIN admissions ON diagnoses_icd.hadm_id = admissions.hadm_id WHERE diagnoses_icd.icd9_code = (SELECT d_icd_diagnoses.icd9_code FROM d_... | mimic_iii |
CREATE TABLE table_16731248_1 (
spi VARCHAR,
number_on_cyl VARCHAR
) | Are there SPI on the number 7 cylinder? | SELECT spi FROM table_16731248_1 WHERE number_on_cyl = "7" | sql_create_context |
CREATE TABLE ReviewTaskStates (
Id number,
Name text,
Description text
)
CREATE TABLE Users (
Id number,
Reputation number,
CreationDate time,
DisplayName text,
LastAccessDate time,
WebsiteUrl text,
Location text,
AboutMe text,
Views number,
UpVotes number,
DownV... | Number of Votes per Post. | SELECT PostId, COUNT(*) FROM Votes WHERE NOT PostId IS NULL GROUP BY PostId ORDER BY PostId, NEWID() | sede |
CREATE TABLE hz_info_mzjzjlb (
JZLSH number,
YLJGDM number,
mzjzjlb_id number
)
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,
... | 列出在医院2797205中编号为16026423患者就诊科室名称包含足踝的所有门诊就诊记录的流水号是多少? | SELECT mzjzjlb.JZLSH FROM hz_info JOIN mzjzjlb JOIN hz_info_mzjzjlb ON hz_info.YLJGDM = hz_info_mzjzjlb.YLJGDM AND hz_info.KH = mzjzjlb.KH AND hz_info.KLX = mzjzjlb.KLX AND hz_info_mzjzjlb.JZLSH = mzjzjlb.JZLSH AND hz_info_mzjzjlb.YLJGDM = hz_info_mzjzjlb.YLJGDM AND hz_info_mzjzjlb.JZLSH = mzjzjlb.JZLSH AND hz_info_mzj... | css |
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 ... | 从10年12月28日开始到2011年10月6日为止,为病员25627838检测前白蛋白的医务人员工号及姓名各是什么? | SELECT jyjgzbb.JCRGH, jyjgzbb.JCRXM FROM hz_info JOIN mzjzjlb JOIN jybgb JOIN jyjgzbb JOIN mzjzjlb_jybgb ON hz_info.YLJGDM = mzjzjlb.YLJGDM AND hz_info.KH = mzjzjlb.KH AND hz_info.KLX = mzjzjlb.KLX AND mzjzjlb.YLJGDM = mzjzjlb_jybgb.YLJGDM_MZJZJLB AND mzjzjlb.JZLSH = jybgb.JZLSH_MZJZJLB AND jybgb.YLJGDM = jyjgzbb.YLJGD... | css |
CREATE TABLE table_name_28 (
serial_numbers VARCHAR,
class VARCHAR
) | What are the serial numbers for the locomotives of Class 4-8-4 oooooooo northern? | SELECT serial_numbers FROM table_name_28 WHERE class = "4-8-4 — oooooooo — northern" | sql_create_context |
CREATE TABLE table_18755 (
"Frequency" text,
"Call sign" text,
"Name" text,
"Format" text,
"Owner" text,
"Target city/ market" text,
"City of license" text
) | What are the market city/market(s) for Rapid City Alternative format? | SELECT "Target city/ market" FROM table_18755 WHERE "City of license" = 'Rapid City' AND "Format" = 'Alternative' | wikisql |
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 text
)
CREATE... | A bar chart shows the distribution of meter_600 and ID , could you rank in desc by the X-axis? | SELECT meter_600, ID FROM swimmer ORDER BY meter_600 DESC | nvbench |
CREATE TABLE table_12782 (
"Satellite" text,
"Launch date" text,
"Carrier rocket" text,
"Launch site" text,
"COSPAR ID" text
) | Which satellite was launched from Vandenberg? | SELECT "Satellite" FROM table_12782 WHERE "Launch site" = 'vandenberg' | wikisql |
CREATE TABLE table_22165661_3 (
location VARCHAR,
tournament VARCHAR
) | What is the location of the 1999 tournament? | SELECT location FROM table_22165661_3 WHERE tournament = 1999 | sql_create_context |
CREATE TABLE Course_Authors_and_Tutors (
author_id INTEGER,
author_tutor_ATB VARCHAR(3),
login_name VARCHAR(40),
password VARCHAR(40),
personal_name VARCHAR(80),
middle_name VARCHAR(80),
family_name VARCHAR(80),
gender_mf VARCHAR(1),
address_line_1 VARCHAR(80)
)
CREATE TABLE Courses... | A bar chart for returning the number of the completion date for all the tests that have 'Fail' result, and list from high to low by the Y-axis. | SELECT date_of_completion, COUNT(date_of_completion) FROM Student_Course_Enrolment AS T1 JOIN Student_Tests_Taken AS T2 ON T1.registration_id = T2.registration_id WHERE T2.test_result = "Fail" GROUP BY date_of_completion ORDER BY COUNT(date_of_completion) DESC | nvbench |
CREATE TABLE table_26815 (
"Episode no." real,
"Airdate" text,
"Viewers" real,
"BBC Three weekly ranking" text,
"Cable rank" text
) | What date did the episode air that had a ranking of 17 for cable? | SELECT "Airdate" FROM table_26815 WHERE "Cable rank" = '17' | wikisql |
CREATE TABLE table_name_25 (
attendance VARCHAR,
tie_no VARCHAR
) | Which Attendance has a Tie # of 15? | SELECT attendance FROM table_name_25 WHERE tie_no = "15" | sql_create_context |
CREATE TABLE table_name_49 (
state VARCHAR,
city VARCHAR,
aam_accredited VARCHAR,
astc_member VARCHAR
) | What is State, when AAM Accredited is No, when ASTC Member is No, and when City is Tulsa? | SELECT state FROM table_name_49 WHERE aam_accredited = "no" AND astc_member = "no" AND city = "tulsa" | sql_create_context |
CREATE TABLE Allergy_Type (
Allergy VARCHAR(20),
AllergyType VARCHAR(20)
)
CREATE TABLE Has_Allergy (
StuID INTEGER,
Allergy VARCHAR(20)
)
CREATE TABLE Student (
StuID INTEGER,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER... | Show all allergy type with number of students affected Visualize by bar chart, list the total number in descending order. | SELECT AllergyType, COUNT(*) FROM Has_Allergy AS T1 JOIN Allergy_Type AS T2 ON T1.Allergy = T2.Allergy GROUP BY T2.AllergyType ORDER BY COUNT(*) DESC | nvbench |
CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE prescriptions... | count the number of patients on main drug prescription who have procedure icd9 code 5771. | 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 = "5771" AND prescriptions.drug_type = "MAIN" | mimicsql_data |
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,
... | count the number of patients whose drug route is im. | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE prescriptions.route = "IM" | mimicsql_data |
CREATE TABLE TagSynonyms (
Id number,
SourceTagName text,
TargetTagName text,
CreationDate time,
OwnerUserId number,
AutoRenameCount number,
LastAutoRename time,
Score number,
ApprovedByUserId number,
ApprovalDate time
)
CREATE TABLE VoteTypes (
Id number,
Name text
)
C... | Questions by FavouriteCount minus Score. | SELECT Id AS "post_link", Score, FavoriteCount FROM Posts WHERE PostTypeId = 1 AND ClosedDate IS NULL AND CommunityOwnedDate IS NULL ORDER BY FavoriteCount - Score DESC LIMIT 100 | sede |
CREATE TABLE table_203_350 (
id number,
"team #1" text,
"agg." text,
"team #2" text,
"1st leg" text,
"2nd leg" text
) | what was the 1st leg score in the match between lamia and kastoria ? | SELECT "1st leg" FROM table_203_350 WHERE "team #1" = 'lamia' AND "team #2" = 'kastoria' | squall |
CREATE TABLE Department (
DNO INTEGER,
Division VARCHAR(2),
DName VARCHAR(25),
Room VARCHAR(5),
Building VARCHAR(13),
DPhone INTEGER
)
CREATE TABLE Member_of (
FacID INTEGER,
DNO INTEGER,
Appt_Type VARCHAR(15)
)
CREATE TABLE Minor_in (
StuID INTEGER,
DNO INTEGER
)
CREATE T... | Draw a bar chart about the distribution of Days and the sum of Credits , and group by attribute Days. | SELECT Days, SUM(Credits) FROM Course GROUP BY Days ORDER BY Credits | nvbench |
CREATE TABLE table_32422 (
"Team" text,
"Chassis" text,
"Engine" text,
"Tires" text,
"Drivers" text
) | What is the engine for the Bettenhausen Motorsports team? | SELECT "Engine" FROM table_32422 WHERE "Team" = 'bettenhausen motorsports' | wikisql |
CREATE TABLE table_32564 (
"Home team" text,
"Home team score" text,
"Away team" text,
"Away team score" text,
"Venue" text,
"Crowd" real,
"Date" text
) | Who watches North Melbourne when they are away? | SELECT "Crowd" FROM table_32564 WHERE "Away team" = 'north melbourne' | wikisql |
CREATE TABLE table_name_20 (
channel_4_weekly_rank_a INTEGER,
viewers__millions_ VARCHAR,
airdate VARCHAR
) | What is the average Channel 4 weekly rank for less than 2.19 million viewers on December 7, 2007? | SELECT AVG(channel_4_weekly_rank_a) FROM table_name_20 WHERE viewers__millions_ < 2.19 AND airdate = "december 7, 2007" | sql_create_context |
CREATE TABLE table_62000 (
"Date" text,
"Result" text,
"Score" text,
"Venue" text,
"Competition" text
) | What is the result of the friendly competition on 23 January 2010? | SELECT "Result" FROM table_62000 WHERE "Competition" = 'friendly' AND "Date" = '23 january 2010' | wikisql |
CREATE TABLE table_4128 (
"Pick" text,
"Player" text,
"Position" text,
"Nationality" text,
"NHL team" text,
"College/junior/club team" text
) | How many picks have canada as the nationality and larry courville is the player? | SELECT COUNT("Pick") FROM table_4128 WHERE "Nationality" = 'Canada' AND "Player" = 'Larry Courville' | wikisql |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.