answer
stringlengths
18
557
question
stringlengths
12
244
context
stringlengths
27
484
SELECT owner_operator FROM table_name_85 WHERE licence_number = "pl 59"
Who is the owner operator who has license number PL 59?
CREATE TABLE table_name_85 (owner_operator VARCHAR, licence_number VARCHAR)
SELECT replaced_by FROM table_17327458_1 WHERE date_of_appointment = "11 July"
Who was replaced on 11 July?
CREATE TABLE table_17327458_1 (replaced_by VARCHAR, date_of_appointment VARCHAR)
SELECT MAX(stu_gpa), AVG(stu_gpa), MIN(stu_gpa), dept_code FROM student GROUP BY dept_code
Find the max, average, and minimum gpa of all students in each department.
CREATE TABLE student (dept_code VARCHAR, stu_gpa INTEGER)
SELECT avg_finish FROM table_1507423_4 WHERE avg_start = "18.4"
What was the average finish when the average start was 18.4?
CREATE TABLE table_1507423_4 (avg_finish VARCHAR, avg_start VARCHAR)
SELECT model FROM table_name_85 WHERE seats = 29 AND built = "1941–1942"
What is the Model of the Engine with 29 Seats Built in 1941–1942?
CREATE TABLE table_name_85 (model VARCHAR, seats VARCHAR, built VARCHAR)
SELECT MIN(pick) FROM table_name_51 WHERE position = "ss, p" AND team = "minnesota twins"
What is the lowest pick of a player for the SS, P Position for the Minnesota Twins?
CREATE TABLE table_name_51 (pick INTEGER, position VARCHAR, team VARCHAR)
SELECT AVG(bronze) FROM table_name_36 WHERE total = 4 AND silver < 2
What is the average Bronze, when Total is 4, and when Silver is less than 2?
CREATE TABLE table_name_36 (bronze INTEGER, total VARCHAR, silver VARCHAR)
SELECT team FROM table_name_28 WHERE recopa_sudamericana_1992 = "runner-up"
Which Team has a Recopa Sudamericana 1992 of runner-up?
CREATE TABLE table_name_28 (team VARCHAR, recopa_sudamericana_1992 VARCHAR)
SELECT location FROM table_name_52 WHERE res = "win" AND record = "8-5"
Tell me the location for win with record of 8-5
CREATE TABLE table_name_52 (location VARCHAR, res VARCHAR, record VARCHAR)
SELECT record FROM table_name_91 WHERE home = "nashville"
What is the team's record when they play nashville at home?
CREATE TABLE table_name_91 (record VARCHAR, home VARCHAR)
SELECT ceremony FROM table_name_35 WHERE work = "big titty milfs"
what ceremony did big titty milfs work in
CREATE TABLE table_name_35 (ceremony VARCHAR, work VARCHAR)
SELECT high_assists FROM table_name_83 WHERE team = "@ milwaukee"
What is High Assists, when Team is "@ Milwaukee"?
CREATE TABLE table_name_83 (high_assists VARCHAR, team VARCHAR)
SELECT record FROM table_name_72 WHERE arena = "arrowhead pond of anaheim" AND opponent = "sharks"
What was the record after the game against the Sharks at Arrowhead Pond of Anaheim?
CREATE TABLE table_name_72 (record VARCHAR, arena VARCHAR, opponent VARCHAR)
SELECT group_position FROM table_name_93 WHERE result_f_a = "5–0"
Result F–A of 5–0 had what group position?
CREATE TABLE table_name_93 (group_position VARCHAR, result_f_a VARCHAR)
SELECT date FROM table_name_35 WHERE year = "2004"
Tell me the date for 2004
CREATE TABLE table_name_35 (date VARCHAR, year VARCHAR)
SELECT MIN(games) FROM table_name_40 WHERE wins < 1 AND draws > 1
What is the lowest Games, when Wins is less than 1, and when Draws is greater than 1?
CREATE TABLE table_name_40 (games INTEGER, wins VARCHAR, draws VARCHAR)
SELECT customer_name FROM customers WHERE payment_method = "Cash"
What are the names of customers who use payment method "Cash"?
CREATE TABLE customers (customer_name VARCHAR, payment_method VARCHAR)
SELECT AVG(2008) FROM table_name_21 WHERE year = "beijing" AND 2005 > 2
Name the average 2008 for beijing and 2005 more than 2
CREATE TABLE table_name_21 (year VARCHAR)
SELECT away_team FROM table_name_65 WHERE home_team = "sheffield wednesday"
What is Away Team, when Home Team is "Sheffield Wednesday"?
CREATE TABLE table_name_65 (away_team VARCHAR, home_team VARCHAR)
SELECT AVG(silver) FROM table_name_53 WHERE gold > 6 AND bronze < 5
What is the average number of silver medals with more than 6 gold meals and less than 5 bronze medals?
CREATE TABLE table_name_53 (silver INTEGER, gold VARCHAR, bronze VARCHAR)
SELECT date FROM table_name_69 WHERE surface = "carpet" AND partner = "marty riessen"
When did Marty Riessen team up with a partner during a match on a carpet surface?
CREATE TABLE table_name_69 (date VARCHAR, surface VARCHAR, partner VARCHAR)
SELECT ipv6_address FROM table_name_65 WHERE operator = "wide project"
Which IPv6 address has an operator of Wide project?
CREATE TABLE table_name_65 (ipv6_address VARCHAR, operator VARCHAR)
SELECT serial_no FROM table_name_71 WHERE colour = "black" AND pilot_car_no > 2 AND engine_no = 1008
What is the serial number of the pilot car that is black, has a pilot car number larger than 2, and an engine number of 1008?
CREATE TABLE table_name_71 (serial_no VARCHAR, engine_no VARCHAR, colour VARCHAR, pilot_car_no VARCHAR)
SELECT stadium FROM table_name_89 WHERE home_team = "dallas cowboys 21"
In what stadium was the home team Dallas Cowboys 21?
CREATE TABLE table_name_89 (stadium VARCHAR, home_team VARCHAR)
SELECT AVG(tonnage) FROM table_name_81 WHERE name_of_ship = "proletarij"
What is the average tonnage of the ship named proletarij?
CREATE TABLE table_name_81 (tonnage INTEGER, name_of_ship VARCHAR)
SELECT player FROM table_name_47 WHERE nationality = "sweden"
Which player is from Sweden?
CREATE TABLE table_name_47 (player VARCHAR, nationality VARCHAR)
SELECT SUM(attendance) FROM table_name_79 WHERE score = "3:1"
What was the total attendance for the 3:1 game?
CREATE TABLE table_name_79 (attendance INTEGER, score VARCHAR)
SELECT COUNT(DISTINCT Nationality) FROM conductor
How many different nationalities do conductors have?
CREATE TABLE conductor (Nationality VARCHAR)
SELECT avg_start FROM table_1458412_1 WHERE starts = 30
What is the avg start that starts at 30?
CREATE TABLE table_1458412_1 (avg_start VARCHAR, starts VARCHAR)
SELECT competition FROM table_1061075_1 WHERE aggregate = "4–7"
what's the competition where aggregate is 4–7
CREATE TABLE table_1061075_1 (competition VARCHAR, aggregate VARCHAR)
SELECT place FROM table_name_59 WHERE to_par < 15 AND score = 76 - 72 - 75 - 71 = 294
What is Place, when To Par is less than 15, and when Score is 76-72-75-71=294?
CREATE TABLE table_name_59 (place VARCHAR, to_par VARCHAR, score VARCHAR)
SELECT name FROM table_name_41 WHERE number < 6 AND date < 1993
What is the name of the train numbered less than 6 before 1993?
CREATE TABLE table_name_41 (name VARCHAR, number VARCHAR, date VARCHAR)
SELECT title FROM table_19161605_2 WHERE _number = 14
What is the title of episode number 14?
CREATE TABLE table_19161605_2 (title VARCHAR, _number VARCHAR)
SELECT COUNT(*) FROM driver WHERE home_city = 'Hartford' OR age < 40
How many drivers are from Hartford city or younger than 40?
CREATE TABLE driver (home_city VARCHAR, age VARCHAR)
SELECT location FROM table_name_23 WHERE current_conference = "ssac" AND institution = "belhaven college"
Where is the Belhaven College SSAC conference location?
CREATE TABLE table_name_23 (location VARCHAR, current_conference VARCHAR, institution VARCHAR)
SELECT studio FROM table_name_41 WHERE title = "mask"
WHAT IS THE STUDIO WITH THE TITLE MASK?
CREATE TABLE table_name_41 (studio VARCHAR, title VARCHAR)
SELECT source FROM table_21535453_1 WHERE brian_moran = "26%"
What source gave 26% of the votes to Brian Moran?
CREATE TABLE table_21535453_1 (source VARCHAR, brian_moran VARCHAR)
SELECT transfer_fee FROM table_name_10 WHERE moving_from = "youth system" AND nat = "mar"
Which Transfer fee has a Moving from of youth system, and a Nat of mar?
CREATE TABLE table_name_10 (transfer_fee VARCHAR, moving_from VARCHAR, nat VARCHAR)
SELECT AVG(fa_cup) FROM table_name_62 WHERE player = "khairan ezuan razali" AND total < 0
Which FA Cup has a Player of khairan ezuan razali, and a Total smaller than 0?
CREATE TABLE table_name_62 (fa_cup INTEGER, player VARCHAR, total VARCHAR)
SELECT AVG(price) FROM products
Compute the average price of all the products.
CREATE TABLE products (price INTEGER)
SELECT T2.Name, T1.ArtistId FROM ALBUM AS T1 JOIN ARTIST AS T2 ON T1.ArtistId = T2.ArtistID GROUP BY T1.ArtistId HAVING COUNT(*) >= 3 ORDER BY T2.Name
Please list the name and id of all artists that have at least 3 albums in alphabetical order.
CREATE TABLE ARTIST (Name VARCHAR, ArtistID VARCHAR); CREATE TABLE ALBUM (ArtistId VARCHAR)
SELECT circuit FROM table_2446333_2 WHERE country = "United Arab Emirates"
Name the circuit for united arab emirates
CREATE TABLE table_2446333_2 (circuit VARCHAR, country VARCHAR)
SELECT score FROM table_name_87 WHERE game = 18
What was the score for game 18?
CREATE TABLE table_name_87 (score VARCHAR, game VARCHAR)
SELECT nhl_team FROM table_name_51 WHERE college_junior_club_team = "estevan bruins (wchl)"
The Estevan Bruins (WCHL) are affiliated with what NHL team?
CREATE TABLE table_name_51 (nhl_team VARCHAR, college_junior_club_team VARCHAR)
SELECT points FROM table_name_59 WHERE lost = "13" AND points_against = "461"
How many points did the club with 13 losses and 461 points against have?
CREATE TABLE table_name_59 (points VARCHAR, lost VARCHAR, points_against VARCHAR)
SELECT high_assists FROM table_name_44 WHERE date = "november 25"
Can you tell me the High assists that has the Date of november 25?
CREATE TABLE table_name_44 (high_assists VARCHAR, date VARCHAR)
SELECT date FROM table_name_49 WHERE venue = "arden street oval"
What is the date of the game at the Arden Street Oval?
CREATE TABLE table_name_49 (date VARCHAR, venue VARCHAR)
SELECT distinguished_service_cross FROM table_2104176_1 WHERE navy_cross = "Coast Guard Commendation Medal"
What is the distinguished service cross when the navy cross is Coast Guard commendation medal?
CREATE TABLE table_2104176_1 (distinguished_service_cross VARCHAR, navy_cross VARCHAR)
SELECT nationality FROM table_name_94 WHERE round = 3 AND college = "mercer"
For the draft pick from round 3 out of Mercer College what is the nationality?
CREATE TABLE table_name_94 (nationality VARCHAR, round VARCHAR, college VARCHAR)
SELECT incumbent FROM table_19753079_36 WHERE candidates = "Sue Myrick (R) 69.0% Jeff Doctor (D) 31.0%"
Name the incumbent for sue myrick (r) 69.0% jeff doctor (d) 31.0%
CREATE TABLE table_19753079_36 (incumbent VARCHAR, candidates VARCHAR)
SELECT administrative_division FROM table_24027047_1 WHERE population_density___km²_2011_ = "1,604.3"
In what division was there a population density in km2 of 1,604.3 in 2011?
CREATE TABLE table_24027047_1 (administrative_division VARCHAR, population_density___km²_2011_ VARCHAR)
SELECT game FROM table_name_59 WHERE date = "april 30"
What is the playoff Game on April 30?
CREATE TABLE table_name_59 (game VARCHAR, date VARCHAR)
SELECT democrat FROM table_name_16 WHERE sample_size < 516 AND republican = "ron paul"
Which Democrat was selected in the poll with a sample size smaller than 516 where the Republican chosen was Ron Paul?
CREATE TABLE table_name_16 (democrat VARCHAR, sample_size VARCHAR, republican VARCHAR)
SELECT time FROM table_name_11 WHERE opponent = "eddie miller"
Which time has eddie miller as opponent?
CREATE TABLE table_name_11 (time VARCHAR, opponent VARCHAR)
SELECT course FROM table_name_10 WHERE date = "1 june"
What is the course on 1 June?
CREATE TABLE table_name_10 (course VARCHAR, date VARCHAR)
SELECT no_in_series FROM table_16581695_4 WHERE production_code = "303"
What is the series episode number of the episode with production code 303?
CREATE TABLE table_16581695_4 (no_in_series VARCHAR, production_code VARCHAR)
SELECT scoring_average FROM table_name_92 WHERE year < 1998 AND wins > 3
Tell me the scoring average for year less than 1998 and wins more than 3
CREATE TABLE table_name_92 (scoring_average VARCHAR, year VARCHAR, wins VARCHAR)
SELECT home_team FROM table_name_86 WHERE away_team = "tottenham hotspur"
What team was the home team when Tottenham Hotspur is the away team?
CREATE TABLE table_name_86 (home_team VARCHAR, away_team VARCHAR)
SELECT date FROM table_name_44 WHERE winning_driver = "emerson fittipaldi" AND race = "spanish grand prix"
What day did Emerson Fittipaldi win the Spanish Grand Prix?
CREATE TABLE table_name_44 (date VARCHAR, winning_driver VARCHAR, race 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 to_par FROM table_name_96 WHERE country = "united states" AND place = "t4" AND player = "arnold palmer"
What is To Par, when Country is "United States", when Place is "T4", and when Player is "Arnold Palmer"?
CREATE TABLE table_name_96 (to_par VARCHAR, player VARCHAR, country VARCHAR, place VARCHAR)
SELECT COUNT(party) FROM table_1342270_3 WHERE district = "Alabama 6"
how many party with dbeingtrict being alabama 6
CREATE TABLE table_1342270_3 (party VARCHAR, district VARCHAR)
SELECT score FROM table_name_18 WHERE surface = "clay" AND tournament = "san marino"
what is the score when the surface is clay and the tournament is san marino?
CREATE TABLE table_name_18 (score VARCHAR, surface VARCHAR, tournament VARCHAR)
SELECT MIN(bits_14_12) FROM table_14249278_1 WHERE description = "Output from accumulator to character bus"
Name the most bits 14-12 for output from accumulator to character bus
CREATE TABLE table_14249278_1 (bits_14_12 INTEGER, description VARCHAR)
SELECT title FROM table_2468961_4 WHERE no_in_series = 56
What was the title of series number 56?
CREATE TABLE table_2468961_4 (title VARCHAR, no_in_series VARCHAR)
SELECT MIN(position) FROM table_16034882_4 WHERE loses = 3
What position did the team with 3 losses finish?
CREATE TABLE table_16034882_4 (position INTEGER, loses VARCHAR)
SELECT 2001 FROM table_name_94 WHERE 1989 = "a" AND tournament = "u.s. open"
What is 2001, when 1989 is "A", and when Tournament is "U.S. Open"?
CREATE TABLE table_name_94 (tournament VARCHAR)
SELECT division FROM table_1087659_2 WHERE playoffs = "division Semifinals"
What is the division for the division semifinals playoffs?
CREATE TABLE table_1087659_2 (division VARCHAR, playoffs VARCHAR)
SELECT circuit FROM table_name_15 WHERE team = "volvo cars australia"
What circuit has volvo cars australia as the team?
CREATE TABLE table_name_15 (circuit VARCHAR, team VARCHAR)
SELECT engine_code FROM table_name_76 WHERE model = "xdrive25i"
What is the engine code for the Xdrive25i?
CREATE TABLE table_name_76 (engine_code VARCHAR, model VARCHAR)
SELECT MIN(number_of_bearers_2008) FROM table_name_13 WHERE surname = "jansson" AND rank < 13
What was the lowest number of 2008 total bearers with a rank less than 13 and the Surname Jansson?
CREATE TABLE table_name_13 (number_of_bearers_2008 INTEGER, surname VARCHAR, rank VARCHAR)
SELECT race_time FROM table_2196127_1 WHERE driver = "Jeff Gordon"
What was the race time for Jeff Gordon?
CREATE TABLE table_2196127_1 (race_time VARCHAR, driver VARCHAR)
SELECT COUNT(segment_a) FROM table_15187735_14 WHERE series_ep = "14-05"
How many segment A were in series episode 14-05
CREATE TABLE table_15187735_14 (segment_a VARCHAR, series_ep VARCHAR)
SELECT COUNT(owner) FROM table_14623167_1 WHERE branding = "Prairie Public"
Name the owners for prairie public
CREATE TABLE table_14623167_1 (owner VARCHAR, branding VARCHAR)
SELECT position FROM table_29626583_3 WHERE mls_team = "New York Red Bulls"
What position did the team new york red bulls pick?
CREATE TABLE table_29626583_3 (position VARCHAR, mls_team VARCHAR)
SELECT date FROM table_18847736_2 WHERE dolphins_points = 6
How many dates do the dolphins have 6 points?
CREATE TABLE table_18847736_2 (date VARCHAR, dolphins_points VARCHAR)
SELECT date FROM table_name_16 WHERE record = "53-75"
What date was 53-75 recorded?
CREATE TABLE table_name_16 (date VARCHAR, record VARCHAR)
SELECT COUNT(overall) FROM table_name_53 WHERE pick__number > 9 AND round > 5
How much Overall has a Pick # larger than 9, and a Round larger than 5?
CREATE TABLE table_name_53 (overall VARCHAR, pick__number VARCHAR, round VARCHAR)
SELECT SUM(1979) FROM table_name_51 WHERE reservation = "standing rock indian reservation" AND 1989 < 54.9
What is the 1979 number for Standing Rock Indian Reservation when the 1989 is less than 54.9?
CREATE TABLE table_name_51 (reservation VARCHAR)
SELECT AVG(top_25) FROM table_name_93 WHERE top_10 < 2
What is the average number of top-25s for events with less than 2 top-10s?
CREATE TABLE table_name_93 (top_25 INTEGER, top_10 INTEGER)
SELECT surface FROM table_name_16 WHERE score = "4–6, 6–4, 3–6"
What is the Surface of the court in the match with a Score of 4–6, 6–4, 3–6?
CREATE TABLE table_name_16 (surface VARCHAR, score VARCHAR)
SELECT latitude FROM table_16799784_11 WHERE name = "Yuzut-Arkh Fossae"
At what latitude can the name origin of yuzut-arkh fossae be found?
CREATE TABLE table_16799784_11 (latitude VARCHAR, name VARCHAR)
SELECT season FROM table_name_12 WHERE episode_count > 5 AND time_length = "159 minutes"
Which season has more than 5 episodes each 159 minutes in length?
CREATE TABLE table_name_12 (season VARCHAR, episode_count VARCHAR, time_length VARCHAR)
SELECT COUNT(high_points) FROM table_22879323_9 WHERE location_attendance = "Ford Center"
Name the number of high points for ford center
CREATE TABLE table_22879323_9 (high_points VARCHAR, location_attendance VARCHAR)
SELECT COUNT(week) FROM table_name_25 WHERE opponent = "dallas cowboys"
What is the total number of weeks that the Giants played against the Dallas Cowboys?
CREATE TABLE table_name_25 (week VARCHAR, opponent VARCHAR)
SELECT year FROM table_name_40 WHERE distance = "1-1/16" AND jockey = "ramon dominguez"
What year did jockey Ramon Dominguez have a distance of 1-1/16?
CREATE TABLE table_name_40 (year VARCHAR, distance VARCHAR, jockey VARCHAR)
SELECT saffir_simpson_category FROM table_15416002_1 WHERE name = "Bonnie"
What is the Saffir-Simpson category for the hurricane named Bonnie?
CREATE TABLE table_15416002_1 (saffir_simpson_category VARCHAR, name VARCHAR)
SELECT circumstances FROM table_name_93 WHERE date = "2009-09-05"
What happened on 2009-09-05?
CREATE TABLE table_name_93 (circumstances VARCHAR, date VARCHAR)
SELECT MIN(tons___lton__) FROM table_23614702_1 WHERE warship = "Independencia"
How much does the Independencia weight?
CREATE TABLE table_23614702_1 (tons___lton__ INTEGER, warship VARCHAR)
SELECT DISTINCT address_type_code FROM customer_addresses
What are the distinct address type codes for all customer addresses?
CREATE TABLE customer_addresses (address_type_code VARCHAR)
SELECT density___km²_ FROM table_name_34 WHERE hanzi = "昌黎县"
What is the density of 昌黎县?
CREATE TABLE table_name_34 (density___km²_ VARCHAR, hanzi VARCHAR)
SELECT bleeding_time FROM table_14006_1 WHERE condition = "Factor V deficiency"
what's the bleeding time with condition being factor v deficiency
CREATE TABLE table_14006_1 (bleeding_time VARCHAR, condition VARCHAR)
SELECT vacated_throne FROM table_name_63 WHERE archbishop = "albert daeger"
When did Archbishop Albert Daeger vacate the throne?
CREATE TABLE table_name_63 (vacated_throne VARCHAR, archbishop VARCHAR)
SELECT position FROM table_name_73 WHERE nationality = "france"
WHAT IS THE POSITION OF FRANCE?
CREATE TABLE table_name_73 (position VARCHAR, nationality VARCHAR)
SELECT winning_driver FROM table_name_1 WHERE pole_position = "jim clark" AND fastest_lap = "jim clark"
Tell me the winning driver for jim clark as pole position and fastest lap
CREATE TABLE table_name_1 (winning_driver VARCHAR, pole_position VARCHAR, fastest_lap VARCHAR)
SELECT winner FROM table_name_39 WHERE finalist = "lietuvos rytas" AND season < 2010
Who was the winner of the season before 2010 with Lietuvos Rytas as a finalist?
CREATE TABLE table_name_39 (winner VARCHAR, finalist VARCHAR, season VARCHAR)
SELECT date FROM table_name_22 WHERE h___a = "a" AND league_position = "2nd" AND opponents = "manchester city"
What date was the game against manchester city when they had a league position of 2nd?
CREATE TABLE table_name_22 (date VARCHAR, opponents VARCHAR, h___a VARCHAR, league_position VARCHAR)
SELECT COUNT(name) FROM table_24565004_14 WHERE appearances¹ = 101
How many names correspond to the value 101 for appearances?
CREATE TABLE table_24565004_14 (name VARCHAR, appearances¹ VARCHAR)
SELECT opponent FROM table_name_3 WHERE record = "34–31–6"
What is the Opponent when the Record is 34–31–6?
CREATE TABLE table_name_3 (opponent VARCHAR, record VARCHAR)
SELECT city FROM table_name_95 WHERE lead = "tyler forrest"
Which City has a Lead of tyler forrest?
CREATE TABLE table_name_95 (city VARCHAR, lead VARCHAR)