answer stringlengths 6 3.91k | question stringlengths 7 766 | context stringlengths 27 7.14k |
|---|---|---|
SELECT COUNT(population__1991_) FROM table_2562572_2 WHERE city___municipality = "Bečej" | What is the number of 1991 populations named Bečej? | CREATE TABLE table_2562572_2 (population__1991_ VARCHAR, city___municipality VARCHAR) |
SELECT length FROM table_name_26 WHERE bullet = "6.5 (.257)" | Which length has a Bullet of 6.5 (.257)? | CREATE TABLE table_name_26 (length VARCHAR, bullet VARCHAR) |
SELECT manager FROM table_name_52 WHERE manufacturer = "adidas" AND club = "newcastle united" | What Premier League Manager has an Adidas sponsor and a Newcastle United club? | CREATE TABLE table_name_52 (
manager VARCHAR,
manufacturer VARCHAR,
club VARCHAR
) |
SELECT population__1991_ FROM table_2562572_2 WHERE urban_settlement = "Bački Jarak" | What is the 1991 population for the urban settlement named Bački Jarak? | CREATE TABLE table_2562572_2 (population__1991_ VARCHAR, urban_settlement VARCHAR) |
SELECT MIN(overall) FROM table_name_11 WHERE college = "washington" | What is the lowest overall pick for a player from Washington? | CREATE TABLE table_name_11 (overall INTEGER, college VARCHAR) |
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN prescriptions ON demographic.hadm_id = prescriptions.hadm_id WHERE demographic.ethnicity = "HISPANIC/LATINO - PUERTO RICAN" AND prescriptions.drug = "Sulfamethoxazole-Trimethoprim" | how many patients of hispano/latino - puerto rican ethnicity have been prescribed the drug sulfamethoxazole - trimethoprim? | 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,
language text,
religion text,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear text
)
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 text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
) |
SELECT COUNT(population__2011_) FROM table_2562572_2 WHERE population__2002_ = 29449 | What is the number of 2011 populations having a 2002 population of 29449? | CREATE TABLE table_2562572_2 (population__2011_ VARCHAR, population__2002_ VARCHAR) |
SELECT position FROM table_name_95 WHERE round = 7 AND college = "oklahoma" | What position does the player from Oklahoma who was drafted in round 7 play? | CREATE TABLE table_name_95 (position VARCHAR, round VARCHAR, college VARCHAR) |
SELECT questao.Id AS "post_link", questao.Score, questao.ViewCount, comentario.Id, comentario.Score AS socre_comentario, comentario.ViewCount AS views_comentario FROM Posts AS questao JOIN Posts AS comentario ON questao.Id = comentario.ParentId WHERE questao.Tags LIKE '%<android%' AND questao.ParentId IS NULL ORDER BY questao.ViewCount LIMIT 100 | Low views, high votes yet unanswered. A list of questions with a high score and low view count | CREATE TABLE ReviewTaskTypes (
Id number,
Name text,
Description text
)
CREATE TABLE Votes (
Id number,
PostId number,
VoteTypeId number,
UserId number,
CreationDate time,
BountyAmount number
)
CREATE TABLE PostTags (
PostId number,
TagId number
)
CREATE TABLE ReviewTaskStates (
Id number,
Name text,
Description text
)
CREATE TABLE CloseReasonTypes (
Id number,
Name text,
Description text
)
CREATE TABLE Badges (
Id number,
UserId number,
Name text,
Date time,
Class number,
TagBased boolean
)
CREATE TABLE PostNoticeTypes (
Id number,
ClassId number,
Name text,
Body text,
IsHidden boolean,
Predefined boolean,
PostNoticeDurationId number
)
CREATE TABLE VoteTypes (
Id number,
Name text
)
CREATE TABLE PostHistoryTypes (
Id number,
Name text
)
CREATE TABLE Posts (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
ViewCount number,
Body text,
OwnerUserId number,
OwnerDisplayName text,
LastEditorUserId number,
LastEditorDisplayName text,
LastEditDate time,
LastActivityDate time,
Title text,
Tags text,
AnswerCount number,
CommentCount number,
FavoriteCount number,
ClosedDate time,
CommunityOwnedDate time,
ContentLicense text
)
CREATE TABLE ReviewTasks (
Id number,
ReviewTaskTypeId number,
CreationDate time,
DeletionDate time,
ReviewTaskStateId number,
PostId number,
SuggestedEditId number,
CompletedByReviewTaskId number
)
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 ReviewTaskResults (
Id number,
ReviewTaskId number,
ReviewTaskResultTypeId number,
CreationDate time,
RejectionReasonId number,
Comment text
)
CREATE TABLE Users (
Id number,
Reputation number,
CreationDate time,
DisplayName text,
LastAccessDate time,
WebsiteUrl text,
Location text,
AboutMe text,
Views number,
UpVotes number,
DownVotes number,
ProfileImageUrl text,
EmailHash text,
AccountId number
)
CREATE TABLE Comments (
Id number,
PostId number,
Score number,
Text text,
CreationDate time,
UserDisplayName text,
UserId number,
ContentLicense text
)
CREATE TABLE PostsWithDeleted (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
ViewCount number,
Body text,
OwnerUserId number,
OwnerDisplayName text,
LastEditorUserId number,
LastEditorDisplayName text,
LastEditDate time,
LastActivityDate time,
Title text,
Tags text,
AnswerCount number,
CommentCount number,
FavoriteCount number,
ClosedDate time,
CommunityOwnedDate time,
ContentLicense text
)
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 PostHistory (
Id number,
PostHistoryTypeId number,
PostId number,
RevisionGUID other,
CreationDate time,
UserId number,
UserDisplayName text,
Comment text,
Text text,
ContentLicense text
)
CREATE TABLE PostFeedback (
Id number,
PostId number,
IsAnonymous boolean,
VoteTypeId number,
CreationDate time
)
CREATE TABLE Tags (
Id number,
TagName text,
Count number,
ExcerptPostId number,
WikiPostId number
)
CREATE TABLE PendingFlags (
Id number,
FlagTypeId number,
PostId number,
CreationDate time,
CloseReasonTypeId number,
CloseAsOffTopicReasonTypeId number,
DuplicateOfQuestionId number,
BelongsOnBaseHostAddress text
)
CREATE TABLE PostTypes (
Id number,
Name text
)
CREATE TABLE ReviewRejectionReasons (
Id number,
Name text,
Description text,
PostTypeId number
)
CREATE TABLE CloseAsOffTopicReasonTypes (
Id number,
IsUniversal boolean,
InputTitle text,
MarkdownInputGuidance text,
MarkdownPostOwnerGuidance text,
MarkdownPrivilegedUserGuidance text,
MarkdownConcensusDescription text,
CreationDate time,
CreationModeratorId number,
ApprovalDate time,
ApprovalModeratorId number,
DeactivationDate time,
DeactivationModeratorId number
)
CREATE TABLE SuggestedEditVotes (
Id number,
SuggestedEditId number,
UserId number,
VoteTypeId number,
CreationDate time,
TargetUserId number,
TargetRepChange number
)
CREATE TABLE PostNotices (
Id number,
PostId number,
PostNoticeTypeId number,
CreationDate time,
DeletionDate time,
ExpiryDate time,
Body text,
OwnerUserId number,
DeletionUserId number
)
CREATE TABLE ReviewTaskResultTypes (
Id number,
Name text,
Description text
)
CREATE TABLE FlagTypes (
Id number,
Name text,
Description text
)
CREATE TABLE PostLinks (
Id number,
CreationDate time,
PostId number,
RelatedPostId number,
LinkTypeId number
) |
SELECT COUNT(city___municipality) FROM table_2562572_2 WHERE urban_settlement = "Srbobran" | What is the number of cities/municipalities having an urban settlement of Srbobran? | CREATE TABLE table_2562572_2 (city___municipality VARCHAR, urban_settlement VARCHAR) |
SELECT MAX(overall) FROM table_name_36 WHERE college = "kentucky state" | What is the highest overall number for a player from Kentucky State? | CREATE TABLE table_name_36 (overall INTEGER, college VARCHAR) |
SELECT "Venue" FROM table_56514 WHERE "Home team" = 'essendon' | If essendon is the home team, what venue did they play at? | CREATE TABLE table_56514 (
"Home team" text,
"Home team score" text,
"Away team" text,
"Away team score" text,
"Venue" text,
"Crowd" real,
"Date" text
) |
SELECT settlement FROM table_2562572_25 WHERE type = "town" | When town is the type what is the settlement? | CREATE TABLE table_2562572_25 (settlement VARCHAR, type VARCHAR) |
SELECT COUNT(round) FROM table_name_25 WHERE position = "defensive tackle" AND overall < 149 | In what round was a defensive tackle drafted with an overall pick smaller than 149? | CREATE TABLE table_name_25 (round VARCHAR, position VARCHAR, overall VARCHAR) |
SELECT "Status" FROM table_6915 WHERE "Unit" = 'daohugou beds' | Which Status has a Unit of daohugou beds? | CREATE TABLE table_6915 (
"Name" text,
"Novelty" text,
"Status" text,
"Authors" text,
"Unit" text,
"Location" text
) |
SELECT type FROM table_2562572_25 WHERE cyrillic_name_other_names = "Оџаци" | When оџаци is the cyrillic name other names what is the type? | CREATE TABLE table_2562572_25 (type VARCHAR, cyrillic_name_other_names VARCHAR) |
SELECT COUNT(crowd) FROM table_name_99 WHERE away_team = "north melbourne" | How many attended the game with north melbourne as the away side? | CREATE TABLE table_name_99 (crowd VARCHAR, away_team VARCHAR) |
SELECT Id AS "post_link", Body FROM Posts WHERE Body LIKE '%http://bit.ly%' | Posts containing bit.ly shortened URLs. Posts containing bit.ly shortened URLs, which allow for tracking clicks :-(
See http://meta.stackoverflow.com/questions/29518/can-and-should-stack-overflow-automatically-rewrite-bit-ly-links
See http://stackapps.com/questions/121/what-ideas-do-you-have-for-the-api/546#546 | CREATE TABLE Users (
Id number,
Reputation number,
CreationDate time,
DisplayName text,
LastAccessDate time,
WebsiteUrl text,
Location text,
AboutMe text,
Views number,
UpVotes number,
DownVotes number,
ProfileImageUrl text,
EmailHash text,
AccountId number
)
CREATE TABLE PostTypes (
Id number,
Name text
)
CREATE TABLE Tags (
Id number,
TagName text,
Count number,
ExcerptPostId number,
WikiPostId number
)
CREATE TABLE ReviewTaskResultTypes (
Id number,
Name text,
Description text
)
CREATE TABLE CloseAsOffTopicReasonTypes (
Id number,
IsUniversal boolean,
InputTitle text,
MarkdownInputGuidance text,
MarkdownPostOwnerGuidance text,
MarkdownPrivilegedUserGuidance text,
MarkdownConcensusDescription text,
CreationDate time,
CreationModeratorId number,
ApprovalDate time,
ApprovalModeratorId number,
DeactivationDate time,
DeactivationModeratorId number
)
CREATE TABLE PostsWithDeleted (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
ViewCount number,
Body text,
OwnerUserId number,
OwnerDisplayName text,
LastEditorUserId number,
LastEditorDisplayName text,
LastEditDate time,
LastActivityDate time,
Title text,
Tags text,
AnswerCount number,
CommentCount number,
FavoriteCount number,
ClosedDate time,
CommunityOwnedDate time,
ContentLicense text
)
CREATE TABLE ReviewTaskTypes (
Id number,
Name text,
Description text
)
CREATE TABLE PostHistoryTypes (
Id number,
Name text
)
CREATE TABLE PendingFlags (
Id number,
FlagTypeId number,
PostId number,
CreationDate time,
CloseReasonTypeId number,
CloseAsOffTopicReasonTypeId number,
DuplicateOfQuestionId number,
BelongsOnBaseHostAddress text
)
CREATE TABLE Votes (
Id number,
PostId number,
VoteTypeId number,
UserId number,
CreationDate time,
BountyAmount number
)
CREATE TABLE ReviewTasks (
Id number,
ReviewTaskTypeId number,
CreationDate time,
DeletionDate time,
ReviewTaskStateId number,
PostId number,
SuggestedEditId number,
CompletedByReviewTaskId number
)
CREATE TABLE SuggestedEditVotes (
Id number,
SuggestedEditId number,
UserId number,
VoteTypeId number,
CreationDate time,
TargetUserId number,
TargetRepChange number
)
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 ReviewRejectionReasons (
Id number,
Name text,
Description text,
PostTypeId number
)
CREATE TABLE ReviewTaskStates (
Id number,
Name text,
Description text
)
CREATE TABLE PostFeedback (
Id number,
PostId number,
IsAnonymous boolean,
VoteTypeId number,
CreationDate time
)
CREATE TABLE PostNotices (
Id number,
PostId number,
PostNoticeTypeId number,
CreationDate time,
DeletionDate time,
ExpiryDate time,
Body text,
OwnerUserId number,
DeletionUserId number
)
CREATE TABLE Badges (
Id number,
UserId number,
Name text,
Date time,
Class number,
TagBased boolean
)
CREATE TABLE PostLinks (
Id number,
CreationDate time,
PostId number,
RelatedPostId number,
LinkTypeId number
)
CREATE TABLE CloseReasonTypes (
Id number,
Name text,
Description text
)
CREATE TABLE Comments (
Id number,
PostId number,
Score number,
Text text,
CreationDate time,
UserDisplayName text,
UserId number,
ContentLicense text
)
CREATE TABLE Posts (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
ViewCount number,
Body text,
OwnerUserId number,
OwnerDisplayName text,
LastEditorUserId number,
LastEditorDisplayName text,
LastEditDate time,
LastActivityDate time,
Title text,
Tags text,
AnswerCount number,
CommentCount number,
FavoriteCount number,
ClosedDate time,
CommunityOwnedDate time,
ContentLicense text
)
CREATE TABLE PostNoticeTypes (
Id number,
ClassId number,
Name text,
Body text,
IsHidden boolean,
Predefined boolean,
PostNoticeDurationId number
)
CREATE TABLE PostHistory (
Id number,
PostHistoryTypeId number,
PostId number,
RevisionGUID other,
CreationDate time,
UserId number,
UserDisplayName text,
Comment text,
Text text,
ContentLicense text
)
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 FlagTypes (
Id number,
Name text,
Description text
)
CREATE TABLE VoteTypes (
Id number,
Name text
)
CREATE TABLE PostTags (
PostId number,
TagId number
)
CREATE TABLE ReviewTaskResults (
Id number,
ReviewTaskId number,
ReviewTaskResultTypeId number,
CreationDate time,
RejectionReasonId number,
Comment text
) |
SELECT cyrillic_name_other_names FROM table_2562572_25 WHERE settlement = "Ratkovo" | When ratkovo is the settlement what is the cyrllic name other names? | CREATE TABLE table_2562572_25 (cyrillic_name_other_names VARCHAR, settlement VARCHAR) |
SELECT venue FROM table_name_27 WHERE away_team = "north melbourne" | What venue featured north melbourne as the away side? | CREATE TABLE table_name_27 (venue VARCHAR, away_team VARCHAR) |
SELECT "Wednesday" FROM table_17166 WHERE "Series" = 'Big Brother 13' | Who is the Wednesday presenter of the show Big Brother 13? | CREATE TABLE table_17166 (
"Series" text,
"Monday" text,
"Tuesday" text,
"Wednesday" text,
"Thursday" text,
"Friday" text,
"Saturday" text,
"Sunday" text
) |
SELECT settlement FROM table_2562572_25 WHERE dominant_religion__2002_ = "Orthodox Christianity" AND type = "village" AND cyrillic_name_other_names = "Ратково" | When ратково is cyrillic name other names and village is the type and orthodox Christianity is the dominant religion of 2002 what is the settlement? | CREATE TABLE table_2562572_25 (settlement VARCHAR, cyrillic_name_other_names VARCHAR, dominant_religion__2002_ VARCHAR, type VARCHAR) |
SELECT crowd FROM table_name_58 WHERE away_team = "melbourne" | How many attended the game with north melbourne as the away side? | CREATE TABLE table_name_58 (crowd VARCHAR, away_team VARCHAR) |
SELECT right_ascension___j2000__ FROM table_name_2 WHERE object_type = "globular cluster" AND apparent_magnitude = 8.5 AND ngc_number = 6273 | Tell me the right ascensuon for object type of globular cluster and apparent magnitude of 8.5 and NGC number of 6273 | CREATE TABLE table_name_2 (
right_ascension___j2000__ VARCHAR,
ngc_number VARCHAR,
object_type VARCHAR,
apparent_magnitude VARCHAR
) |
SELECT largest_ethnic_group__2002_ FROM table_2562572_25 WHERE cyrillic_name_other_names = "Дероње" | When дероње is the cyrillic name other names what is the largest ethnic group of 2002? | CREATE TABLE table_2562572_25 (largest_ethnic_group__2002_ VARCHAR, cyrillic_name_other_names VARCHAR) |
SELECT elite_eight FROM table_name_47 WHERE conference = "atlantic 10" | How many teams from the Atlantic 10 conference made it to the Elite Eight? | CREATE TABLE table_name_47 (elite_eight VARCHAR, conference VARCHAR) |
SELECT competition FROM table_name_47 WHERE date = "17/9/00" | Which competition was on 17/9/00? | CREATE TABLE table_name_47 (
competition VARCHAR,
date VARCHAR
) |
SELECT largest_ethnic_group__2002_ FROM table_2562572_27 WHERE settlement = "Gunaroš" | What are the largest ethnic groups in gunaroš? | CREATE TABLE table_2562572_27 (largest_ethnic_group__2002_ VARCHAR, settlement VARCHAR) |
SELECT final_four FROM table_name_1 WHERE conference = "big 12" | How many Big 12 teams made it to the Final Four? | CREATE TABLE table_name_1 (final_four VARCHAR, conference VARCHAR) |
SELECT COUNT(*) > 0 FROM intakeoutput WHERE intakeoutput.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '022-6959')) AND intakeoutput.cellpath LIKE '%output%' AND intakeoutput.celllabel = 'urine' AND DATETIME(intakeoutput.intakeoutputtime, 'start of month') = DATETIME(CURRENT_TIME(), 'start of month', '-0 month') | had patient 022-6959 excreted any urine in this month? | CREATE TABLE intakeoutput (
intakeoutputid number,
patientunitstayid number,
cellpath text,
celllabel text,
cellvaluenumeric number,
intakeoutputtime time
)
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 lab (
labid number,
patientunitstayid number,
labname text,
labresult number,
labresulttime time
)
CREATE TABLE microlab (
microlabid number,
patientunitstayid number,
culturesite text,
organism text,
culturetakentime time
)
CREATE TABLE cost (
costid number,
uniquepid text,
patienthealthsystemstayid number,
eventtype text,
eventid number,
chargetime time,
cost number
)
CREATE TABLE diagnosis (
diagnosisid number,
patientunitstayid number,
diagnosisname text,
diagnosistime time,
icd9code text
)
CREATE TABLE allergy (
allergyid number,
patientunitstayid number,
drugname text,
allergyname text,
allergytime time
)
CREATE TABLE medication (
medicationid number,
patientunitstayid number,
drugname text,
dosage text,
routeadmin text,
drugstarttime time,
drugstoptime time
)
CREATE TABLE treatment (
treatmentid number,
patientunitstayid number,
treatmentname text,
treatmenttime time
)
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,
hospitaladmitsource text,
unitadmittime time,
unitdischargetime time,
hospitaldischargetime time,
hospitaldischargestatus text
) |
SELECT largest_ethnic_group__2002_ FROM table_2562572_27 WHERE cyrillic_name_other_names = "Пачир (Hungarian: Pacsér)" | What are the largest ethnic groups where the cyrillic name and other names is пачир (hungarian: pacsér)? | CREATE TABLE table_2562572_27 (largest_ethnic_group__2002_ VARCHAR, cyrillic_name_other_names VARCHAR) |
SELECT chassis FROM table_name_73 WHERE engine = "cosworth" AND drivers = "gordon johncock" | What chassis did Gordon Johncock use with his cosworth engine? | CREATE TABLE table_name_73 (chassis VARCHAR, engine VARCHAR, drivers VARCHAR) |
SELECT HIRE_DATE, EMPLOYEE_ID FROM employees WHERE NOT DEPARTMENT_ID IN (SELECT DEPARTMENT_ID FROM departments WHERE MANAGER_ID BETWEEN 100 AND 200) ORDER BY HIRE_DATE DESC | For those employees who do not work in departments with managers that have ids between 100 and 200, give me the trend about employee_id over hire_date , show X in descending order. | CREATE TABLE departments (
DEPARTMENT_ID decimal(4,0),
DEPARTMENT_NAME varchar(30),
MANAGER_ID decimal(6,0),
LOCATION_ID decimal(4,0)
)
CREATE TABLE locations (
LOCATION_ID decimal(4,0),
STREET_ADDRESS varchar(40),
POSTAL_CODE varchar(12),
CITY varchar(30),
STATE_PROVINCE varchar(25),
COUNTRY_ID varchar(2)
)
CREATE TABLE job_history (
EMPLOYEE_ID decimal(6,0),
START_DATE date,
END_DATE date,
JOB_ID varchar(10),
DEPARTMENT_ID decimal(4,0)
)
CREATE TABLE jobs (
JOB_ID varchar(10),
JOB_TITLE varchar(35),
MIN_SALARY decimal(6,0),
MAX_SALARY decimal(6,0)
)
CREATE TABLE countries (
COUNTRY_ID varchar(2),
COUNTRY_NAME varchar(40),
REGION_ID decimal(10,0)
)
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),
COMMISSION_PCT decimal(2,2),
MANAGER_ID decimal(6,0),
DEPARTMENT_ID decimal(4,0)
) |
SELECT COUNT(settlement) FROM table_2562572_27 WHERE cyrillic_name_other_names = "Његошево" | How many places have as their cyrillic name and other names његошево? | CREATE TABLE table_2562572_27 (settlement VARCHAR, cyrillic_name_other_names VARCHAR) |
SELECT drivers FROM table_name_21 WHERE engine = "chevrolet" AND chassis = "eagle" | Who drove the Chevrolet with the Eagle chassis? | CREATE TABLE table_name_21 (drivers VARCHAR, engine VARCHAR, chassis VARCHAR) |
SELECT catalog FROM table_name_59 WHERE region = "japan" | What is the Catalog Number is for the Japan region? | CREATE TABLE table_name_59 (
catalog VARCHAR,
region VARCHAR
) |
SELECT dominant_religion__2002_ FROM table_2562572_27 WHERE population__2011_ = "83" | What are the dominant religions in the place with a population of 83? | CREATE TABLE table_2562572_27 (dominant_religion__2002_ VARCHAR, population__2011_ VARCHAR) |
SELECT tires FROM table_name_15 WHERE engine = "offy" AND chassis = "manta" AND team = "bfm enterprises" | What tires did BFM Enterprises run on their Offy engine and manta chassis? | CREATE TABLE table_name_15 (tires VARCHAR, team VARCHAR, engine VARCHAR, chassis VARCHAR) |
SELECT "SZDSZ" FROM table_35704 WHERE "MSZP" = '25%' AND "Date" = '25/2/2009' | What is the SZDSZ percentage with an MSZP of 25% on 25/2/2009? | CREATE TABLE table_35704 (
"Source" text,
"Date" text,
"Fidesz" text,
"MSZP" text,
"SZDSZ" text,
"Jobbik" text,
"others" text
) |
SELECT settlement FROM table_2562572_27 WHERE cyrillic_name_other_names = "Панонија" | How many settlements have as their cyrillic name and other names панонија? | CREATE TABLE table_2562572_27 (settlement VARCHAR, cyrillic_name_other_names VARCHAR) |
SELECT chassis FROM table_name_13 WHERE drivers = "gary bettenhausen" | What chassis does Gary Bettenhausen use? | CREATE TABLE table_name_13 (chassis VARCHAR, drivers VARCHAR) |
SELECT set_2 FROM table_name_45 WHERE date = "25 may" AND set_3 = "21–25" | Which Set 2 has a Date of 25 may, and a Set 3 of 21 25? | CREATE TABLE table_name_45 (
set_2 VARCHAR,
date VARCHAR,
set_3 VARCHAR
) |
SELECT cyrillic_name_other_names FROM table_2562572_33 WHERE settlement = "Martonoš" | What is the other name for martonoš? | CREATE TABLE table_2562572_33 (cyrillic_name_other_names VARCHAR, settlement VARCHAR) |
SELECT chassis FROM table_name_51 WHERE drivers = "ross davis" | What chassis doe Ross Davis use? | CREATE TABLE table_name_51 (chassis VARCHAR, drivers VARCHAR) |
SELECT T2.roomName, COUNT(*), T1.Room FROM Reservations AS T1 JOIN Rooms AS T2 ON T1.Room = T2.RoomId GROUP BY T1.Room | Return the name and number of reservations made for each of the rooms. | CREATE TABLE Rooms (
roomName VARCHAR,
RoomId VARCHAR
)
CREATE TABLE Reservations (
Room VARCHAR
) |
SELECT type FROM table_2562572_33 WHERE cyrillic_name_other_names = "Ором (Hungarian: Orom)" | What type of settlement is ором (hungarian: orom)? | CREATE TABLE table_2562572_33 (type VARCHAR, cyrillic_name_other_names VARCHAR) |
SELECT engine FROM table_name_36 WHERE team = "parts washer service" AND drivers = "chip mead" | What engine does Chip Mead of Parts Washer Service use? | CREATE TABLE table_name_36 (engine VARCHAR, team VARCHAR, drivers VARCHAR) |
WITH USER_BY_TAG AS (SELECT ROW_NUMBER() OVER (ORDER BY COUNT(*) DESC) AS Rank, u.Id AS "user_link", COUNT(*) AS UpVotes FROM Tags AS t INNER JOIN PostTags AS pt ON pt.TagId = t.Id INNER JOIN Posts AS p ON p.ParentId = pt.PostId INNER JOIN Votes AS v ON v.PostId = p.Id AND VoteTypeId = 2 INNER JOIN Users AS u ON u.Id = p.OwnerUserId WHERE LOWER(Location) LIKE ('%turkey%') OR LOWER(Location) LIKE ('%istanbul%') OR LOWER(Location) LIKE ('%ankara%') OR LOWER(Location) LIKE ('%izmir%') AND TagName = 'android' GROUP BY u.Id, TagName) SELECT * FROM USER_BY_TAG WHERE rank <= 1000 ORDER BY UpVotes DESC | Top 100 android users from Pakistan. | CREATE TABLE ReviewTaskTypes (
Id number,
Name text,
Description text
)
CREATE TABLE PendingFlags (
Id number,
FlagTypeId number,
PostId number,
CreationDate time,
CloseReasonTypeId number,
CloseAsOffTopicReasonTypeId number,
DuplicateOfQuestionId number,
BelongsOnBaseHostAddress text
)
CREATE TABLE PostFeedback (
Id number,
PostId number,
IsAnonymous boolean,
VoteTypeId number,
CreationDate time
)
CREATE TABLE PostNotices (
Id number,
PostId number,
PostNoticeTypeId number,
CreationDate time,
DeletionDate time,
ExpiryDate time,
Body text,
OwnerUserId number,
DeletionUserId number
)
CREATE TABLE PostHistory (
Id number,
PostHistoryTypeId number,
PostId number,
RevisionGUID other,
CreationDate time,
UserId number,
UserDisplayName text,
Comment text,
Text text,
ContentLicense text
)
CREATE TABLE PostTags (
PostId number,
TagId number
)
CREATE TABLE SuggestedEditVotes (
Id number,
SuggestedEditId number,
UserId number,
VoteTypeId number,
CreationDate time,
TargetUserId number,
TargetRepChange number
)
CREATE TABLE ReviewTaskResultTypes (
Id number,
Name text,
Description text
)
CREATE TABLE VoteTypes (
Id number,
Name text
)
CREATE TABLE ReviewTasks (
Id number,
ReviewTaskTypeId number,
CreationDate time,
DeletionDate time,
ReviewTaskStateId number,
PostId number,
SuggestedEditId number,
CompletedByReviewTaskId number
)
CREATE TABLE ReviewTaskResults (
Id number,
ReviewTaskId number,
ReviewTaskResultTypeId number,
CreationDate time,
RejectionReasonId number,
Comment text
)
CREATE TABLE Posts (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
ViewCount number,
Body text,
OwnerUserId number,
OwnerDisplayName text,
LastEditorUserId number,
LastEditorDisplayName text,
LastEditDate time,
LastActivityDate time,
Title text,
Tags text,
AnswerCount number,
CommentCount number,
FavoriteCount number,
ClosedDate time,
CommunityOwnedDate time,
ContentLicense text
)
CREATE TABLE CloseAsOffTopicReasonTypes (
Id number,
IsUniversal boolean,
InputTitle text,
MarkdownInputGuidance text,
MarkdownPostOwnerGuidance text,
MarkdownPrivilegedUserGuidance text,
MarkdownConcensusDescription text,
CreationDate time,
CreationModeratorId number,
ApprovalDate time,
ApprovalModeratorId number,
DeactivationDate time,
DeactivationModeratorId number
)
CREATE TABLE Badges (
Id number,
UserId number,
Name text,
Date time,
Class number,
TagBased boolean
)
CREATE TABLE Users (
Id number,
Reputation number,
CreationDate time,
DisplayName text,
LastAccessDate time,
WebsiteUrl text,
Location text,
AboutMe text,
Views number,
UpVotes number,
DownVotes number,
ProfileImageUrl text,
EmailHash text,
AccountId number
)
CREATE TABLE PostLinks (
Id number,
CreationDate time,
PostId number,
RelatedPostId number,
LinkTypeId number
)
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 Comments (
Id number,
PostId number,
Score number,
Text text,
CreationDate time,
UserDisplayName text,
UserId number,
ContentLicense text
)
CREATE TABLE CloseReasonTypes (
Id number,
Name text,
Description text
)
CREATE TABLE PostNoticeTypes (
Id number,
ClassId number,
Name text,
Body text,
IsHidden boolean,
Predefined boolean,
PostNoticeDurationId number
)
CREATE TABLE Tags (
Id number,
TagName text,
Count number,
ExcerptPostId number,
WikiPostId number
)
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 ReviewRejectionReasons (
Id number,
Name text,
Description text,
PostTypeId number
)
CREATE TABLE Votes (
Id number,
PostId number,
VoteTypeId number,
UserId number,
CreationDate time,
BountyAmount number
)
CREATE TABLE FlagTypes (
Id number,
Name text,
Description text
)
CREATE TABLE PostTypes (
Id number,
Name text
)
CREATE TABLE PostsWithDeleted (
Id number,
PostTypeId number,
AcceptedAnswerId number,
ParentId number,
CreationDate time,
DeletionDate time,
Score number,
ViewCount number,
Body text,
OwnerUserId number,
OwnerDisplayName text,
LastEditorUserId number,
LastEditorDisplayName text,
LastEditDate time,
LastActivityDate time,
Title text,
Tags text,
AnswerCount number,
CommentCount number,
FavoriteCount number,
ClosedDate time,
CommunityOwnedDate time,
ContentLicense text
)
CREATE TABLE PostHistoryTypes (
Id number,
Name text
)
CREATE TABLE ReviewTaskStates (
Id number,
Name text,
Description text
) |
SELECT settlement FROM table_2562572_33 WHERE cyrillic_name_other_names = "Мартонош (Hungarian: Martonos)" | What settlement is also called мартонош (hungarian: martonos)? | CREATE TABLE table_2562572_33 (settlement VARCHAR, cyrillic_name_other_names VARCHAR) |
SELECT heat__lane_ FROM table_name_75 WHERE rank = 22 | Which heat and lane was in rank of 22? | CREATE TABLE table_name_75 (heat__lane_ VARCHAR, rank VARCHAR) |
SELECT DISTINCT course.department, course.name, course.number FROM course, course_offering, program_course, semester WHERE course_offering.friday = 'N' AND course.course_id = course_offering.course_id AND program_course.category LIKE '%ULCS%' AND program_course.course_id = course.course_id AND semester.semester = 'FA' AND semester.semester_id = course_offering.semester AND semester.year = 2016 | Next semester , which upper level elective classes only meet Monday , Tuesday , Wednesday and / or Thursday ? | CREATE TABLE program_requirement (
program_id int,
category varchar,
min_credit int,
additional_req varchar
)
CREATE TABLE student (
student_id int,
lastname varchar,
firstname varchar,
program_id int,
declare_major varchar,
total_credit int,
total_gpa float,
entered_as varchar,
admit_term int,
predicted_graduation_semester int,
degree varchar,
minor varchar,
internship varchar
)
CREATE TABLE program (
program_id int,
name varchar,
college varchar,
introduction varchar
)
CREATE TABLE student_record (
student_id int,
course_id int,
semester int,
grade varchar,
how varchar,
transfer_source varchar,
earn_credit varchar,
repeat_term varchar,
test_id varchar
)
CREATE TABLE course_tags_count (
course_id int,
clear_grading int,
pop_quiz int,
group_projects int,
inspirational int,
long_lectures int,
extra_credit int,
few_tests int,
good_feedback int,
tough_tests int,
heavy_papers int,
cares_for_students int,
heavy_assignments int,
respected int,
participation int,
heavy_reading int,
tough_grader int,
hilarious int,
would_take_again int,
good_lecture int,
no_skip int
)
CREATE TABLE offering_instructor (
offering_instructor_id int,
offering_id int,
instructor_id int
)
CREATE TABLE ta (
campus_job_id int,
student_id int,
location varchar
)
CREATE TABLE program_course (
program_id int,
course_id int,
workload int,
category varchar
)
CREATE TABLE gsi (
course_offering_id int,
student_id int
)
CREATE TABLE course_prerequisite (
pre_course_id int,
course_id int
)
CREATE TABLE instructor (
instructor_id int,
name varchar,
uniqname varchar
)
CREATE TABLE semester (
semester_id int,
semester varchar,
year int
)
CREATE TABLE area (
course_id int,
area varchar
)
CREATE TABLE comment_instructor (
instructor_id int,
student_id int,
score int,
comment_text varchar
)
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_projects varchar,
has_exams varchar,
num_reviews int,
clarity_score int,
easiness_score int,
helpfulness_score int
)
CREATE TABLE course_offering (
offering_id int,
course_id int,
semester int,
section_number int,
start_time time,
end_time time,
monday varchar,
tuesday varchar,
wednesday varchar,
thursday varchar,
friday varchar,
saturday varchar,
sunday varchar,
has_final_project varchar,
has_final_exam varchar,
textbook varchar,
class_address varchar,
allow_audit varchar
)
CREATE TABLE jobs (
job_id int,
job_title varchar,
description varchar,
requirement varchar,
city varchar,
state varchar,
country varchar,
zip int
)
CREATE TABLE requirement (
requirement_id int,
requirement varchar,
college varchar
) |
SELECT largest_ethnic_group__2002_ FROM table_2562572_33 WHERE cyrillic_name_other_names = "Мале Пијаце (Hungarian: Kispiac)" | What is the largest ethnic group in мале пијаце (hungarian: kispiac)? | CREATE TABLE table_2562572_33 (largest_ethnic_group__2002_ VARCHAR, cyrillic_name_other_names VARCHAR) |
SELECT name FROM table_name_32 WHERE rank < 125 AND time = "00: 56.30" | Who has a rank below 125 and time of 00: 56.30? | CREATE TABLE table_name_32 (name VARCHAR, rank VARCHAR, time VARCHAR) |
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id WHERE demographic.insurance = "Government" AND diagnoses.icd9_code = "78720" | give me the number of patients whose insurance is government and diagnoses icd9 code is 78720? | 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,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear 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 (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
)
CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
) |
SELECT largest_ethnic_group__2002_ FROM table_2562572_33 WHERE settlement = "Doline" | What is the largest ethnic group in doline? | CREATE TABLE table_2562572_33 (largest_ethnic_group__2002_ VARCHAR, settlement VARCHAR) |
SELECT terminus FROM table_name_1 WHERE line = "line 10" | Which Terminus is on line 10? | CREATE TABLE table_name_1 (terminus VARCHAR, line VARCHAR) |
SELECT last_name, COUNT(last_name) FROM Staff AS T1 JOIN Engineer_Visits AS T2 ON T1.staff_id = T2.contact_staff_id JOIN Maintenance_Engineers AS T3 ON T2.engineer_id = T3.engineer_id GROUP BY last_name ORDER BY last_name | How many staffs have contacted with each engineer? Give me a bar chart grouping by each engineer's last name, display in asc by the x-axis. | CREATE TABLE Fault_Log (
fault_log_entry_id INTEGER,
asset_id INTEGER,
recorded_by_staff_id INTEGER,
fault_log_entry_datetime DATETIME,
fault_description VARCHAR(255),
other_fault_details VARCHAR(255)
)
CREATE TABLE Skills_Required_To_Fix (
part_fault_id INTEGER,
skill_id INTEGER
)
CREATE TABLE Staff (
staff_id INTEGER,
staff_name VARCHAR(255),
gender VARCHAR(1),
other_staff_details VARCHAR(255)
)
CREATE TABLE Fault_Log_Parts (
fault_log_entry_id INTEGER,
part_fault_id INTEGER,
fault_status VARCHAR(10)
)
CREATE TABLE Maintenance_Contracts (
maintenance_contract_id INTEGER,
maintenance_contract_company_id INTEGER,
contract_start_date DATETIME,
contract_end_date DATETIME,
other_contract_details VARCHAR(255)
)
CREATE TABLE Skills (
skill_id INTEGER,
skill_code VARCHAR(20),
skill_description VARCHAR(255)
)
CREATE TABLE Engineer_Skills (
engineer_id INTEGER,
skill_id INTEGER
)
CREATE TABLE Maintenance_Engineers (
engineer_id INTEGER,
company_id INTEGER,
first_name VARCHAR(50),
last_name VARCHAR(50),
other_details VARCHAR(255)
)
CREATE TABLE Part_Faults (
part_fault_id INTEGER,
part_id INTEGER,
fault_short_name VARCHAR(20),
fault_description VARCHAR(255),
other_fault_details VARCHAR(255)
)
CREATE TABLE Parts (
part_id INTEGER,
part_name VARCHAR(255),
chargeable_yn VARCHAR(1),
chargeable_amount VARCHAR(20),
other_part_details VARCHAR(255)
)
CREATE TABLE Assets (
asset_id INTEGER,
maintenance_contract_id INTEGER,
supplier_company_id INTEGER,
asset_details VARCHAR(255),
asset_make VARCHAR(20),
asset_model VARCHAR(20),
asset_acquired_date DATETIME,
asset_disposed_date DATETIME,
other_asset_details VARCHAR(255)
)
CREATE TABLE Third_Party_Companies (
company_id INTEGER,
company_type VARCHAR(5),
company_name VARCHAR(255),
company_address VARCHAR(255),
other_company_details VARCHAR(255)
)
CREATE TABLE Engineer_Visits (
engineer_visit_id INTEGER,
contact_staff_id INTEGER,
engineer_id INTEGER,
fault_log_entry_id INTEGER,
fault_status VARCHAR(10),
visit_start_datetime DATETIME,
visit_end_datetime DATETIME,
other_visit_details VARCHAR(255)
)
CREATE TABLE Asset_Parts (
asset_id INTEGER,
part_id INTEGER
) |
SELECT dominant_religion__2002_ FROM table_2562572_37 WHERE settlement = "Srpska Crnja" | Name the dominant religion of srpska crnja | CREATE TABLE table_2562572_37 (dominant_religion__2002_ VARCHAR, settlement VARCHAR) |
SELECT terminus FROM table_name_46 WHERE color = "diamond" | The color diamond is assigned to which Terminus? | CREATE TABLE table_name_46 (terminus VARCHAR, color VARCHAR) |
SELECT "Airport" FROM table_49753 WHERE "IATA" = 'tbj' | What is the airport when the iata is tbj? | CREATE TABLE table_49753 (
"City" text,
"Country" text,
"IATA" text,
"ICAO" text,
"Airport" text
) |
SELECT settlement FROM table_2562572_37 WHERE cyrillic_name_other_names = "Александрово" | Name the settlement for александрово | CREATE TABLE table_2562572_37 (settlement VARCHAR, cyrillic_name_other_names VARCHAR) |
SELECT length FROM table_name_89 WHERE stations = "16" | Stations of 16 is assigned what length? | CREATE TABLE table_name_89 (length VARCHAR, stations VARCHAR) |
SELECT "Party" FROM table_18534 WHERE "Incumbent" = 'Overton Brooks' | What is the party where the incumbent is overton brooks? | CREATE TABLE table_18534 (
"District" text,
"Incumbent" text,
"Party" text,
"First elected" real,
"Result" text,
"Candidates" text
) |
SELECT cyrillic_name_other_names FROM table_2562572_37 WHERE population__2011_ = 518 | Name the cyrillic name for 518 | CREATE TABLE table_2562572_37 (cyrillic_name_other_names VARCHAR, population__2011_ VARCHAR) |
SELECT terminus FROM table_name_4 WHERE color = "sapphire" | The color sapphire is assigned to which Terminus? | CREATE TABLE table_name_4 (terminus VARCHAR, color VARCHAR) |
SELECT DISTINCT flight.departure_time 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 = 'ATLANTA' AND CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'BOSTON' AND flight.from_airport = AIRPORT_SERVICE_0.airport_code AND flight.to_airport = AIRPORT_SERVICE_1.airport_code) AND flight.departure_time BETWEEN 1200 AND 1800 | can you tell me the time a flight would leave from ATLANTA to BOSTON in the afternoon | CREATE TABLE dual_carrier (
main_airline varchar,
low_flight_number int,
high_flight_number int,
dual_airline varchar,
service_name text
)
CREATE TABLE class_of_service (
booking_class varchar,
rank int,
class_description text
)
CREATE TABLE airport (
airport_code varchar,
airport_name text,
airport_location text,
state_code varchar,
country_name varchar,
time_zone_code varchar,
minimum_connect_time int
)
CREATE TABLE flight_leg (
flight_id int,
leg_number int,
leg_flight int
)
CREATE TABLE flight_stop (
flight_id int,
stop_number int,
stop_days text,
stop_airport text,
arrival_time int,
arrival_airline text,
arrival_flight_number int,
departure_time int,
departure_airline text,
departure_flight_number int,
stop_time int
)
CREATE TABLE ground_service (
city_code text,
airport_code text,
transport_type text,
ground_fare int
)
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 date_day (
month_number int,
day_number int,
year int,
day_name varchar
)
CREATE TABLE aircraft (
aircraft_code varchar,
aircraft_description varchar,
manufacturer varchar,
basic_type varchar,
engines int,
propulsion varchar,
wide_body varchar,
wing_span int,
length int,
weight int,
capacity int,
pay_load int,
cruising_speed int,
range_miles int,
pressurized varchar
)
CREATE TABLE state (
state_code text,
state_name text,
country_name text
)
CREATE TABLE airport_service (
city_code varchar,
airport_code varchar,
miles_distant int,
direction varchar,
minutes_distant int
)
CREATE TABLE airline (
airline_code varchar,
airline_name text,
note text
)
CREATE TABLE month (
month_number int,
month_name text
)
CREATE TABLE code_description (
code varchar,
description text
)
CREATE TABLE fare_basis (
fare_basis_code text,
booking_class text,
class_type text,
premium text,
economy text,
discounted text,
night text,
season text,
basis_days text
)
CREATE TABLE city (
city_code varchar,
city_name varchar,
state_code varchar,
country_name varchar,
time_zone_code varchar
)
CREATE TABLE equipment_sequence (
aircraft_code_sequence varchar,
aircraft_code varchar
)
CREATE TABLE flight_fare (
flight_id int,
fare_id int
)
CREATE TABLE food_service (
meal_code text,
meal_number int,
compartment text,
meal_description varchar
)
CREATE TABLE days (
days_code varchar,
day_name varchar
)
CREATE TABLE time_interval (
period text,
begin_time int,
end_time int
)
CREATE TABLE compartment_class (
compartment varchar,
class_type varchar
)
CREATE TABLE restriction (
restriction_code text,
advance_purchase int,
stopovers text,
saturday_stay_required text,
minimum_stay int,
maximum_stay int,
application text,
no_discounts text
)
CREATE TABLE time_zone (
time_zone_code text,
time_zone_name text,
hours_from_gmt int
)
CREATE TABLE flight (
aircraft_code_sequence text,
airline_code varchar,
airline_flight text,
arrival_time int,
connections int,
departure_time int,
dual_carrier text,
flight_days text,
flight_id int,
flight_number int,
from_airport varchar,
meal_code text,
stops int,
time_elapsed int,
to_airport varchar
) |
SELECT COUNT(population__2011_) FROM table_2562572_37 WHERE cyrillic_name_other_names = "Александрово" | Name the population for александрово | CREATE TABLE table_2562572_37 (population__2011_ VARCHAR, cyrillic_name_other_names VARCHAR) |
SELECT length FROM table_name_60 WHERE daily_ridership > 414 | Daily ridership greater that 414 is associated with which length? | CREATE TABLE table_name_60 (length VARCHAR, daily_ridership INTEGER) |
SELECT "Venue" FROM table_33011 WHERE "State" = 'colorado' | What Venue is in Colorado? | CREATE TABLE table_33011 (
"Region" text,
"Host" text,
"Venue" text,
"City" text,
"State" text
) |
SELECT population__2011_ FROM table_2562572_37 WHERE cyrillic_name_other_names = "Српска Црња" | Name the population for 2011 for српска црња | CREATE TABLE table_2562572_37 (population__2011_ VARCHAR, cyrillic_name_other_names VARCHAR) |
SELECT competition FROM table_name_55 WHERE position = "4th" AND year > 2003 AND venue = "budapest, hungary" | Which competition did Târlea come in 4th place, in 2003 at Budapest, Hungary? | CREATE TABLE table_name_55 (competition VARCHAR, venue VARCHAR, position VARCHAR, year VARCHAR) |
SELECT position FROM table_20898602_1 WHERE height = "ft0in (m)" | what is the position of the player of height ft0in (m) | CREATE TABLE table_20898602_1 (
position VARCHAR,
height VARCHAR
) |
SELECT largest_ethnic_group__2002_ FROM table_2562572_43 WHERE population__2011_ = 200 | What is the largest ethnic group in 2002 when the population is 200? | CREATE TABLE table_2562572_43 (largest_ethnic_group__2002_ VARCHAR, population__2011_ VARCHAR) |
SELECT competition FROM table_name_75 WHERE notes = "400 m hurdles" AND year < 2004 AND venue = "johannesburg, south africa" | Prior to 2004, what was the name of the competition that took place in Johannesburg, South Africa and had the 400 m hurdles event? | CREATE TABLE table_name_75 (competition VARCHAR, venue VARCHAR, notes VARCHAR, year VARCHAR) |
SELECT "UK Broadcast Date" FROM table_5301 WHERE "Episode Title" = 'from hong kong to ulaanbaatar' | What is the broadcast date for the episode titled, 'From Hong Kong to Ulaanbaatar'? | CREATE TABLE table_5301 (
"Episode No." text,
"Episode Title" text,
"UK Broadcast Date" text,
"Presenter" text,
"Countries Visited" text
) |
SELECT COUNT(type) FROM table_2562572_43 WHERE cyrillic_name_other_names = "Падина (Slovak: Padina)" | How many entries are there for type for the cyrillic name other names is падина (slovak: padina)? | CREATE TABLE table_2562572_43 (type VARCHAR, cyrillic_name_other_names VARCHAR) |
SELECT notes FROM table_name_96 WHERE year = 1997 | What events did the competition that took place in 1997 have? | CREATE TABLE table_name_96 (notes VARCHAR, year VARCHAR) |
SELECT bullet_weight FROM table_name_99 WHERE source = "hornady" | What is Bullet weight, when Source is hornady? | CREATE TABLE table_name_99 (
bullet_weight VARCHAR,
source VARCHAR
) |
SELECT type FROM table_2562572_43 WHERE population__2011_ = 1004 | What is the type for the population in 2011 of 1004? | CREATE TABLE table_2562572_43 (type VARCHAR, population__2011_ VARCHAR) |
SELECT MIN(year) FROM table_name_6 WHERE position = "7th" | What was the earliest year that Târlea took 7th place? | CREATE TABLE table_name_6 (year INTEGER, position VARCHAR) |
SELECT HIRE_DATE, AVG(EMPLOYEE_ID) FROM employees WHERE NOT DEPARTMENT_ID IN (SELECT DEPARTMENT_ID FROM departments WHERE MANAGER_ID BETWEEN 100 AND 200) ORDER BY AVG(EMPLOYEE_ID) | For those employees who do not work in departments with managers that have ids between 100 and 200, return a bar chart about the distribution of hire_date and the average of employee_id bin hire_date by weekday, and I want to rank by the total number in asc. | CREATE TABLE countries (
COUNTRY_ID varchar(2),
COUNTRY_NAME varchar(40),
REGION_ID decimal(10,0)
)
CREATE TABLE locations (
LOCATION_ID decimal(4,0),
STREET_ADDRESS varchar(40),
POSTAL_CODE varchar(12),
CITY varchar(30),
STATE_PROVINCE varchar(25),
COUNTRY_ID varchar(2)
)
CREATE TABLE 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),
COMMISSION_PCT decimal(2,2),
MANAGER_ID decimal(6,0),
DEPARTMENT_ID decimal(4,0)
)
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 job_history (
EMPLOYEE_ID decimal(6,0),
START_DATE date,
END_DATE date,
JOB_ID varchar(10),
DEPARTMENT_ID decimal(4,0)
) |
SELECT dominant_religion__2002_ FROM table_2562572_43 WHERE largest_ethnic_group__2002_ = "Slovaks" AND type = "village" | What was the 2002 dominant religion when the largest ethnic group (2002) was slovaks and type is village? | CREATE TABLE table_2562572_43 (dominant_religion__2002_ VARCHAR, largest_ethnic_group__2002_ VARCHAR, type VARCHAR) |
SELECT position FROM table_name_56 WHERE competition = "european indoor championships" | What place did Târlea come in at the European Indoor Championships? | CREATE TABLE table_name_56 (position VARCHAR, competition VARCHAR) |
SELECT "High points" FROM table_29779 WHERE "Date" = 'April 8' | What were the high points on April 8? | CREATE TABLE table_29779 (
"Game" real,
"Date" text,
"Team" text,
"Score" text,
"High points" text,
"High rebounds" text,
"High assists" text,
"Location Attendance" text,
"Record" text
) |
SELECT cyrillic_name_other_names FROM table_2562572_43 WHERE settlement = "Debeljača" | What is the cyrillic name other names for the settlement of debeljača? | CREATE TABLE table_2562572_43 (cyrillic_name_other_names VARCHAR, settlement VARCHAR) |
SELECT venue FROM table_name_7 WHERE notes = "400 m hurdles" AND competition = "european championships" | What venue did the European Championships' 400 m Hurdles take place? | CREATE TABLE table_name_7 (venue VARCHAR, notes VARCHAR, competition VARCHAR) |
SELECT player FROM table_name_86 WHERE position = "sg" | Who has a position of sg? | CREATE TABLE table_name_86 (
player VARCHAR,
position VARCHAR
) |
SELECT COUNT(cyrillic_name_other_names) FROM table_2562572_43 WHERE settlement = "Idvor" | How many entries are there for cyrillic name other names where settlement is idvor? | CREATE TABLE table_2562572_43 (cyrillic_name_other_names VARCHAR, settlement VARCHAR) |
SELECT MAX(year) FROM table_name_34 WHERE champion = "marcel granollers" | what year has the highest marcel granollers champions? | CREATE TABLE table_name_34 (year INTEGER, champion VARCHAR) |
SELECT MAX("React") FROM table_63559 WHERE "Time" < '20.58' AND "Athlete" = 'christian malcolm' | What is Christian Malcolm s highest react when his time was below 20.58? | CREATE TABLE table_63559 (
"Rank" real,
"Lane" real,
"Athlete" text,
"Nationality" text,
"Time" real,
"React" real
) |
SELECT dominant_religion__2002_ FROM table_2562572_44 WHERE settlement = "Lokve" | What was the dominant religion in 2002 in lokve? | CREATE TABLE table_2562572_44 (dominant_religion__2002_ VARCHAR, settlement VARCHAR) |
SELECT MAX(sex_ratio__child_) FROM table_name_24 WHERE work_participation___percentage_ = "37.7%" | What is the child sex ration for the population with 37.7% work participation? | CREATE TABLE table_name_24 (sex_ratio__child_ INTEGER, work_participation___percentage_ VARCHAR) |
SELECT candidates FROM table_1341690_35 WHERE first_elected = 1966 | Who were the candidates in the districts that was first elected in 1966? | CREATE TABLE table_1341690_35 (
candidates VARCHAR,
first_elected VARCHAR
) |
SELECT largest_ethnic_group__2002_ FROM table_2562572_44 WHERE cyrillic_name_other_names = "Банатски Карловац" | What was the largest ethnic group in in the settlement with the cyrillic name банатски карловац? | CREATE TABLE table_2562572_44 (largest_ethnic_group__2002_ VARCHAR, cyrillic_name_other_names VARCHAR) |
SELECT date FROM table_name_26 WHERE venue = "punt road oval" | What day does the team play at punt road oval? | CREATE TABLE table_name_26 (date VARCHAR, venue VARCHAR) |
SELECT series FROM table_26400438_1 WHERE team = "Lecor Sports" | In which series did Lecor Sports participate? | CREATE TABLE table_26400438_1 (
series VARCHAR,
team VARCHAR
) |
SELECT COUNT(largest_ethnic_group__2002_) FROM table_2562572_44 WHERE population__2011_ = 5082 | What is the largest ethnic group in the settlement with a 2011 population of 5082? | CREATE TABLE table_2562572_44 (largest_ethnic_group__2002_ VARCHAR, population__2011_ VARCHAR) |
SELECT venue FROM table_name_64 WHERE away_team = "geelong" | What venue features geelong as the away side? | CREATE TABLE table_name_64 (venue VARCHAR, away_team VARCHAR) |
SELECT "Points against ( Tests )" FROM table_14086 WHERE "Year(s)" = '2000' AND "Games won ( Tests )" = '4 (1)' | What are the points against for 2000, when games won is 4 (1)? | CREATE TABLE table_14086 (
"Year(s)" real,
"Tournament or series" text,
"Played in" text,
"Games played ( Tests )" text,
"Games won ( Tests )" text,
"Games lost ( Tests )" text,
"Games drawn ( Tests )" text,
"Points for ( Tests )" text,
"Points against ( Tests )" text
) |
SELECT population__2011_ FROM table_2562572_44 WHERE settlement = "Banatski Karlovac" | What was the population in 2011 of banatski karlovac? | CREATE TABLE table_2562572_44 (population__2011_ VARCHAR, settlement VARCHAR) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.