question
stringlengths
12
244
context
stringlengths
27
489
answer
stringlengths
18
557
What is the last year on this list someone was first elected?
CREATE TABLE table_1342451_38 (first_elected INTEGER)
SELECT MAX(first_elected) FROM table_1342451_38
How many episodes have the Netflix episode number S08E04?
CREATE TABLE table_15187735_15 (episode VARCHAR, netflix VARCHAR)
SELECT COUNT(episode) FROM table_15187735_15 WHERE netflix = "S08E04"
What is the sum of Avg/G for Dan Dierking when the Loss is 0 and the Gain is more than 34?
CREATE TABLE table_name_95 (avg_g INTEGER, gain VARCHAR, loss VARCHAR, name VARCHAR)
SELECT SUM(avg_g) FROM table_name_95 WHERE loss = 0 AND name = "dan dierking" AND gain > 34
who is the author when the title is destination: nerva?
CREATE TABLE table_name_73 (author VARCHAR, title VARCHAR)
SELECT author FROM table_name_73 WHERE title = "destination: nerva"
What was the box score for the game where the away team was the sydney spirit?
CREATE TABLE table_name_40 (Box VARCHAR, away_team VARCHAR)
SELECT Box AS score FROM table_name_40 WHERE away_team = "sydney spirit"
Who is Gene Felton's TO Winning Team?
CREATE TABLE table_13657749_2 (to_winning_team VARCHAR, gto_winning_team VARCHAR)
SELECT to_winning_team FROM table_13657749_2 WHERE gto_winning_team = "Gene Felton"
What is the number of floors for the Citic Square?
CREATE TABLE table_name_10 (floors INTEGER, name VARCHAR)
SELECT AVG(floors) FROM table_name_10 WHERE name = "citic square"
What is the record of the game where the visitor team is the Edmonton Oilers?
CREATE TABLE table_name_50 (record VARCHAR, visitor VARCHAR)
SELECT record FROM table_name_50 WHERE visitor = "edmonton oilers"
Studio host of jimmy myers had what play by play?
CREATE TABLE table_name_80 (play_by_play VARCHAR, studio_host VARCHAR)
SELECT play_by_play FROM table_name_80 WHERE studio_host = "jimmy myers"
how many airports are there in each country?
CREATE TABLE airport (country VARCHAR)
SELECT COUNT(*), country FROM airport GROUP BY country
When did grid 8 finish?
CREATE TABLE table_name_66 (time_retired VARCHAR, grid VARCHAR)
SELECT time_retired FROM table_name_66 WHERE grid = 8
Who was the General Classification awardee if Sergio Luis Henao was the winner and the Points Classification award was given to Sergio Luis Henao?
CREATE TABLE table_28853064_15 (general_classification VARCHAR, winner VARCHAR, points_classification VARCHAR)
SELECT general_classification FROM table_28853064_15 WHERE winner = "Sergio Luis Henao" AND points_classification = "Sergio Luis Henao"
Name the archive for run time of 23:55
CREATE TABLE table_2102782_1 (archive VARCHAR, run_time VARCHAR)
SELECT archive FROM table_2102782_1 WHERE run_time = "23:55"
What is the lowest Killed, when Perpetrator is "Sherrill, Patrick Henry , 44"?
CREATE TABLE table_name_93 (killed INTEGER, perpetrator VARCHAR)
SELECT MIN(killed) FROM table_name_93 WHERE perpetrator = "sherrill, patrick henry , 44"
in which class was the ohio state university
CREATE TABLE table_19897896_7 (class VARCHAR, university VARCHAR)
SELECT class FROM table_19897896_7 WHERE university = "Ohio state"
Name the crew chief for rhonda thorson
CREATE TABLE table_24535095_2 (crew_chief VARCHAR, listed_owner_s_ VARCHAR)
SELECT crew_chief FROM table_24535095_2 WHERE listed_owner_s_ = "Rhonda Thorson"
Which team was the opponent on December 30?
CREATE TABLE table_name_17 (team VARCHAR, date VARCHAR)
SELECT team FROM table_name_17 WHERE date = "december 30"
Who was the player in 1981?
CREATE TABLE table_name_67 (player VARCHAR, year VARCHAR)
SELECT player FROM table_name_67 WHERE year = "1981"
Find the name and rank points of the winner who won the most times.
CREATE TABLE matches (winner_name VARCHAR, winner_rank_points VARCHAR)
SELECT winner_name, winner_rank_points FROM matches GROUP BY winner_name ORDER BY COUNT(*) DESC LIMIT 1
What is the total points in 1974?
CREATE TABLE table_name_47 (points VARCHAR, year VARCHAR)
SELECT COUNT(points) FROM table_name_47 WHERE year = 1974
What was the attendance at the Fitzroy home game?
CREATE TABLE table_name_36 (crowd INTEGER, home_team VARCHAR)
SELECT SUM(crowd) FROM table_name_36 WHERE home_team = "fitzroy"
What is the height in inches of contestants who are from the province of La Rioja?
CREATE TABLE table_23476629_2 (height__in_ VARCHAR, province VARCHAR)
SELECT height__in_ FROM table_23476629_2 WHERE province = "La Rioja"
What is the name of the parish that has a former local authority of St Neots urban district?
CREATE TABLE table_name_71 (name VARCHAR, former_local_authority VARCHAR)
SELECT name FROM table_name_71 WHERE former_local_authority = "st neots urban district"
What isssue has 7th heaven as an actual title?
CREATE TABLE table_name_51 (issue VARCHAR, actual_title VARCHAR)
SELECT issue FROM table_name_51 WHERE actual_title = "7th heaven"
How many runs did mahela jayawardene and thilan samaraweera have?
CREATE TABLE table_name_82 (runs INTEGER, batting_partners VARCHAR)
SELECT SUM(runs) FROM table_name_82 WHERE batting_partners = "mahela jayawardene and thilan samaraweera"
Name the total number of years for chassis of ensign n175
CREATE TABLE table_name_2 (year VARCHAR, chassis VARCHAR)
SELECT COUNT(year) FROM table_name_2 WHERE chassis = "ensign n175"
I want the lowest points for tries of 39 and goals more than 0
CREATE TABLE table_name_1 (points INTEGER, tries VARCHAR, goals VARCHAR)
SELECT MIN(points) FROM table_name_1 WHERE tries = 39 AND goals > 0
Tell me the country for ICAO of tjig
CREATE TABLE table_name_84 (country VARCHAR, icao VARCHAR)
SELECT country FROM table_name_84 WHERE icao = "tjig"
when changsha 長沙 is the commandery what is the commandery capital?
CREATE TABLE table_278229_1 (commandery VARCHAR)
SELECT commandery AS capital FROM table_278229_1 WHERE commandery = "Changsha 長沙"
What is the lowest number of bronze medals for Great Britain with more than 2 medals total?
CREATE TABLE table_name_71 (bronze INTEGER, nation VARCHAR, total VARCHAR)
SELECT MIN(bronze) FROM table_name_71 WHERE nation = "great britain" AND total > 2
Which region has Stanford University as host?
CREATE TABLE table_name_12 (region VARCHAR, host VARCHAR)
SELECT region FROM table_name_12 WHERE host = "stanford university"
When 2 is the k-band what is the v-band?
CREATE TABLE table_186468_1 (v_band VARCHAR, k_band VARCHAR)
SELECT v_band FROM table_186468_1 WHERE k_band = "2"
Which stadium is managed by Kari Martonen?
CREATE TABLE table_25129482_1 (stadium VARCHAR, manager VARCHAR)
SELECT stadium FROM table_25129482_1 WHERE manager = "Kari Martonen"
What home team has a score of 2–1, when the away team was Telford United?
CREATE TABLE table_name_10 (home_team VARCHAR, score VARCHAR, away_team VARCHAR)
SELECT home_team FROM table_name_10 WHERE score = "2–1" AND away_team = "telford united"
Who was in Academic & University Affairs when Andrew Langille was in local affairs?
CREATE TABLE table_name_72 (academic_ VARCHAR, _university_affairs VARCHAR, local_affairs VARCHAR)
SELECT academic_ & _university_affairs FROM table_name_72 WHERE local_affairs = "andrew langille"
What's the name of Channel 29 (UHF)?
CREATE TABLE table_name_65 (name VARCHAR, channel___bkk__ VARCHAR)
SELECT name FROM table_name_65 WHERE channel___bkk__ = "29 (uhf)"
Find the name of players whose card is yes in the descending order of training hours.
CREATE TABLE Player (pName VARCHAR, yCard VARCHAR, HS VARCHAR)
SELECT pName FROM Player WHERE yCard = 'yes' ORDER BY HS DESC
What player has a span of 1997-2009?
CREATE TABLE table_name_54 (player VARCHAR, span VARCHAR)
SELECT player FROM table_name_54 WHERE span = "1997-2009"
Which nation won 29 gold medals?
CREATE TABLE table_name_3 (nation VARCHAR, gold VARCHAR)
SELECT nation FROM table_name_3 WHERE gold = 29
Which lane did the swimmer who had a Reaction time of 0.185 and a time of 20.9 swim in?
CREATE TABLE table_name_15 (lane INTEGER, react VARCHAR, time VARCHAR)
SELECT SUM(lane) FROM table_name_15 WHERE react = 0.185 AND time < 20.9
Who was the opponent on June 29?
CREATE TABLE table_name_86 (opponent VARCHAR, date VARCHAR)
SELECT opponent FROM table_name_86 WHERE date = "june 29"
What shows for the League when the FA Cup is 6 (20)?
CREATE TABLE table_name_47 (league_a VARCHAR, fa_cup VARCHAR)
SELECT league_a FROM table_name_47 WHERE fa_cup = "6 (20)"
What was the Attendance before Week 17 with a Record of Bye?
CREATE TABLE table_name_77 (attendance VARCHAR, week VARCHAR, record VARCHAR)
SELECT attendance FROM table_name_77 WHERE week < 17 AND record = "bye"
Who drove the grid 11 car?
CREATE TABLE table_name_43 (driver VARCHAR, grid VARCHAR)
SELECT driver FROM table_name_43 WHERE grid = 11
Which vocal type has the band mate with last name "Heilo" played the most?
CREATE TABLE vocals (bandmate VARCHAR); CREATE TABLE band (id VARCHAR)
SELECT TYPE FROM vocals AS T1 JOIN band AS T2 ON T1.bandmate = T2.id WHERE lastname = "Heilo" GROUP BY TYPE ORDER BY COUNT(*) DESC LIMIT 1
What is the name of the episode directed by Miguel Arteta?
CREATE TABLE table_2182654_3 (title VARCHAR, directed_by VARCHAR)
SELECT title FROM table_2182654_3 WHERE directed_by = "Miguel Arteta"
Name the number of shows when there was 2 million views
CREATE TABLE table_13336122_6 (us_viewers__million_ VARCHAR, no_in_season VARCHAR)
SELECT COUNT(us_viewers__million_) FROM table_13336122_6 WHERE no_in_season = 2
What was the date for Game 41?
CREATE TABLE table_name_33 (date VARCHAR, game VARCHAR)
SELECT date FROM table_name_33 WHERE game = "41"
Tell me the constellation which has a right ascension of 18h17m41.1s
CREATE TABLE table_name_54 (constellation VARCHAR, right_ascension___j2000__ VARCHAR)
SELECT constellation FROM table_name_54 WHERE right_ascension___j2000__ = "18h17m41.1s"
Find the name of the dorm with the largest capacity.
CREATE TABLE dorm (dorm_name VARCHAR, student_capacity VARCHAR)
SELECT dorm_name FROM dorm ORDER BY student_capacity DESC LIMIT 1
What is the highest water (sq mi) of the township glenila, which has more than 33.576 sq mi of land and a latitude greater than 48.832189?
CREATE TABLE table_name_91 (water__sqmi_ INTEGER, latitude VARCHAR, land___sqmi__ VARCHAR, township VARCHAR)
SELECT MAX(water__sqmi_) FROM table_name_91 WHERE land___sqmi__ > 33.576 AND township = "glenila" AND latitude > 48.832189
what's the party with opponent being deborah pryce (r) 70.7% bill buckel (d) 29.1%
CREATE TABLE table_1341522_38 (party VARCHAR, opponent VARCHAR)
SELECT party FROM table_1341522_38 WHERE opponent = "Deborah Pryce (R) 70.7% Bill Buckel (D) 29.1%"
Which location was won by George Heath?
CREATE TABLE table_name_15 (location VARCHAR, driver VARCHAR)
SELECT location FROM table_name_15 WHERE driver = "george heath"
What team has a player from Santa Clara?
CREATE TABLE table_name_82 (team VARCHAR, college VARCHAR)
SELECT team FROM table_name_82 WHERE college = "santa clara"
What was the location and attendance for game 60?
CREATE TABLE table_17121262_9 (location_attendance VARCHAR, game VARCHAR)
SELECT location_attendance FROM table_17121262_9 WHERE game = 60
What is the name of the race from round 1?
CREATE TABLE table_name_90 (race_name VARCHAR, round VARCHAR)
SELECT race_name FROM table_name_90 WHERE round = 1
What country has a total of 293?
CREATE TABLE table_name_37 (country VARCHAR, total VARCHAR)
SELECT country FROM table_name_37 WHERE total = 293
What are the earpads of the headphone with a plastic construction, an unknown sensitivity, and was succeeded by sr325?
CREATE TABLE table_name_43 (earpads VARCHAR, succeeded_by VARCHAR, construction VARCHAR, sensitivity__db_ VARCHAR)
SELECT earpads FROM table_name_43 WHERE construction = "plastic" AND sensitivity__db_ = "unknown" AND succeeded_by = "sr325"
What is the to par that has macdonald smith as the player?
CREATE TABLE table_name_41 (to_par VARCHAR, player VARCHAR)
SELECT to_par FROM table_name_41 WHERE player = "macdonald smith"
Which exaltation has a fall of moon?
CREATE TABLE table_name_21 (exaltation VARCHAR, fall VARCHAR)
SELECT exaltation FROM table_name_21 WHERE fall = "moon"
What player had a pick higher than 53, and a position of defensive tackle?
CREATE TABLE table_name_35 (player VARCHAR, pick VARCHAR, position VARCHAR)
SELECT player FROM table_name_35 WHERE pick > 53 AND position = "defensive tackle"
What is the number of gold for the country ranked 19?
CREATE TABLE table_name_19 (gold INTEGER, rank VARCHAR)
SELECT SUM(gold) FROM table_name_19 WHERE rank = "19"
What's the name of Linroy Bottoson's victim?
CREATE TABLE table_23546266_1 (victim_s_ VARCHAR, executed_person VARCHAR)
SELECT victim_s_ FROM table_23546266_1 WHERE executed_person = "Linroy Bottoson"
how many is the minimum for citv
CREATE TABLE table_1397655_1 (year_acquired INTEGER, station VARCHAR)
SELECT MIN(year_acquired) FROM table_1397655_1 WHERE station = "CITV"
What is the date of the Last Performance of Rarmian Newton as Billy Elliot?
CREATE TABLE table_name_3 (last_performance VARCHAR, name VARCHAR)
SELECT last_performance FROM table_name_3 WHERE name = "rarmian newton"
Which airport has SEB as its IATA code?
CREATE TABLE table_name_86 (airport VARCHAR, iata VARCHAR)
SELECT airport FROM table_name_86 WHERE iata = "seb"
What premieres had a finale on May 25, 2004?
CREATE TABLE table_175980_2 (premiere VARCHAR, finale VARCHAR)
SELECT premiere FROM table_175980_2 WHERE finale = "May 25, 2004"
What was the score when the Rangers' attendance was 23,493?
CREATE TABLE table_name_70 (score VARCHAR, attendance VARCHAR)
SELECT score FROM table_name_70 WHERE attendance = "23,493"
Find the number of students whose city code is NYC and who have class senator votes in the spring election cycle.
CREATE TABLE STUDENT (StuID VARCHAR, city_code VARCHAR); CREATE TABLE VOTING_RECORD (Election_Cycle VARCHAR)
SELECT COUNT(*) FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID = Class_Senator_Vote WHERE T1.city_code = "NYC" AND T2.Election_Cycle = "Spring"
Can you tell me the Player that has the Country of united states, and the Score of 77-72-72=221?
CREATE TABLE table_name_68 (player VARCHAR, country VARCHAR, score VARCHAR)
SELECT player FROM table_name_68 WHERE country = "united states" AND score = 77 - 72 - 72 = 221
What year was yellow jersey of Jacques Anquetil?
CREATE TABLE table_name_66 (year INTEGER, yellow_jersey VARCHAR)
SELECT MIN(year) FROM table_name_66 WHERE yellow_jersey = "jacques anquetil"
How many farmers were included by the department with 32 projects?
CREATE TABLE table_17118006_2 (farmers INTEGER, projects VARCHAR)
SELECT MAX(farmers) FROM table_17118006_2 WHERE projects = 32
When did the king who entered office in 1012 leave office?
CREATE TABLE table_name_34 (left_office VARCHAR, entered_office VARCHAR)
SELECT left_office FROM table_name_34 WHERE entered_office = "1012"
Name the head of household for married filing jointly or qualified widow(er) being $137,051–$208,850
CREATE TABLE table_name_32 (head_of_household VARCHAR, married_filing_jointly_or_qualified_widow_er_ VARCHAR)
SELECT head_of_household FROM table_name_32 WHERE married_filing_jointly_or_qualified_widow_er_ = "$137,051–$208,850"
what are the maximum f/laps?
CREATE TABLE table_26178824_1 (f_laps INTEGER)
SELECT MAX(f_laps) FROM table_26178824_1
What is the location of the track that opened in 1950?
CREATE TABLE table_1245148_1 (location VARCHAR, year_opened VARCHAR)
SELECT location FROM table_1245148_1 WHERE year_opened = 1950
What are the id and zip code of the address with the highest monthly rental?
CREATE TABLE Student_Addresses (address_id VARCHAR); CREATE TABLE Addresses (zip_postcode VARCHAR, address_id VARCHAR)
SELECT T2.address_id, T1.zip_postcode FROM Addresses AS T1 JOIN Student_Addresses AS T2 ON T1.address_id = T2.address_id ORDER BY monthly_rental DESC LIMIT 1
What country has chunkath, mohan verghese as the name?
CREATE TABLE table_name_88 (country VARCHAR, name VARCHAR)
SELECT country FROM table_name_88 WHERE name = "chunkath, mohan verghese"
Tell me the position in 2012-13 and number of seasons in leigue 1 of 30 with ligue 1 titles of 1
CREATE TABLE table_name_69 (position_in_2012_13 VARCHAR, number_of_seasons_in_ligue_1 VARCHAR, ligue_1_titles VARCHAR)
SELECT position_in_2012_13 FROM table_name_69 WHERE number_of_seasons_in_ligue_1 = 30 AND ligue_1_titles = 1
What is the average year that the Belanger Motors had an Offenhauser l4 engine?
CREATE TABLE table_name_8 (year INTEGER, engine VARCHAR, entrant VARCHAR)
SELECT AVG(year) FROM table_name_8 WHERE engine = "offenhauser l4" AND entrant = "belanger motors"
What is the soccer stadium with the varsity name is citadins?
CREATE TABLE table_27369069_4 (soccer_stadium VARCHAR, varsity_name VARCHAR)
SELECT soccer_stadium FROM table_27369069_4 WHERE varsity_name = "Citadins"
Who was the incumbent that retired to run for the senate democratic hold?
CREATE TABLE table_name_82 (incumbent VARCHAR, result VARCHAR)
SELECT incumbent FROM table_name_82 WHERE result = "retired to run for the senate democratic hold"
What is the total when the gold of 0, and a bronze larger than 1?
CREATE TABLE table_name_25 (total INTEGER, gold VARCHAR, bronze VARCHAR)
SELECT MAX(total) FROM table_name_25 WHERE gold = 0 AND bronze > 1
When 2008 t is the original number what is the lowest year?
CREATE TABLE table_21795986_1 (year INTEGER, original_number VARCHAR)
SELECT MIN(year) FROM table_21795986_1 WHERE original_number = "2008 T"
What is the home team with scarborough as the away team?
CREATE TABLE table_name_50 (home_team VARCHAR, away_team VARCHAR)
SELECT home_team FROM table_name_50 WHERE away_team = "scarborough"
How many points did the song with a draw number 3 get?
CREATE TABLE table_20183474_1 (total_points VARCHAR, draw VARCHAR)
SELECT total_points FROM table_20183474_1 WHERE draw = 3
What is the highest number of bronzes for teams ranked number 7 with more than 0 silver?
CREATE TABLE table_name_77 (bronze INTEGER, silver VARCHAR, rank VARCHAR)
SELECT MAX(bronze) FROM table_name_77 WHERE silver > 0 AND rank = 7
Which country has a to par of +2 for Bernhard Langer?
CREATE TABLE table_name_3 (country VARCHAR, to_par VARCHAR, player VARCHAR)
SELECT country FROM table_name_3 WHERE to_par = "+2" AND player = "bernhard langer"
I want to know the total number of national university of ireland with agricultural panel of 0 and labour panel more than 0
CREATE TABLE table_name_34 (national_university_of_ireland VARCHAR, agricultural_panel VARCHAR, labour_panel VARCHAR)
SELECT COUNT(national_university_of_ireland) FROM table_name_34 WHERE agricultural_panel = 0 AND labour_panel > 0
How many appointed archbishops were ordained as priests on December 20, 1959
CREATE TABLE table_1656555_1 (Appointed VARCHAR, ordained_priest VARCHAR)
SELECT COUNT(Appointed) AS archbishop FROM table_1656555_1 WHERE ordained_priest = "December 20, 1959"
Dallas Burn's draft pick was which position?
CREATE TABLE table_26141160_2 (position VARCHAR, team VARCHAR)
SELECT position FROM table_26141160_2 WHERE team = "Dallas Burn"
What is Top Par, when Score is less than 68, and when Country is England?
CREATE TABLE table_name_58 (to_par VARCHAR, score VARCHAR, country VARCHAR)
SELECT to_par FROM table_name_58 WHERE score < 68 AND country = "england"
What were the least points with a Coloni FC88 chassis?
CREATE TABLE table_name_43 (points INTEGER, chassis VARCHAR)
SELECT MIN(points) FROM table_name_43 WHERE chassis = "coloni fc88"
Which Fuel Propulsion has a Fleet Series (Quantity) of 04001-04125 (125)?
CREATE TABLE table_name_73 (fuel_propulsion VARCHAR, fleet_series__quantity_ VARCHAR)
SELECT fuel_propulsion FROM table_name_73 WHERE fleet_series__quantity_ = "04001-04125 (125)"
What is the college when the over is larger than 15 in round 7?
CREATE TABLE table_name_41 (college VARCHAR, overall VARCHAR, round VARCHAR)
SELECT college FROM table_name_41 WHERE overall > 15 AND round = 7
What's the season number of the episode viewed by 3.19 million people in the US?
CREATE TABLE table_18268826_1 (no_in_season INTEGER, us_viewers__million_ VARCHAR)
SELECT MAX(no_in_season) FROM table_18268826_1 WHERE us_viewers__million_ = "3.19"
What is the name of the player from Vanderbilt University?
CREATE TABLE table_name_43 (player VARCHAR, school VARCHAR)
SELECT player FROM table_name_43 WHERE school = "vanderbilt university"
I want the tournament for 1889
CREATE TABLE table_name_76 (tournament VARCHAR, year VARCHAR)
SELECT tournament FROM table_name_76 WHERE year = 1889
What were the television air dates for the series that had a production start date of June 16?
CREATE TABLE table_1949994_8 (premiere_air_dates VARCHAR, start_date VARCHAR)
SELECT premiere_air_dates FROM table_1949994_8 WHERE start_date = "June 16"
Who wrote series number 99?
CREATE TABLE table_name_68 (written_by VARCHAR, series__number VARCHAR)
SELECT written_by FROM table_name_68 WHERE series__number = 99