answer
stringlengths
18
557
question
stringlengths
12
244
context
stringlengths
27
489
SELECT AVG(total) FROM table_name_32 WHERE nation = "guatemala" AND bronze < 2
Tell me the average total for guatemala and bronze less than 2
CREATE TABLE table_name_32 (total INTEGER, nation VARCHAR, bronze VARCHAR)
SELECT series FROM table_25572068_1 WHERE winning_team = "TDS Racing" AND date = "9 October"
In what series was TDS Racing the winning team on 9 October?
CREATE TABLE table_25572068_1 (series VARCHAR, winning_team VARCHAR, date VARCHAR)
SELECT SUM(played) FROM table_name_63 WHERE against > 37 AND lost = 15 AND points < 11
How much Played has an Against larger than 37, and a Lost of 15, and Points smaller than 11?
CREATE TABLE table_name_63 (played INTEGER, points VARCHAR, against VARCHAR, lost VARCHAR)
SELECT winner FROM table_22756549_1 WHERE runner_up_a = "V. A. Muthiah"
Who won when V. A. Muthiah was the runner-up?
CREATE TABLE table_22756549_1 (winner VARCHAR, runner_up_a VARCHAR)
SELECT COUNT(_percentage__1960_) FROM table_name_98 WHERE _percentage__2040_ = 3.4
What is the % (1960) of the county with a % (2040) of 3.4?
CREATE TABLE table_name_98 (_percentage__1960_ VARCHAR, _percentage__2040_ VARCHAR)
SELECT syracuse FROM table_name_51 WHERE utica = "solsville shale and sandstone"
What is Syracuse, when Utica is Solsville Shale And Sandstone?
CREATE TABLE table_name_51 (syracuse VARCHAR, utica VARCHAR)
SELECT viewers__in_millions_ FROM table_1849243_1 WHERE run_time = "23:55"
How many viewers in millions watched the episode 23:55 minutes long?
CREATE TABLE table_1849243_1 (viewers__in_millions_ VARCHAR, run_time VARCHAR)
SELECT MIN(crowd) FROM table_name_8 WHERE away_team = "fitzroy"
What is the smallest crowd with fitzroy as the home team?
CREATE TABLE table_name_8 (crowd INTEGER, away_team VARCHAR)
SELECT MIN(rank) FROM table_30058355_5
What's the best rank possible?
CREATE TABLE table_30058355_5 (rank INTEGER)
SELECT type FROM table_name_79 WHERE faith = "–" AND name = "greenway"
Faith of –, and a Name of greenway has what type?
CREATE TABLE table_name_79 (type VARCHAR, faith VARCHAR, name VARCHAR)
SELECT score FROM table_name_56 WHERE high_points = "raymond felton (32)"
Which Score has High points of raymond felton (32)?
CREATE TABLE table_name_56 (score VARCHAR, high_points VARCHAR)
SELECT wicket_partnership FROM table_name_91 WHERE season = "1928"
What was the partnership in the season of 1928
CREATE TABLE table_name_91 (wicket_partnership VARCHAR, season VARCHAR)
SELECT dudley_tuckey_medal FROM table_1165048_1 WHERE leading_goalkicker = "Scott Simister (46)"
who is the dudley tuckey medal where leading goalkicker is scott simister (46)
CREATE TABLE table_1165048_1 (dudley_tuckey_medal VARCHAR, leading_goalkicker VARCHAR)
SELECT left_bloc FROM table_name_33 WHERE socialist = "49.0%"
What is the left bloc with a 49.0% socialist?
CREATE TABLE table_name_33 (left_bloc VARCHAR, socialist VARCHAR)
SELECT nationality FROM table_name_59 WHERE lane < 4 AND rank = 4
What Nationality of the person who has a Rank of 4
CREATE TABLE table_name_59 (nationality VARCHAR, lane VARCHAR, rank VARCHAR)
SELECT opponent FROM table_name_84 WHERE time = "4:51"
Which Opponent has a Time of 4:51?
CREATE TABLE table_name_84 (opponent VARCHAR, time VARCHAR)
SELECT time FROM table_name_94 WHERE show_name = "classic hits"
When does Classic Hits air?
CREATE TABLE table_name_94 (time VARCHAR, show_name VARCHAR)
SELECT score FROM table_name_12 WHERE date = "21/07/07"
On 21/07/07, what was the score?
CREATE TABLE table_name_12 (score VARCHAR, date VARCHAR)
SELECT combined FROM table_name_93 WHERE overall = "2" AND slalom = "5"
What is the combined of 2 overalls and 5 slaloms?
CREATE TABLE table_name_93 (combined VARCHAR, overall VARCHAR, slalom VARCHAR)
SELECT player FROM table_name_73 WHERE score = 70 - 68 - 74 = 212
Who is the player with a 70-68-74=212 score?
CREATE TABLE table_name_73 (player VARCHAR, score VARCHAR)
SELECT SUM(laps) FROM table_name_33 WHERE bike = "honda cbr1000rr" AND time = "+16.569"
What is the sum of laps of the honda cbr1000rr bike, which has a time of +16.569?
CREATE TABLE table_name_33 (laps INTEGER, bike VARCHAR, time VARCHAR)
SELECT result FROM table_name_47 WHERE date = "10 october 2009"
What was the result of the game from 10 October 2009?
CREATE TABLE table_name_47 (result VARCHAR, date VARCHAR)
SELECT Ends AS lost FROM table_25689740_2 WHERE pa = 44
What is shown for ends lost when pa is 44?
CREATE TABLE table_25689740_2 (Ends VARCHAR, pa VARCHAR)
SELECT province FROM table_2251578_4 WHERE elevation__m_ = 4550
Which province has an elevation of 4550?
CREATE TABLE table_2251578_4 (province VARCHAR, elevation__m_ VARCHAR)
SELECT 2012 FROM table_name_47 WHERE 2008 = "grand slam tournaments"
Which 2012 has a 2008 of grand slam tournaments?
CREATE TABLE table_name_47 (Id VARCHAR)
SELECT race FROM table_name_60 WHERE finish = "1st" AND track = "saratoga race course"
Which race had a finish of 1st at Saratoga Race Course?
CREATE TABLE table_name_60 (race VARCHAR, finish VARCHAR, track VARCHAR)
SELECT rank FROM table_name_10 WHERE wins = 0 AND points = 2
Name the rank for wins of 0 and points of 2
CREATE TABLE table_name_10 (rank VARCHAR, wins VARCHAR, points VARCHAR)
SELECT high_points FROM table_27755603_10 WHERE date = "March 25"
What were the high points on March 25?
CREATE TABLE table_27755603_10 (high_points VARCHAR, date VARCHAR)
SELECT zip_code_prefix_es_ FROM table_name_39 WHERE county_seat = "boonville"
what is the zip code of boonville
CREATE TABLE table_name_39 (zip_code_prefix_es_ VARCHAR, county_seat VARCHAR)
SELECT MIN(population__2011_) FROM table_189598_7 WHERE name = "Beauval"
When beauval is the name what is the lowest population of 2011?
CREATE TABLE table_189598_7 (population__2011_ INTEGER, name VARCHAR)
SELECT MIN(post_code) FROM table_1976898_1 WHERE chinese_name__simplified___traditional_ = "潜山县 / 潛山縣"
What's the post code of the county with the Chinese name 潜山县 / 潛山縣?
CREATE TABLE table_1976898_1 (post_code INTEGER, chinese_name__simplified___traditional_ VARCHAR)
SELECT MIN(rank) FROM table_name_4 WHERE title = "american pie 2"
What is the rank of American Pie 2?
CREATE TABLE table_name_4 (rank INTEGER, title VARCHAR)
SELECT sigma__with_15σ_shift_ FROM table_222448_1 WHERE percent_defective = "69%"
What is the sigma (with 1.5σ shift) when there are 69% defective?
CREATE TABLE table_222448_1 (sigma__with_15σ_shift_ VARCHAR, percent_defective VARCHAR)
SELECT MAX(top_25) FROM table_name_84 WHERE events > 20 AND top_10 > 21
I want the most top 25 when events are more than 20 and top 10 is more than 21
CREATE TABLE table_name_84 (top_25 INTEGER, events VARCHAR, top_10 VARCHAR)
SELECT nat FROM table_name_76 WHERE app_l_c_e_ = "0 (0/0/0)" AND name = "yahaya"
What is the Nationality of the player named Yahaya, who has as App(L/C/E) of 0 (0/0/0)?
CREATE TABLE table_name_76 (nat VARCHAR, app_l_c_e_ VARCHAR, name VARCHAR)
SELECT date FROM table_name_10 WHERE venue = "carson"
On what Date was the Venue in Carson?
CREATE TABLE table_name_10 (date VARCHAR, venue VARCHAR)
SELECT leading_scorer_1 FROM table_name_8 WHERE season = "2010–11"
Which Leading scorer 1 has a Season of 2010–11?
CREATE TABLE table_name_8 (leading_scorer_1 VARCHAR, season VARCHAR)
SELECT ensemble_name FROM table_name_29 WHERE area = "oxfordshire"
What is Oxfordshire Area's Ensemble Name?
CREATE TABLE table_name_29 (ensemble_name VARCHAR, area VARCHAR)
SELECT document_status_description FROM Ref_Document_Status WHERE document_status_code = "working"
What is the description of document status code 'working'?
CREATE TABLE Ref_Document_Status (document_status_description VARCHAR, document_status_code VARCHAR)
SELECT director FROM table_17155250_1 WHERE original_title = "The Patience Stone"
Who was the director of the film with the original title of "The Patience Stone"?
CREATE TABLE table_17155250_1 (director VARCHAR, original_title VARCHAR)
SELECT COUNT(total) FROM table_name_40 WHERE bronze = 2
How many totals have 2 for the bronze?
CREATE TABLE table_name_40 (total VARCHAR, bronze VARCHAR)
SELECT SUM(gold) FROM table_name_62 WHERE bronze > 2
How many gold medals were won when more than 2 bronze medals were won?
CREATE TABLE table_name_62 (gold INTEGER, bronze INTEGER)
SELECT MAX(year_commissioned) FROM table_name_75 WHERE gross_head__metres_ = 60 AND average_annual_output__million_kwh_ < 59
What is the Year commissioned of the power station with a Gross head of 60 metres and Average annual output of less than 59 million KWh?
CREATE TABLE table_name_75 (year_commissioned INTEGER, gross_head__metres_ VARCHAR, average_annual_output__million_kwh_ VARCHAR)
SELECT country FROM table_name_57 WHERE label = "control"
What country has the label Control?
CREATE TABLE table_name_57 (country VARCHAR, label VARCHAR)
SELECT COUNT(total) FROM table_name_52 WHERE vault = 38.437 AND floor_exercise < 37.524
What is the sum of totals with a Vault of 38.437, and a Floor Exercise smaller than 37.524?
CREATE TABLE table_name_52 (total VARCHAR, vault VARCHAR, floor_exercise VARCHAR)
SELECT engine FROM table_name_59 WHERE year = 1960
What is the engine for a vehicle in 1960?
CREATE TABLE table_name_59 (engine VARCHAR, year VARCHAR)
SELECT new_entries_this_round FROM table_name_58 WHERE clubs = "2 → 1"
How many new entries this round have clubs 2 → 1?
CREATE TABLE table_name_58 (new_entries_this_round VARCHAR, clubs VARCHAR)
SELECT location_attendance FROM table_27902171_7 WHERE high_rebounds = "B. Benjamin (10)"
What is the location and attendance for the game where b. benjamin (10) had the high rebounds?
CREATE TABLE table_27902171_7 (location_attendance VARCHAR, high_rebounds VARCHAR)
SELECT opponent FROM table_name_19 WHERE location_attendance = "madison square garden"
Who was the opponent at the game at Madison Square Garden?
CREATE TABLE table_name_19 (opponent VARCHAR, location_attendance VARCHAR)
SELECT MAX(matches) FROM table_name_77 WHERE prize_money = "£5,000"
What is are the highest matches with £5,000 in prize money?
CREATE TABLE table_name_77 (matches INTEGER, prize_money VARCHAR)
SELECT MAX(area_km_2) FROM table_name_92 WHERE status = "village" AND census_ranking = "1,442 of 5,008" AND population < 1 OFFSET 778
What is the area of the village with a census ranking of 1,442 of 5,008 and a population less than 1,778?
CREATE TABLE table_name_92 (area_km_2 INTEGER, population VARCHAR, status VARCHAR, census_ranking VARCHAR)
SELECT shareholder_name FROM table_206359_1 WHERE a_shares = 0
What shareholders have 0 A shares?
CREATE TABLE table_206359_1 (shareholder_name VARCHAR, a_shares VARCHAR)
SELECT position FROM table_name_27 WHERE round = 7
Which position is round 7?
CREATE TABLE table_name_27 (position VARCHAR, round VARCHAR)
SELECT partnering FROM table_name_52 WHERE score = "6-4, 2-6, 7-6"
Who is the Partner in the match with a Score of 6-4, 2-6, 7-6?
CREATE TABLE table_name_52 (partnering VARCHAR, score VARCHAR)
SELECT COUNT(overall_attendance) FROM table_2771237_1 WHERE average_attendance = 17807
How many times was the overall attendance 17807?
CREATE TABLE table_2771237_1 (overall_attendance VARCHAR, average_attendance VARCHAR)
SELECT location FROM table_name_41 WHERE mountain_range = "coast mountains" AND rank < 18 AND mountain_peak = "skihist mountain"
Which location includes Coast Mountains with a rank less than 18 at Skihist Mountain?
CREATE TABLE table_name_41 (location VARCHAR, mountain_peak VARCHAR, mountain_range VARCHAR, rank VARCHAR)
SELECT AVG(acquired) FROM table_name_49 WHERE design = "1a1" AND name = "wallenstein"
What is the average year for Wallenstein with 1a1 design?
CREATE TABLE table_name_49 (acquired INTEGER, design VARCHAR, name VARCHAR)
SELECT name FROM table_name_9 WHERE regional_county_municipality = "d'autray" AND code < 52017
What is the name for the regional county municipality of d'autray and a code less than 52017?
CREATE TABLE table_name_9 (name VARCHAR, regional_county_municipality VARCHAR, code VARCHAR)
SELECT driver FROM table_name_58 WHERE grid = "18"
Which driver had a grid of 18?
CREATE TABLE table_name_58 (driver VARCHAR, grid VARCHAR)
SELECT MIN(silver) FROM table_22355_35
which is the minimun amount of silver medals?
CREATE TABLE table_22355_35 (silver INTEGER)
SELECT close_of_reactor FROM table_name_13 WHERE rated_power = "945 mw" AND finish_construction = "may 10, 1978"
When did the reactor that has a rated power of 945 MW and ended construction on May 10, 1978 close?
CREATE TABLE table_name_13 (close_of_reactor VARCHAR, rated_power VARCHAR, finish_construction VARCHAR)
SELECT home_team FROM table_name_93 WHERE venue = "victoria park"
What is the home team for victoria park?
CREATE TABLE table_name_93 (home_team VARCHAR, venue VARCHAR)
SELECT tenure FROM table_name_96 WHERE courtesy_title = "yamashiro-no-kami"
What is the tenure of the person whose courtesy title is yamashiro-no-kami?
CREATE TABLE table_name_96 (tenure VARCHAR, courtesy_title VARCHAR)
SELECT MAX(pick) FROM table_name_55 WHERE new_team = "texas rangers" AND round = "compensation-a"
What was the biggest pick number for the new team of Texas Rangers, in the compensation-a round?
CREATE TABLE table_name_55 (pick INTEGER, new_team VARCHAR, round VARCHAR)
SELECT gcm__kg__technical_capacity FROM table_11497980_1 WHERE transmission_make_type_speed = "Eaton FS 5306-A Manual Synchromesh 6 Speed"
When the transmission make/type/speed is eaton fs 5306-a manual synchromesh 6 speed, what is the value of the gcm (kg) technical capacity?
CREATE TABLE table_11497980_1 (gcm__kg__technical_capacity VARCHAR, transmission_make_type_speed VARCHAR)
SELECT caps FROM table_name_20 WHERE scotland_career = "1920–1923"
Which caps was in scotland in 1920–1923?
CREATE TABLE table_name_20 (caps VARCHAR, scotland_career VARCHAR)
SELECT written_by FROM table_29273182_1 WHERE production_code = "IP03007"
Who wrote the episode with a production code of ip03007?
CREATE TABLE table_29273182_1 (written_by VARCHAR, production_code VARCHAR)
SELECT status FROM table_2589963_1 WHERE juniors = "Baby Olympians"
What status of school is the school represented by the baby olympians?
CREATE TABLE table_2589963_1 (status VARCHAR, juniors VARCHAR)
SELECT record FROM table_17058151_6 WHERE date = "December 6"
Name the record for december 6
CREATE TABLE table_17058151_6 (record VARCHAR, date VARCHAR)
SELECT COUNT(gold) FROM table_name_93 WHERE bronze = 2 AND silver > 5
What is the total number of gold medals when the team got 2 bronze and more than 5 silver medals?
CREATE TABLE table_name_93 (gold VARCHAR, bronze VARCHAR, silver VARCHAR)
SELECT total_score_week FROM table_name_38 WHERE status = "eliminated" AND scores_by_each_individual_judge = 5 + 5 + 4 = 14
Which Total score/week has a Status of eliminated, and Scores by each individual judge of 5 + 5 + 4 = 14?
CREATE TABLE table_name_38 (total_score_week VARCHAR, status VARCHAR, scores_by_each_individual_judge VARCHAR)
SELECT AVG(year_born) FROM table_name_97 WHERE player = "radek necas" AND height < 2.04
When was radek necas with less than 2.04 height born?
CREATE TABLE table_name_97 (year_born INTEGER, player VARCHAR, height VARCHAR)
SELECT english_meaning FROM table_name_22 WHERE full_word = "shens gamo"
What is English Meaning, when Full Word is "Shens Gamo"?
CREATE TABLE table_name_22 (english_meaning VARCHAR, full_word VARCHAR)
SELECT resolution FROM table_name_36 WHERE dish = "5270"
Name the resolution for dish of 5270
CREATE TABLE table_name_36 (resolution VARCHAR, dish VARCHAR)
SELECT attendance FROM table_name_53 WHERE game_site = "bye"
How many fans attended the game at Bye?
CREATE TABLE table_name_53 (attendance VARCHAR, game_site VARCHAR)
SELECT COUNT(rank) FROM table_name_56 WHERE time = "7:34.24"
What is the total rank for the athlete that had a race time of 7:34.24?
CREATE TABLE table_name_56 (rank VARCHAR, time VARCHAR)
SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'
Find the id of the pet owned by student whose last name is ‘Smith’.
CREATE TABLE has_pet (petid VARCHAR, stuid VARCHAR); CREATE TABLE student (stuid VARCHAR, Lname VARCHAR)
SELECT game_site FROM table_name_64 WHERE attendance = "39,889"
Where was the game that had an attendance of 39,889?
CREATE TABLE table_name_64 (game_site VARCHAR, attendance VARCHAR)
SELECT SUM(points) FROM table_name_73 WHERE average < 1 AND played > 38 AND team = "gimnasia de la plata"
How many Points have an Average smaller than 1, a Played larger than 38, and a Team of gimnasia de la plata?
CREATE TABLE table_name_73 (points INTEGER, team VARCHAR, average VARCHAR, played VARCHAR)
SELECT result FROM table_name_1 WHERE year__ceremony_ = "2006 (79th)"
What is the result of the ceremony in 2006 (79th)?
CREATE TABLE table_name_1 (result VARCHAR, year__ceremony_ VARCHAR)
SELECT date_test_taken FROM Student_Tests_Taken WHERE test_result = "Pass"
Find the dates of the tests taken with result "Pass".
CREATE TABLE Student_Tests_Taken (date_test_taken VARCHAR, test_result VARCHAR)
SELECT player FROM table_name_9 WHERE height = "6-2"
Which player is 6-2?
CREATE TABLE table_name_9 (player VARCHAR, height VARCHAR)
SELECT prod_code FROM table_name_16 WHERE episode_title = "life's no fun anymore"
What is the production code fore the episode titled, life's no fun anymore?
CREATE TABLE table_name_16 (prod_code VARCHAR, episode_title VARCHAR)
SELECT time FROM table_name_55 WHERE method = "decision(majority)" AND opponent = "keisuke yamada"
Which time has a Method of decision(majority), and an Opponent of keisuke yamada?
CREATE TABLE table_name_55 (time VARCHAR, method VARCHAR, opponent VARCHAR)
SELECT MAX(revenue__) AS $m_ FROM table_name_92 WHERE operating_income__$m_ > 27 AND team = "hamburg" AND debt_as__percentage_of_value < 0
Name the most revenue for operating income more than 27 for hamburg and debt as % of value less than 0
CREATE TABLE table_name_92 (revenue__ INTEGER, debt_as__percentage_of_value VARCHAR, operating_income__$m_ VARCHAR, team VARCHAR)
SELECT date_of_vacancy FROM table_name_9 WHERE manner_of_departure = "fired" AND replaced_by = "albert cartier"
What was the date of vacancy where the replacement was Albert Cartier and the manager was fired?
CREATE TABLE table_name_9 (date_of_vacancy VARCHAR, manner_of_departure VARCHAR, replaced_by VARCHAR)
SELECT date FROM table_name_84 WHERE venue = "rome"
The venue of Rome has which date?
CREATE TABLE table_name_84 (date VARCHAR, venue VARCHAR)
SELECT store_id FROM inventory GROUP BY store_id ORDER BY COUNT(*) DESC LIMIT 1
Which store owns most items?
CREATE TABLE inventory (store_id VARCHAR)
SELECT place FROM table_name_30 WHERE player = "mark brooks"
which Place has a Player of mark brooks?
CREATE TABLE table_name_30 (place VARCHAR, player VARCHAR)
SELECT team FROM table_name_20 WHERE replaced_by = "geraint williams"
what is the team geraint williams is the replacement?
CREATE TABLE table_name_20 (team VARCHAR, replaced_by VARCHAR)
SELECT 2008 FROM table_name_53 WHERE 2007 = "a" AND 2011 = "a" AND 2010 = "a" AND tournament = "china"
what is 2008 when 2007 is a, 2011 is a, 2010 is a and tournament is china?
CREATE TABLE table_name_53 (tournament VARCHAR)
SELECT driver FROM table_name_42 WHERE year = "1969"
Who is the driver from 1969?
CREATE TABLE table_name_42 (driver VARCHAR, year VARCHAR)
SELECT AVG(rank) FROM table_name_30 WHERE losses < 6 AND wins < 11 AND school = "michigan state"
Tell me the average Rank for lossess less than 6 and wins less than 11 for michigan state
CREATE TABLE table_name_30 (rank INTEGER, school VARCHAR, losses VARCHAR, wins VARCHAR)
SELECT AVG(attendance) FROM table_name_34 WHERE date = "january 6, 2008"
What's the average attendance on january 6, 2008?
CREATE TABLE table_name_34 (attendance INTEGER, date VARCHAR)
SELECT alvin_greene__d_ FROM table_name_71 WHERE jim_demint__r_ = "62%"
What was the vote for Alvin Green when Jim DeMint was 62%?
CREATE TABLE table_name_71 (alvin_greene__d_ VARCHAR, jim_demint__r_ VARCHAR)
SELECT date FROM table_name_57 WHERE label = "rca" AND catalog = "sf-7635"
What is the Date of the RCA release with Catalog number SF-7635?
CREATE TABLE table_name_57 (date VARCHAR, label VARCHAR, catalog VARCHAR)
SELECT country FROM table_name_8 WHERE score = 76 - 71 = 147
What country has a 76-71=147 score?
CREATE TABLE table_name_8 (country VARCHAR, score VARCHAR)
SELECT AVG(pick) FROM table_name_19 WHERE player = "paul maclean" AND draft < 1978
What is the average pick of player paul maclean, who had a draft before 1978?
CREATE TABLE table_name_19 (pick INTEGER, player VARCHAR, draft VARCHAR)
SELECT status FROM table_name_87 WHERE against > 20 AND date = "18/11/1995"
What's the status with an against over 20 on 18/11/1995?
CREATE TABLE table_name_87 (status VARCHAR, against VARCHAR, date VARCHAR)
SELECT grid FROM table_name_93 WHERE laps = "2"
What grid has 2 laps?
CREATE TABLE table_name_93 (grid VARCHAR, laps VARCHAR)