answer stringlengths 6 3.91k | question stringlengths 7 766 | context stringlengths 27 7.14k |
|---|---|---|
SELECT class FROM table_name_1 WHERE no_built < 12 AND operator = "southern" | What class has less than 12 numbers built operated by southern? | CREATE TABLE table_name_1 (class VARCHAR, no_built VARCHAR, operator VARCHAR) |
SELECT COUNT(license) FROM table_15038373_1 WHERE software = "Mind WorkStation" | How many licenses have mind workstation software? | CREATE TABLE table_15038373_1 (license VARCHAR, software VARCHAR) |
SELECT Country, COUNT(Country) FROM manager WHERE Age > 50 OR Age < 46 GROUP BY Country ORDER BY Country DESC | A bar chart for showing the number of the countries that have managers of age above 50 or below 46, list in descending by the bars. | CREATE TABLE railway_manage (
Railway_ID int,
Manager_ID int,
From_Year text
)
CREATE TABLE railway (
Railway_ID int,
Railway text,
Builder text,
Built text,
Wheels text,
Location text,
ObjectNumber text
)
CREATE TABLE train (
Train_ID int,
Train_Num text,
Name text... |
SELECT episode FROM table_name_62 WHERE viewers__m_ > 5.63 AND households__rating_share_ = "4.5/7" | Name the episode for viewers bigger than 5.63 and the households rating is 4.5/7 | CREATE TABLE table_name_62 (episode VARCHAR, viewers__m_ VARCHAR, households__rating_share_ VARCHAR) |
SELECT software FROM table_15038373_1 WHERE version = "1.2.2.0" | What is the software with version 1.2.2.0? | CREATE TABLE table_15038373_1 (software VARCHAR, version VARCHAR) |
SELECT "Skipper" FROM table_22433 WHERE "Corrected Time d:hh:mm:ss" = '2:18:31:49' | Who was the skipper for the vessel with a corrected time of 2:18:31:49? | CREATE TABLE table_22433 (
"Position" real,
"Sail Number" text,
"Yacht" text,
"State/Country" text,
"Yacht Type" text,
"LOA (Metres)" text,
"Skipper" text,
"Corrected Time d:hh:mm:ss" text
) |
SELECT 18 AS _49__rating_share_ FROM table_name_1 WHERE weekly_rank___number_ = "30" | Name the 18-49 rating for weekly rank of 30 | CREATE TABLE table_name_1 (weekly_rank___number_ VARCHAR) |
SELECT license FROM table_15038373_1 WHERE software = "BeeOne SMOD/HMS" | What is hte license for beeone smod/hms software? | CREATE TABLE table_15038373_1 (license VARCHAR, software VARCHAR) |
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_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'TACOMA' AND fare.round_trip_required = 'NO' AND flight_fare.fare_id = ... | show me all flights from ONTARIO to TACOMA one way | CREATE TABLE time_zone (
time_zone_code text,
time_zone_name text,
hours_from_gmt int
)
CREATE TABLE code_description (
code varchar,
description text
)
CREATE TABLE fare (
fare_id int,
from_airport varchar,
to_airport varchar,
fare_basis_code text,
fare_airline text,
restr... |
SELECT driver FROM table_name_39 WHERE laps = "29" | Who was the driver with 29 laps? | CREATE TABLE table_name_39 (driver VARCHAR, laps VARCHAR) |
SELECT operating_systems FROM table_15038373_1 WHERE software = "SBaGen" | What are all the operating systems for sbagen? | CREATE TABLE table_15038373_1 (operating_systems VARCHAR, software VARCHAR) |
SELECT Name, COUNT(Name) FROM debate_people AS T1 JOIN debate AS T2 ON T1.Debate_ID = T2.Debate_ID JOIN people AS T3 ON T1.Affirmative = T3.People_ID GROUP BY Name | Show the number of debates for each person on the affirmative side in a bar chart. | CREATE TABLE debate_people (
Debate_ID int,
Affirmative int,
Negative int,
If_Affirmative_Win bool
)
CREATE TABLE people (
People_ID int,
District text,
Name text,
Party text,
Age int
)
CREATE TABLE debate (
Debate_ID int,
Date text,
Venue text,
Num_of_Audience int
... |
SELECT time_retired FROM table_name_76 WHERE grid = "18" | What was the retired time for someone who was on grid 18? | CREATE TABLE table_name_76 (time_retired VARCHAR, grid VARCHAR) |
SELECT english FROM table_15040_8 WHERE french = "cheval" | What is the English word for the French word cheval? | CREATE TABLE table_15040_8 (english VARCHAR, french VARCHAR) |
SELECT runner_up FROM table_21808535_1 WHERE date = "September 11" | Who was the runner-up on September 11? | CREATE TABLE table_21808535_1 (
runner_up VARCHAR,
date VARCHAR
) |
SELECT grid FROM table_name_84 WHERE driver = "jacques villeneuve" | Jacques Villeneuve was on what grid? | CREATE TABLE table_name_84 (grid VARCHAR, driver VARCHAR) |
SELECT spanish FROM table_15040_8 WHERE french = "filtrer" | What is the Spanish word for the French word filtrer? | CREATE TABLE table_15040_8 (spanish VARCHAR, french VARCHAR) |
SELECT COUNT(incumbent) FROM table_1341690_18 WHERE district = "Louisiana 5" | How many incumbents are there in district Louisiana 5? | CREATE TABLE table_1341690_18 (
incumbent VARCHAR,
district VARCHAR
) |
SELECT time_retired FROM table_name_34 WHERE grid = "9" | What's the time for someone on grid 9? | CREATE TABLE table_name_34 (time_retired VARCHAR, grid VARCHAR) |
SELECT french FROM table_15040_8 WHERE german = "filtern" | What is the French word where the German word is filtern? | CREATE TABLE table_15040_8 (french VARCHAR, german VARCHAR) |
SELECT play FROM table_name_18 WHERE country = "belgium" | What play is from the country Belgium? | CREATE TABLE table_name_18 (
play VARCHAR,
country VARCHAR
) |
SELECT grid FROM table_name_77 WHERE driver = "alex yoong" | What was the grid of Alex Yoong? | CREATE TABLE table_name_77 (grid VARCHAR, driver VARCHAR) |
SELECT french FROM table_15040_8 WHERE russian = "filtrovat (фильтровать)" | What is the french word for the Russian word filtrovat (фильтровать)? | CREATE TABLE table_15040_8 (french VARCHAR, russian VARCHAR) |
SELECT Company, COUNT(*) FROM station_company AS T1 JOIN company AS T2 ON T1.Company_ID = T2.Company_ID GROUP BY T1.Company_ID ORDER BY COUNT(*) DESC | Show the company name with the number of gas station by a bar chart, and show in descending by the y-axis. | CREATE TABLE station_company (
Station_ID int,
Company_ID int,
Rank_of_the_Year int
)
CREATE TABLE gas_station (
Station_ID int,
Open_Year int,
Location text,
Manager_Name text,
Vice_Manager_Name text,
Representative_Name text
)
CREATE TABLE company (
Company_ID int,
Rank i... |
SELECT date FROM table_name_80 WHERE venue = "lake oval" | What date was the game played at Lake Oval? | CREATE TABLE table_name_80 (date VARCHAR, venue VARCHAR) |
SELECT french FROM table_15040_8 WHERE italian = "nazione" | What is the French word for the Italian word nazione? | CREATE TABLE table_15040_8 (french VARCHAR, italian VARCHAR) |
SELECT (SELECT SUM(CASE WHEN DERIVED_TABLEalias0.FRIDAY = 'Y' THEN 1 ELSE 0 END) + SUM(CASE WHEN DERIVED_TABLEalias0.MONDAY = 'Y' THEN 1 ELSE 0 END) + SUM(CASE WHEN DERIVED_TABLEalias0.SATURDAY = 'Y' THEN 1 ELSE 0 END) + SUM(CASE WHEN DERIVED_TABLEalias0.SUNDAY = 'Y' THEN 1 ELSE 0 END) + SUM(CASE WHEN DERIVED_TABLEalia... | How many lectures each week does CDB 598 have ? | CREATE TABLE requirement (
requirement_id int,
requirement varchar,
college varchar
)
CREATE TABLE offering_instructor (
offering_instructor_id int,
offering_id int,
instructor_id int
)
CREATE TABLE instructor (
instructor_id int,
name varchar,
uniqname varchar
)
CREATE TABLE cour... |
SELECT COUNT(crowd) FROM table_name_17 WHERE venue = "victoria park" | How many people came to the game at Victoria Park? | CREATE TABLE table_name_17 (crowd VARCHAR, venue VARCHAR) |
SELECT english FROM table_15040_8 WHERE russian = "loshad, kobyla (лошадь, кобыла)" | What is the English word for the Russian words loshad, kobyla (лошадь, кобыла)? | CREATE TABLE table_15040_8 (english VARCHAR, russian VARCHAR) |
SELECT round FROM table_name_73 WHERE record = "8-2" | What round had a record of 8-2? | CREATE TABLE table_name_73 (
round VARCHAR,
record VARCHAR
) |
SELECT opponent FROM table_name_26 WHERE loss = "moyer (9–4)" | Who lost to moyer (9–4)? | CREATE TABLE table_name_26 (opponent VARCHAR, loss VARCHAR) |
SELECT states FROM table_15055594_6 WHERE fall_06 = 3821 | Which state had 3821 students in the fall of 06? | CREATE TABLE table_15055594_6 (states VARCHAR, fall_06 VARCHAR) |
SELECT "Type" FROM table_27893 WHERE "Settlement" = 'Jazak' | What type of settlement is Jazak? | CREATE TABLE table_27893 (
"Settlement" text,
"Cyrillic Name Other Names" text,
"Type" text,
"Population (2011)" real,
"Largest ethnic group (2002)" text,
"Dominant religion (2002)" text
) |
SELECT attendance FROM table_name_38 WHERE record = "47–63" | How many people attended when the record was broken with 47–63? | CREATE TABLE table_name_38 (attendance VARCHAR, record VARCHAR) |
SELECT fall_05 FROM table_15055594_6 WHERE states = "Maryland" | How man students were from Maryland in Fall 05? | CREATE TABLE table_15055594_6 (fall_05 VARCHAR, states VARCHAR) |
SELECT "U.S. viewers (million)" FROM table_27555 WHERE "Directed by" = 'Jeffrey Blitz' | How many millions of viewers did the episode directed by Jeffrey Blitz have? | CREATE TABLE table_27555 (
"No. in series" real,
"Title" text,
"Directed by" text,
"Written by" text,
"Original air date" text,
"U.S. viewers (million)" text
) |
SELECT home_team AS score FROM table_name_70 WHERE away_team = "collingwood" | What is the score of the home team that played Collingwood? | CREATE TABLE table_name_70 (home_team VARCHAR, away_team VARCHAR) |
SELECT MAX(fall_09) FROM table_15055594_6 WHERE fall_07 = 3940 | What is the number of students in Fall 09 from the state that had 3940 in Fall 07? | CREATE TABLE table_15055594_6 (fall_09 INTEGER, fall_07 VARCHAR) |
SELECT MAX(against) FROM table_name_14 WHERE difference = "12" | Which Against is the highest one that has a Difference of 12? | CREATE TABLE table_name_14 (
against INTEGER,
difference VARCHAR
) |
SELECT visitor FROM table_name_4 WHERE decision = "ward" AND record = "22–21–4" | Who was the visitor when ward recorded the decision with a record of 22–21–4? | CREATE TABLE table_name_4 (visitor VARCHAR, decision VARCHAR, record VARCHAR) |
SELECT MAX(fall_09) FROM table_15055594_6 WHERE fall_06 = 3821 | What was the highest number of students in Fall 09 in the state that had 3821 in Fall 06? | CREATE TABLE table_15055594_6 (fall_09 INTEGER, fall_06 VARCHAR) |
SELECT f_id FROM song WHERE resolution > (SELECT AVG(resolution) FROM song WHERE genre_is = "modern") | What is ids of the songs whose resolution is higher than the average resolution of songs in modern genre? | CREATE TABLE artist (
artist_name text,
country text,
gender text,
preferred_genre text
)
CREATE TABLE files (
f_id number,
artist_name text,
file_size text,
duration text,
formats text
)
CREATE TABLE genre (
g_name text,
rating text,
most_popular_in text
)
CREATE TABL... |
SELECT score FROM table_name_77 WHERE record = "22–19–4" | What is the score of the game when they had a record of 22–19–4? | CREATE TABLE table_name_77 (score VARCHAR, record VARCHAR) |
SELECT MIN(fall_06) FROM table_15055594_6 | What is the lowest number of students from a state during the Fall 06 semester? | CREATE TABLE table_15055594_6 (fall_06 INTEGER) |
SELECT DISTINCT COURSE_0.department, COURSE_0.name, COURSE_0.number FROM course AS COURSE_0, course AS COURSE_1, course_prerequisite WHERE COURSE_0.course_id = course_prerequisite.pre_course_id AND NOT COURSE_0.course_id IN (SELECT STUDENT_RECORDalias0.course_id FROM student_record AS STUDENT_RECORDalias0 WHERE STUDENT... | What courses do I have to take before I can take CHE 472 ? | CREATE TABLE course_prerequisite (
pre_course_id int,
course_id int
)
CREATE TABLE area (
course_id int,
area varchar
)
CREATE TABLE semester (
semester_id int,
semester varchar,
year int
)
CREATE TABLE offering_instructor (
offering_instructor_id int,
offering_id int,
instruc... |
SELECT SUM(1 AS st_week_sales) FROM table_name_51 WHERE album = "finding forever" AND number < 6 | What is the 1st week sales for the album finding forever before the number 6? | CREATE TABLE table_name_51 (album VARCHAR, number VARCHAR) |
SELECT 1321 AS _percentage FROM table_15051_4 WHERE north_carolina = "Colorado" | Name the 132.1% for where north carolina is colorado | CREATE TABLE table_15051_4 (north_carolina VARCHAR) |
SELECT MIN(points) FROM table_name_86 WHERE entrant = "parmalat forti ford" AND year > 1995 | What is the smallest amount of points for parmalat forti ford entrant later than 1995? | CREATE TABLE table_name_86 (
points INTEGER,
entrant VARCHAR,
year VARCHAR
) |
SELECT COUNT(grid) FROM table_name_60 WHERE time_retired = "2:41:38.4" AND laps > 40 | What is the sum number of grid where time/retired is 2:41:38.4 and laps were more than 40? | CREATE TABLE table_name_60 (grid VARCHAR, time_retired VARCHAR, laps VARCHAR) |
SELECT COUNT(shot_pct) FROM table_1505809_2 WHERE blank_ends = 8 | What is the total of all Shot PCT occurrences when the value of Blank Ends is 8? | CREATE TABLE table_1505809_2 (shot_pct VARCHAR, blank_ends VARCHAR) |
SELECT "Nationality" FROM table_52825 WHERE "Player" = 'jeff hornacek' | What Nationality is Jeff Hornacek? | CREATE TABLE table_52825 (
"Player" text,
"Nationality" text,
"Position" text,
"Years for Jazz" text,
"School/Club Team" text
) |
SELECT constructor FROM table_name_14 WHERE laps > 21 AND driver = "john surtees" | Which constructor had laps amounting to more than 21 where the driver was John Surtees? | CREATE TABLE table_name_14 (constructor VARCHAR, laps VARCHAR, driver VARCHAR) |
SELECT locale FROM table_1505809_2 WHERE l = 2 | Where is the Locale when L is 2. | CREATE TABLE table_1505809_2 (locale VARCHAR, l VARCHAR) |
SELECT q.Id AS "post_link", a.Id AS "post_link", q.Score, a.Score, a.Score - q.Score AS gap FROM Posts AS q INNER JOIN (SELECT Id, ParentId, Score, PostTypeId, OwnerUserId FROM Posts WHERE PostTypeId = 2) AS a ON q.Id = a.ParentId INNER JOIN Users AS u ON u.Id = a.OwnerUserId WHERE q.PostTypeId = 1 AND (a.Score > q.Sco... | Largest gap in score between question and answer. | CREATE TABLE PostLinks (
Id number,
CreationDate time,
PostId number,
RelatedPostId number,
LinkTypeId number
)
CREATE TABLE CloseReasonTypes (
Id number,
Name text,
Description text
)
CREATE TABLE SuggestedEdits (
Id number,
PostId number,
CreationDate time,
ApprovalDa... |
SELECT SUM(laps) FROM table_name_6 WHERE driver = "jo bonnier" AND grid < 11 | How many laps did Jo Bonnier driver when the grid number was smaller than 11? | CREATE TABLE table_name_6 (laps INTEGER, driver VARCHAR, grid VARCHAR) |
SELECT MIN(blank_ends) FROM table_1505809_2 WHERE stolen_ends = 7 | What is the lowest value of Blank Ends when Stolen Ends is 7. | CREATE TABLE table_1505809_2 (blank_ends INTEGER, stolen_ends VARCHAR) |
SELECT retired FROM table_13605170_2 WHERE aircraft_type = "Airspeed Fleet Shadower" | How many Airspeed Fleet Shadower aircraft are retired? | CREATE TABLE table_13605170_2 (
retired VARCHAR,
aircraft_type VARCHAR
) |
SELECT SUM(laps) FROM table_name_53 WHERE time_retired = "gearbox" | How many laps were there when time/retired was gearbox? | CREATE TABLE table_name_53 (laps INTEGER, time_retired VARCHAR) |
SELECT Ends AS lost FROM table_1505809_2 WHERE blank_ends = 9 | What is the value of Ends Lost when Blank Ends is 9. | CREATE TABLE table_1505809_2 (Ends VARCHAR, blank_ends VARCHAR) |
SELECT district FROM table_1341884_19 WHERE incumbent = "Frank Chelf" | What district is incumbent frank chelf from? | CREATE TABLE table_1341884_19 (
district VARCHAR,
incumbent VARCHAR
) |
SELECT SUM(attendance) FROM table_name_67 WHERE visitor = "jazz" | How many were in attendance at the game where the visiting team was the Jazz? | CREATE TABLE table_name_67 (attendance INTEGER, visitor VARCHAR) |
SELECT COUNT(combination_classification) FROM table_15059783_1 WHERE points_classification = "Alessandro Petacchi" AND winner = "Erik Zabel" | How many combination classifications have the winner as Erik Zabel and a points classification as Alessandro Petacchi | CREATE TABLE table_15059783_1 (combination_classification VARCHAR, points_classification VARCHAR, winner VARCHAR) |
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE prescriptions.formulary_drug_cd = "SENN187" | give me the number of patients whose drug code is senn187? | 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 opponent FROM table_name_82 WHERE attendance = "34,063" | Who did the Chiefs play at the game attended by 34,063? | CREATE TABLE table_name_82 (opponent VARCHAR, attendance VARCHAR) |
SELECT mountains_classification FROM table_15059783_1 WHERE winner = "Alejandro Valverde" AND points_classification = "Erik Zabel" | If winner is alejandro Valverde and the points Classification is by Erik Zabel, who is the mountain classification? | CREATE TABLE table_15059783_1 (mountains_classification VARCHAR, winner VARCHAR, points_classification VARCHAR) |
SELECT AVG("Mean") FROM table_58852 WHERE "Drug" = 'alcohol' AND "Psychological dependence" > '1.9' | What is the average Mean, when Drug is 'Alcohol', and when Psychological Dependence is greater than 1.9? | CREATE TABLE table_58852 (
"Drug" text,
"Mean" real,
"Pleasure" real,
"Psychological dependence" real,
"Physical dependence" real
) |
SELECT week FROM table_name_48 WHERE attendance = "33,057" | Which week's game was attended by 33,057 people? | CREATE TABLE table_name_48 (week VARCHAR, attendance VARCHAR) |
SELECT COUNT(team_classification) FROM table_15059783_1 WHERE combination_classification = "Alejandro Valverde" AND points_classification = "Alessandro Petacchi" | How many teams have a combination classification of Alejandro Valverde and a Points classification of Alessandro Petacchi? | CREATE TABLE table_15059783_1 (team_classification VARCHAR, combination_classification VARCHAR, points_classification VARCHAR) |
SELECT Nationality, SUM(meter_100) FROM swimmer GROUP BY Nationality ORDER BY Nationality DESC | Bar chart x axis nationality y axis sum meter 100, and I want to sort in desc by the X. | CREATE TABLE record (
ID int,
Result text,
Swimmer_ID int,
Event_ID int
)
CREATE TABLE swimmer (
ID int,
name text,
Nationality text,
meter_100 real,
meter_200 text,
meter_300 text,
meter_400 text,
meter_500 text,
meter_600 text,
meter_700 text,
Time text
)
... |
SELECT organisation FROM table_name_84 WHERE year < 2005 AND award = "best variety show host" | what is the organisation when the year is less than 2005 and the award is the best variety show host? | CREATE TABLE table_name_84 (organisation VARCHAR, year VARCHAR, award VARCHAR) |
SELECT COUNT(avg_finish) FROM table_1507423_4 WHERE winnings = "$3,816,362" | How many times were the winnings $3,816,362? | CREATE TABLE table_1507423_4 (avg_finish VARCHAR, winnings VARCHAR) |
SELECT All_Home, COUNT(All_Home) FROM basketball_match GROUP BY All_Home ORDER BY All_Home DESC | Show me the number of all home by all home in a histogram, and could you order by the bars from high to low? | CREATE TABLE university (
School_ID int,
School text,
Location text,
Founded real,
Affiliation text,
Enrollment real,
Nickname text,
Primary_conference text
)
CREATE TABLE basketball_match (
Team_ID int,
School_ID int,
Team_Name text,
ACC_Regular_Season text,
ACC_Per... |
SELECT organisation FROM table_name_79 WHERE nominated_work_title = "n/a" AND year = 2005 | what is the organisation when the nominated work title is n/a in the year 2005? | CREATE TABLE table_name_79 (organisation VARCHAR, nominated_work_title VARCHAR, year VARCHAR) |
SELECT COUNT(wins) FROM table_1507423_4 WHERE position = "26th" | How many wins were there when the position was 26th? | CREATE TABLE table_1507423_4 (wins VARCHAR, position VARCHAR) |
SELECT "Open Cup" FROM table_26223 WHERE "League" = 'USL PDL' AND "Playoffs" = 'Did not qualify' | Name the open cup for usl pdl for did not qualify | CREATE TABLE table_26223 (
"Year" real,
"Division" real,
"League" text,
"Regular Season" text,
"Playoffs" text,
"Open Cup" text
) |
SELECT MIN(year) FROM table_name_99 WHERE result = "nominated" AND nominated_work_title = "love bites" | what is the lowest year with the result is nominated for the work title is love bites? | CREATE TABLE table_name_99 (year INTEGER, result VARCHAR, nominated_work_title VARCHAR) |
SELECT avg_finish FROM table_1507423_4 WHERE avg_start = "18.4" | What was the average finish when the average start was 18.4? | CREATE TABLE table_1507423_4 (avg_finish VARCHAR, avg_start VARCHAR) |
SELECT CreationDate, Id AS "comment_link" FROM Comments WHERE LOWER(Text) LIKE '%fixed%' AND CreationDate >= '2018-01-01' ORDER BY LENGTH(Text) LIMIT 1000 | Comments including the word 'fixed'. | CREATE TABLE ReviewTaskStates (
Id number,
Name text,
Description text
)
CREATE TABLE ReviewTaskResults (
Id number,
ReviewTaskId number,
ReviewTaskResultTypeId number,
CreationDate time,
RejectionReasonId number,
Comment text
)
CREATE TABLE Comments (
Id number,
PostId num... |
SELECT year FROM table_name_98 WHERE organisation = "star awards" AND result = "won" AND nominated_work_title = "n/a" | what is the year when then organisation is star awards, the result is won and the nominated work title is n/a? | CREATE TABLE table_name_98 (year VARCHAR, nominated_work_title VARCHAR, organisation VARCHAR, result VARCHAR) |
SELECT COUNT(team_s_) FROM table_1507423_4 WHERE position = "76th" | How many teams had a 76th position finish? | CREATE TABLE table_1507423_4 (team_s_ VARCHAR, position VARCHAR) |
SELECT engine FROM table_1181375_1 WHERE number_range = "8–9, 13–16" | what's the engine where number range is 8 9, 13 16 | CREATE TABLE table_1181375_1 (
engine VARCHAR,
number_range VARCHAR
) |
SELECT MAX(year) FROM table_name_85 WHERE result = "nominated" AND nominated_work_title = "n/a" | what is the latest year that has the result of nominated and the nominated work title is n/a? | CREATE TABLE table_name_85 (year INTEGER, result VARCHAR, nominated_work_title VARCHAR) |
SELECT MIN(wins) FROM table_1507423_4 | What is the maximumum number of wins? | CREATE TABLE table_1507423_4 (wins INTEGER) |
SELECT t2.drug FROM (SELECT admissions.subject_id, procedures_icd.charttime FROM procedures_icd JOIN admissions ON procedures_icd.hadm_id = admissions.hadm_id WHERE admissions.subject_id = 65582 AND procedures_icd.icd9_code = (SELECT d_icd_procedures.icd9_code FROM d_icd_procedures WHERE d_icd_procedures.short_title = ... | what drug was prescribed to patient 65582 within 2 days after having undergone the pancreat sphincteroplas since 02/2105? | CREATE TABLE diagnoses_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
CREATE TABLE patients (
row_id number,
subject_id number,
gender text,
dob time,
dod time
)
CREATE TABLE cost (
row_id number,
subject_id number,
hadm_id ... |
SELECT nominated_work_title FROM table_name_52 WHERE result = "won" AND organisation = "star awards" AND award = "top 10 most popular female artiste" AND year > 2007 | what is the nominated work title when the result is won, the organisation is star awards and the award is top 10 most popular female artiste in the year 2007? | CREATE TABLE table_name_52 (nominated_work_title VARCHAR, year VARCHAR, award VARCHAR, result VARCHAR, organisation VARCHAR) |
SELECT team_s_ FROM table_1507423_4 WHERE year = 2007 | What teams won in 2007? | CREATE TABLE table_1507423_4 (team_s_ VARCHAR, year VARCHAR) |
SELECT japanese FROM table_name_98 WHERE number = 3 | What is the Japanese name of the station with a number 3? | CREATE TABLE table_name_98 (
japanese VARCHAR,
number VARCHAR
) |
SELECT rank FROM table_name_47 WHERE gold = "9" AND silver = "9" | What is the rank of the games that had 9 gold and 9 silvers? | CREATE TABLE table_name_47 (rank VARCHAR, gold VARCHAR, silver VARCHAR) |
SELECT COUNT(top_10) FROM table_1507423_5 WHERE position = "78th" | How many entries arr there for the top 10 for the 78th position? | CREATE TABLE table_1507423_5 (top_10 VARCHAR, position VARCHAR) |
SELECT (SELECT vitalperiodic.heartrate FROM vitalperiodic WHERE vitalperiodic.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '025-50213') AND patient.unitdischargetime IS NULL... | compared to second measured on the current intensive care unit visit, is heartrate of patient 025-50213 less than first measured on the current intensive care unit visit? | CREATE TABLE intakeoutput (
intakeoutputid number,
patientunitstayid number,
cellpath text,
celllabel text,
cellvaluenumeric number,
intakeoutputtime time
)
CREATE TABLE patient (
uniquepid text,
patienthealthsystemstayid number,
patientunitstayid number,
gender text,
age te... |
SELECT gold FROM table_name_8 WHERE bronze = "17" AND total = "31" | How many golds were there in a game that has 17 bronze and a total of 31? | CREATE TABLE table_name_8 (gold VARCHAR, bronze VARCHAR, total VARCHAR) |
SELECT MAX(top_10) FROM table_1507423_5 WHERE team_s_ = "#55/#83 Robby Gordon Motorsports" | Where does team #55/#83 robby gordon motorsports rank in the top 10? | CREATE TABLE table_1507423_5 (top_10 INTEGER, team_s_ VARCHAR) |
SELECT longitude FROM table_name_27 WHERE latitude = "77°28′n" | If the latitude is 77 28 n, what is the longitude? | CREATE TABLE table_name_27 (
longitude VARCHAR,
latitude VARCHAR
) |
SELECT games FROM table_name_61 WHERE bronze = "8" AND gold = "4" | Which game had 8 bronze and 4 gold? | CREATE TABLE table_name_61 (games VARCHAR, bronze VARCHAR, gold VARCHAR) |
SELECT COUNT(winnings) FROM table_1507423_5 WHERE team_s_ = "#07 Robby Gordon Motorsports" | How many entries are shown for winnings for team #07 robby gordon motorsports? | CREATE TABLE table_1507423_5 (winnings VARCHAR, team_s_ VARCHAR) |
SELECT T1.name FROM club AS T1 JOIN player AS T2 ON T1.club_id = T2.club_id WHERE T2.position = "Right Wing" | What are the names of the clubs that have players in the position of 'Right Wing'? | CREATE TABLE club (
club_id number,
name text,
region text,
start_year text
)
CREATE TABLE competition (
competition_id number,
year number,
competition_type text,
country text
)
CREATE TABLE player (
player_id number,
name text,
position text,
club_id number,
apps ... |
SELECT date FROM table_name_91 WHERE visitor = "san jose" | When did San Jose visit the St. Louis? | CREATE TABLE table_name_91 (date VARCHAR, visitor VARCHAR) |
SELECT to_par FROM table_1507431_1 WHERE winning_score = 67 - 67 - 69 - 69 = 272 | What are all values for 'to par' for the winning score of 67-67-69-69=272? | CREATE TABLE table_1507431_1 (to_par VARCHAR, winning_score VARCHAR) |
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.diagnosis = "STERNAL WOUND INFECTION" AND demographic.dob_year < "2120" | get the number of patients born before 2120 who are suffering from sternal wound infection primary disease. | 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 SUM(wins) FROM table_name_12 WHERE latest_win = "1999 italian grand prix" AND rank > 15 | How many total wins with the latest win at the 1999 Italian Grand Prix at a rank of 15? | CREATE TABLE table_name_12 (wins INTEGER, latest_win VARCHAR, rank VARCHAR) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.