answer
stringlengths
18
557
question
stringlengths
12
244
context
stringlengths
27
484
SELECT COUNT(basis_for_team_song) FROM table_28243323_1 WHERE club_name = "Fremantle"
How many team songs does fremantle have?
CREATE TABLE table_28243323_1 (basis_for_team_song VARCHAR, club_name VARCHAR)
SELECT rider FROM table_name_44 WHERE laps < 15 AND grid > 32 AND time_retired = "accident"
Who is the rider with less than 15 laps, more than 32 grids, and an accident time/retired?
CREATE TABLE table_name_44 (rider VARCHAR, time_retired VARCHAR, laps VARCHAR, grid VARCHAR)
SELECT romaji_title FROM table_name_65 WHERE tv_station = "fuji tv" AND average_ratings = "12.41%"
Which Romaji Title has a TV Station of fuji tv, and Average Ratings of 12.41%?
CREATE TABLE table_name_65 (romaji_title VARCHAR, tv_station VARCHAR, average_ratings VARCHAR)
SELECT fri_26_aug FROM table_30058355_7 WHERE wed_24_aug = "23' 52.67 94.807mph"
What is every entry for Friday August 26 when the entry for Wednesday August 24 is 23' 52.67 94.807mph?
CREATE TABLE table_30058355_7 (fri_26_aug VARCHAR, wed_24_aug VARCHAR)
SELECT MIN(score) FROM table_name_59 WHERE to_par = "–1"
Which Score has a To Par of –1?
CREATE TABLE table_name_59 (score INTEGER, to_par VARCHAR)
SELECT college_junior_club_team FROM table_name_81 WHERE position = "defence" AND player = "rory fitzpatrick"
What college, junior, or club team did defence player Rory Fitzpatrick play for?
CREATE TABLE table_name_81 (college_junior_club_team VARCHAR, position VARCHAR, player VARCHAR)
SELECT opponent FROM table_name_92 WHERE february > 2 AND game < 55
What team was the opponent when February shows more than 2, with a game number less than 55?
CREATE TABLE table_name_92 (opponent VARCHAR, february VARCHAR, game VARCHAR)
SELECT MAX(goals) FROM table_name_51 WHERE name = "lee smith" AND appearances < 364
What was Lee Smith's highest number of goals when he made fewer than 364 appearances?
CREATE TABLE table_name_51 (goals INTEGER, name VARCHAR, appearances VARCHAR)
SELECT laurel_mountain_channel FROM table_name_51 WHERE b_mountain_channel = "7"
What Laurel Mountain Channel is associated with B Mountain Channel of 7?
CREATE TABLE table_name_51 (laurel_mountain_channel VARCHAR, b_mountain_channel VARCHAR)
SELECT call_sign FROM table_name_9 WHERE frequency = "1200 am"
What is the call sign of 1200 am?
CREATE TABLE table_name_9 (call_sign VARCHAR, frequency VARCHAR)
SELECT rebounds_per_game FROM table_2761641_1 WHERE tournament = "2006 FIBA World Championship"
How many rebounds per game did he have at the 2006 fiba world championship?
CREATE TABLE table_2761641_1 (rebounds_per_game VARCHAR, tournament VARCHAR)
SELECT venue FROM table_name_82 WHERE event = "4x400m relay" AND year > 2002 AND position = "4th"
Is there a Venus that's a year later than 2002, with an Event of 4x400m relay in 4th Position?
CREATE TABLE table_name_82 (venue VARCHAR, position VARCHAR, event VARCHAR, year VARCHAR)
SELECT 1 AS st_runner_up FROM table_name_90 WHERE miss_earth_venezuela = "maría daniela torrealba"
who is the 1st runner-up when the miss earth Venezuela is maría daniela torrealba?
CREATE TABLE table_name_90 (miss_earth_venezuela VARCHAR)
SELECT AVG(year) FROM table_name_89 WHERE venue = "melbourne, australia"
What is the year of the tournament played at Melbourne, Australia?
CREATE TABLE table_name_89 (year INTEGER, venue VARCHAR)
SELECT MAX(year) FROM table_name_30 WHERE reg_season = "3rd, western" AND division > 2
Which Year is the highest one that has a Reg Season of 3rd, western, and a Division larger than 2?
CREATE TABLE table_name_30 (year INTEGER, reg_season VARCHAR, division VARCHAR)
SELECT nosawa_rongai FROM table_name_97 WHERE block_a = "petey williams"
Name the NOSAWA Rongai for petey williams
CREATE TABLE table_name_97 (nosawa_rongai VARCHAR, block_a VARCHAR)
SELECT title_subject FROM table_20903658_1 WHERE medium = "Bronze" AND public_office = "colonist and soldier in Ville Marie, New France"
Who was the subject of the bronze sculpture who was a colonist and soldier in Ville Marie, New France?
CREATE TABLE table_20903658_1 (title_subject VARCHAR, medium VARCHAR, public_office VARCHAR)
SELECT MAX(top_5) FROM table_name_40 WHERE cuts_made > 39
what is the highest top-5 when cuts made is more than 39?
CREATE TABLE table_name_40 (top_5 INTEGER, cuts_made INTEGER)
SELECT away_team AS score FROM table_name_70 WHERE home_team = "collingwood"
In the game where the home team is collingwood, what is the score of the away team?
CREATE TABLE table_name_70 (away_team VARCHAR, home_team VARCHAR)
SELECT MAX(crowd) FROM table_14312471_4 WHERE ground = "SCG"
What's the maximum crowd when scg is the ground?
CREATE TABLE table_14312471_4 (crowd INTEGER, ground VARCHAR)
SELECT pole_position FROM table_name_36 WHERE winning_driver = "michael schumacher" AND grand_prix = "san marino grand prix"
What was the pole position at the san marino grand prix with michael schumacher as winning driver?
CREATE TABLE table_name_36 (pole_position VARCHAR, winning_driver VARCHAR, grand_prix VARCHAR)
SELECT team FROM table_name_96 WHERE home_venue = "anyang stadium"
What is the Team with a venue of Anyang Stadium?
CREATE TABLE table_name_96 (team VARCHAR, home_venue VARCHAR)
SELECT MIN(density_per_km²) FROM table_name_21 WHERE number__map_ < 13 AND area_in_km² = 11.1
Which Density per km² is the lowest one that has a Number (map) smaller than 13, and an Area in km² of 11.1?
CREATE TABLE table_name_21 (density_per_km² INTEGER, number__map_ VARCHAR, area_in_km² VARCHAR)
SELECT pinyin FROM table_1976898_1 WHERE post_code = 246500
What's the Pinyin name of the county with a postcode 246500?
CREATE TABLE table_1976898_1 (pinyin VARCHAR, post_code VARCHAR)
SELECT COUNT(field_goals) FROM table_name_99 WHERE touchdowns < 3 AND points = 4 AND extra_points < 4
What is the total number of field goals for a player that had less than 3 touchdowns, had 4 points, and had less than 4 extra points?
CREATE TABLE table_name_99 (field_goals VARCHAR, extra_points VARCHAR, touchdowns VARCHAR, points VARCHAR)
SELECT COUNT(*), project_id FROM Documents WHERE document_type_code = "BK" GROUP BY project_id
How many documents are with document type code BK for each product id?
CREATE TABLE Documents (project_id VARCHAR, document_type_code VARCHAR)
SELECT MAX(goals) FROM table_name_12 WHERE current_club = "real madrid" AND ratio < 1.08 AND rank < 5
Which Goals have a Current Club of real madrid, and a Ratio smaller than 1.08, and a Rank smaller than 5?
CREATE TABLE table_name_12 (goals INTEGER, rank VARCHAR, current_club VARCHAR, ratio VARCHAR)
SELECT T1.County FROM APPELLATIONS AS T1 JOIN WINE AS T2 ON T1.Appelation = T2.Appelation WHERE T2.Score > 90 GROUP BY T1.County ORDER BY COUNT(*) DESC LIMIT 1
Find the county where produces the most number of wines with score higher than 90.
CREATE TABLE WINE (Appelation VARCHAR, Score INTEGER); CREATE TABLE APPELLATIONS (County VARCHAR, Appelation VARCHAR)
SELECT race FROM table_1140073_2 WHERE location = "Kyalami"
Which race is located in kyalami?
CREATE TABLE table_1140073_2 (race VARCHAR, location VARCHAR)
SELECT AVG(1 AS st_prize___) AS $__ FROM table_name_95 WHERE winner = "paul azinger (9)"
What was the amount of the 1st prize when paul azinger (9) was the winner?
CREATE TABLE table_name_95 (winner VARCHAR)
SELECT MIN(match2) FROM table_24538140_2
What is the lowest score of all games for match 2?
CREATE TABLE table_24538140_2 (match2 INTEGER)
SELECT rk FROM table_26218783_6 WHERE new_points = 5760
If the new points were 5760, what is the RK?
CREATE TABLE table_26218783_6 (rk VARCHAR, new_points VARCHAR)
SELECT away_team AS score FROM table_name_31 WHERE home_team = "melbourne"
what was the away team score in a game with north melbourne as home team?
CREATE TABLE table_name_31 (away_team VARCHAR, home_team VARCHAR)
SELECT MAX(year) FROM table_1046454_1 WHERE regular_season = "4th, Northwest"
what being the maximum year where regular season is 4th, northwest
CREATE TABLE table_1046454_1 (year INTEGER, regular_season VARCHAR)
SELECT 2012 FROM table_name_35 WHERE 2005 = "1r"
WHAT IS THE 2012 WITH 2005 OF 1R?
CREATE TABLE table_name_35 (Id VARCHAR)
SELECT home FROM table_name_83 WHERE visitor = "grizzlies" AND leading_scorer = "rudy gay (21)"
What is the home team of the game where the Grizzlies were the visitor team and Rudy Gay (21) was the leading scorer?
CREATE TABLE table_name_83 (home VARCHAR, visitor VARCHAR, leading_scorer VARCHAR)
SELECT time FROM table_name_42 WHERE lane < 4 AND rank > 4
For the swimmer in the lane less than 4, and is ranked greater than 4 what was the time?
CREATE TABLE table_name_42 (time VARCHAR, lane VARCHAR, rank VARCHAR)
SELECT home_team FROM table_name_32 WHERE venue = "windy hill"
Which home team has a venue of windy hill?
CREATE TABLE table_name_32 (home_team VARCHAR, venue VARCHAR)
SELECT place FROM table_name_75 WHERE country = "zimbabwe"
What is the Place of the Player from Zimbabwe?
CREATE TABLE table_name_75 (place VARCHAR, country VARCHAR)
SELECT date FROM table_name_51 WHERE livery = "operational"
What is the date for the Operational Livery?
CREATE TABLE table_name_51 (date VARCHAR, livery VARCHAR)
SELECT AVG(crowd) FROM table_name_41 WHERE venue = "moorabbin oval"
What was the attendance at Moorabbin Oval?
CREATE TABLE table_name_41 (crowd INTEGER, venue VARCHAR)
SELECT MAX(2 AS nd) FROM table_11570261_6 WHERE cuts_made = "11"
How many times did Tiger get second in the year where there were 11 cuts?
CREATE TABLE table_11570261_6 (cuts_made VARCHAR)
SELECT MIN(points) FROM table_name_99 WHERE game = 60
What were the lowest points of game 60?
CREATE TABLE table_name_99 (points INTEGER, game VARCHAR)
SELECT away_team AS score FROM table_name_75 WHERE home_team = "richmond"
What was the score for the away team when the home team was richmond?
CREATE TABLE table_name_75 (away_team VARCHAR, home_team VARCHAR)
SELECT COUNT(player) FROM table_24549777_1 WHERE high_checkout = 84
How man players checked out at 84?
CREATE TABLE table_24549777_1 (player VARCHAR, high_checkout VARCHAR)
SELECT iata FROM table_name_19 WHERE icao = "hlls"
What is the IATA code for the airport with an ICAO code of HLLS?
CREATE TABLE table_name_19 (iata VARCHAR, icao VARCHAR)
SELECT broadcast_date FROM table_name_46 WHERE viewers__in_millions_ = "7.0"
What is the broadcast date with 7.0 million viewers?
CREATE TABLE table_name_46 (broadcast_date VARCHAR, viewers__in_millions_ VARCHAR)
SELECT COUNT(DISTINCT StuID) FROM Sportsinfo
How many students play sports?
CREATE TABLE Sportsinfo (StuID VARCHAR)
SELECT date FROM table_name_37 WHERE competition = "2008 africa cup of nations"
What is the date of Competition of 2008 africa cup of nations?
CREATE TABLE table_name_37 (date VARCHAR, competition VARCHAR)
SELECT tournament FROM table_name_96 WHERE date = "sep 12, 1976"
What is Tournament, when Date is "Sep 12, 1976"?
CREATE TABLE table_name_96 (tournament VARCHAR, date VARCHAR)
SELECT position FROM table_23619005_3 WHERE player = "Doug Borden"
What's Doug Borden's position?
CREATE TABLE table_23619005_3 (position VARCHAR, player VARCHAR)
SELECT name FROM table_name_9 WHERE overall > 164 AND pick__number > 2 AND position = "running back" AND round = 16
Which name has an overall number of more than 164, when the pick number is more than 2, the position is running back, and the round is 16?
CREATE TABLE table_name_9 (name VARCHAR, round VARCHAR, position VARCHAR, overall VARCHAR, pick__number VARCHAR)
SELECT league FROM table_1214035_1 WHERE division = "3"
What leagues includes division 3
CREATE TABLE table_1214035_1 (league VARCHAR, division VARCHAR)
SELECT date FROM table_name_10 WHERE tournament = "the tour championship"
When did the Tournament of the Tour Championship take place?
CREATE TABLE table_name_10 (date VARCHAR, tournament VARCHAR)
SELECT power FROM table_250230_2 WHERE model = "Type R"
What is the power of the Type R?
CREATE TABLE table_250230_2 (power VARCHAR, model VARCHAR)
SELECT COUNT(college_junior_club_team) FROM table_22402438_7 WHERE player = "John Garrett"
How many college/junior/clubteams have John garrett as the player?
CREATE TABLE table_22402438_7 (college_junior_club_team VARCHAR, player VARCHAR)
SELECT COUNT(attendance) FROM table_name_54 WHERE score = "7-3" AND loss = "worrell (0-1)"
How many people were in attendance when the Washington Nationals had a score of 7-3 and a loss of Worrell (0-1)?
CREATE TABLE table_name_54 (attendance VARCHAR, score VARCHAR, loss VARCHAR)
SELECT COUNT(no_in_series) FROM table_2226817_6 WHERE original_air_date = "October 28, 1990"
How many series numbers do the episodes originally aired on October 28, 1990?
CREATE TABLE table_2226817_6 (no_in_series VARCHAR, original_air_date VARCHAR)
SELECT candidates FROM table_1341453_22 WHERE party = "Republican" AND district = "Maryland 1"
List the candidates in district Maryland 1 where the republican party won.
CREATE TABLE table_1341453_22 (candidates VARCHAR, party VARCHAR, district VARCHAR)
SELECT SUM(money___) AS $__ FROM table_name_12 WHERE score = 75 - 71 - 75 - 72 = 293
What is the monetary sum with a score of 75-71-75-72=293?
CREATE TABLE table_name_12 (money___ INTEGER, score VARCHAR)
SELECT bills_originally_cosponsored FROM table_18852984_2 WHERE all_amendments_cosponsored = 0
How many bills where originally cosponsored in those years where the total of all amendments cosponsored was 0?
CREATE TABLE table_18852984_2 (bills_originally_cosponsored VARCHAR, all_amendments_cosponsored VARCHAR)
SELECT professional_jury FROM table_14977252_2 WHERE points = 10
Name the jury of 10 points
CREATE TABLE table_14977252_2 (professional_jury VARCHAR, points VARCHAR)
SELECT winning_driver FROM table_name_45 WHERE race = "belgian grand prix"
Name the winning driver for belgian grand prix
CREATE TABLE table_name_45 (winning_driver VARCHAR, race VARCHAR)
SELECT round FROM table_name_19 WHERE year < 1987
What is the round for a year earlier than 1987?
CREATE TABLE table_name_19 (round VARCHAR, year INTEGER)
SELECT MAX(bronze) FROM table_name_15 WHERE rank = "2" AND silver < 3
What was the highest number of bronze medals for the entry with rank 2 and fewer than 3 silver medals?
CREATE TABLE table_name_15 (bronze INTEGER, rank VARCHAR, silver VARCHAR)
SELECT date FROM table_name_48 WHERE record = "7-9"
Which Date has a Record of 7-9?
CREATE TABLE table_name_48 (date VARCHAR, record VARCHAR)
SELECT date FROM table_name_18 WHERE name = "tirrana"
what is the date for tirrana?
CREATE TABLE table_name_18 (date VARCHAR, name VARCHAR)
SELECT MAX(commenced_operations) FROM table_name_39 WHERE airline = "valuair"
Which Commenced operations have an Airline of valuair?
CREATE TABLE table_name_39 (commenced_operations INTEGER, airline VARCHAR)
SELECT to_par FROM table_name_46 WHERE score = 68 - 73 = 141
What's the to par when the score was 68-73=141?
CREATE TABLE table_name_46 (to_par VARCHAR, score VARCHAR)
SELECT year FROM table_name_90 WHERE manufacturer = "letecke zavody n.p., jinonice"
In what year was Letecke Zavody N.P., Jinonice the manufacturer?
CREATE TABLE table_name_90 (year VARCHAR, manufacturer VARCHAR)
SELECT time FROM table_name_57 WHERE opponent = "shinya aoki"
What was the time when Shinya Aoki was the opponent?
CREATE TABLE table_name_57 (time VARCHAR, opponent VARCHAR)
SELECT COUNT(round) FROM table_name_76 WHERE position = "rb" AND college = "purdue" AND pick < 3
What is the total round of the rb player from Purdue with a pick less than 3?
CREATE TABLE table_name_76 (round VARCHAR, pick VARCHAR, position VARCHAR, college VARCHAR)
SELECT COUNT(crowd) FROM table_name_54 WHERE home_team = "st kilda"
What was the crowd size when st kilda played home?
CREATE TABLE table_name_54 (crowd VARCHAR, home_team VARCHAR)
SELECT viewers FROM table_24399615_10 WHERE cable_rank = "5"
List the number of viewers when the cable rank for Russell Howard's Good New was 5.
CREATE TABLE table_24399615_10 (viewers VARCHAR, cable_rank VARCHAR)
SELECT MIN(SOl) FROM table_1888157_1
What is the lowest SOL?
CREATE TABLE table_1888157_1 (SOl INTEGER)
SELECT suffix FROM table_name_73 WHERE group = "benzyl"
What is the Suffix for the Group of Benzyl?
CREATE TABLE table_name_73 (suffix VARCHAR, group VARCHAR)
SELECT team FROM table_30083499_1 WHERE tournament = "2012 Clausura"
Which team was in the 2012 clausura tournament?
CREATE TABLE table_30083499_1 (team VARCHAR, tournament VARCHAR)
SELECT author FROM table_1620397_2 WHERE series_sorted = "6Y/AE"
Name the author for 6y/ae
CREATE TABLE table_1620397_2 (author VARCHAR, series_sorted VARCHAR)
SELECT home FROM table_name_61 WHERE visitor = "ottawa senators" AND score = "1–5"
Which home team had a visitor of Ottawa Senators with a score of 1–5?
CREATE TABLE table_name_61 (home VARCHAR, visitor VARCHAR, score VARCHAR)
SELECT service FROM table_name_95 WHERE language = "hindi" AND genre = "general" AND network = "zee tv"
Which service has a hindi language, general genre and zee tv network?
CREATE TABLE table_name_95 (service VARCHAR, network VARCHAR, language VARCHAR, genre VARCHAR)
SELECT COUNT(game) FROM table_27882867_4 WHERE score = "W 112-94"
Name the total number of games for w 112-94
CREATE TABLE table_27882867_4 (game VARCHAR, score VARCHAR)
SELECT additional_major_sponsor_s_ FROM table_name_58 WHERE additional_colour_s_ = "black" AND year = 1984
What are the additional major sponsors which correspond to the additional color black and a year 1984?
CREATE TABLE table_name_58 (additional_major_sponsor_s_ VARCHAR, additional_colour_s_ VARCHAR, year VARCHAR)
SELECT AVG(gold) FROM table_name_13 WHERE rank = "17" AND silver > 4
What is the average number of golds for teams in rank 17 with more than 4 silver?
CREATE TABLE table_name_13 (gold INTEGER, rank VARCHAR, silver VARCHAR)
SELECT AVG(5432) FROM table_name_12 WHERE 11502 > 1163 AND 15122 < 15122 AND 3620 < 624
What is the average 5432 value with a 11502 larger than 1163, a 15122 less than 15122, and a 3620 less than 624?
CREATE TABLE table_name_12 (Id VARCHAR)
SELECT event FROM table_name_10 WHERE score_points = "10"
What is the event where there are 10 score points?
CREATE TABLE table_name_10 (event VARCHAR, score_points VARCHAR)
SELECT date_from FROM table_name_30 WHERE date_to = "end of season" AND name = "theo robinson"
What was the Date From for Theo Robinson, who was with the team until the end of season?
CREATE TABLE table_name_30 (date_from VARCHAR, date_to VARCHAR, name VARCHAR)
SELECT res FROM table_name_97 WHERE event = "pfc: put up or shut up"
What is the result for pfc: put up or shut up?
CREATE TABLE table_name_97 (res VARCHAR, event VARCHAR)
SELECT AVG(losses) FROM table_name_20 WHERE sunrayia_fl = "red cliffs" AND against > 2294
What is the losses when Sunrayia FL is Red Cliffs, and the against is more than 2294?
CREATE TABLE table_name_20 (losses INTEGER, sunrayia_fl VARCHAR, against VARCHAR)
SELECT score FROM table_name_86 WHERE home = "ny islanders" AND visitor = "montreal"
Name the score when the home is ny islanders and the visitor is montreal
CREATE TABLE table_name_86 (score VARCHAR, home VARCHAR, visitor VARCHAR)
SELECT T2.f1 FROM user_profiles AS T1 JOIN follows AS T2 ON T1.uid = T2.f2 WHERE T1.name = "Mary" OR T1.name = "Susan"
Find the id of users who are followed by Mary or Susan.
CREATE TABLE follows (f1 VARCHAR, f2 VARCHAR); CREATE TABLE user_profiles (uid VARCHAR, name VARCHAR)
SELECT winnings FROM table_name_65 WHERE make = "chevrolet" AND car__number > 29 AND points = 102
What were the winnings for the Chevrolet with a number larger than 29 and scored 102 points?
CREATE TABLE table_name_65 (winnings VARCHAR, points VARCHAR, make VARCHAR, car__number VARCHAR)
SELECT home_team AS score FROM table_name_65 WHERE venue = "western oval"
What was the home team score when the VFL played at Western Oval?
CREATE TABLE table_name_65 (home_team VARCHAR, venue VARCHAR)
SELECT date FROM table_name_92 WHERE record = "67-58"
On which date did the Indians have a record of 67-58
CREATE TABLE table_name_92 (date VARCHAR, record VARCHAR)
SELECT alternate FROM table_name_58 WHERE nation = "sweden"
Who is the Alternate for Sweden?
CREATE TABLE table_name_58 (alternate VARCHAR, nation VARCHAR)
SELECT name FROM table_22810095_8 WHERE moving_from = "northampton Town"
Who moved from Northampton Town?
CREATE TABLE table_22810095_8 (name VARCHAR, moving_from VARCHAR)
SELECT score FROM table_name_57 WHERE home = "ny islanders" AND date = "october 20"
What was the score of the game on October 20 when the home team is the NY Islanders?
CREATE TABLE table_name_57 (score VARCHAR, home VARCHAR, date VARCHAR)
SELECT constructor FROM table_name_24 WHERE location = "long beach"
Who was the Long Beach constructor?
CREATE TABLE table_name_24 (constructor VARCHAR, location VARCHAR)
SELECT date FROM table_name_97 WHERE opponent = "george khrikadze"
What date did the opponent George Khrikadze play?
CREATE TABLE table_name_97 (date VARCHAR, opponent VARCHAR)
SELECT opponent FROM table_24918268_2 WHERE date = "Sunday, June 9"
Who are the opponents for games on Sunday, June 9?
CREATE TABLE table_24918268_2 (opponent VARCHAR, date VARCHAR)
SELECT SUM(revenue__) AS $m_ FROM table_name_35 WHERE debt_as__percentageof_value > 27 AND operating_income_$m_ = 77
What was the sum of Revenue ($M), when the Debt as % of value was higher than 27, and the Operating income($m) was 77?
CREATE TABLE table_name_35 (revenue__ INTEGER, debt_as__percentageof_value VARCHAR, operating_income_$m_ VARCHAR)