answer
stringlengths
6
3.91k
question
stringlengths
7
766
context
stringlengths
27
7.14k
SELECT game_site FROM table_25380472_2 WHERE team_record = "1–6"
What game sites are where the team record is 1–6?
CREATE TABLE table_25380472_2 (game_site VARCHAR, team_record VARCHAR)
SELECT tournament FROM table_name_23 WHERE date = "october 11, 2013"
What tournament took place on October 11, 2013?
CREATE TABLE table_name_23 (tournament VARCHAR, date VARCHAR)
SELECT procedures.icd9_code FROM procedures WHERE procedures.subject_id = "3343"
what is procedure icd9 code of subject id 3343?
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 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 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 )
SELECT opponent FROM table_25380472_2 WHERE game_site = "AOL Arena"
In game site AOL Arena, who are all the opponents?
CREATE TABLE table_25380472_2 (opponent VARCHAR, game_site VARCHAR)
SELECT tournament FROM table_name_94 WHERE date = "june 18, 2013"
Which tournament took place on June 18, 2013?
CREATE TABLE table_name_94 (tournament VARCHAR, date VARCHAR)
SELECT ACC_Regular_Season, School_ID FROM basketball_match ORDER BY ACC_Regular_Season DESC
Show me school_id by acc regular season in a histogram, display in desc by the x axis.
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_Percent text, ACC_Home text, ACC_Road text, All_Games text, All_Games_Percent int, All_Home text, All_Road text, All_Neutral text )
SELECT organization FROM table_2538117_12 WHERE founding_date = "1998-11-08"
What organization had the founding date of 1998-11-08?
CREATE TABLE table_2538117_12 (organization VARCHAR, founding_date VARCHAR)
SELECT AVG(week) FROM table_name_94 WHERE date = "november 7, 1976" AND attendance < 46 OFFSET 735
What is the average week on November 7, 1976 with an attendance less than 46,735?
CREATE TABLE table_name_94 (week INTEGER, date VARCHAR, attendance VARCHAR)
SELECT COUNT(*) FROM Votes AS v INNER JOIN Posts AS p ON p.AcceptedAnswerId = v.PostId INNER JOIN Votes AS upv ON upv.PostId = v.PostId AND upv.VoteTypeId = 2 AND upv.CreationDate = v.CreationDate WHERE v.VoteTypeId = 1 AND p.AnswerCount = 1
Posts with a single accepted answer that is downvoted at the same time.
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, DownVotes number, ProfileImageUrl text, EmailHash text, AccountId number ) CREATE TABLE CloseReasonTypes ( Id number, Name text, Description text ) CREATE TABLE ReviewTaskResults ( Id number, ReviewTaskId number, ReviewTaskResultTypeId number, CreationDate time, RejectionReasonId number, Comment text ) 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 PendingFlags ( Id number, FlagTypeId number, PostId number, CreationDate time, CloseReasonTypeId number, CloseAsOffTopicReasonTypeId number, DuplicateOfQuestionId number, BelongsOnBaseHostAddress 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 PostTypes ( Id number, Name text ) CREATE TABLE Tags ( Id number, TagName text, Count number, ExcerptPostId number, WikiPostId number ) 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 PostLinks ( Id number, CreationDate time, PostId number, RelatedPostId number, LinkTypeId number ) CREATE TABLE VoteTypes ( Id number, Name text ) CREATE TABLE ReviewTaskTypes ( Id number, Name text, Description text ) 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 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 Badges ( Id number, UserId number, Name text, Date time, Class number, TagBased boolean ) CREATE TABLE Comments ( Id number, PostId number, Score number, Text text, CreationDate time, UserDisplayName text, UserId number, ContentLicense text ) CREATE TABLE PostNoticeTypes ( Id number, ClassId number, Name text, Body text, IsHidden boolean, Predefined boolean, PostNoticeDurationId number ) CREATE TABLE PostHistoryTypes ( Id number, Name text ) CREATE TABLE PostNotices ( Id number, PostId number, PostNoticeTypeId number, CreationDate time, DeletionDate time, ExpiryDate time, Body text, OwnerUserId number, DeletionUserId 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 PostFeedback ( Id number, PostId number, IsAnonymous boolean, VoteTypeId number, CreationDate time ) CREATE TABLE SuggestedEditVotes ( Id number, SuggestedEditId number, UserId number, VoteTypeId number, CreationDate time, TargetUserId number, TargetRepChange number ) CREATE TABLE ReviewTasks ( Id number, ReviewTaskTypeId number, CreationDate time, DeletionDate time, ReviewTaskStateId number, PostId number, SuggestedEditId number, CompletedByReviewTaskId 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 )
SELECT COUNT(letters) FROM table_2538117_12 WHERE founding_date = "1997-12-12"
How many letters were given to the organization with a founding date of 1997-12-12?
CREATE TABLE table_2538117_12 (letters VARCHAR, founding_date VARCHAR)
SELECT opponent FROM table_name_96 WHERE week = 5
Who is the opponent for week 5?
CREATE TABLE table_name_96 (opponent VARCHAR, week VARCHAR)
SELECT Age, COUNT(*) AS UserCount FROM Users WHERE NOT Age IS NULL AND Age > 0 GROUP BY Age ORDER BY Age
Number of people of each age.
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 CloseReasonTypes ( Id number, Name text, Description 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 ReviewTaskStates ( Id number, Name text, Description 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 PendingFlags ( Id number, FlagTypeId number, PostId number, CreationDate time, CloseReasonTypeId number, CloseAsOffTopicReasonTypeId number, DuplicateOfQuestionId number, BelongsOnBaseHostAddress text ) CREATE TABLE Comments ( Id number, PostId number, Score number, Text text, CreationDate time, UserDisplayName text, UserId number, ContentLicense text ) CREATE TABLE ReviewTaskResultTypes ( Id number, Name text, Description text ) CREATE TABLE PostTags ( PostId number, TagId number ) CREATE TABLE PostNotices ( Id number, PostId number, PostNoticeTypeId number, CreationDate time, DeletionDate time, ExpiryDate time, Body text, OwnerUserId number, DeletionUserId number ) CREATE TABLE ReviewTasks ( Id number, ReviewTaskTypeId number, CreationDate time, DeletionDate time, ReviewTaskStateId number, PostId number, SuggestedEditId number, CompletedByReviewTaskId number ) CREATE TABLE ReviewRejectionReasons ( Id number, Name text, Description text, PostTypeId number ) CREATE TABLE Badges ( Id number, UserId number, Name text, Date time, Class number, TagBased boolean ) CREATE TABLE ReviewTaskTypes ( Id number, Name text, Description text ) 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, Predefined boolean, PostNoticeDurationId number ) CREATE TABLE PostLinks ( Id number, CreationDate time, PostId number, RelatedPostId number, LinkTypeId number ) CREATE TABLE Votes ( Id number, PostId number, VoteTypeId number, UserId number, CreationDate time, BountyAmount number ) CREATE TABLE PostTypes ( Id number, Name text ) 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 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 PostHistoryTypes ( Id number, Name text ) 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 FlagTypes ( Id number, Name text, Description text ) CREATE TABLE PostFeedback ( Id number, PostId number, IsAnonymous boolean, VoteTypeId number, CreationDate time ) CREATE TABLE VoteTypes ( Id number, Name text ) CREATE TABLE ReviewTaskResults ( Id number, ReviewTaskId number, ReviewTaskResultTypeId number, CreationDate time, RejectionReasonId number, Comment 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 Tags ( Id number, TagName text, Count number, ExcerptPostId number, WikiPostId number )
SELECT COUNT(song_choice) FROM table_25374338_1 WHERE original_artist = "Gino Paoli"
What is the song choice where the original artist is Gino Paoli?
CREATE TABLE table_25374338_1 (song_choice VARCHAR, original_artist VARCHAR)
SELECT MAX(overall_rank) FROM table_name_68 WHERE heat_rank > 4 AND lane < 2
Tell me the highest overall rank for heat rank more than 4 and lane less than 2
CREATE TABLE table_name_68 (overall_rank INTEGER, heat_rank VARCHAR, lane VARCHAR)
SELECT aprende FROM table_name_35 WHERE centennial = "1988"
WHich kind of Aprende has a Centennial of 1988?
CREATE TABLE table_name_35 ( aprende VARCHAR, centennial VARCHAR )
SELECT theme FROM table_25374338_1 WHERE original_artist = "Noemi feat. Fiorella Mannoia"
What is the theme where the original artist is Noemi feat. Fiorella Mannoia?
CREATE TABLE table_25374338_1 (theme VARCHAR, original_artist VARCHAR)
SELECT partner FROM table_name_26 WHERE outcome = "runner-up" AND date = "april 6, 1992"
Who is the partner with a runner-up outcome on April 6, 1992?
CREATE TABLE table_name_26 (partner VARCHAR, outcome VARCHAR, date VARCHAR)
SELECT "Power" FROM table_38868 WHERE "Model" = '2.0 tdi (cr) dpf' AND "Years" = '2010–2011'
What is the power for model 2.0 tdi (cr) dpf, and a Years of 2010 2011?
CREATE TABLE table_38868 ( "Model" text, "Years" text, "Engine" text, "Displ." text, "Power" text, "Torque" text )
SELECT song_choice FROM table_25374338_1 WHERE episode = "Live Show 1"
What is the song choice where the episode is Live Show 1?
CREATE TABLE table_25374338_1 (song_choice VARCHAR, episode VARCHAR)
SELECT outcome FROM table_name_3 WHERE surface = "hard" AND score = "4–6, 6–7(3)"
What outcome occurs on a hard surface with a score of 4–6, 6–7(3)?
CREATE TABLE table_name_3 (outcome VARCHAR, surface VARCHAR, score 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, 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
do you have a flight from ATLANTA to BOSTON
CREATE TABLE city ( city_code varchar, city_name varchar, state_code varchar, country_name varchar, time_zone_code varchar ) CREATE TABLE ground_service ( city_code text, airport_code text, transport_type text, ground_fare int ) 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 food_service ( meal_code text, meal_number int, compartment text, meal_description varchar ) CREATE TABLE state ( state_code text, state_name text, country_name text ) CREATE TABLE class_of_service ( booking_class varchar, rank int, class_description text ) 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 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 time_interval ( period text, begin_time int, end_time int ) CREATE TABLE compartment_class ( compartment varchar, class_type varchar ) CREATE TABLE equipment_sequence ( aircraft_code_sequence varchar, aircraft_code varchar ) 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 dual_carrier ( main_airline varchar, low_flight_number int, high_flight_number int, dual_airline varchar, service_name text ) CREATE TABLE month ( month_number int, month_name text ) CREATE TABLE time_zone ( time_zone_code text, time_zone_name text, hours_from_gmt int ) CREATE TABLE airport_service ( city_code varchar, airport_code varchar, miles_distant int, direction varchar, minutes_distant int ) CREATE TABLE restriction ( restriction_code text, advance_purchase int, stopovers text, saturday_stay_required text, minimum_stay int, maximum_stay int, application text, no_discounts text ) CREATE TABLE 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 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 ) CREATE TABLE flight_fare ( flight_id int, fare_id int ) CREATE TABLE flight_leg ( flight_id int, leg_number int, leg_flight int ) CREATE TABLE code_description ( code varchar, description text ) CREATE TABLE days ( days_code varchar, day_name varchar ) CREATE TABLE airline ( airline_code varchar, airline_name text, note text )
SELECT result FROM table_25374338_1 WHERE original_artist = "Prince and The Revolution"
What is the result where the original artist is Prince and the Revolution?
CREATE TABLE table_25374338_1 (result VARCHAR, original_artist VARCHAR)
SELECT date FROM table_name_84 WHERE partner = "lori mcneil" AND score = "6–7(6), 5–7"
On what date did Lori McNeil play as a partner with a score of 6–7(6), 5–7?
CREATE TABLE table_name_84 (date VARCHAR, partner VARCHAR, score VARCHAR)
SELECT "Score" FROM table_65182 WHERE "Tie no" = 'replay' AND "Home team" = 'mansfield town'
What was the score when the tie number was a replay and the home team was mansfield town?
CREATE TABLE table_65182 ( "Tie no" text, "Home team" text, "Score" text, "Away team" text, "Date" text )
SELECT theme FROM table_25374338_1 WHERE original_artist = "AC/DC"
What is the theme where the original artist is AC/DC?
CREATE TABLE table_25374338_1 (theme VARCHAR, original_artist VARCHAR)
SELECT MAX(losses) FROM table_name_62 WHERE percentage > 0.461 AND wins > 86 AND finish = "2nd" AND year = 1953
What is the most losses that the Royals had when they had a percentage over 0.461, won over 86 games, and finished 2nd in 1953?
CREATE TABLE table_name_62 (losses INTEGER, year VARCHAR, finish VARCHAR, percentage VARCHAR, wins VARCHAR)
SELECT MIN(rank) FROM table_name_7 WHERE nation = "spain"
What is the lowest rank that spain got?
CREATE TABLE table_name_7 ( rank INTEGER, nation VARCHAR )
SELECT type FROM table_2538117_2 WHERE organization = "Sigma Phi Omega"
what type of organization is sigma phi omega?
CREATE TABLE table_2538117_2 (type VARCHAR, organization VARCHAR)
SELECT opponent FROM table_name_59 WHERE tournament = "eastbourne" AND score = "6–0, 5–7, 3–6"
Tell the opponent of eastbourne with score of 6–0, 5–7, 3–6
CREATE TABLE table_name_59 (opponent VARCHAR, tournament VARCHAR, score VARCHAR)
SELECT Posts.CreationDate, Posts.Id, Posts.Title, Posts.Tags, Posts.ViewCount, Posts.Body, Posts.OwnerUserId, Posts.OwnerDisplayName, Posts.Score, Posts.FavoriteCount, Posts.PostTypeId, Posts.LastEditDate, Posts.LastActivityDate, Posts.FavoriteCount, Posts.ClosedDate, Users.Reputation, Users.UpVotes, Users.DownVotes, Users.Age, Users.CreationDate, Users.WebsiteUrl, Users.Location FROM Posts JOIN Users ON Posts.OwnerUserId = Users.Id WHERE Posts.AnswerCount = 0 ORDER BY Posts.CreationDate DESC LIMIT 10000
Find new questions with no answers.
CREATE TABLE PendingFlags ( Id number, FlagTypeId number, PostId number, CreationDate time, CloseReasonTypeId number, CloseAsOffTopicReasonTypeId number, DuplicateOfQuestionId number, BelongsOnBaseHostAddress text ) CREATE TABLE ReviewTaskResults ( Id number, ReviewTaskId number, ReviewTaskResultTypeId number, CreationDate time, RejectionReasonId number, Comment text ) CREATE TABLE SuggestedEditVotes ( Id number, SuggestedEditId number, UserId number, VoteTypeId number, CreationDate time, TargetUserId number, TargetRepChange number ) CREATE TABLE Votes ( Id number, PostId number, VoteTypeId number, UserId number, CreationDate time, BountyAmount number ) CREATE TABLE PostNoticeTypes ( Id number, ClassId number, Name text, Body text, IsHidden boolean, Predefined boolean, PostNoticeDurationId number ) 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 PostFeedback ( Id number, PostId number, IsAnonymous boolean, VoteTypeId number, CreationDate time ) 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 PostHistoryTypes ( Id number, Name text ) CREATE TABLE PostTypes ( Id number, Name text ) CREATE TABLE PostTags ( PostId number, TagId 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 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 ReviewTaskResultTypes ( Id number, Name text, Description text ) CREATE TABLE ReviewRejectionReasons ( Id number, Name text, Description text, PostTypeId number ) CREATE TABLE PostNotices ( Id number, PostId number, PostNoticeTypeId number, CreationDate time, DeletionDate time, ExpiryDate time, Body text, OwnerUserId number, DeletionUserId 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 VoteTypes ( Id number, Name text ) CREATE TABLE Tags ( Id number, TagName text, Count number, ExcerptPostId number, WikiPostId number ) CREATE TABLE ReviewTasks ( Id number, ReviewTaskTypeId number, CreationDate time, DeletionDate time, ReviewTaskStateId number, PostId number, SuggestedEditId number, CompletedByReviewTaskId number ) CREATE TABLE Badges ( Id number, UserId number, Name text, Date time, Class number, TagBased boolean ) 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 ReviewTaskStates ( Id number, Name text, Description text ) CREATE TABLE FlagTypes ( Id number, Name text, Description text ) CREATE TABLE ReviewTaskTypes ( Id number, Name text, Description 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 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 )
SELECT COUNT(type) FROM table_2538117_2 WHERE founding_university = "San Diego State University"
how many types of organization were founded in san diego state university?
CREATE TABLE table_2538117_2 (type VARCHAR, founding_university VARCHAR)
SELECT outcome FROM table_name_40 WHERE score = "2–6, 1–6"
Tell me the outcome of 2–6, 1–6
CREATE TABLE table_name_40 (outcome VARCHAR, score VARCHAR)
SELECT "Name" FROM table_31312 WHERE "Country" = 'DR Congo'
What are the names of players from the dr congo?
CREATE TABLE table_31312 ( "Name" text, "Position" text, "Country" text, "Years" text, "Games" real, "Minutes" real, "Goals" real, "Assists" real, "Int. caps" real, "Int. goals" real )
SELECT COUNT(season) FROM table_25375093_1 WHERE position = "4th"
Name the season for position 4th
CREATE TABLE table_25375093_1 (season VARCHAR, position VARCHAR)
SELECT surface FROM table_name_6 WHERE tournament = "eastbourne" AND date = "14 june 1999"
Tell me the surface for eastbourne 14 june 1999
CREATE TABLE table_name_6 (surface VARCHAR, tournament VARCHAR, date VARCHAR)
SELECT "Won" FROM table_19040 WHERE "Points against" = '304'
what's the won with points against being 304
CREATE TABLE table_19040 ( "Club" text, "Played" text, "Won" text, "Drawn" text, "Lost" text, "Points for" text, "Points against" text, "Tries for" text, "Tries against" text, "Try bonus" text, "Losing bonus" text, "Points" text )
SELECT MIN(f_laps) FROM table_25375093_1
Name the least f/laps
CREATE TABLE table_25375093_1 (f_laps INTEGER)
SELECT category FROM table_name_77 WHERE result = "won" AND year > 2009
Tell me the category for result of won and year more than 2009
CREATE TABLE table_name_77 (category VARCHAR, result VARCHAR, year VARCHAR)
SELECT "Result" FROM table_35093 WHERE "Score" = '0–0' AND "Date" = '02-jan-64'
Score of 0 0, and a Date of 02-jan-64 had what result?
CREATE TABLE table_35093 ( "Date" text, "Result" text, "Score" text, "Venue" text, "Competition" text )
SELECT MIN(podiums) FROM table_25375093_1 WHERE position = "9th"
Name the least podiums for 9th position
CREATE TABLE table_25375093_1 (podiums INTEGER, position VARCHAR)
SELECT nominated_work FROM table_name_54 WHERE year > 2011
Tell me the nominated work larger than 2011
CREATE TABLE table_name_54 (nominated_work VARCHAR, year INTEGER)
SELECT MIN("Pick") FROM table_5749 WHERE "Player" = 'mike o''quinn' AND "Round" < '15'
Player of mike o'quinn, and a Round smaller than 15 had what lowest pick?
CREATE TABLE table_5749 ( "Round" real, "Pick" real, "Player" text, "Position" text, "School/Club Team" text )
SELECT COUNT(shot_pct) FROM table_25381437_2 WHERE pa = 79
How many results are listed for shot PCT Where PA is 79?
CREATE TABLE table_25381437_2 (shot_pct VARCHAR, pa VARCHAR)
SELECT result FROM table_name_94 WHERE association = "primetime emmy awards"
Tell me the result for primetime emmy awards
CREATE TABLE table_name_94 (result VARCHAR, association VARCHAR)
SELECT dept_name, COUNT(*) FROM student GROUP BY dept_name
how many students are in each department?
CREATE TABLE student ( ID varchar(5), name varchar(20), dept_name varchar(20), tot_cred numeric(3,0) ) CREATE TABLE teaches ( ID varchar(5), course_id varchar(8), sec_id varchar(8), semester varchar(6), year numeric(4,0) ) CREATE TABLE classroom ( building varchar(15), room_number varchar(7), capacity numeric(4,0) ) CREATE TABLE instructor ( ID varchar(5), name varchar(20), dept_name varchar(20), salary numeric(8,2) ) CREATE TABLE takes ( ID varchar(5), course_id varchar(8), sec_id varchar(8), semester varchar(6), year numeric(4,0), grade varchar(2) ) CREATE TABLE section ( course_id varchar(8), sec_id varchar(8), semester varchar(6), year numeric(4,0), building varchar(15), room_number varchar(7), time_slot_id varchar(4) ) CREATE TABLE advisor ( s_ID varchar(5), i_ID varchar(5) ) CREATE TABLE course ( course_id varchar(8), title varchar(50), dept_name varchar(20), credits numeric(2,0) ) CREATE TABLE prereq ( course_id varchar(8), prereq_id varchar(8) ) CREATE TABLE department ( dept_name varchar(20), building varchar(15), budget numeric(12,2) ) CREATE TABLE time_slot ( time_slot_id varchar(4), day varchar(1), start_hr numeric(2), start_min numeric(2), end_hr numeric(2), end_min numeric(2) )
SELECT locale FROM table_25381437_2 WHERE stolen_ends = 15
Where were stolen ends recorded as 15?
CREATE TABLE table_25381437_2 (locale VARCHAR, stolen_ends VARCHAR)
SELECT competition FROM table_name_31 WHERE date = "1 march 1909"
What competition was held 1 March 1909?
CREATE TABLE table_name_31 (competition VARCHAR, date VARCHAR)
SELECT first_elected FROM table_name_87 WHERE constiuency = "territorial at-large" AND name = "myron walwyn"
What is Myron Walwyn with a Territorial at-large Constiuency's First Elected Date
CREATE TABLE table_name_87 ( first_elected VARCHAR, constiuency VARCHAR, name VARCHAR )
SELECT slno FROM table_25383715_1 WHERE contact_person = "SDE (P), Thiruppattur"
What was the SlNo no of contact person SDE (P), Thiruppattur?
CREATE TABLE table_25383715_1 (slno VARCHAR, contact_person VARCHAR)
SELECT COUNT(gold) FROM table_name_62 WHERE total < 1
Tell me the total number of gold for total less than 1
CREATE TABLE table_name_62 (gold VARCHAR, total INTEGER)
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN procedures ON demographic.hadm_id = procedures.hadm_id WHERE demographic.days_stay > "7" AND procedures.icd9_code = "5732"
give me the number of patients whose days of hospital stay is greater than 7 and procedure icd9 code is 5732?
CREATE TABLE diagnoses ( subject_id text, hadm_id text, icd9_code text, short_title text, long_title text ) CREATE TABLE lab ( subject_id text, hadm_id text, itemid text, charttime text, flag text, value_unit text, label text, fluid text ) CREATE TABLE procedures ( 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 ) 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 )
SELECT production_code FROM table_25390694_2 WHERE writer = "Brendan Cowell"
What was the production code of the episode written by Brendan Cowell?
CREATE TABLE table_25390694_2 (production_code VARCHAR, writer VARCHAR)
SELECT model FROM table_name_30 WHERE total_production = 1347
Tell me the model for total production of 1347
CREATE TABLE table_name_30 (model VARCHAR, total_production VARCHAR)
SELECT Users.Id AS "user_link", Posts.Id AS "post_link" FROM Users JOIN Posts ON Posts.OwnerUserId = Users.Id WHERE Posts.ClosedDate IS NULL AND Posts.AnswerCount > 0 LIMIT 50
unaccepted question rate, grouped by user. for each person who has asked a question on the site, display the userid and their unaccepted-question percentage (their Q's that have no accepted answer divided by their Q's; where Q's are further filtered to be 'not closed' and 'at least one answer')
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 PostHistory ( Id number, PostHistoryTypeId number, PostId number, RevisionGUID other, CreationDate time, UserId number, UserDisplayName text, Comment text, Text text, ContentLicense text ) CREATE TABLE PendingFlags ( Id number, FlagTypeId number, PostId number, CreationDate time, CloseReasonTypeId number, CloseAsOffTopicReasonTypeId number, DuplicateOfQuestionId number, BelongsOnBaseHostAddress 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 Badges ( Id number, UserId number, Name text, Date time, Class number, TagBased boolean ) 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 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 ReviewTaskResultTypes ( Id number, Name text, Description 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 FlagTypes ( Id number, Name text, Description text ) CREATE TABLE PostTags ( PostId number, TagId 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 PostFeedback ( Id number, PostId number, IsAnonymous boolean, VoteTypeId number, CreationDate time ) 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 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 ReviewTaskStates ( Id number, Name text, Description text ) CREATE TABLE PostHistoryTypes ( Id number, Name text ) CREATE TABLE Tags ( Id number, TagName text, Count number, ExcerptPostId number, WikiPostId number ) CREATE TABLE PostTypes ( Id number, Name text ) CREATE TABLE PostNoticeTypes ( Id number, ClassId number, Name text, Body text, IsHidden boolean, Predefined boolean, PostNoticeDurationId number ) CREATE TABLE Votes ( Id number, PostId number, VoteTypeId number, UserId number, CreationDate time, BountyAmount number ) CREATE TABLE SuggestedEditVotes ( Id number, SuggestedEditId number, UserId number, VoteTypeId number, CreationDate time, TargetUserId number, TargetRepChange number ) CREATE TABLE ReviewTaskTypes ( Id number, Name text, Description text ) CREATE TABLE ReviewTaskResults ( Id number, ReviewTaskId number, ReviewTaskResultTypeId number, CreationDate time, RejectionReasonId number, Comment text ) CREATE TABLE ReviewRejectionReasons ( Id number, Name text, Description text, PostTypeId number ) CREATE TABLE PostNotices ( Id number, PostId number, PostNoticeTypeId number, CreationDate time, DeletionDate time, ExpiryDate time, Body text, OwnerUserId number, DeletionUserId number ) CREATE TABLE PostLinks ( Id number, CreationDate time, PostId number, RelatedPostId number, LinkTypeId number )
SELECT COUNT(f_laps) FROM table_25386974_1 WHERE position = "20th"
How many f/laps did Pedro Nunes have when he was in 20th position?
CREATE TABLE table_25386974_1 (f_laps VARCHAR, position VARCHAR)
SELECT SUM(gold) FROM table_name_88 WHERE nation = "guatemala" AND silver < 0
What is the total amount of Gold from guatemala and silver smaller than 0?
CREATE TABLE table_name_88 (gold INTEGER, nation VARCHAR, silver VARCHAR)
SELECT COUNT("Pick #") FROM table_27716 WHERE "Affiliation" = 'University of California NorCal Lamorinda United'
How many picks are there with an affiliation is the University of California Norcal Lamorinda United?
CREATE TABLE table_27716 ( "Pick #" real, "MLS Team" text, "Player" text, "Position" text, "Affiliation" text )
SELECT f_laps FROM table_25386974_1 WHERE series = "GP3 series"
How many f/laps did Pedro Nunes have when he was at the gp3 series?
CREATE TABLE table_25386974_1 (f_laps VARCHAR, series VARCHAR)
SELECT event FROM table_name_70 WHERE games = "2012 london"
Tell me the event for 2012 london games
CREATE TABLE table_name_70 (event VARCHAR, games VARCHAR)
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE diagnoses.icd9_code = "431" AND lab."CATEGORY" = "Chemistry"
let me know the number of patients categorized under chemistry lab test with diagnoses icd9 code 431.
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 ) 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 )
SELECT MIN(races) FROM table_25386974_1
What is the fewest number of races Pedro Nunes completed in any series?
CREATE TABLE table_25386974_1 (races INTEGER)
SELECT games FROM table_name_18 WHERE event = "men's 5000 metres"
Tell me the games for men's 5000 metres
CREATE TABLE table_name_18 (games VARCHAR, event VARCHAR)
SELECT "Quantity" FROM table_64812 WHERE "Axle arrangement ( UIC ) Bauart" = 'c n2t' AND "DRG number(s)" = '99 093'
Which quantity has Axle arrangement (UIC)bauart of c n2t, and DRG number 99 093?
CREATE TABLE table_64812 ( "Class" text, "Railway number(s)" text, "DRG number(s)" text, "Quantity" real, "Year(s) of manufacture" text, "Axle arrangement ( UIC ) Bauart" text )
SELECT MAX(podiums) FROM table_25386974_1 WHERE position = "17th"
What is the most podiums Pedro Nunes had when in 17th position?
CREATE TABLE table_25386974_1 (podiums INTEGER, position VARCHAR)
SELECT date FROM table_name_72 WHERE result = "w 20-19"
When did the w 20-19 happen?
CREATE TABLE table_name_72 (date VARCHAR, result VARCHAR)
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.age < "74" AND lab.label = "WBC, Pleural"
How many patients are younger than 74 years of age and lab tested with wbc pleural?
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 procedures ( subject_id text, hadm_id text, icd9_code text, short_title text, long_title text ) 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 ( subject_id text, hadm_id text, icustay_id text, drug_type text, drug text, formulary_drug_cd text, route text, drug_dose text )
SELECT founding_university FROM table_2538117_5 WHERE organization = "Tau Epsilon Phi 1"
What was the founding university of the organization Tau Epsilon Phi 1?
CREATE TABLE table_2538117_5 (founding_university VARCHAR, organization VARCHAR)
SELECT attendance FROM table_name_61 WHERE result = "w 28-13"
What was the attendance of the w 28-13 game?
CREATE TABLE table_name_61 (attendance VARCHAR, result VARCHAR)
SELECT place FROM table_name_93 WHERE player = "s.k. ho"
What place is S.K. Ho in?
CREATE TABLE table_name_93 ( place VARCHAR, player VARCHAR )
SELECT type FROM table_2538117_5 WHERE letters = "ΣΑΕΠ"
What type is σαεπ?
CREATE TABLE table_2538117_5 (type VARCHAR, letters VARCHAR)
SELECT voting_turnout FROM table_name_91 WHERE general_elections = 1985
Tell me the voting turnout for 1985 general elections
CREATE TABLE table_name_91 (voting_turnout VARCHAR, general_elections VARCHAR)
SELECT t1.labname FROM (SELECT lab.labname, DENSE_RANK() OVER (ORDER BY COUNT(*) DESC) AS c1 FROM lab WHERE lab.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.age BETWEEN 20 AND 29) AND DATETIME(lab.labresulttime, 'start of year') = DATETIME(CURRENT_TIME(), 'start of year', '-0 year') GROUP BY lab.labname) AS t1 WHERE t1.c1 <= 5
what were the top five most frequent lab tests for patients with an age 20s during this year?
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 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 ) CREATE TABLE treatment ( treatmentid number, patientunitstayid number, treatmentname text, treatmenttime time ) CREATE TABLE diagnosis ( diagnosisid number, patientunitstayid number, diagnosisname text, diagnosistime time, icd9code text ) CREATE TABLE medication ( medicationid number, patientunitstayid number, drugname text, dosage text, routeadmin text, drugstarttime time, drugstoptime 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 lab ( labid number, patientunitstayid number, labname text, labresult number, labresulttime 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 allergy ( allergyid number, patientunitstayid number, drugname text, allergyname text, allergytime time )
SELECT founding_university FROM table_2538117_5 WHERE letters = "ΑΕΦ"
What was the founding university of αεφ?
CREATE TABLE table_2538117_5 (founding_university VARCHAR, letters VARCHAR)
SELECT SUM(total) FROM table_name_59 WHERE nation = "england"
What is total number of wins for England?
CREATE TABLE table_name_59 (total INTEGER, nation VARCHAR)
SELECT (SELECT "points" FROM table_202_22 WHERE "rider" = 'robbie mcewen') + (SELECT "points" FROM table_202_22 WHERE "rider" = 'cristian moreni')
how many points did robbie mcewen and cristian moreni score together ?
CREATE TABLE table_202_22 ( id number, "rank" number, "rider" text, "team" text, "points" number )
SELECT type FROM table_2538117_7 WHERE organization = "Gamma Rho Lambda 1"
What is the type if the organization name is Gamma RHO Lambda 1?
CREATE TABLE table_2538117_7 (type VARCHAR, organization VARCHAR)
SELECT COUNT(bronze) FROM table_name_44 WHERE nation = "soviet union" AND silver > 2
The Soviet Union has won more than 2 Silver, but how many Bronzes?
CREATE TABLE table_name_44 (bronze VARCHAR, nation VARCHAR, silver VARCHAR)
SELECT AVG("Attendance") FROM table_68635 WHERE "Record" = '17-18'
What was the average attendance when the record was 17-18?
CREATE TABLE table_68635 ( "Date" text, "Opponent" text, "Score" text, "Loss" text, "Attendance" real, "Record" text )
SELECT founding_date FROM table_2538117_7 WHERE letters = "ΦΑΝ"
If the letters is φαν, what is the founding date?
CREATE TABLE table_2538117_7 (founding_date VARCHAR, letters VARCHAR)
SELECT constituency FROM table_name_41 WHERE party = "alliance" AND election < 1997 AND position = 2 AND candidate = "seamus close"
Which Alliance Constituency has Seamus Close, position 2 and an election smaller than 1997?
CREATE TABLE table_name_41 (constituency VARCHAR, candidate VARCHAR, position VARCHAR, party VARCHAR, election VARCHAR)
SELECT COUNT(DISTINCT icustays.icustay_id) FROM icustays WHERE icustays.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 56009) AND STRFTIME('%y', icustays.intime) = '2100'
how many times had patient 56009 visited intensive care unit in 2100?
CREATE TABLE patients ( row_id number, subject_id number, gender text, dob time, dod time ) CREATE TABLE prescriptions ( row_id number, subject_id number, hadm_id number, startdate time, enddate time, drug text, dose_val_rx text, dose_unit_rx text, route text ) CREATE TABLE procedures_icd ( row_id number, subject_id number, hadm_id number, icd9_code text, charttime time ) CREATE TABLE diagnoses_icd ( row_id number, subject_id number, hadm_id number, icd9_code text, charttime time ) CREATE TABLE outputevents ( row_id number, subject_id number, hadm_id number, icustay_id number, charttime time, itemid number, value number ) CREATE TABLE microbiologyevents ( row_id number, subject_id number, hadm_id number, charttime time, spec_type_desc text, org_name text ) CREATE TABLE admissions ( row_id number, subject_id number, hadm_id number, admittime time, dischtime time, admission_type text, admission_location text, discharge_location text, insurance text, language text, marital_status text, ethnicity text, age number ) CREATE TABLE cost ( row_id number, subject_id number, hadm_id number, event_type text, event_id number, chargetime time, cost number ) CREATE TABLE d_items ( row_id number, itemid number, label text, linksto text ) CREATE TABLE inputevents_cv ( row_id number, subject_id number, hadm_id number, icustay_id number, charttime time, itemid number, amount number ) CREATE TABLE d_icd_procedures ( row_id number, icd9_code text, short_title text, long_title text ) CREATE TABLE chartevents ( row_id number, subject_id number, hadm_id number, icustay_id number, itemid number, charttime time, valuenum number, valueuom text ) CREATE TABLE d_icd_diagnoses ( row_id number, icd9_code text, short_title text, long_title text ) CREATE TABLE labevents ( row_id number, subject_id number, hadm_id number, itemid number, charttime time, valuenum number, valueuom text ) CREATE TABLE icustays ( row_id number, subject_id number, hadm_id number, icustay_id number, first_careunit text, last_careunit text, first_wardid number, last_wardid number, intime time, outtime time ) 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_labitems ( row_id number, itemid number, label text )
SELECT nickname FROM table_2538117_7 WHERE founding_university = "Charlotte, NC"
If the founding university is in Charlotte, NC, what is the nickname?
CREATE TABLE table_2538117_7 (nickname VARCHAR, founding_university VARCHAR)
SELECT AVG(average) FROM table_name_54 WHERE evening_gown = 7.52 AND swimsuit > 7.78
I want the average for evening gown of 7.52 and swimsuit larger than 7.78
CREATE TABLE table_name_54 (average INTEGER, evening_gown VARCHAR, swimsuit VARCHAR)
SELECT AllergyType, COUNT(*) FROM Has_Allergy AS T1 JOIN Allergy_Type AS T2 ON T1.Allergy = T2.Allergy GROUP BY T2.AllergyType
Show all allergy type with number of students affected with a bar chart.
CREATE TABLE Student ( StuID INTEGER, LName VARCHAR(12), Fname VARCHAR(12), Age INTEGER, Sex VARCHAR(1), Major INTEGER, Advisor INTEGER, city_code VARCHAR(3) ) CREATE TABLE Allergy_Type ( Allergy VARCHAR(20), AllergyType VARCHAR(20) ) CREATE TABLE Has_Allergy ( StuID INTEGER, Allergy VARCHAR(20) )
SELECT founding_date FROM table_2538117_7 WHERE letters = "ΚΨΚ"
What is the founding date if the letters are κψκ?
CREATE TABLE table_2538117_7 (founding_date VARCHAR, letters VARCHAR)
SELECT MIN(interview) FROM table_name_46 WHERE state = "oklahoma" AND swimsuit < 8.8
Tell me the lowest interview for oklahoma and swimsuit less than 8.8
CREATE TABLE table_name_46 (interview INTEGER, state VARCHAR, swimsuit VARCHAR)
SELECT All_Games, ACC_Percent FROM basketball_match
Visualize a pie chart about the proportion of All_Games and ACC_Percent.
CREATE TABLE basketball_match ( Team_ID int, School_ID int, Team_Name text, ACC_Regular_Season text, ACC_Percent text, ACC_Home text, ACC_Road text, All_Games text, All_Games_Percent int, All_Home text, All_Road text, All_Neutral text ) CREATE TABLE university ( School_ID int, School text, Location text, Founded real, Affiliation text, Enrollment real, Nickname text, Primary_conference text )
SELECT founding_date FROM table_2538117_7 WHERE founding_university = "Washington, D.C."
If the founding university is in Washington, D.C., what was the founding date?
CREATE TABLE table_2538117_7 (founding_date VARCHAR, founding_university VARCHAR)
SELECT SUM(evening_gown) FROM table_name_53 WHERE average = 9.06 AND swimsuit < 8.76
Tell me the sum of evening gown for average of 9.06 and swimsuit less than 8.76
CREATE TABLE table_name_53 (evening_gown INTEGER, average VARCHAR, swimsuit VARCHAR)
SELECT "Outgoing manager" FROM table_13550 WHERE "Manner of departure" = 'contract terminated' AND "Date of vacancy" = '1 september 2008'
who is the outgoing manager when the manner of departure is contract terminated and the date of vacancy is 1 september 2008?
CREATE TABLE table_13550 ( "Team" text, "Outgoing manager" text, "Manner of departure" text, "Date of vacancy" text, "Replaced by" text, "Date of appointment" text, "Position in table" text )
SELECT MIN(rank_by_average) FROM table_25391981_3 WHERE average = "22.8"
What is the rank by average for the team who averaged 22.8?
CREATE TABLE table_25391981_3 (rank_by_average INTEGER, average VARCHAR)
SELECT MAX(interview) FROM table_name_19 WHERE state = "north carolina" AND evening_gown > 7.68
Tell me the highest interview for north carolina and evening gown more than 7.68
CREATE TABLE table_name_19 (interview INTEGER, state VARCHAR, evening_gown VARCHAR)
SELECT "CVT HD" FROM table_28155 WHERE "Market" = 'Mobile'
What mobile markets have cvt hd?
CREATE TABLE table_28155 ( "Graphics" text, "Launch" real, "Market" text, "CPU" text, "Code name" text, "Device ID" real, "Core clock ( MHz )" text, "Execution units" real, "Shader model" text, "DirectX" text, "OpenGL" text, "OpenCL" text, "Memory bandwidth ( GB/s )" text, "DVMT ( MB )" real, "CVT HD" text, "QSV" text )
SELECT number_of_dances FROM table_25391981_3 WHERE average = "20.6"
What is the number of dances for the team that averages 20.6?
CREATE TABLE table_25391981_3 (number_of_dances VARCHAR, average VARCHAR)
SELECT ncaa_tourn_appearances FROM table_name_3 WHERE conference_titles > "0" AND ncaa_titles = "0" AND coach = "lou watson"
Which NCAA Tournament Appearances have Conference Titles that are larger than 0, NCAA Titles of 0, and were coached by Lou Watson?
CREATE TABLE table_name_3 (ncaa_tourn_appearances VARCHAR, coach VARCHAR, conference_titles VARCHAR, ncaa_titles VARCHAR)
SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.admission_type = "ELECTIVE" AND demographic.admityear < "2197"
Give the number of patients who were admitted before the year 2197 and had admission type as elective.
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 ) CREATE TABLE lab ( subject_id text, hadm_id text, itemid text, charttime text, flag text, value_unit text, label text, fluid text ) 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 )
SELECT couple FROM table_25391981_3 WHERE average = "15.5"
What couple averaged 15.5?
CREATE TABLE table_25391981_3 (couple VARCHAR, average VARCHAR)
SELECT category FROM table_name_92 WHERE year = 2012 AND award = "drama league award"
Tell me the category for 2012 and drama league award
CREATE TABLE table_name_92 (category VARCHAR, year VARCHAR, award VARCHAR)
SELECT "First season" FROM table_73053 WHERE "Home ground(s)" = 'Hillcrest Reserve'
What is the dates where Hillcrest Reserve is the home grounds?
CREATE TABLE table_73053 ( "Name" text, "Nickname" text, "First season" text, "Location" text, "Home ground(s)" text, "Coach" text, "Captain" text )
SELECT italian FROM table_25401_15 WHERE english = "part"
What is every value for Italian when the part is English?
CREATE TABLE table_25401_15 (italian VARCHAR, english VARCHAR)