answer
stringlengths
18
557
question
stringlengths
12
244
context
stringlengths
27
489
SELECT fastest_lap FROM table_19850806_3 WHERE race = "Texas" AND winning_driver = "Dario Franchitti"
Who held the fastest lap in the race in texas and dario franchitti is the winning driver?
CREATE TABLE table_19850806_3 (fastest_lap VARCHAR, race VARCHAR, winning_driver VARCHAR)
SELECT COUNT(result) FROM table_1360997_2 WHERE race = "Stan Fox Stakes"
How many results were there for the Stan Fox Stakes race?
CREATE TABLE table_1360997_2 (result VARCHAR, race VARCHAR)
SELECT postseason FROM table_name_54 WHERE win_percentage > 0.40700000000000003 AND games < 108 AND rank = 1
What postseason has a win% between 0.40700000000000003 and 108 with a rank of 1?
CREATE TABLE table_name_54 (postseason VARCHAR, rank VARCHAR, win_percentage VARCHAR, games VARCHAR)
SELECT COUNT(pos) FROM table_19412902_1 WHERE member_association = "Saudi Arabia"
how many posiitions did saudi arabia land on
CREATE TABLE table_19412902_1 (pos VARCHAR, member_association VARCHAR)
SELECT date FROM table_name_99 WHERE label = "4ad" AND format = "cd (reissue)"
What date had a 4ad label and a CD (reissue) format?
CREATE TABLE table_name_99 (date VARCHAR, label VARCHAR, format VARCHAR)
SELECT COUNT(wins) FROM table_name_29 WHERE losses > 980 AND first_season < 1906 AND college = "washington state" AND rank > 42
How many wins were there for Washington State College with losses greater than 980 and a first season before 1906 and rank greater than 42?
CREATE TABLE table_name_29 (wins VARCHAR, rank VARCHAR, college VARCHAR, losses VARCHAR, first_season VARCHAR)
SELECT 1976 FROM table_name_67 WHERE tournament = "overall win – loss"
What 1976 has a Tournament of overall win – loss?
CREATE TABLE table_name_67 (tournament VARCHAR)
SELECT MAX(played) FROM table_name_6 WHERE goals_against > 60 AND losses < 29
When goals against is greater than 60 and losses less than 29, what is the highest played?
CREATE TABLE table_name_6 (played INTEGER, goals_against VARCHAR, losses VARCHAR)
SELECT SUM(apps) FROM table_name_30 WHERE club = "flamengo" AND season = "2009" AND goals > 0
When the club is flamengo in the 2009 season, and they scored more than 0 goals, what's the sum of the Apps?
CREATE TABLE table_name_30 (apps INTEGER, goals VARCHAR, club VARCHAR, season VARCHAR)
SELECT MAX(laps) FROM table_name_24 WHERE time_retired = "+2 laps" AND driver = "felice bonetto"
Tell me the highest laps for time/retired of +2 laps and driver of felice bonetto
CREATE TABLE table_name_24 (laps INTEGER, time_retired VARCHAR, driver VARCHAR)
SELECT name FROM station WHERE lat < 37.5
What are the names of stations that have latitude lower than 37.5?
CREATE TABLE station (name VARCHAR, lat INTEGER)
SELECT COUNT(knots) FROM table_name_11 WHERE ship = "ms moby vincent" AND passengers < 1.6
How many knots did the Ms Moby Vincent have when passengers was less than 1.6?
CREATE TABLE table_name_11 (knots VARCHAR, ship VARCHAR, passengers VARCHAR)
SELECT club FROM table_name_32 WHERE number_of_seasons_in_liga_mx < 40 AND number_of_seasons_in_top_division = 65
Which club has fewer than 40 seasons in Liga MX and 65 seasons in the top division?
CREATE TABLE table_name_32 (club VARCHAR, number_of_seasons_in_liga_mx VARCHAR, number_of_seasons_in_top_division VARCHAR)
SELECT COUNT(rank) FROM table_name_82 WHERE games = 25 AND team = "maccabi tel aviv"
What is the Rank of the Maccabi Tel Aviv Player with 25 Games?
CREATE TABLE table_name_82 (rank VARCHAR, games VARCHAR, team VARCHAR)
SELECT pos FROM table_name_52 WHERE date_of_birth = "1976-09-20"
What is the position played by the man born on 1976-09-20?
CREATE TABLE table_name_52 (pos VARCHAR, date_of_birth VARCHAR)
SELECT rank___number_ FROM table_11274401_2 WHERE viewers__m_ = "2.65"
How did the episode rank that had 2.65 million viewers?
CREATE TABLE table_11274401_2 (rank___number_ VARCHAR, viewers__m_ VARCHAR)
SELECT MIN(score) FROM table_name_79 WHERE place = "t10" AND country = "ireland"
What is the lowest score that has t10 as the place, with Ireland as the country?
CREATE TABLE table_name_79 (score INTEGER, place VARCHAR, country VARCHAR)
SELECT 1989 FROM table_name_10 WHERE 1997 = "qf" AND 1993 = "a"
What was the value in 1989 with QF in 1997 and A in 1993?
CREATE TABLE table_name_10 (Id VARCHAR)
SELECT constructor FROM table_name_10 WHERE driver = "david coulthard"
Tell me the constructor for david coulthard
CREATE TABLE table_name_10 (constructor VARCHAR, driver VARCHAR)
SELECT site FROM table_name_44 WHERE date = "october 7"
WHAT IS THE SITE ON OCTOBER 7?
CREATE TABLE table_name_44 (site VARCHAR, date VARCHAR)
SELECT MIN(population) FROM table_name_17 WHERE city = "kragerø"
What is the population of Kragerø?
CREATE TABLE table_name_17 (population INTEGER, city VARCHAR)
SELECT date FROM table_name_46 WHERE competition = "2011 lg cup"
On what Date was the 2011 LG Cup Competittion?
CREATE TABLE table_name_46 (date VARCHAR, competition VARCHAR)
SELECT away_team FROM table_name_81 WHERE venue = "junction oval"
Who was the away team at junction oval?
CREATE TABLE table_name_81 (away_team VARCHAR, venue VARCHAR)
SELECT AVG(year) FROM table_name_16 WHERE venue = "bokskogens"
What was the average year that the venue was Bokskogens?
CREATE TABLE table_name_16 (year INTEGER, venue VARCHAR)
SELECT venue FROM table_name_6 WHERE result = "won 5-0"
Where was the game with a result of won 5-0?
CREATE TABLE table_name_6 (venue VARCHAR, result VARCHAR)
SELECT fixed_charge___rs__kwh_ FROM table_25479607_3 WHERE tariff___rs__kwh_ = "11.30"
What is the fixed charge for the user who had a tariff of 11.30?
CREATE TABLE table_25479607_3 (fixed_charge___rs__kwh_ VARCHAR, tariff___rs__kwh_ VARCHAR)
SELECT class AS pos FROM table_name_73 WHERE pos = "4th"
What was the class position of the team that was in the 4th position?
CREATE TABLE table_name_73 (class VARCHAR, pos VARCHAR)
SELECT losing_bp FROM table_name_14 WHERE lost = "19" AND club = "newport saracens rfc"
Name the Losing BP of Newport Saracens RFC and has a Lost of 19.
CREATE TABLE table_name_14 (losing_bp VARCHAR, lost VARCHAR, club VARCHAR)
SELECT kerry_number FROM table_1302886_1 WHERE bush_number = 3907
When bush# is 3907, what is Kerry#?
CREATE TABLE table_1302886_1 (kerry_number VARCHAR, bush_number VARCHAR)
SELECT chassis FROM table_name_59 WHERE entrant = "team lotus" AND year > 1964
What chassis did team lotus use after 1964?
CREATE TABLE table_name_59 (chassis VARCHAR, entrant VARCHAR, year VARCHAR)
SELECT opponent FROM table_name_97 WHERE week < 11 AND date = "october 31, 1976"
Who was the opponent of the game before week 11 on October 31, 1976?
CREATE TABLE table_name_97 (opponent VARCHAR, week VARCHAR, date VARCHAR)
SELECT MAX(position) FROM table_name_28 WHERE wins = 4 AND points < 11
What was the highest position when the wins were higher than 4 and the points were lower than 11?
CREATE TABLE table_name_28 (position INTEGER, wins VARCHAR, points VARCHAR)
SELECT COUNT(*) FROM Faculty AS T1 JOIN Faculty_participates_in AS T2 ON T1.facID = T2.facID WHERE T1.fname = "Mark" AND T1.lname = "Giuliano"
How many activities does Mark Giuliano participate in?
CREATE TABLE Faculty_participates_in (facID VARCHAR); CREATE TABLE Faculty (facID VARCHAR, fname VARCHAR, lname VARCHAR)
SELECT name FROM table_name_41 WHERE city = "santiago"
Who has the city Santiago?
CREATE TABLE table_name_41 (name VARCHAR, city VARCHAR)
SELECT MAX(year) FROM table_name_38 WHERE result = "nominated" AND nominee_s_ = "neal baer"
What is the latest year when Neal Baer was a nominee, and the result was nominated?
CREATE TABLE table_name_38 (year INTEGER, result VARCHAR, nominee_s_ VARCHAR)
SELECT title FROM table_name_11 WHERE rank < 17 AND worldwide_gross = "$299,288,605"
what is the title when the rank is less than 17 and the worldwide gross is $299,288,605?
CREATE TABLE table_name_11 (title VARCHAR, rank VARCHAR, worldwide_gross VARCHAR)
SELECT MIN(s_spoilt_vote) FROM table_15082102_3 WHERE electorate = 83850
in electorate of 83850 what is the minimum s split vote
CREATE TABLE table_15082102_3 (s_spoilt_vote INTEGER, electorate VARCHAR)
SELECT school FROM table_name_63 WHERE year_left = "1992"
From what school was the team that left the conference in 1992?
CREATE TABLE table_name_63 (school VARCHAR, year_left VARCHAR)
SELECT date FROM table_name_70 WHERE visiting_team = "new york giants" AND final_score = "37-34"
What is the date the new york giants were the visiting team and the Final Score was 37-34?
CREATE TABLE table_name_70 (date VARCHAR, visiting_team VARCHAR, final_score VARCHAR)
SELECT school FROM table_name_31 WHERE position = "ends"
What is the school of the player who plays ends?
CREATE TABLE table_name_31 (school VARCHAR, position VARCHAR)
SELECT MAX(sf_round) FROM table_23293785_2 WHERE country = "England"
What is the highest value for SF round for the country of England?
CREATE TABLE table_23293785_2 (sf_round INTEGER, country VARCHAR)
SELECT away_team FROM table_name_82 WHERE venue = "mcg"
Which Away team has a Venue of mcg?
CREATE TABLE table_name_82 (away_team VARCHAR, venue VARCHAR)
SELECT round FROM table_name_32 WHERE position = "defense" AND nationality = "united states"
What is the round of the defense player from the United States?
CREATE TABLE table_name_32 (round VARCHAR, position VARCHAR, nationality VARCHAR)
SELECT city FROM table_name_82 WHERE date = "october 8"
On October 8, what city was the game played?
CREATE TABLE table_name_82 (city VARCHAR, date VARCHAR)
SELECT week_5 FROM table_name_36 WHERE week_1 = "dani dior"
What is the week 5 after Dani Dior as week 1?
CREATE TABLE table_name_36 (week_5 VARCHAR, week_1 VARCHAR)
SELECT host_city FROM table_name_24 WHERE venue = "singapore indoor stadium" AND theme = "valentine's day"
What is the host city of the Singapore Indoor Stadium venue and a Valentine's Day theme?
CREATE TABLE table_name_24 (host_city VARCHAR, venue VARCHAR, theme VARCHAR)
SELECT score FROM table_name_83 WHERE player = "bert yancey"
what was the score of bert yancey
CREATE TABLE table_name_83 (score VARCHAR, player VARCHAR)
SELECT tie_no FROM table_name_53 WHERE away_team = "newcastle united"
What was the tie number for the round against visiting opponent Newcastle United?
CREATE TABLE table_name_53 (tie_no VARCHAR, away_team VARCHAR)
SELECT 2000 FROM table_name_57 WHERE 2002 = "not tier i" AND 2006 = "2r"
Which 2000 Tournament has a 2002 of not tier i, and a 2006 of 2r?
CREATE TABLE table_name_57 (Id VARCHAR)
SELECT monotone FROM table_name_41 WHERE pareto_efficiency = "yes" AND non_dictatorship = "yes" AND clone_independence = "yes"
what is the monotone when pareto efficiency is yes, non-dictatorship is yes, and clone independence is yes?
CREATE TABLE table_name_41 (monotone VARCHAR, clone_independence VARCHAR, pareto_efficiency VARCHAR, non_dictatorship VARCHAR)
SELECT score FROM table_name_12 WHERE home = "scotland" AND date = "24 february"
What's the Score with a Home of Scotland and Date of 24 February?
CREATE TABLE table_name_12 (score VARCHAR, home VARCHAR, date VARCHAR)
SELECT AVG(long) FROM table_name_18 WHERE player = "ramon richardson" AND avg > 5.5
What is the average long that Ramon Richardson played and an average greater than 5.5?
CREATE TABLE table_name_18 (long INTEGER, player VARCHAR, avg VARCHAR)
SELECT COUNT(category) FROM table_1942366_9 WHERE STRUCT(low) = "35.5"
In how many different categories is the value of C_{low} 35.5?
CREATE TABLE table_1942366_9 (category VARCHAR, low VARCHAR)
SELECT away_team FROM table_name_8 WHERE home_team = "south melbourne"
Who was South Melbourne's away team opponent?
CREATE TABLE table_name_8 (away_team VARCHAR, home_team VARCHAR)
SELECT date FROM table_25572118_1 WHERE series = "EMT 9"
When emt 9 is the series what is the date?
CREATE TABLE table_25572118_1 (date VARCHAR, series VARCHAR)
SELECT result FROM table_name_26 WHERE venue = "jinan"
What is the result of the game played at Jinan?
CREATE TABLE table_name_26 (result VARCHAR, venue VARCHAR)
SELECT high_rebounds FROM table_27755603_8 WHERE date = "January 14"
Name the high rebounds for january 14
CREATE TABLE table_27755603_8 (high_rebounds VARCHAR, date VARCHAR)
SELECT MAX(laps) FROM table_name_80 WHERE time_retired = "wheel"
What is the highest Laps with a Time/Retired Wheel?
CREATE TABLE table_name_80 (laps INTEGER, time_retired VARCHAR)
SELECT total FROM table_name_33 WHERE player = "davis love iii"
What is Davis Love III's total?
CREATE TABLE table_name_33 (total VARCHAR, player VARCHAR)
SELECT MIN(year) FROM table_name_40 WHERE engine = "judd"
When is the earliest year that there's a judd engine?
CREATE TABLE table_name_40 (year INTEGER, engine VARCHAR)
SELECT employee_id, first_name, last_name, job_id FROM employees WHERE salary > (SELECT MAX(salary) FROM employees WHERE job_id = 'PU_MAN')
display the employee number, name( first name and last name ) and job title for all employees whose salary is more than any salary of those employees whose job title is PU_MAN.
CREATE TABLE employees (employee_id VARCHAR, first_name VARCHAR, last_name VARCHAR, job_id VARCHAR, salary INTEGER)
SELECT place FROM table_name_24 WHERE score = 69 - 69 = 138 AND country = "germany"
What was the place in Germany with a score of 69-69=138?
CREATE TABLE table_name_24 (place VARCHAR, country VARCHAR, score VARCHAR)
SELECT name FROM table_name_63 WHERE intra_molecular_structure = "no" AND link = "webserver" AND comparative = "no"
Which Name has an Intra-molecular structure of no, and a Link of webserver, and a Comparative of no?
CREATE TABLE table_name_63 (name VARCHAR, comparative VARCHAR, intra_molecular_structure VARCHAR, link VARCHAR)
SELECT MAX(goals_for) FROM table_name_46 WHERE position > 10 AND goal_difference < -24 AND played > 30
What is the highest goals for the position after 10, a goal difference less than -24, and played more than 30 times?
CREATE TABLE table_name_46 (goals_for INTEGER, played VARCHAR, position VARCHAR, goal_difference VARCHAR)
SELECT result FROM table_14981555_3 WHERE venue = "Ascot (UK)"
In Ascot (UK), what was the result?
CREATE TABLE table_14981555_3 (result VARCHAR, venue VARCHAR)
SELECT date_of_birth FROM Guests WHERE gender_code = "Male"
Return the date of birth for all the guests with gender code "Male".
CREATE TABLE Guests (date_of_birth VARCHAR, gender_code VARCHAR)
SELECT COUNT(p) FROM table_22683369_8 WHERE player = "Bryan Hodge"
What is bryan hodge's player number
CREATE TABLE table_22683369_8 (p VARCHAR, player VARCHAR)
SELECT road_team FROM table_name_94 WHERE home_team = "boston" AND date = "april 16"
What is the road team playing against Boston on April 16?
CREATE TABLE table_name_94 (road_team VARCHAR, home_team VARCHAR, date VARCHAR)
SELECT COUNT(DISTINCT city) FROM station
What is the number of distinct cities the stations are located at?
CREATE TABLE station (city VARCHAR)
SELECT mhra_approved FROM table_name_24 WHERE generic_name = "blonanserin"
Is Blonanserin MHRA approved?
CREATE TABLE table_name_24 (mhra_approved VARCHAR, generic_name VARCHAR)
SELECT MAX(match) FROM table_name_37 WHERE points > 18 AND draw > 1
What is the highest number of matches with more than 18 points and more than 1 draw?
CREATE TABLE table_name_37 (match INTEGER, points VARCHAR, draw VARCHAR)
SELECT track FROM table_name_64 WHERE event_name = "daytona arca 200"
At which track did the event Daytona Arca 200 take place?
CREATE TABLE table_name_64 (track VARCHAR, event_name VARCHAR)
SELECT venue FROM table_name_38 WHERE home_team = "melbourne"
Where did Melbourne play as the home team?
CREATE TABLE table_name_38 (venue VARCHAR, home_team VARCHAR)
SELECT former_county FROM table_2801185_2 WHERE district = "Great Grimsby"
What are the former counties of the Great Grimsby district?
CREATE TABLE table_2801185_2 (former_county VARCHAR, district VARCHAR)
SELECT COUNT(opponent) FROM table_23453931_5 WHERE date = "December 3"
Name the opponents for december 3
CREATE TABLE table_23453931_5 (opponent VARCHAR, date VARCHAR)
SELECT MAX(first_elected) FROM table_1342013_20 WHERE incumbent = "John W. Heselton"
John W. Heselton was first elected in what year?
CREATE TABLE table_1342013_20 (first_elected INTEGER, incumbent VARCHAR)
SELECT date FROM table_27537518_9 WHERE record = "27-28-11"
On which date was the record of 27-28-11 set?
CREATE TABLE table_27537518_9 (date VARCHAR, record VARCHAR)
SELECT lost FROM table_name_84 WHERE tries_for = "103"
How many losses were there with 103 tries for?
CREATE TABLE table_name_84 (lost VARCHAR, tries_for VARCHAR)
SELECT MIN(points) FROM table_name_90 WHERE places = "81"
What is the low point total for teams with 81 places?
CREATE TABLE table_name_90 (points INTEGER, places VARCHAR)
SELECT tie_no FROM table_name_42 WHERE home_team = "crystal palace"
What was the tie for the Crystal Palace team?
CREATE TABLE table_name_42 (tie_no VARCHAR, home_team VARCHAR)
SELECT account_id, date_account_opened, account_name, other_account_details FROM Accounts
Show the id, the date of account opened, the account name, and other account detail for all accounts.
CREATE TABLE Accounts (account_id VARCHAR, date_account_opened VARCHAR, account_name VARCHAR, other_account_details VARCHAR)
SELECT color FROM table_name_19 WHERE thai_name = "วันพฤหัสบดี"
Show the Color which has a Thai name of วันพฤหัสบดี?
CREATE TABLE table_name_19 (color VARCHAR, thai_name VARCHAR)
SELECT ret_number FROM table_name_63 WHERE records = "4"
what pitcher scored 4
CREATE TABLE table_name_63 (ret_number VARCHAR, records VARCHAR)
SELECT MIN(pick) FROM table_name_35 WHERE position = "of" AND team = "chicago white sox"
What was the lowest pick when the position was OF with the Chicago White Sox?
CREATE TABLE table_name_35 (pick INTEGER, position VARCHAR, team VARCHAR)
SELECT T1.emp_fname, T2.prof_office FROM employee AS T1 JOIN professor AS T2 ON T1.emp_num = T2.emp_num JOIN department AS T3 ON T3.dept_code = T2.dept_code WHERE T3.dept_name = 'History' AND T2.prof_high_degree = 'Ph.D.'
Find the first name and office of the professor who is in the history department and has a Ph.D. degree.
CREATE TABLE department (dept_code VARCHAR, dept_name VARCHAR); CREATE TABLE professor (prof_office VARCHAR, emp_num VARCHAR, dept_code VARCHAR, prof_high_degree VARCHAR); CREATE TABLE employee (emp_fname VARCHAR, emp_num VARCHAR)
SELECT MIN(highest_score) FROM table_name_72 WHERE dance = "quickstep" AND lowest_score < 16
What is the lowest of the Highest score for the Quickstep Dance and the Lowest score under 16?
CREATE TABLE table_name_72 (highest_score INTEGER, dance VARCHAR, lowest_score VARCHAR)
SELECT score FROM table_name_9 WHERE date = "20/6/97"
What was the score on 20/6/97?
CREATE TABLE table_name_9 (score VARCHAR, date VARCHAR)
SELECT MIN(year_s_) FROM table_1998037_9 WHERE spokesperson = "Ruslana"
What is the year when the spoksperson is Ruslana?
CREATE TABLE table_1998037_9 (year_s_ INTEGER, spokesperson VARCHAR)
SELECT MAX(week) FROM table_name_52 WHERE date = "october 4, 1992"
Which Week has a Date of october 4, 1992?
CREATE TABLE table_name_52 (week INTEGER, date VARCHAR)
SELECT home_team AS score FROM table_name_26 WHERE home_team = "south melbourne"
How many points did South Melbourne score as the home team?
CREATE TABLE table_name_26 (home_team VARCHAR)
SELECT COUNT(2) FROM table_2305948_1 WHERE country = "England"
How many times has a wrestler from the country of England wrestled in this event?
CREATE TABLE table_2305948_1 (country VARCHAR)
SELECT model FROM table_name_52 WHERE cpu_speed = "133mhz"
Which model has a CPU speed of 133mhz?
CREATE TABLE table_name_52 (model VARCHAR, cpu_speed VARCHAR)
SELECT prefecture FROM table_221398_1 WHERE number_in_map = "39"
What prefecture is listed in the map as number 39?
CREATE TABLE table_221398_1 (prefecture VARCHAR, number_in_map VARCHAR)
SELECT venue FROM table_name_97 WHERE competition = "1995 southeast asian games"
What's the venue of the 1995 Southeast Asian Games?
CREATE TABLE table_name_97 (venue VARCHAR, competition VARCHAR)
SELECT date FROM table_name_59 WHERE loss = "carman (3-12)"
Name the date with loss of carman (3-12)
CREATE TABLE table_name_59 (date VARCHAR, loss VARCHAR)
SELECT award FROM table_name_17 WHERE year > 2005 AND result = "nominated"
What is the name of the award in a year more than 2005, and the Result of nominated?
CREATE TABLE table_name_17 (award VARCHAR, year VARCHAR, result VARCHAR)
SELECT order__number FROM table_26250189_1 WHERE theme = "The Rolling Stones"
What was Katie's order number when the theme was The Rolling Stones?
CREATE TABLE table_26250189_1 (order__number VARCHAR, theme VARCHAR)
SELECT result FROM table_name_37 WHERE round = "f"
What result is found for the round that has f?
CREATE TABLE table_name_37 (result VARCHAR, round VARCHAR)
SELECT time FROM table_name_36 WHERE country = "belgium"
What is the Time of the Rowers from Belgium?
CREATE TABLE table_name_36 (time VARCHAR, country VARCHAR)
SELECT avg_speed FROM table_name_47 WHERE winning_driver = "tony stewart" AND make = "chevrolet impala"
What was the average speed of Tony Stewart's winning Chevrolet Impala?
CREATE TABLE table_name_47 (avg_speed VARCHAR, winning_driver VARCHAR, make VARCHAR)