answer stringlengths 18 557 | question stringlengths 12 244 | context stringlengths 27 489 |
|---|---|---|
SELECT SUM(city_population) FROM district WHERE city_area > (SELECT AVG(city_area) FROM district) | Find the total population of the districts where the area is bigger than the average city area. | CREATE TABLE district (city_population INTEGER, city_area INTEGER) |
SELECT SUM(wins) FROM table_name_39 WHERE club = "cobden" AND draws > 2 | What is the total number of wins for Cobden club when there are more than 2 draws? | CREATE TABLE table_name_39 (wins INTEGER, club VARCHAR, draws VARCHAR) |
SELECT AVG(followers) FROM user_profiles WHERE UID IN (SELECT UID FROM tweets) | Find the average number of followers for the users who had some tweets. | CREATE TABLE user_profiles (followers INTEGER, UID VARCHAR); CREATE TABLE tweets (followers INTEGER, UID VARCHAR) |
SELECT runner_up FROM table_name_52 WHERE last_16 = "£300" | Which Runner-Up has a Last 16 of £300? | CREATE TABLE table_name_52 (runner_up VARCHAR, last_16 VARCHAR) |
SELECT unit FROM table_name_31 WHERE type = "wwer-440/213" | Which unite had the type wwer-440/213? | CREATE TABLE table_name_31 (unit VARCHAR, type 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 singular_word FROM table_name_82 WHERE plural_abbreviation = "pp." | A plural abbreviation of pp. is used for what singular word? | CREATE TABLE table_name_82 (singular_word VARCHAR, plural_abbreviation VARCHAR) |
SELECT venue FROM table_name_2 WHERE away_team = "richmond" | What location was the game played at when Richmond was the away team? | CREATE TABLE table_name_2 (venue VARCHAR, away_team VARCHAR) |
SELECT no_in_series FROM table_26259391_1 WHERE production_code = "8ACX05" | how many series have production code 8acx05 | CREATE TABLE table_26259391_1 (no_in_series VARCHAR, production_code VARCHAR) |
SELECT region FROM table_name_67 WHERE date = "early september 1999" | Which Region has a Date of early september 1999? | CREATE TABLE table_name_67 (region VARCHAR, date VARCHAR) |
SELECT COUNT(draw) FROM table_name_54 WHERE televote_sms = "2.39%" AND place > 9 | how many times was the televote/sms 2.39% and the place more than 9? | CREATE TABLE table_name_54 (draw VARCHAR, televote_sms VARCHAR, place VARCHAR) |
SELECT won FROM table_27293285_6 WHERE tries_for = "61" | How many matches were won by the teams that scored exactly 61 tries for? | CREATE TABLE table_27293285_6 (won VARCHAR, tries_for VARCHAR) |
SELECT result FROM table_name_2 WHERE date = "30 june 1995" | What is the result on 30 june 1995? | CREATE TABLE table_name_2 (result VARCHAR, date VARCHAR) |
SELECT 3 AS rd_place FROM table_20462111_1 WHERE date = "01.02.2009" | Who got the 3rd place in the cup on 01.02.2009? | CREATE TABLE table_20462111_1 (date VARCHAR) |
SELECT venue FROM table_name_26 WHERE year < 2006 AND position = "10th" | What was the venue before 2006, with the position of 10th? | CREATE TABLE table_name_26 (venue VARCHAR, year VARCHAR, position VARCHAR) |
SELECT nickname FROM table_1715730_2 WHERE founded = 1902 | what is the nickname founded in 1902? | CREATE TABLE table_1715730_2 (nickname VARCHAR, founded VARCHAR) |
SELECT MIN(bronze) FROM table_name_95 WHERE silver < 2 AND total > 1 AND nation = "uzbekistan" | What is the lowest number of bronze medals with less than 2 silver medals and more than 1 medal in total for Uzbekistan? | CREATE TABLE table_name_95 (bronze INTEGER, nation VARCHAR, silver VARCHAR, total VARCHAR) |
SELECT location FROM table_name_52 WHERE type = "club trophy" AND years = "1867 only" | What is the location for the club trophy from the year 1867 only? | CREATE TABLE table_name_52 (location VARCHAR, type VARCHAR, years VARCHAR) |
SELECT COUNT(cuts_made) FROM table_name_81 WHERE events = 2 | What is the total number of cuts made of tournaments with 2 Events? | CREATE TABLE table_name_81 (cuts_made VARCHAR, events VARCHAR) |
SELECT priority_entry_rights_to_derby FROM table_name_51 WHERE NOT race_name = 4 | What is the Priority-entry-rights to Derby in rank 4? | CREATE TABLE table_name_51 (priority_entry_rights_to_derby VARCHAR, race_name VARCHAR) |
SELECT T2.Name, T1.Name FROM country AS T1 JOIN roller_coaster AS T2 ON T1.Country_ID = T2.Country_ID | Show the names of roller coasters and names of country they are in. | CREATE TABLE country (Name VARCHAR, Country_ID VARCHAR); CREATE TABLE roller_coaster (Name VARCHAR, Country_ID VARCHAR) |
SELECT COUNT(*), Grape FROM WINE GROUP BY Grape | What are the numbers of wines for different grapes? | CREATE TABLE WINE (Grape VARCHAR) |
SELECT AVG(bronze) FROM table_name_62 WHERE silver > "2" AND rank = "2" AND gold > 2 | What is the average Bronze when silver is more than 2, and rank is 2, and gold more than 2 | CREATE TABLE table_name_62 (bronze INTEGER, gold VARCHAR, silver VARCHAR, rank VARCHAR) |
SELECT Local AS mission FROM table_name_8 WHERE mission = "mauritius" | What is Local Mission, when Mission is "Mauritius"? | CREATE TABLE table_name_8 (Local VARCHAR, mission VARCHAR) |
SELECT AVG(wins) FROM table_name_96 WHERE played < 30 | What is the average Wins, when Played is less than 30? | CREATE TABLE table_name_96 (wins INTEGER, played INTEGER) |
SELECT T2.name FROM Rating AS T1 JOIN Reviewer AS T2 ON T1.rID = T2.rID WHERE T1.stars = 3 INTERSECT SELECT T2.name FROM Rating AS T1 JOIN Reviewer AS T2 ON T1.rID = T2.rID WHERE T1.stars = 4 | What are the names of reviewers who had rated 3 star and 4 star? | CREATE TABLE Reviewer (name VARCHAR, rID VARCHAR); CREATE TABLE Rating (rID VARCHAR, stars VARCHAR) |
SELECT AVG(total) FROM table_name_85 WHERE nation = "japan (jpn)" AND silver < 1 | Which Total has a Nation of japan (jpn), and a Silver smaller than 1? | CREATE TABLE table_name_85 (total INTEGER, nation VARCHAR, silver VARCHAR) |
SELECT MAX(game) FROM table_11960610_10 WHERE team = "San Antonio" | What is San Antonio game number? | CREATE TABLE table_11960610_10 (game INTEGER, team VARCHAR) |
SELECT date FROM table_name_68 WHERE circuit = "monza" | When was the Monza circuit? | CREATE TABLE table_name_68 (date VARCHAR, circuit VARCHAR) |
SELECT association FROM table_name_54 WHERE nominee = "daniel mananta" AND year > 2011 | Who was the association that Daniel Mananta belonged to after 2011? | CREATE TABLE table_name_54 (association VARCHAR, nominee VARCHAR, year VARCHAR) |
SELECT subdivision_name___ru____gost_ FROM table_290017_1 WHERE subdivision_name___be____bgn_pcgn_ = "Hrodzenskaya voblasts'" | What are the subdivision names (RU) where the subdivision name (BE) is Hrodzenskaya Voblasts'? | CREATE TABLE table_290017_1 (subdivision_name___ru____gost_ VARCHAR, subdivision_name___be____bgn_pcgn_ VARCHAR) |
SELECT class FROM table_name_66 WHERE event = "championship test" AND result = "62.516" | What class had a Championship Test event with a 62.516 result? | CREATE TABLE table_name_66 (class VARCHAR, event VARCHAR, result VARCHAR) |
SELECT date FROM table_name_60 WHERE countries_surveyed < 122 AND _percentage_rank = "47" | Date for less than 122 countries and a 47% rank? | CREATE TABLE table_name_60 (date VARCHAR, countries_surveyed VARCHAR, _percentage_rank VARCHAR) |
SELECT wins FROM table_name_70 WHERE matches = "4" AND success_rate = "25%" | What was the win for 4 matches with a success rate of 25%? | CREATE TABLE table_name_70 (wins VARCHAR, matches VARCHAR, success_rate VARCHAR) |
SELECT nationality FROM table_name_89 WHERE position = "point guard" AND years_for_grizzlies = "1999-2001" | What was the nationality of a point guard position in 1999-2001? | CREATE TABLE table_name_89 (nationality VARCHAR, position VARCHAR, years_for_grizzlies VARCHAR) |
SELECT term_end FROM table_name_5 WHERE name = "fejzi bej alizoti" | When did Fejzi Bej Alizoti's term end? | CREATE TABLE table_name_5 (term_end VARCHAR, name VARCHAR) |
SELECT season FROM table_name_17 WHERE points = 78 | What season had 78 points? | CREATE TABLE table_name_17 (season VARCHAR, points VARCHAR) |
SELECT COUNT(date) FROM table_21091162_1 WHERE opponent = "Boston College" | How many dates have boston college as the opponent? | CREATE TABLE table_21091162_1 (date VARCHAR, opponent VARCHAR) |
SELECT record FROM table_name_5 WHERE game > 40 AND opponent = "new york rangers" | What is the Record of the Game after 40 with New York Rangers as Opponent? | CREATE TABLE table_name_5 (record VARCHAR, game VARCHAR, opponent VARCHAR) |
SELECT rider FROM table_name_11 WHERE laps < 22 AND grid = 2 | What rider went under 22 laps with grid number 2? | CREATE TABLE table_name_11 (rider VARCHAR, laps VARCHAR, grid VARCHAR) |
SELECT country FROM airlines GROUP BY country ORDER BY COUNT(*) DESC LIMIT 1 | Which countries has the most number of airlines? | CREATE TABLE airlines (country VARCHAR) |
SELECT high_rebounds FROM table_name_68 WHERE team = "charlotte" | What is the High rebounds with a Team that is charlotte? | CREATE TABLE table_name_68 (high_rebounds VARCHAR, team VARCHAR) |
SELECT high_assists FROM table_17340355_6 WHERE score = "W 106–104 (OT)" | Who made high points on games of score w 106–104 (ot) | CREATE TABLE table_17340355_6 (high_assists VARCHAR, score VARCHAR) |
SELECT player FROM table_name_99 WHERE to_club = "reggina" | Which player was transferred to Reggina? | CREATE TABLE table_name_99 (player VARCHAR, to_club VARCHAR) |
SELECT league FROM table_name_3 WHERE year = "1915/16" | Tell me the league for year of 1915/16 | CREATE TABLE table_name_3 (league VARCHAR, year VARCHAR) |
SELECT name FROM table_name_26 WHERE current_status = "demolished" AND location = "toolamba" | What is the name of the station in Toolamba that is currently demolished? | CREATE TABLE table_name_26 (name VARCHAR, current_status VARCHAR, location VARCHAR) |
SELECT college FROM table_name_39 WHERE overall > 180 | Which college had an overall number more than 180? | CREATE TABLE table_name_39 (college VARCHAR, overall INTEGER) |
SELECT term_end FROM table_name_23 WHERE political_party = "balli kombëtar" AND born_died = "1905–1972" | Which Term end has a Political Party of balli kombëtar, and a Born-Died of 1905–1972? | CREATE TABLE table_name_23 (term_end VARCHAR, political_party VARCHAR, born_died VARCHAR) |
SELECT founded FROM table_13759592_2 WHERE location = "Kirkland" | What year was Kirkland founded? | CREATE TABLE table_13759592_2 (founded VARCHAR, location VARCHAR) |
SELECT seat_no_1 FROM table_2231241_1 WHERE mayor = "John J. Seguier" | Who is seat no 1 when the mayor was john j. seguier | CREATE TABLE table_2231241_1 (seat_no_1 VARCHAR, mayor VARCHAR) |
SELECT new_entries_this_round FROM table_name_82 WHERE clubs = "48 → 32" | when there were 48 → 32 clubs? | CREATE TABLE table_name_82 (new_entries_this_round VARCHAR, clubs VARCHAR) |
SELECT COUNT(games) FROM table_name_99 WHERE rank < 4 AND rebounds < 102 | What is the total number of Games, when Rank is less than 4, and when Rebounds is less than 102? | CREATE TABLE table_name_99 (games VARCHAR, rank VARCHAR, rebounds VARCHAR) |
SELECT tournament FROM table_name_53 WHERE outcome = "winner" AND opponent = "dia evtimova" | Which tournament has an Outcome of winner, and a Opponent of dia evtimova? | CREATE TABLE table_name_53 (tournament VARCHAR, outcome VARCHAR, opponent VARCHAR) |
SELECT track FROM table_2454550_1 WHERE date = "March 19" | On what tra k was the march 19 race held? | CREATE TABLE table_2454550_1 (track VARCHAR, date VARCHAR) |
SELECT driver FROM table_name_44 WHERE time_retired = "2:45:46.2" | Which driver has a Time/Retired of 2:45:46.2? | CREATE TABLE table_name_44 (driver VARCHAR, time_retired VARCHAR) |
SELECT MAX(viewers) FROM table_24399615_3 WHERE airdate = "22 October 2009" | How many viewers were there for airdate is 22 october 2009? | CREATE TABLE table_24399615_3 (viewers INTEGER, airdate VARCHAR) |
SELECT location_code, COUNT(*) FROM Document_locations GROUP BY location_code | Show the location codes and the number of documents in each location. | CREATE TABLE Document_locations (location_code VARCHAR) |
SELECT SUM(year) FROM table_name_5 WHERE album = "roots and branches" | What is the total years for roots and branches? | CREATE TABLE table_name_5 (year INTEGER, album VARCHAR) |
SELECT year FROM table_name_22 WHERE gauge = "2 ft 6 in" | In what Year is the Gauge 2 ft 6 in? | CREATE TABLE table_name_22 (year VARCHAR, gauge VARCHAR) |
SELECT february FROM table_27539535_7 WHERE opponent = "Boston Bruins" | What day in February did the team play the boston bruins? | CREATE TABLE table_27539535_7 (february VARCHAR, opponent VARCHAR) |
SELECT air_date FROM table_name_39 WHERE winner = "red" AND challenge = "emergency braking" | What air date has a red winner and an emergency braking challenge? | CREATE TABLE table_name_39 (air_date VARCHAR, winner VARCHAR, challenge VARCHAR) |
SELECT creation FROM department GROUP BY creation ORDER BY COUNT(*) DESC LIMIT 1 | In which year were most departments established? | CREATE TABLE department (creation VARCHAR) |
SELECT 3 AS rd_place FROM table_name_53 WHERE year = "2011" | What was the 3rd place value in 2011? | CREATE TABLE table_name_53 (year VARCHAR) |
SELECT 1997 FROM table_name_99 WHERE 1999 = "1r" AND 1995 = "3r" AND 1993 = "1r" | What's the 1997 if 1993 has a 1R, 1995 has a 3R, and 1999 has a 1R? | CREATE TABLE table_name_99 (Id VARCHAR) |
SELECT history FROM table_name_88 WHERE name = "speedrunner iii (ssc3)" | What is the history behind Speedrunner III (SSC3)? | CREATE TABLE table_name_88 (history VARCHAR, name 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 COUNT(seasons) FROM table_name_1 WHERE years = "1976–1977" | How many Seasons that has Years of 1976–1977? | CREATE TABLE table_name_1 (seasons VARCHAR, years VARCHAR) |
SELECT branding FROM table_name_23 WHERE frequency = "93.1mhz" AND callsign = "dwrx" | What is the branding for the station with a frequency of 93.1mhz and a callsign of DWRX? | CREATE TABLE table_name_23 (branding VARCHAR, frequency VARCHAR, callsign VARCHAR) |
SELECT MAX(points) AS defending FROM table_24431264_18 WHERE player = "Radek Štěpánek" | How many defending points did radek štěpánek have? | CREATE TABLE table_24431264_18 (points INTEGER, player VARCHAR) |
SELECT constructor FROM table_name_58 WHERE grid > 17 AND time_retired = "brakes" | Who constructed the car that retired due to brakes with a grid larger than 17? | CREATE TABLE table_name_58 (constructor VARCHAR, grid VARCHAR, time_retired VARCHAR) |
SELECT official_name FROM table_176529_2 WHERE area_km_2 = "578.28" | What is the name of the place where area is 578.28 square km? | CREATE TABLE table_176529_2 (official_name VARCHAR, area_km_2 VARCHAR) |
SELECT catalog_number FROM table_name_66 WHERE format = "album" AND label = "seed records" AND formats = "cd" AND title = "grey" | I want to know the catalog number for album and seed records label for cd and title of grey | CREATE TABLE table_name_66 (catalog_number VARCHAR, title VARCHAR, formats VARCHAR, format VARCHAR, label VARCHAR) |
SELECT akkadian FROM table_26919_7 WHERE geez = "libb" | if the geez is libb, what is the akkadian? | CREATE TABLE table_26919_7 (akkadian VARCHAR, geez VARCHAR) |
SELECT Name FROM artwork ORDER BY Name | List the name of artworks in ascending alphabetical order. | CREATE TABLE artwork (Name VARCHAR) |
SELECT COUNT(*) FROM VOTING_RECORD | Find the number of voting records in total. | CREATE TABLE VOTING_RECORD (Id VARCHAR) |
SELECT county FROM table_25438110_5 WHERE casinos = 17 | What county has exactly 17 casinos? | CREATE TABLE table_25438110_5 (county VARCHAR, casinos VARCHAR) |
SELECT season FROM table_name_54 WHERE champion = "juventus" | what season did the juventus win | CREATE TABLE table_name_54 (season VARCHAR, champion VARCHAR) |
SELECT authority FROM table_name_93 WHERE gender = "coed" AND area = "kelvin grove" AND name = "tkkm o manawatu" | In the tkkm o manawatu coed school in kelvin grove, what is the Authority listed/ | CREATE TABLE table_name_93 (authority VARCHAR, name VARCHAR, gender VARCHAR, area VARCHAR) |
SELECT production_code FROM table_25996938_1 WHERE no_in_series = 11 | Which prod code was series 11? | CREATE TABLE table_25996938_1 (production_code VARCHAR, no_in_series VARCHAR) |
SELECT player FROM table_name_89 WHERE team = "oakland raiders" | What is the player when the team is oakland raiders? | CREATE TABLE table_name_89 (player VARCHAR, team VARCHAR) |
SELECT competition FROM table_name_64 WHERE assist_pass = "stephanie cox" AND date = "2011-07-02" | Name the competition for stephanie cox on 2011-07-02 | CREATE TABLE table_name_64 (competition VARCHAR, assist_pass VARCHAR, date VARCHAR) |
SELECT year FROM table_name_90 WHERE position = "forward" AND name = "iman mcfarland" | In what year of school is the forward Iman McFarland? | CREATE TABLE table_name_90 (year VARCHAR, position VARCHAR, name VARCHAR) |
SELECT DISTINCT T1.FirstName FROM CUSTOMER AS T1 JOIN INVOICE AS T2 ON T1.CustomerId = T2.CustomerId WHERE T1.country = "Brazil" | Find the first names of all customers that live in Brazil and have an invoice. | CREATE TABLE CUSTOMER (FirstName VARCHAR, CustomerId VARCHAR, country VARCHAR); CREATE TABLE INVOICE (CustomerId VARCHAR) |
SELECT city FROM table_name_27 WHERE average = 6.85 | Which City has an Average of 6.85? | CREATE TABLE table_name_27 (city VARCHAR, average VARCHAR) |
SELECT venue FROM table_name_71 WHERE date = "september 5, 1998" | What venue did the game on september 5, 1998 take place at? | CREATE TABLE table_name_71 (venue VARCHAR, date VARCHAR) |
SELECT place FROM table_name_8 WHERE player = "chris dimarco" | What is the Place, when the Player is Chris Dimarco? | CREATE TABLE table_name_8 (place VARCHAR, player VARCHAR) |
SELECT space_agency FROM table_name_17 WHERE name = "herschel space observatory" | Which space agency launched the herschel space observatory? | CREATE TABLE table_name_17 (space_agency VARCHAR, name VARCHAR) |
SELECT callsign FROM table_2638104_1 WHERE channel = 6 | What is the call sign for channel 6? | CREATE TABLE table_2638104_1 (callsign VARCHAR, channel VARCHAR) |
SELECT record FROM table_name_14 WHERE high_points = "clippers" | What is the record when Clippers have the high points? | CREATE TABLE table_name_14 (record VARCHAR, high_points VARCHAR) |
SELECT graded_hammer_three__gh3_ FROM table_name_20 WHERE model = "clp320" | Which Graded Hammer Three (GH3) shows Model of clp320? | CREATE TABLE table_name_20 (graded_hammer_three__gh3_ VARCHAR, model VARCHAR) |
SELECT team FROM table_name_88 WHERE wins > 10 AND champion = "mat mladin" | Which team had more than 10 wins with a champion of Mat Mladin? | CREATE TABLE table_name_88 (team VARCHAR, wins VARCHAR, champion VARCHAR) |
SELECT player FROM table_11677691_4 WHERE hometown = "Pewaukee, Wisconsin" | Which player's hometown was Pewaukee, Wisconsin? | CREATE TABLE table_11677691_4 (player VARCHAR, hometown VARCHAR) |
SELECT COUNT(opponent) FROM table_12206918_2 WHERE date = "1982-12-03" | How many opponents fought on 1982-12-03? | CREATE TABLE table_12206918_2 (opponent VARCHAR, date VARCHAR) |
SELECT year_s__won FROM table_name_65 WHERE to_par = "+8" | Which Year(s) won has a To par of +8? | CREATE TABLE table_name_65 (year_s__won VARCHAR, to_par VARCHAR) |
SELECT moving_to FROM table_name_34 WHERE name = "konchesky" | Where did Konchesky move to? | CREATE TABLE table_name_34 (moving_to VARCHAR, name VARCHAR) |
SELECT mls_team FROM table_29836557_2 WHERE player = "Babayele Sodade" | What MLS team picked Babayele Sodade? | CREATE TABLE table_29836557_2 (mls_team VARCHAR, player VARCHAR) |
SELECT COUNT(time) FROM table_name_52 WHERE lane < 8 AND nationality = "canada" AND rank < 8 | What is the total time of the athlete from Canada with a lane less than 8 and a rank less than 8? | CREATE TABLE table_name_52 (time VARCHAR, rank VARCHAR, lane VARCHAR, nationality VARCHAR) |
SELECT date FROM table_name_79 WHERE host_team = "baltimore ravens" | When did the Baltimore Ravens play at home ? | CREATE TABLE table_name_79 (date VARCHAR, host_team VARCHAR) |
SELECT COUNT(total) FROM table_name_71 WHERE to_par = 12 | What is the total number of Total, when To Par is 12? | CREATE TABLE table_name_71 (total VARCHAR, to_par VARCHAR) |
SELECT MIN(assists) FROM table_name_17 WHERE name = "ben duggan" AND points < 7 | What is the smallest number of assists for Ben Duggan with less than 7 points? | CREATE TABLE table_name_17 (assists INTEGER, name VARCHAR, points VARCHAR) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.