question_id
int64
0
16.1k
db_id
stringclasses
259 values
dber_id
stringlengths
15
29
question
stringlengths
16
325
SQL
stringlengths
18
1.25k
tokens
listlengths
4
62
entities
listlengths
0
21
entity_to_token
listlengths
20
20
dber_tags
listlengths
4
62
4,087
tracking_grants_for_research
spider:train_spider.json:4378
What is the last date of the staff leaving the projects?
SELECT date_to FROM Project_Staff ORDER BY date_to DESC LIMIT 1
[ "What", "is", "the", "last", "date", "of", "the", "staff", "leaving", "the", "projects", "?" ]
[ { "id": 0, "type": "table", "value": "project_staff" }, { "id": 1, "type": "column", "value": "date_to" } ]
[ { "entity_id": 0, "token_idxs": [ 10 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O" ]
4,089
video_games
bird:train.json:3460
How many shooter games are there?
SELECT COUNT(T1.id) FROM game AS T1 INNER JOIN genre AS T2 ON T1.genre_id = T2.id WHERE T2.genre_name = 'Shooter'
[ "How", "many", "shooter", "games", "are", "there", "?" ]
[ { "id": 2, "type": "column", "value": "genre_name" }, { "id": 5, "type": "column", "value": "genre_id" }, { "id": 3, "type": "value", "value": "Shooter" }, { "id": 1, "type": "table", "value": "genre" }, { "id": 0, "type": "table", "value":...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 2 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "B-VALUE", "B-TABLE", "O", "B-TABLE", "O" ]
4,090
toxicology
bird:dev.json:262
Among the single bond molecule id, which molecules are not carcinogenic?
SELECT DISTINCT T1.molecule_id FROM bond AS T1 INNER JOIN molecule AS T2 ON T1.molecule_id = T2.molecule_id WHERE T2.label = '-' AND T1.bond_type = '-'
[ "Among", "the", "single", "bond", "molecule", "i", "d", ",", "which", "molecules", "are", "not", "carcinogenic", "?" ]
[ { "id": 0, "type": "column", "value": "molecule_id" }, { "id": 5, "type": "column", "value": "bond_type" }, { "id": 2, "type": "table", "value": "molecule" }, { "id": 3, "type": "column", "value": "label" }, { "id": 1, "type": "table", "val...
[ { "entity_id": 0, "token_idxs": [ 5, 6 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 4 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id":...
[ "O", "O", "O", "B-TABLE", "B-TABLE", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "O" ]
4,091
social_media
bird:train.json:825
How many female users reshared their tweets?
SELECT COUNT(T1.UserID) FROM twitter AS T1 INNER JOIN user AS T2 ON T1.UserID = T2.UserID WHERE T2.Gender = 'Female' AND T1.IsReshare = 'TRUE'
[ "How", "many", "female", "users", "reshared", "their", "tweets", "?" ]
[ { "id": 4, "type": "column", "value": "isreshare" }, { "id": 0, "type": "table", "value": "twitter" }, { "id": 1, "type": "column", "value": "userid" }, { "id": 2, "type": "column", "value": "gender" }, { "id": 3, "type": "value", "value": ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 2 ] }, { "entity_id": 4, "token_idxs": [ 4 ] }, { "entity_id": 5, "...
[ "O", "O", "B-VALUE", "B-COLUMN", "B-COLUMN", "O", "O", "O" ]
4,093
trains
bird:train.json:704
How many cars on a train that runs in the east direction have a flat roof?
SELECT SUM(CASE WHEN T1.roof = 'flat' THEN 1 ELSE 0 END)as count FROM cars AS T1 INNER JOIN trains AS T2 ON T1.train_id = T2.id WHERE T2.direction = 'east'
[ "How", "many", "cars", "on", "a", "train", "that", "runs", "in", "the", "east", "direction", "have", "a", "flat", "roof", "?" ]
[ { "id": 2, "type": "column", "value": "direction" }, { "id": 4, "type": "column", "value": "train_id" }, { "id": 1, "type": "table", "value": "trains" }, { "id": 0, "type": "table", "value": "cars" }, { "id": 3, "type": "value", "value": "e...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [ 11 ] }, { "entity_id": 3, "token_idxs": [ 10 ] }, { "entity_id": 4, "token_idxs": [] }, { "entit...
[ "O", "O", "B-TABLE", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-VALUE", "B-COLUMN", "O", "O", "B-VALUE", "B-COLUMN", "O" ]
4,094
music_1
spider:train_spider.json:3623
List the duration, file size and format of songs whose genre is pop, ordered by title?
SELECT T1.duration , T1.file_size , T1.formats FROM files AS T1 JOIN song AS T2 ON T1.f_id = T2.f_id WHERE T2.genre_is = "pop" ORDER BY T2.song_name
[ "List", "the", "duration", ",", "file", "size", "and", "format", "of", "songs", "whose", "genre", "is", "pop", ",", "ordered", "by", "title", "?" ]
[ { "id": 1, "type": "column", "value": "file_size" }, { "id": 7, "type": "column", "value": "song_name" }, { "id": 0, "type": "column", "value": "duration" }, { "id": 5, "type": "column", "value": "genre_is" }, { "id": 2, "type": "column", "...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [ 4 ] }, { "entity_id": 4, "token_idxs": [ 9 ] }, {...
[ "O", "O", "B-COLUMN", "O", "B-TABLE", "B-COLUMN", "O", "B-COLUMN", "O", "B-TABLE", "O", "B-COLUMN", "I-COLUMN", "B-COLUMN", "O", "O", "O", "O", "O" ]
4,095
department_store
spider:train_spider.json:4762
What are the names of staff who have been assigned multiple jobs?
SELECT T1.staff_name FROM staff AS T1 JOIN staff_department_assignments AS T2 ON T1.staff_id = T2.staff_id GROUP BY T2.staff_id HAVING COUNT (*) > 1
[ "What", "are", "the", "names", "of", "staff", "who", "have", "been", "assigned", "multiple", "jobs", "?" ]
[ { "id": 3, "type": "table", "value": "staff_department_assignments" }, { "id": 1, "type": "column", "value": "staff_name" }, { "id": 0, "type": "column", "value": "staff_id" }, { "id": 2, "type": "table", "value": "staff" }, { "id": 4, "type": ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { ...
[ "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O" ]
4,096
public_review_platform
bird:train.json:4012
Among all the users with the average ratings of at least 4 and above of all reviews, calculate the percent that have no fans or followers.
SELECT CAST(SUM(CASE WHEN user_fans = 'None' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(user_id) FROM Users WHERE user_average_stars >= 4
[ "Among", "all", "the", "users", "with", "the", "average", "ratings", "of", "at", "least", "4", "and", "above", "of", "all", "reviews", ",", "calculate", "the", "percent", "that", "have", "no", "fans", "or", "followers", "." ]
[ { "id": 1, "type": "column", "value": "user_average_stars" }, { "id": 7, "type": "column", "value": "user_fans" }, { "id": 4, "type": "column", "value": "user_id" }, { "id": 0, "type": "table", "value": "users" }, { "id": 8, "type": "value", ...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 11 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "O" ]
4,097
regional_sales
bird:train.json:2655
How many online sales were made in May 2018 where products were shipped from Norman?
SELECT SUM(CASE WHEN T1.OrderDate LIKE '5/%/18' AND T1.`Sales Channel` = 'Online' AND T2.`City Name` = 'Norman' THEN 1 ELSE 0 END) FROM `Sales Orders` AS T1 INNER JOIN `Store Locations` AS T2 ON T2.StoreID = T1._StoreID
[ "How", "many", "online", "sales", "were", "made", "in", "May", "2018", "where", "products", "were", "shipped", "from", "Norman", "?" ]
[ { "id": 1, "type": "table", "value": "Store Locations" }, { "id": 8, "type": "column", "value": "Sales Channel" }, { "id": 0, "type": "table", "value": "Sales Orders" }, { "id": 6, "type": "column", "value": "orderdate" }, { "id": 10, "type": "...
[ { "entity_id": 0, "token_idxs": [ 3, 4 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] ...
[ "O", "O", "B-VALUE", "B-TABLE", "I-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
4,098
menu
bird:train.json:5477
What is the highest price of the dish "Clear green turtle" on a menu page?
SELECT T2.price FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id WHERE T1.name = 'Clear green turtle' ORDER BY T2.price DESC LIMIT 1
[ "What", "is", "the", "highest", "price", "of", "the", "dish", "\"", "Clear", "green", "turtle", "\"", "on", "a", "menu", "page", "?" ]
[ { "id": 4, "type": "value", "value": "Clear green turtle" }, { "id": 2, "type": "table", "value": "menuitem" }, { "id": 6, "type": "column", "value": "dish_id" }, { "id": 0, "type": "column", "value": "price" }, { "id": 1, "type": "table", ...
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 13, 14, 15 ] }, { "entity_id": 4, "token_idxs": [ 9, ...
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O" ]
4,099
olympics
bird:train.json:4950
Where was the first Olympic game held?
SELECT T2.city_name FROM games_city AS T1 INNER JOIN city AS T2 ON T1.city_id = T2.id INNER JOIN games AS T3 ON T1.games_id = T3.id ORDER BY T3.games_year LIMIT 1
[ "Where", "was", "the", "first", "Olympic", "game", "held", "?" ]
[ { "id": 2, "type": "column", "value": "games_year" }, { "id": 3, "type": "table", "value": "games_city" }, { "id": 0, "type": "column", "value": "city_name" }, { "id": 5, "type": "column", "value": "games_id" }, { "id": 7, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { ...
[ "O", "O", "O", "O", "O", "B-TABLE", "O", "O" ]
4,100
debate
spider:train_spider.json:1498
Show different parties of people along with the number of people in each party.
SELECT Party , COUNT(*) FROM people GROUP BY Party
[ "Show", "different", "parties", "of", "people", "along", "with", "the", "number", "of", "people", "in", "each", "party", "." ]
[ { "id": 0, "type": "table", "value": "people" }, { "id": 1, "type": "column", "value": "party" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 13 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O" ]
4,101
medicine_enzyme_interaction
spider:train_spider.json:957
What is the most common interaction type between enzymes and medicine? And how many are there?
SELECT interaction_type , count(*) FROM medicine_enzyme_interaction GROUP BY interaction_type ORDER BY count(*) DESC LIMIT 1
[ "What", "is", "the", "most", "common", "interaction", "type", "between", "enzymes", "and", "medicine", "?", "And", "how", "many", "are", "there", "?" ]
[ { "id": 0, "type": "table", "value": "medicine_enzyme_interaction" }, { "id": 1, "type": "column", "value": "interaction_type" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5, 6 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] ...
[ "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
4,102
department_store
spider:train_spider.json:4742
Return the ids of the two department store chains with the most department stores.
SELECT dept_store_chain_id FROM department_stores GROUP BY dept_store_chain_id ORDER BY count(*) DESC LIMIT 2
[ "Return", "the", "ids", "of", "the", "two", "department", "store", "chains", "with", "the", "most", "department", "stores", "." ]
[ { "id": 1, "type": "column", "value": "dept_store_chain_id" }, { "id": 0, "type": "table", "value": "department_stores" } ]
[ { "entity_id": 0, "token_idxs": [ 12, 13 ] }, { "entity_id": 1, "token_idxs": [ 6, 7, 8 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "enti...
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "B-TABLE", "I-TABLE", "O" ]
4,103
european_football_2
bird:dev.json:1129
List down the long name for slow speed class team.
SELECT DISTINCT t1.team_long_name FROM Team AS t1 INNER JOIN Team_Attributes AS t2 ON t1.team_api_id = t2.team_api_id WHERE t2.buildUpPlaySpeedClass = 'Slow'
[ "List", "down", "the", "long", "name", "for", "slow", "speed", "class", "team", "." ]
[ { "id": 3, "type": "column", "value": "buildupplayspeedclass" }, { "id": 2, "type": "table", "value": "team_attributes" }, { "id": 0, "type": "column", "value": "team_long_name" }, { "id": 5, "type": "column", "value": "team_api_id" }, { "id": 1, ...
[ { "entity_id": 0, "token_idxs": [ 2, 3, 4 ] }, { "entity_id": 1, "token_idxs": [ 9 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 7, 8 ] }, { "entity_id": 4, "token_idxs": [ 6 ...
[ "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "B-VALUE", "B-COLUMN", "I-COLUMN", "B-TABLE", "O" ]
4,104
airline
bird:train.json:5838
What is the number of air carriers in the database?
SELECT COUNT(Code) FROM `Air Carriers`
[ "What", "is", "the", "number", "of", "air", "carriers", "in", "the", "database", "?" ]
[ { "id": 0, "type": "table", "value": "Air Carriers" }, { "id": 1, "type": "column", "value": "code" } ]
[ { "entity_id": 0, "token_idxs": [ 5, 6 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] ...
[ "O", "O", "O", "O", "O", "B-TABLE", "I-TABLE", "O", "O", "O", "O" ]
4,105
products_gen_characteristics
spider:train_spider.json:5550
List all the product names with the color description "white".
SELECT t1.product_name FROM products AS t1 JOIN ref_colors AS t2 ON t1.color_code = t2.color_code WHERE t2.color_description = "white"
[ "List", "all", "the", "product", "names", "with", "the", "color", "description", "\"", "white", "\"", "." ]
[ { "id": 3, "type": "column", "value": "color_description" }, { "id": 0, "type": "column", "value": "product_name" }, { "id": 2, "type": "table", "value": "ref_colors" }, { "id": 5, "type": "column", "value": "color_code" }, { "id": 1, "type": "...
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [ 10 ] }, { "entity...
[ "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "B-COLUMN", "B-COLUMN", "O", "B-COLUMN", "O", "O" ]
4,106
sing_contest
bird:test.json:752
What are the voice sound quality scores received for the song named ' The Balkan Girls ' in English language ?
SELECT T1.voice_sound_quality FROM performance_score AS T1 JOIN songs AS T2 ON T1.songs_id = T2.id WHERE T2.name = ' The Balkan Girls ' AND T2.language = 'English'
[ "What", "are", "the", "voice", "sound", "quality", "scores", "received", "for", "the", "song", "named", "'", "The", "Balkan", "Girls", "'", "in", "English", "language", "?" ]
[ { "id": 0, "type": "column", "value": "voice_sound_quality" }, { "id": 6, "type": "value", "value": " The Balkan Girls " }, { "id": 1, "type": "table", "value": "performance_score" }, { "id": 3, "type": "column", "value": "songs_id" }, { "id": 7, ...
[ { "entity_id": 0, "token_idxs": [ 3, 4, 5 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5,...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "O", "B-VALUE", "B-COLUMN", "O" ]
4,107
image_and_language
bird:train.json:7599
List all the attribute classes of image ID 22.
SELECT T1.ATT_CLASS FROM ATT_CLASSES AS T1 INNER JOIN IMG_OBJ_ATT AS T2 ON T1.ATT_CLASS_ID = T2.ATT_CLASS_ID WHERE T2.IMG_ID = 22
[ "List", "all", "the", "attribute", "classes", "of", "image", "ID", "22", "." ]
[ { "id": 5, "type": "column", "value": "att_class_id" }, { "id": 1, "type": "table", "value": "att_classes" }, { "id": 2, "type": "table", "value": "img_obj_att" }, { "id": 0, "type": "column", "value": "att_class" }, { "id": 3, "type": "column"...
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 6, 7 ] }, { "entity_id": 4, "token_idxs": [ 8 ] }, { "entity_id":...
[ "O", "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "B-VALUE", "O" ]
4,108
sales_in_weather
bird:train.json:8140
What was the temperature range of station no.1 on 2012/1/1?
SELECT tmax - tmin AS temrange FROM weather WHERE station_nbr = 1 AND `date` = '2012-01-01'
[ "What", "was", "the", "temperature", "range", "of", "station", "no.1", "on", "2012/1/1", "?" ]
[ { "id": 3, "type": "column", "value": "station_nbr" }, { "id": 6, "type": "value", "value": "2012-01-01" }, { "id": 0, "type": "table", "value": "weather" }, { "id": 1, "type": "column", "value": "tmax" }, { "id": 2, "type": "column", "valu...
[ { "entity_id": 0, "token_idxs": [ 1, 2 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "toke...
[ "O", "B-TABLE", "I-TABLE", "O", "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "O" ]
4,109
debit_card_specializing
bird:dev.json:1507
Please list the disparate time of the transactions taken place in the gas stations from chain no. 11.
SELECT DISTINCT T1.Time FROM transactions_1k AS T1 INNER JOIN gasstations AS T2 ON T1.GasStationID = T2.GasStationID WHERE T2.ChainID = 11
[ "Please", "list", "the", "disparate", "time", "of", "the", "transactions", "taken", "place", "in", "the", "gas", "stations", "from", "chain", "no", ".", "11", "." ]
[ { "id": 1, "type": "table", "value": "transactions_1k" }, { "id": 5, "type": "column", "value": "gasstationid" }, { "id": 2, "type": "table", "value": "gasstations" }, { "id": 3, "type": "column", "value": "chainid" }, { "id": 0, "type": "colum...
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [ 12, 13 ] }, { "entity_id": 3, "token_idxs": [ 15 ] }, { "entity_id": 4, "token_idxs": [ 18 ...
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-TABLE", "I-TABLE", "O", "B-COLUMN", "O", "O", "B-VALUE", "O" ]
4,110
european_football_2
bird:dev.json:1066
What is the passing class of CLB team?
SELECT DISTINCT t2.buildUpPlayPassingClass FROM Team AS t1 INNER JOIN Team_Attributes AS t2 ON t1.team_api_id = t2.team_api_id WHERE t1.team_short_name = 'CLB'
[ "What", "is", "the", "passing", "class", "of", "CLB", "team", "?" ]
[ { "id": 0, "type": "column", "value": "buildupplaypassingclass" }, { "id": 2, "type": "table", "value": "team_attributes" }, { "id": 3, "type": "column", "value": "team_short_name" }, { "id": 5, "type": "column", "value": "team_api_id" }, { "id": 1...
[ { "entity_id": 0, "token_idxs": [ 3, 4 ] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 6 ] }, { "entity_id":...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-VALUE", "B-TABLE", "O" ]
4,111
video_games
bird:train.json:3442
Which publisher has published the game 'Pachi-Slot Kanzen Kouryaku 3: Universal Koushiki Gaido Volume 3'?
SELECT T1.publisher_name FROM publisher AS T1 INNER JOIN game_publisher AS T2 ON T1.id = T2.publisher_id INNER JOIN game AS T3 ON T2.game_id = T3.id WHERE T3.game_name = 'Pachi-Slot Kanzen Kouryaku 3: Universal Koushiki Gaido Volume 3'
[ "Which", "publisher", "has", "published", "the", "game", "'", "Pachi", "-", "Slot", "Kanzen", "Kouryaku", "3", ":", "Universal", "Koushiki", "Gaido", "Volume", "3", "'", "?" ]
[ { "id": 3, "type": "value", "value": "Pachi-Slot Kanzen Kouryaku 3: Universal Koushiki Gaido Volume 3" }, { "id": 0, "type": "column", "value": "publisher_name" }, { "id": 5, "type": "table", "value": "game_publisher" }, { "id": 8, "type": "column", "value...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, ...
[ "O", "B-TABLE", "O", "B-COLUMN", "O", "B-TABLE", "O", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "O", "O" ]
4,112
books
bird:train.json:5973
Among the books published in 2004, list the name of the publisher of books with number of pages greater than 70% of the average number of pages of all books.
SELECT T1.title, T2.publisher_name FROM book AS T1 INNER JOIN publisher AS T2 ON T1.publisher_id = T2.publisher_id WHERE STRFTIME('%Y', T1.publication_date) = '2004' AND T1.num_pages * 100 > ( SELECT AVG(num_pages) FROM book ) * 70
[ "Among", "the", "books", "published", "in", "2004", ",", "list", "the", "name", "of", "the", "publisher", "of", "books", "with", "number", "of", "pages", "greater", "than", "70", "%", "of", "the", "average", "number", "of", "pages", "of", "all", "books",...
[ { "id": 7, "type": "column", "value": "publication_date" }, { "id": 1, "type": "column", "value": "publisher_name" }, { "id": 4, "type": "column", "value": "publisher_id" }, { "id": 3, "type": "table", "value": "publisher" }, { "id": 8, "type":...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 2 ] }, { "entity_id": 3, "token_idxs": [ 12 ] }, { "entity_id": 4, "token_idxs": [ 3 ] }, { "entity_id": 5, ...
[ "O", "O", "B-TABLE", "B-COLUMN", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "B-VALUE", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O" ]
4,113
hr_1
spider:train_spider.json:3424
Return all information about employees with salaries between 8000 and 12000 for which commission is not null or where their department id is not 40.
SELECT * FROM employees WHERE salary BETWEEN 8000 AND 12000 AND commission_pct != "null" OR department_id != 40
[ "Return", "all", "information", "about", "employees", "with", "salaries", "between", "8000", "and", "12000", "for", "which", "commission", "is", "not", "null", "or", "where", "their", "department", "i", "d", "is", "not", "40", "." ]
[ { "id": 6, "type": "column", "value": "commission_pct" }, { "id": 1, "type": "column", "value": "department_id" }, { "id": 0, "type": "table", "value": "employees" }, { "id": 3, "type": "column", "value": "salary" }, { "id": 5, "type": "value",...
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 20, 21, 22 ] }, { "entity_id": 2, "token_idxs": [ 25 ] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [ ...
[ "O", "O", "O", "O", "B-TABLE", "O", "B-COLUMN", "O", "B-VALUE", "O", "B-VALUE", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "B-VALUE", "O" ]
4,115
superhero
bird:dev.json:726
Rank heroes published by Marvel Comics by their height in descending order.
SELECT superhero_name, height_cm, RANK() OVER (ORDER BY height_cm DESC) AS HeightRank FROM superhero INNER JOIN publisher ON superhero.publisher_id = publisher.id WHERE publisher.publisher_name = 'Marvel Comics'
[ "Rank", "heroes", "published", "by", "Marvel", "Comics", "by", "their", "height", "in", "descending", "order", "." ]
[ { "id": 0, "type": "column", "value": "superhero_name" }, { "id": 4, "type": "column", "value": "publisher_name" }, { "id": 5, "type": "value", "value": "Marvel Comics" }, { "id": 6, "type": "column", "value": "publisher_id" }, { "id": 1, "type...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 8 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 2 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-TABLE", "O", "B-VALUE", "I-VALUE", "O", "O", "B-COLUMN", "O", "O", "O", "O" ]
4,116
food_inspection
bird:train.json:8799
Which business was the first one to get a low risk violation because of "Permit license or inspection report not posted"? Give the name of the business.
SELECT T2.name FROM violations AS T1 INNER JOIN businesses AS T2 ON T1.business_id = T2.business_id WHERE T1.`date` = ( SELECT MIN(`date`) FROM violations WHERE risk_category = 'Low Risk' AND description = 'Permit license or inspection report not posted' ) AND T1.risk_category = 'Low Risk' AND T1.description = 'Permit ...
[ "Which", "business", "was", "the", "first", "one", "to", "get", "a", "low", "risk", "violation", "because", "of", "\"", "Permit", "license", "or", "inspection", "report", "not", "posted", "\"", "?", "Give", "the", "name", "of", "the", "business", "." ]
[ { "id": 8, "type": "value", "value": "Permit license or inspection report not posted" }, { "id": 5, "type": "column", "value": "risk_category" }, { "id": 3, "type": "column", "value": "business_id" }, { "id": 7, "type": "column", "value": "description" }...
[ { "entity_id": 0, "token_idxs": [ 26 ] }, { "entity_id": 1, "token_idxs": [ 11 ] }, { "entity_id": 2, "token_idxs": [ 29 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "B-TABLE", "O", "O", "O", "B-VALUE", "I-VALUE", "B-COLUMN", "I-COLUMN", "B-VALUE", "I-VALUE", "I-VALUE", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O" ]
4,117
book_publishing_company
bird:train.json:208
Among the publishers in the USA, how many of them have published books that are over $15?
SELECT COUNT(DISTINCT T1.pub_id) FROM titles AS T1 INNER JOIN publishers AS T2 ON T1.pub_id = T2.pub_id WHERE T2.country = 'USA' AND T1.price > 15
[ "Among", "the", "publishers", "in", "the", "USA", ",", "how", "many", "of", "them", "have", "published", "books", "that", "are", "over", "$", "15", "?" ]
[ { "id": 1, "type": "table", "value": "publishers" }, { "id": 3, "type": "column", "value": "country" }, { "id": 0, "type": "table", "value": "titles" }, { "id": 2, "type": "column", "value": "pub_id" }, { "id": 5, "type": "column", "value":...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 12 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 5 ] }, { "entity_id": 5, ...
[ "O", "O", "B-TABLE", "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
4,118
movielens
bird:train.json:2337
What is the total average movie directed by the directors who's quality and revenue is 4?
SELECT CAST(SUM(CASE WHEN T1.d_quality = 4 AND T1.avg_revenue = 4 THEN 1 ELSE 0 END) AS REAL) / COUNT(T2.movieid) FROM directors AS T1 INNER JOIN movies2directors AS T2 ON T1.directorid = T2.directorid
[ "What", "is", "the", "total", "average", "movie", "directed", "by", "the", "directors", "who", "'s", "quality", "and", "revenue", "is", "4", "?" ]
[ { "id": 1, "type": "table", "value": "movies2directors" }, { "id": 8, "type": "column", "value": "avg_revenue" }, { "id": 2, "type": "column", "value": "directorid" }, { "id": 0, "type": "table", "value": "directors" }, { "id": 6, "type": "colu...
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "O", "O", "O", "B-COLUMN", "B-TABLE", "O", "O", "B-TABLE", "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "B-VALUE", "O" ]
4,120
legislator
bird:train.json:4872
Among the Independent senators that started their term in 2011 and onwards, what are the official full names of the senators that caucused with the Democrat?
SELECT T1.official_full_name FROM current AS T1 INNER JOIN `current-terms` AS T2 ON T1.bioguide_id = T2.bioguide WHERE T2.party = 'Independent' AND strftime('%Y', T2.start) >= '2011' AND T2.type = 'sen' AND T2.caucus = 'Democrat'
[ "Among", "the", "Independent", "senators", "that", "started", "their", "term", "in", "2011", "and", "onwards", ",", "what", "are", "the", "official", "full", "names", "of", "the", "senators", "that", "caucused", "with", "the", "Democrat", "?" ]
[ { "id": 0, "type": "column", "value": "official_full_name" }, { "id": 2, "type": "table", "value": "current-terms" }, { "id": 3, "type": "column", "value": "bioguide_id" }, { "id": 6, "type": "value", "value": "Independent" }, { "id": 4, "type"...
[ { "entity_id": 0, "token_idxs": [ 16, 17, 18 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token...
[ "O", "O", "B-VALUE", "O", "O", "B-COLUMN", "O", "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "O" ]
4,121
cars
bird:train.json:3066
How much US dollars does a Ford Torino cost?
SELECT T2.price FROM data AS T1 INNER JOIN price AS T2 ON T1.ID = T2.ID WHERE T1.car_name = 'ford torino'
[ "How", "much", "US", "dollars", "does", "a", "Ford", "Torino", "cost", "?" ]
[ { "id": 4, "type": "value", "value": "ford torino" }, { "id": 3, "type": "column", "value": "car_name" }, { "id": 0, "type": "column", "value": "price" }, { "id": 2, "type": "table", "value": "price" }, { "id": 1, "type": "table", "value": ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 6, 7 ] }, { "entity_id": 5, "token_idxs": [] ...
[ "O", "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "O", "O" ]
4,122
department_management
spider:train_spider.json:7
What are the names of the states where at least 3 heads were born?
SELECT born_state FROM head GROUP BY born_state HAVING count(*) >= 3
[ "What", "are", "the", "names", "of", "the", "states", "where", "at", "least", "3", "heads", "were", "born", "?" ]
[ { "id": 1, "type": "column", "value": "born_state" }, { "id": 0, "type": "table", "value": "head" }, { "id": 2, "type": "value", "value": "3" } ]
[ { "entity_id": 0, "token_idxs": [ 11 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "B-VALUE", "B-TABLE", "O", "O", "O" ]
4,123
game_1
spider:train_spider.json:6018
What is the first and last name of the student who played the most sports?
SELECT T2.Fname , T2.Lname FROM Sportsinfo AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID ORDER BY count(*) DESC LIMIT 1
[ "What", "is", "the", "first", "and", "last", "name", "of", "the", "student", "who", "played", "the", "most", "sports", "?" ]
[ { "id": 3, "type": "table", "value": "sportsinfo" }, { "id": 4, "type": "table", "value": "student" }, { "id": 0, "type": "column", "value": "stuid" }, { "id": 1, "type": "column", "value": "fname" }, { "id": 2, "type": "column", "value": "...
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [ 14 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-TABLE", "O" ]
4,124
college_1
spider:train_spider.json:3332
What are the first names of student who only took one course?
SELECT T1.stu_fname FROM student AS T1 JOIN enroll AS T2 ON T1.stu_num = T2.stu_num GROUP BY T2.stu_num HAVING count(*) = 1
[ "What", "are", "the", "first", "names", "of", "student", "who", "only", "took", "one", "course", "?" ]
[ { "id": 1, "type": "column", "value": "stu_fname" }, { "id": 0, "type": "column", "value": "stu_num" }, { "id": 2, "type": "table", "value": "student" }, { "id": 3, "type": "table", "value": "enroll" }, { "id": 4, "type": "value", "value": ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3, 4 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "toke...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-TABLE", "O", "O", "O", "O", "O", "O" ]
4,125
shipping
bird:train.json:5621
What was the maximum weight of the shipment carried to Boston? Name the customer of that shipment.
SELECT T1.weight, T2.cust_name FROM shipment AS T1 INNER JOIN customer AS T2 ON T1.cust_id = T2.cust_id INNER JOIN city AS T3 ON T3.city_id = T1.city_id WHERE T3.city_name = 'Boston' ORDER BY T1.weight DESC LIMIT 1
[ "What", "was", "the", "maximum", "weight", "of", "the", "shipment", "carried", "to", "Boston", "?", "Name", "the", "customer", "of", "that", "shipment", "." ]
[ { "id": 1, "type": "column", "value": "cust_name" }, { "id": 3, "type": "column", "value": "city_name" }, { "id": 5, "type": "table", "value": "shipment" }, { "id": 6, "type": "table", "value": "customer" }, { "id": 7, "type": "column", "va...
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 12 ] }, { "entity_id": 4, "token_idxs": [ 10 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-VALUE", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "B-TABLE", "O" ]
4,126
legislator
bird:train.json:4801
Among the legislators who started a term on 2nd December 1793, how many of them were males?
SELECT COUNT(T1.bioguide_id) FROM historical AS T1 INNER JOIN `historical-terms` AS T2 ON T1.bioguide_id = T2.bioguide WHERE T1.gender_bio = 'M' AND T2.start = '1793-12-02'
[ "Among", "the", "legislators", "who", "started", "a", "term", "on", "2nd", "December", "1793", ",", "how", "many", "of", "them", "were", "males", "?" ]
[ { "id": 1, "type": "table", "value": "historical-terms" }, { "id": 2, "type": "column", "value": "bioguide_id" }, { "id": 0, "type": "table", "value": "historical" }, { "id": 4, "type": "column", "value": "gender_bio" }, { "id": 7, "type": "val...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id...
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
4,127
public_review_platform
bird:train.json:3909
How many business have been reviewed by user ID 3 and how long have this user been with Yelp?
SELECT COUNT(T1.business_id) , strftime('%Y', 'now') - T2.user_yelping_since_year FROM Reviews AS T1 INNER JOIN Users AS T2 ON T1.user_id = T2.user_id WHERE T1.user_id = 3
[ "How", "many", "business", "have", "been", "reviewed", "by", "user", "ID", "3", "and", "how", "long", "have", "this", "user", "been", "with", "Yelp", "?" ]
[ { "id": 5, "type": "column", "value": "user_yelping_since_year" }, { "id": 4, "type": "column", "value": "business_id" }, { "id": 0, "type": "table", "value": "reviews" }, { "id": 2, "type": "column", "value": "user_id" }, { "id": 1, "type": "t...
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [ 15 ] }, { "entity_id": 2, "token_idxs": [ 7, 8 ] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [ 2 ...
[ "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "B-COLUMN", "I-COLUMN", "B-VALUE", "O", "B-VALUE", "O", "O", "O", "B-TABLE", "O", "O", "O", "O" ]
4,128
customers_and_products_contacts
spider:train_spider.json:5667
Show the product type and name for the products with price higher than 1000 or lower than 500.
SELECT product_type_code , product_name FROM products WHERE product_price > 1000 OR product_price < 500
[ "Show", "the", "product", "type", "and", "name", "for", "the", "products", "with", "price", "higher", "than", "1000", "or", "lower", "than", "500", "." ]
[ { "id": 1, "type": "column", "value": "product_type_code" }, { "id": 3, "type": "column", "value": "product_price" }, { "id": 2, "type": "column", "value": "product_name" }, { "id": 0, "type": "table", "value": "products" }, { "id": 4, "type": ...
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 2 ] }, { "entity_id": 3, "token_idxs": [ 9, 10 ] }, { "entity_id": 4, "token_idxs": [ 13 ...
[ "O", "O", "B-COLUMN", "B-COLUMN", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "I-COLUMN", "O", "O", "B-VALUE", "O", "O", "O", "B-VALUE", "O" ]
4,129
image_and_language
bird:train.json:7527
Define the onion's bounding box on image no. 285930.
SELECT T1.X, T1.Y, T1.W, T1.H FROM IMG_OBJ AS T1 INNER JOIN OBJ_CLASSES AS T2 ON T1.OBJ_CLASS_ID = T2.OBJ_CLASS_ID WHERE T1.IMG_ID = 285930 AND T2.OBJ_CLASS = 'onion'
[ "Define", "the", "onion", "'s", "bounding", "box", "on", "image", "no", ".", "285930", "." ]
[ { "id": 6, "type": "column", "value": "obj_class_id" }, { "id": 5, "type": "table", "value": "obj_classes" }, { "id": 9, "type": "column", "value": "obj_class" }, { "id": 4, "type": "table", "value": "img_obj" }, { "id": 7, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id...
[ "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
4,130
cre_Students_Information_Systems
bird:test.json:441
List the biographical data and student id for the students who take 2 or more classes and the students who have less than 2 detentions.
SELECT T1.bio_data , T1.student_id FROM Students AS T1 JOIN Classes AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) >= 2 UNION SELECT T1.bio_data , T1.student_id FROM Students AS T1 JOIN Detention AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) < 2
[ "List", "the", "biographical", "data", "and", "student", "i", "d", "for", "the", "students", "who", "take", "2", "or", "more", "classes", "and", "the", "students", "who", "have", "less", "than", "2", "detentions", "." ]
[ { "id": 0, "type": "column", "value": "student_id" }, { "id": 5, "type": "table", "value": "detention" }, { "id": 1, "type": "column", "value": "bio_data" }, { "id": 2, "type": "table", "value": "students" }, { "id": 3, "type": "table", "va...
[ { "entity_id": 0, "token_idxs": [ 5, 6, 7 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 19 ] }, { "entity_id": 3, "token_idxs": [ 16 ] }, { "entity_id": 4, "token_idxs": [ ...
[ "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "B-TABLE", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-TABLE", "O" ]
4,131
store_product
spider:train_spider.json:4922
Find the number of stores in each city.
SELECT t3.headquartered_city , count(*) FROM store AS t1 JOIN store_district AS t2 ON t1.store_id = t2.store_id JOIN district AS t3 ON t2.district_id = t3.district_id GROUP BY t3.headquartered_city
[ "Find", "the", "number", "of", "stores", "in", "each", "city", "." ]
[ { "id": 0, "type": "column", "value": "headquartered_city" }, { "id": 3, "type": "table", "value": "store_district" }, { "id": 4, "type": "column", "value": "district_id" }, { "id": 1, "type": "table", "value": "district" }, { "id": 5, "type": ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 4 ] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "O", "B-TABLE", "B-TABLE", "O", "O", "O" ]
4,132
store_1
spider:train_spider.json:604
How many employees who are IT staff are from each city?
SELECT count(*) , city FROM employees WHERE title = 'IT Staff' GROUP BY city
[ "How", "many", "employees", "who", "are", "IT", "staff", "are", "from", "each", "city", "?" ]
[ { "id": 0, "type": "table", "value": "employees" }, { "id": 3, "type": "value", "value": "IT Staff" }, { "id": 2, "type": "column", "value": "title" }, { "id": 1, "type": "column", "value": "city" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 10 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 5, 6 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id"...
[ "O", "O", "B-TABLE", "O", "O", "B-VALUE", "I-VALUE", "O", "O", "O", "B-COLUMN", "O" ]
4,134
trains
bird:train.json:703
Please list the shapes of all the head cars on the trains that run in the east direction.
SELECT T1.shape FROM cars AS T1 INNER JOIN trains AS T2 ON T1.train_id = T2.id WHERE T2.direction = 'east' AND T1.position = 1 GROUP BY T1.shape
[ "Please", "list", "the", "shapes", "of", "all", "the", "head", "cars", "on", "the", "trains", "that", "run", "in", "the", "east", "direction", "." ]
[ { "id": 5, "type": "column", "value": "direction" }, { "id": 3, "type": "column", "value": "train_id" }, { "id": 7, "type": "column", "value": "position" }, { "id": 2, "type": "table", "value": "trains" }, { "id": 0, "type": "column", "valu...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 8 ] }, { "entity_id": 2, "token_idxs": [ 11 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-TABLE", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-VALUE", "B-COLUMN", "O" ]
4,135
human_resources
bird:train.json:8968
What is the average salary of all employees with a 2 year degree position?
SELECT AVG(CAST(REPLACE(SUBSTR(T1.salary, 4), ',', '') AS REAL)) FROM employee AS T1 INNER JOIN position AS T2 ON T1.positionID = T2.positionID WHERE T2.educationrequired = '2 year degree'
[ "What", "is", "the", "average", "salary", "of", "all", "employees", "with", "a", "2", "year", "degree", "position", "?" ]
[ { "id": 2, "type": "column", "value": "educationrequired" }, { "id": 3, "type": "value", "value": "2 year degree" }, { "id": 4, "type": "column", "value": "positionid" }, { "id": 0, "type": "table", "value": "employee" }, { "id": 1, "type": "ta...
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "entity_id": 1, "token_idxs": [ 13 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 10, 11, 12 ] }, { "entity_id": 4, "token_idxs": [] }, { ...
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "B-TABLE", "O" ]
4,136
address
bird:train.json:5172
Compare the numbers of postal points under Smith Adrian and Heck Joe.
SELECT CASE WHEN COUNT(CASE WHEN T1.first_name = 'Smith' AND T1.last_name = 'Adrian' THEN T2.zip_code ELSE NULL END) > COUNT(CASE WHEN T1.first_name = 'Heck' AND T1.last_name = 'Joe' THEN T2.zip_code ELSE NULL END) THEN 'Smith Adrian>Heck Joe' ELSE 'Smith Adrian<=Heck Joe' END AS COMPARE FROM congress AS T1 INNER JOIN ...
[ "Compare", "the", "numbers", "of", "postal", "points", "under", "Smith", "Adrian", "and", "Heck", "Joe", "." ]
[ { "id": 2, "type": "value", "value": "Smith Adrian<=Heck Joe" }, { "id": 5, "type": "value", "value": "Smith Adrian>Heck Joe" }, { "id": 3, "type": "column", "value": "cognress_rep_id" }, { "id": 1, "type": "table", "value": "zip_congress" }, { "id...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 9 ] }, { ...
[ "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "B-VALUE", "B-VALUE", "B-VALUE", "B-VALUE", "O" ]
4,137
soccer_2016
bird:train.json:1934
Give me the match ID and date of the matches that were held in Kingsmead for three consecutive days.
SELECT T1.Match_Id, T1.Match_Date FROM `Match` AS T1 INNER JOIN Venue AS T2 ON T1.Venue_Id = T2.Venue_Id WHERE T2.Venue_Name = 'Kingsmead'
[ "Give", "me", "the", "match", "ID", "and", "date", "of", "the", "matches", "that", "were", "held", "in", "Kingsmead", "for", "three", "consecutive", "days", "." ]
[ { "id": 1, "type": "column", "value": "match_date" }, { "id": 4, "type": "column", "value": "venue_name" }, { "id": 5, "type": "value", "value": "Kingsmead" }, { "id": 0, "type": "column", "value": "match_id" }, { "id": 6, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 9 ] }, { "entity_id": 2, "token_idxs": [ 3 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "O", "O" ]
4,138
boat_1
bird:test.json:877
What is the name of all sailors whose rating is higher than any sailor named Luis?
SELECT name FROM Sailors WHERE rating > (SELECT min(rating) FROM Sailors WHERE name = 'Luis')
[ "What", "is", "the", "name", "of", "all", "sailors", "whose", "rating", "is", "higher", "than", "any", "sailor", "named", "Luis", "?" ]
[ { "id": 0, "type": "table", "value": "sailors" }, { "id": 2, "type": "column", "value": "rating" }, { "id": 1, "type": "column", "value": "name" }, { "id": 3, "type": "value", "value": "Luis" } ]
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [ 15 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity...
[ "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
4,139
college_1
spider:train_spider.json:3209
What is the number of professors for different school?
SELECT count(*) , T1.school_code FROM department AS T1 JOIN professor AS T2 ON T1.dept_code = T2.dept_code GROUP BY T1.school_code
[ "What", "is", "the", "number", "of", "professors", "for", "different", "school", "?" ]
[ { "id": 0, "type": "column", "value": "school_code" }, { "id": 1, "type": "table", "value": "department" }, { "id": 2, "type": "table", "value": "professor" }, { "id": 3, "type": "column", "value": "dept_code" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "O", "O", "O", "B-TABLE", "O", "B-TABLE", "B-COLUMN", "O" ]
4,140
disney
bird:train.json:4694
Describe the voice actors and villains in Cinderella.
SELECT T1.`voice-actor`, T2.villian FROM `voice-actors` AS T1 INNER JOIN characters AS T2 ON T1.movie = T2.movie_title WHERE T2.movie_title = 'Cinderella'
[ "Describe", "the", "voice", "actors", "and", "villains", "in", "Cinderella", "." ]
[ { "id": 2, "type": "table", "value": "voice-actors" }, { "id": 0, "type": "column", "value": "voice-actor" }, { "id": 4, "type": "column", "value": "movie_title" }, { "id": 3, "type": "table", "value": "characters" }, { "id": 5, "type": "value"...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 3 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-COLUMN", "B-TABLE", "O", "B-COLUMN", "O", "B-VALUE", "O" ]
4,141
address
bird:train.json:5165
Among the postal points in the District of Columbia, how many of them have an area with above 20000 black population?
SELECT COUNT(T1.zip_code) FROM country AS T1 INNER JOIN zip_data AS T2 ON T1.zip_code = T2.zip_code WHERE T1.county = 'DISTRICT OF COLUMBIA' AND T2.black_population > 20000
[ "Among", "the", "postal", "points", "in", "the", "District", "of", "Columbia", ",", "how", "many", "of", "them", "have", "an", "area", "with", "above", "20000", "black", "population", "?" ]
[ { "id": 4, "type": "value", "value": "DISTRICT OF COLUMBIA" }, { "id": 5, "type": "column", "value": "black_population" }, { "id": 1, "type": "table", "value": "zip_data" }, { "id": 2, "type": "column", "value": "zip_code" }, { "id": 0, "type":...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 6, 7, 8 ] }, { "entity_id": 5, "token_id...
[ "O", "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "B-COLUMN", "I-COLUMN", "O" ]
4,142
formula_1
bird:dev.json:925
Please give the link of the website that shows more information about the circuits the Spanish Grand Prix used in 2009.
SELECT T1.url FROM circuits AS T1 INNER JOIN races AS T2 ON T2.circuitID = T1.circuitId WHERE T2.year = 2009 AND T2.name = 'Spanish Grand Prix'
[ "Please", "give", "the", "link", "of", "the", "website", "that", "shows", "more", "information", "about", "the", "circuits", "the", "Spanish", "Grand", "Prix", "used", "in", "2009", "." ]
[ { "id": 7, "type": "value", "value": "Spanish Grand Prix" }, { "id": 3, "type": "column", "value": "circuitid" }, { "id": 1, "type": "table", "value": "circuits" }, { "id": 2, "type": "table", "value": "races" }, { "id": 4, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 13 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 20 ...
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O", "O", "B-VALUE", "O" ]
4,143
menu
bird:train.json:5526
What dishes made their first and last appearances in 1855 and 1900, respectively?
SELECT name FROM Dish WHERE first_appeared = 1855 AND last_appeared = 1900
[ "What", "dishes", "made", "their", "first", "and", "last", "appearances", "in", "1855", "and", "1900", ",", "respectively", "?" ]
[ { "id": 2, "type": "column", "value": "first_appeared" }, { "id": 4, "type": "column", "value": "last_appeared" }, { "id": 0, "type": "table", "value": "dish" }, { "id": 1, "type": "column", "value": "name" }, { "id": 3, "type": "value", "v...
[ { "entity_id": 0, "token_idxs": [ 1 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 4, 5 ] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [ 6, 7 ] }...
[ "O", "B-TABLE", "O", "O", "B-COLUMN", "I-COLUMN", "B-COLUMN", "I-COLUMN", "O", "B-VALUE", "O", "B-VALUE", "O", "O", "O" ]
4,144
thrombosis_prediction
bird:dev.json:1193
Excluding all P only ANA Pattern patients, how many of the remainder are women born between 1980 and 1989?
SELECT COUNT(DISTINCT T1.ID) FROM Patient AS T1 INNER JOIN Examination AS T2 ON T1.ID = T2.ID WHERE T2.`ANA Pattern` != 'P' AND STRFTIME('%Y', T1.Birthday) BETWEEN '1980' AND '1989' AND T1.SEX = 'F'
[ "Excluding", "all", "P", "only", "ANA", "Pattern", "patients", ",", "how", "many", "of", "the", "remainder", "are", "women", "born", "between", "1980", "and", "1989", "?" ]
[ { "id": 1, "type": "table", "value": "examination" }, { "id": 3, "type": "column", "value": "ANA Pattern" }, { "id": 10, "type": "column", "value": "birthday" }, { "id": 0, "type": "table", "value": "patient" }, { "id": 5, "type": "value", ...
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 4, 5 ] }, { "entity_id": 4, "token_idxs": [ 2 ] }, { "entity_id":...
[ "O", "O", "B-VALUE", "O", "B-COLUMN", "I-COLUMN", "B-TABLE", "O", "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "B-VALUE", "O" ]
4,145
university
bird:train.json:8031
How many institutions with over 50,000 students in 2011 had a percentage of oversea students of more than 10%?
SELECT COUNT(*) FROM university_year WHERE year = 2011 AND num_students > 50000 AND pct_international_students > 10
[ "How", "many", "institutions", "with", "over", "50,000", "students", "in", "2011", "had", "a", "percentage", "of", "oversea", "students", "of", "more", "than", "10", "%", "?" ]
[ { "id": 5, "type": "column", "value": "pct_international_students" }, { "id": 0, "type": "table", "value": "university_year" }, { "id": 3, "type": "column", "value": "num_students" }, { "id": 4, "type": "value", "value": "50000" }, { "id": 1, "...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [ 5 ] }, { "entity_id": 5, "...
[ "O", "O", "O", "O", "O", "B-VALUE", "B-COLUMN", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "O" ]
4,146
race_track
spider:train_spider.json:771
List the race class with at least two races.
SELECT CLASS FROM race GROUP BY CLASS HAVING count(*) >= 2
[ "List", "the", "race", "class", "with", "at", "least", "two", "races", "." ]
[ { "id": 1, "type": "column", "value": "class" }, { "id": 0, "type": "table", "value": "race" }, { "id": 2, "type": "value", "value": "2" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "O", "O", "O" ]
4,147
professional_basketball
bird:train.json:2804
List all the coaches with more game lost than won from year 2000-2010. List the coach ID, team name and year.
SELECT DISTINCT T1.coachID, T2.tmID, T1.year FROM coaches AS T1 INNER JOIN teams AS T2 ON T1.tmID = T2.tmID AND T1.year = T2.year WHERE T1.year BETWEEN 2000 AND 2010 AND T2.lost > T2.won
[ "List", "all", "the", "coaches", "with", "more", "game", "lost", "than", "won", "from", "year", "2000", "-", "2010", ".", "List", "the", "coach", "ID", ",", "team", "name", "and", "year", "." ]
[ { "id": 0, "type": "column", "value": "coachid" }, { "id": 3, "type": "table", "value": "coaches" }, { "id": 4, "type": "table", "value": "teams" }, { "id": 1, "type": "column", "value": "tmid" }, { "id": 2, "type": "column", "value": "year...
[ { "entity_id": 0, "token_idxs": [ 18 ] }, { "entity_id": 1, "token_idxs": [ 19 ] }, { "entity_id": 2, "token_idxs": [ 24 ] }, { "entity_id": 3, "token_idxs": [ 3 ] }, { "entity_id": 4, "token_idxs": [ 21 ] },...
[ "O", "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "O", "B-VALUE", "O", "B-VALUE", "O", "O", "O", "B-COLUMN", "B-COLUMN", "O", "B-TABLE", "O", "O", "B-COLUMN", "O" ]
4,148
formula_1
spider:train_spider.json:2161
List the forename and surname of all distinct drivers who once had laptime less than 93000 milliseconds?
SELECT DISTINCT T1.forename , T1.surname FROM drivers AS T1 JOIN laptimes AS T2 ON T1.driverid = T2.driverid WHERE T2.milliseconds < 93000
[ "List", "the", "forename", "and", "surname", "of", "all", "distinct", "drivers", "who", "once", "had", "laptime", "less", "than", "93000", "milliseconds", "?" ]
[ { "id": 4, "type": "column", "value": "milliseconds" }, { "id": 0, "type": "column", "value": "forename" }, { "id": 3, "type": "table", "value": "laptimes" }, { "id": 6, "type": "column", "value": "driverid" }, { "id": 1, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [ 12 ] }, { "entity_id": 4, "token_idxs": [ 16 ] }, ...
[ "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-TABLE", "O", "O", "B-VALUE", "B-COLUMN", "O" ]
4,149
regional_sales
bird:train.json:2702
How many sales channels does the sales team have in the Midwest?
SELECT COUNT(T1.`Sales Channel`) FROM `Sales Orders` AS T1 INNER JOIN `Sales Team` AS T2 ON T2.SalesTeamID = T1._SalesTeamID WHERE T2.Region = 'Midwest'
[ "How", "many", "sales", "channels", "does", "the", "sales", "team", "have", "in", "the", "Midwest", "?" ]
[ { "id": 4, "type": "column", "value": "Sales Channel" }, { "id": 0, "type": "table", "value": "Sales Orders" }, { "id": 6, "type": "column", "value": "_salesteamid" }, { "id": 5, "type": "column", "value": "salesteamid" }, { "id": 1, "type": "t...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 6, 7 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 11 ] }, { "entity_id": 4, "token_idxs": [ 2, 3 ] }, { "e...
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "I-TABLE", "O", "O", "O", "B-VALUE", "O" ]
4,150
music_2
spider:train_spider.json:5177
return all columns of the albums created in the year of 2012.
SELECT * FROM Albums WHERE YEAR = 2012
[ "return", "all", "columns", "of", "the", "albums", "created", "in", "the", "year", "of", "2012", "." ]
[ { "id": 0, "type": "table", "value": "albums" }, { "id": 1, "type": "column", "value": "year" }, { "id": 2, "type": "value", "value": "2012" } ]
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [ 9 ] }, { "entity_id": 2, "token_idxs": [ 11 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "O", "B-VALUE", "O" ]
4,151
music_1
spider:train_spider.json:3552
Find the file format that is used by the most files.
SELECT formats FROM files GROUP BY formats ORDER BY COUNT (*) DESC LIMIT 1
[ "Find", "the", "file", "format", "that", "is", "used", "by", "the", "most", "files", "." ]
[ { "id": 1, "type": "column", "value": "formats" }, { "id": 0, "type": "table", "value": "files" } ]
[ { "entity_id": 0, "token_idxs": [ 10 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "B-TABLE", "O" ]
4,152
movies_4
bird:train.json:461
Give the names of the female cast in Movie No. 1865.
SELECT T2.person_name FROM movie_cast AS T1 INNER JOIN person AS T2 ON T1.person_id = T2.person_id INNER JOIN gender AS T3 ON T1.gender_id = T3.gender_id WHERE T1.movie_id = 1865 AND T3.gender = 'Female'
[ "Give", "the", "names", "of", "the", "female", "cast", "in", "Movie", "No", ".", "1865", "." ]
[ { "id": 0, "type": "column", "value": "person_name" }, { "id": 2, "type": "table", "value": "movie_cast" }, { "id": 4, "type": "column", "value": "gender_id" }, { "id": 9, "type": "column", "value": "person_id" }, { "id": 5, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 8 ] }, { ...
[ "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "O" ]
4,153
behavior_monitoring
spider:train_spider.json:3097
What is the incident type description for the incident type with code "VIOLENCE"?
SELECT incident_type_description FROM Ref_Incident_Type WHERE incident_type_code = "VIOLENCE"
[ "What", "is", "the", "incident", "type", "description", "for", "the", "incident", "type", "with", "code", "\"", "VIOLENCE", "\"", "?" ]
[ { "id": 1, "type": "column", "value": "incident_type_description" }, { "id": 2, "type": "column", "value": "incident_type_code" }, { "id": 0, "type": "table", "value": "ref_incident_type" }, { "id": 3, "type": "column", "value": "VIOLENCE" } ]
[ { "entity_id": 0, "token_idxs": [ 3, 4 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [ 8, 9, 10, 11 ] }, { "entity_id": 3, "token_idxs": [ 13 ] }, { "entity_id": 4, ...
[ "O", "O", "O", "B-TABLE", "I-TABLE", "B-COLUMN", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "I-COLUMN", "O", "B-COLUMN", "O", "O" ]
4,154
movie
bird:train.json:753
How tall is the actor who played "Lurch"?
SELECT T2.`Height (Inches)` FROM characters AS T1 INNER JOIN actor AS T2 ON T1.ActorID = T2.ActorID WHERE T1.`Character Name` = 'Lurch'
[ "How", "tall", "is", "the", "actor", "who", "played", "\"", "Lurch", "\"", "?" ]
[ { "id": 0, "type": "column", "value": "Height (Inches)" }, { "id": 3, "type": "column", "value": "Character Name" }, { "id": 1, "type": "table", "value": "characters" }, { "id": 5, "type": "column", "value": "actorid" }, { "id": 2, "type": "tab...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 4 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 8 ] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-VALUE", "O", "O" ]
4,155
mondial_geo
bird:train.json:8272
Which two countries does the Detroit River flow through? Give the full name of the country.
SELECT T3.Name FROM located AS T1 INNER JOIN river AS T2 ON T1.River = T2.Name INNER JOIN country AS T3 ON T3.Code = T1.Country WHERE T2.Name = 'Detroit River'
[ "Which", "two", "countries", "does", "the", "Detroit", "River", "flow", "through", "?", "Give", "the", "full", "name", "of", "the", "country", "." ]
[ { "id": 2, "type": "value", "value": "Detroit River" }, { "id": 1, "type": "table", "value": "country" }, { "id": 3, "type": "table", "value": "located" }, { "id": 6, "type": "column", "value": "country" }, { "id": 4, "type": "table", "valu...
[ { "entity_id": 0, "token_idxs": [ 13 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "O", "O", "O", "B-VALUE", "B-COLUMN", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O" ]
4,156
match_season
spider:train_spider.json:1068
Show the players and the years played.
SELECT Player , Years_Played FROM player
[ "Show", "the", "players", "and", "the", "years", "played", "." ]
[ { "id": 2, "type": "column", "value": "years_played" }, { "id": 0, "type": "table", "value": "player" }, { "id": 1, "type": "column", "value": "player" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 5, 6 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "toke...
[ "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "I-COLUMN", "O" ]
4,157
entertainment_awards
spider:train_spider.json:4617
Show the number of audience in year 2008 or 2010.
SELECT Num_of_Audience FROM festival_detail WHERE YEAR = 2008 OR YEAR = 2010
[ "Show", "the", "number", "of", "audience", "in", "year", "2008", "or", "2010", "." ]
[ { "id": 0, "type": "table", "value": "festival_detail" }, { "id": 1, "type": "column", "value": "num_of_audience" }, { "id": 2, "type": "column", "value": "year" }, { "id": 3, "type": "value", "value": "2008" }, { "id": 4, "type": "value", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2, 3, 4 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [ 7 ] }, { "entity_id": 4, "token_idxs": [ 9 ] }...
[ "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "B-COLUMN", "B-VALUE", "O", "B-VALUE", "O" ]
4,158
film_rank
spider:train_spider.json:4153
Which studios have never worked with the director Walter Hill?
SELECT Studio FROM film EXCEPT SELECT Studio FROM film WHERE Director = "Walter Hill"
[ "Which", "studios", "have", "never", "worked", "with", "the", "director", "Walter", "Hill", "?" ]
[ { "id": 3, "type": "column", "value": "Walter Hill" }, { "id": 2, "type": "column", "value": "director" }, { "id": 1, "type": "column", "value": "studio" }, { "id": 0, "type": "table", "value": "film" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 1 ] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [ 8, 9 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id":...
[ "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-COLUMN", "B-COLUMN", "I-COLUMN", "O" ]
4,159
icfp_1
spider:train_spider.json:2901
Find the country that the most papers are affiliated with.
SELECT t1.country FROM inst AS t1 JOIN authorship AS t2 ON t1.instid = t2.instid JOIN papers AS t3 ON t2.paperid = t3.paperid GROUP BY t1.country ORDER BY count(*) DESC LIMIT 1
[ "Find", "the", "country", "that", "the", "most", "papers", "are", "affiliated", "with", "." ]
[ { "id": 3, "type": "table", "value": "authorship" }, { "id": 0, "type": "column", "value": "country" }, { "id": 4, "type": "column", "value": "paperid" }, { "id": 1, "type": "table", "value": "papers" }, { "id": 5, "type": "column", "value"...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "B-COLUMN", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "O", "O", "O", "O" ]
4,160
public_review_platform
bird:train.json:4129
What is the category of the business with short review length and highest review stars within business ID from 7 to 14?
SELECT DISTINCT T3.category_name FROM Reviews AS T1 INNER JOIN Business_Categories AS T2 ON T1.business_id = T2.business_id INNER JOIN Categories AS T3 ON T2.category_id = T3.category_id WHERE T2.business_id >= 7 AND T2.business_id < 15 AND T1.review_length = 'Short' AND T1.review_stars = ( SELECT MAX(review_stars) FRO...
[ "What", "is", "the", "category", "of", "the", "business", "with", "short", "review", "length", "and", "highest", "review", "stars", "within", "business", "ID", "from", "7", "to", "14", "?" ]
[ { "id": 3, "type": "table", "value": "business_categories" }, { "id": 0, "type": "column", "value": "category_name" }, { "id": 8, "type": "column", "value": "review_length" }, { "id": 10, "type": "column", "value": "review_stars" }, { "id": 4, ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 13 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-VALUE", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "O", "B-VALUE", "O", "O", "O" ]
4,161
talkingdata
bird:train.json:1049
How many female users use ZenFone 5 devices?
SELECT COUNT(T1.gender) FROM gender_age AS T1 INNER JOIN phone_brand_device_model2 AS T2 ON T2.device_id = T1.device_id WHERE T1.gender = 'F' AND T2.device_model = 'ZenFone 5'
[ "How", "many", "female", "users", "use", "ZenFone", "5", "devices", "?" ]
[ { "id": 1, "type": "table", "value": "phone_brand_device_model2" }, { "id": 5, "type": "column", "value": "device_model" }, { "id": 0, "type": "table", "value": "gender_age" }, { "id": 3, "type": "column", "value": "device_id" }, { "id": 6, "ty...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 7 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { ...
[ "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "B-COLUMN", "O" ]
4,162
election_representative
spider:train_spider.json:1177
What are the minimum and maximum vote percents of elections?
SELECT min(Vote_Percent) , max(Vote_Percent) FROM election
[ "What", "are", "the", "minimum", "and", "maximum", "vote", "percents", "of", "elections", "?" ]
[ { "id": 1, "type": "column", "value": "vote_percent" }, { "id": 0, "type": "table", "value": "election" } ]
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [ 6, 7 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "toke...
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-TABLE", "O" ]
4,163
activity_1
spider:train_spider.json:6768
Find the number of activities available.
SELECT count(*) FROM Activity
[ "Find", "the", "number", "of", "activities", "available", "." ]
[ { "id": 0, "type": "table", "value": "activity" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { ...
[ "O", "O", "O", "O", "B-TABLE", "O", "O" ]
4,164
e_commerce
bird:test.json:117
What are the tracking numbers and dates for all shipments listed?
SELECT shipment_tracking_number , shipment_date FROM Shipments
[ "What", "are", "the", "tracking", "numbers", "and", "dates", "for", "all", "shipments", "listed", "?" ]
[ { "id": 1, "type": "column", "value": "shipment_tracking_number" }, { "id": 2, "type": "column", "value": "shipment_date" }, { "id": 0, "type": "table", "value": "shipments" } ]
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [ 2, 3, 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-TABLE", "O", "O" ]
4,165
party_people
spider:train_spider.json:2058
How many members are in each party?
SELECT T2.party_name , count(*) FROM Member AS T1 JOIN party AS T2 ON T1.party_id = T2.party_id GROUP BY T1.party_id
[ "How", "many", "members", "are", "in", "each", "party", "?" ]
[ { "id": 1, "type": "column", "value": "party_name" }, { "id": 0, "type": "column", "value": "party_id" }, { "id": 2, "type": "table", "value": "member" }, { "id": 3, "type": "table", "value": "party" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 2 ] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-TABLE", "O", "O", "O", "B-TABLE", "O" ]
4,166
school_bus
spider:train_spider.json:6361
Show the school name and type for schools without a school bus.
SELECT school , TYPE FROM school WHERE school_id NOT IN (SELECT school_id FROM school_bus)
[ "Show", "the", "school", "name", "and", "type", "for", "schools", "without", "a", "school", "bus", "." ]
[ { "id": 4, "type": "table", "value": "school_bus" }, { "id": 3, "type": "column", "value": "school_id" }, { "id": 0, "type": "table", "value": "school" }, { "id": 1, "type": "column", "value": "school" }, { "id": 2, "type": "column", "value...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 10 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [ 2 ] }, { "entity_id": 4, "token_idxs": [ 11 ] }, { "entit...
[ "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-COLUMN", "B-TABLE", "O" ]
4,167
movie_3
bird:train.json:9144
Who is the owner of email address "JEREMY.HURTADO@sakilacustomer.org"? Give the full name.
SELECT first_name, last_name FROM customer WHERE email = 'JEREMY.HURTADO@sakilacustomer.org'
[ "Who", "is", "the", "owner", "of", "email", "address", "\"", "JEREMY.HURTADO@sakilacustomer.org", "\"", "?", "Give", "the", "full", "name", "." ]
[ { "id": 4, "type": "value", "value": "JEREMY.HURTADO@sakilacustomer.org" }, { "id": 1, "type": "column", "value": "first_name" }, { "id": 2, "type": "column", "value": "last_name" }, { "id": 0, "type": "table", "value": "customer" }, { "id": 3, ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 14 ] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [ 8 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "B-COLUMN", "O" ]
4,168
tracking_grants_for_research
spider:train_spider.json:4331
What is the type and id of the organization that has the most research staff?
SELECT T1.organisation_type , T1.organisation_id FROM Organisations AS T1 JOIN Research_Staff AS T2 ON T1.organisation_id = T2.employer_organisation_id GROUP BY T1.organisation_id ORDER BY count(*) DESC LIMIT 1
[ "What", "is", "the", "type", "and", "i", "d", "of", "the", "organization", "that", "has", "the", "most", "research", "staff", "?" ]
[ { "id": 4, "type": "column", "value": "employer_organisation_id" }, { "id": 1, "type": "column", "value": "organisation_type" }, { "id": 0, "type": "column", "value": "organisation_id" }, { "id": 3, "type": "table", "value": "research_staff" }, { "...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 9 ] }, { "entity_id": 3, "token_idxs": [ 14, 15 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "to...
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-TABLE", "I-TABLE", "O" ]
4,169
institution_sports
bird:test.json:1656
Give the stadium of the institution which is the greatest enrollment.
SELECT Stadium FROM institution ORDER BY Enrollment DESC LIMIT 1
[ "Give", "the", "stadium", "of", "the", "institution", "which", "is", "the", "greatest", "enrollment", "." ]
[ { "id": 0, "type": "table", "value": "institution" }, { "id": 2, "type": "column", "value": "enrollment" }, { "id": 1, "type": "column", "value": "stadium" } ]
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-COLUMN", "O" ]
4,170
music_1
spider:train_spider.json:3628
What are the names of the different artists from Bangladesh who never received a rating higher than a 7?
SELECT DISTINCT artist_name FROM artist WHERE country = "Bangladesh" EXCEPT SELECT DISTINCT artist_name FROM song WHERE rating > 7
[ "What", "are", "the", "names", "of", "the", "different", "artists", "from", "Bangladesh", "who", "never", "received", "a", "rating", "higher", "than", "a", "7", "?" ]
[ { "id": 2, "type": "column", "value": "artist_name" }, { "id": 4, "type": "column", "value": "Bangladesh" }, { "id": 3, "type": "column", "value": "country" }, { "id": 0, "type": "table", "value": "artist" }, { "id": 5, "type": "column", "v...
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 9 ] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "B-COLUMN", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "B-VALUE", "O" ]
4,171
debit_card_specializing
bird:dev.json:1519
What was the product id of the transaction happened at 2012/8/23 21:20:00?
SELECT T1.ProductID FROM transactions_1k AS T1 INNER JOIN gasstations AS T2 ON T1.GasStationID = T2.GasStationID WHERE T1.Date = '2012-08-23' AND T1.Time = '21:20:00'
[ "What", "was", "the", "product", "i", "d", "of", "the", "transaction", "happened", "at", "2012/8/23", "21:20:00", "?" ]
[ { "id": 1, "type": "table", "value": "transactions_1k" }, { "id": 3, "type": "column", "value": "gasstationid" }, { "id": 2, "type": "table", "value": "gasstations" }, { "id": 5, "type": "value", "value": "2012-08-23" }, { "id": 0, "type": "col...
[ { "entity_id": 0, "token_idxs": [ 3, 4, 5 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "O", "O", "B-VALUE", "B-VALUE", "O" ]
4,172
debate
spider:train_spider.json:1494
What are the date and venue of each debate?
SELECT Date , Venue FROM debate
[ "What", "are", "the", "date", "and", "venue", "of", "each", "debate", "?" ]
[ { "id": 0, "type": "table", "value": "debate" }, { "id": 2, "type": "column", "value": "venue" }, { "id": 1, "type": "column", "value": "date" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "O", "B-TABLE", "O" ]
4,174
mental_health_survey
bird:train.json:4617
How many respondents who participated in the survey in 2014 work remotely at least 50% of the time?
SELECT COUNT(T1.AnswerText) FROM Answer AS T1 INNER JOIN Question AS T2 ON T1.QuestionID = T2.questionid WHERE T1.QuestionID = 93 AND T1.SurveyID = 2014 AND T1.AnswerText = 'Yes'
[ "How", "many", "respondents", "who", "participated", "in", "the", "survey", "in", "2014", "work", "remotely", "at", "least", "50", "%", "of", "the", "time", "?" ]
[ { "id": 2, "type": "column", "value": "answertext" }, { "id": 3, "type": "column", "value": "questionid" }, { "id": 1, "type": "table", "value": "question" }, { "id": 5, "type": "column", "value": "surveyid" }, { "id": 0, "type": "table", "...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 7 ] }, { ...
[ "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
4,175
gymnast
spider:train_spider.json:1743
Return the average horizontal bar points across all gymnasts.
SELECT avg(Horizontal_Bar_Points) FROM gymnast
[ "Return", "the", "average", "horizontal", "bar", "points", "across", "all", "gymnasts", "." ]
[ { "id": 1, "type": "column", "value": "horizontal_bar_points" }, { "id": 0, "type": "table", "value": "gymnast" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 3, 4, 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "O" ]
4,176
cs_semester
bird:train.json:908
Name the professor who got graduation from the University of Boston.
SELECT first_name, last_name FROM prof WHERE graduate_from = 'University of Boston'
[ "Name", "the", "professor", "who", "got", "graduation", "from", "the", "University", "of", "Boston", "." ]
[ { "id": 4, "type": "value", "value": "University of Boston" }, { "id": 3, "type": "column", "value": "graduate_from" }, { "id": 1, "type": "column", "value": "first_name" }, { "id": 2, "type": "column", "value": "last_name" }, { "id": 0, "type"...
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 0 ] }, { "entity_id": 3, "token_idxs": [ 5, 6 ] }, { "entity_id": 4, "token_idxs": [ 8, 10 ] ...
[ "B-COLUMN", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-VALUE", "B-TABLE", "B-VALUE", "O" ]
4,177
election
spider:train_spider.json:2768
Who were the governors of the parties associated with delegates from district 1?
SELECT T2.Governor FROM election AS T1 JOIN party AS T2 ON T1.Party = T2.Party_ID WHERE T1.District = 1
[ "Who", "were", "the", "governors", "of", "the", "parties", "associated", "with", "delegates", "from", "district", "1", "?" ]
[ { "id": 0, "type": "column", "value": "governor" }, { "id": 1, "type": "table", "value": "election" }, { "id": 3, "type": "column", "value": "district" }, { "id": 6, "type": "column", "value": "party_id" }, { "id": 2, "type": "table", "valu...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 11 ] }, { "entity_id": 4, "token_idxs": [ 12 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-COLUMN", "B-VALUE", "O" ]
4,178
movielens
bird:train.json:2293
List the ids and ratings of each actors played in the movie with the id 1722327?
SELECT T1.actorid, T1.a_quality FROM actors AS T1 INNER JOIN movies2actors AS T2 ON T1.actorid = T2.actorid WHERE T2.movieid = 1722327
[ "List", "the", "ids", "and", "ratings", "of", "each", "actors", "played", "in", "the", "movie", "with", "the", "i", "d", "1722327", "?" ]
[ { "id": 3, "type": "table", "value": "movies2actors" }, { "id": 1, "type": "column", "value": "a_quality" }, { "id": 0, "type": "column", "value": "actorid" }, { "id": 4, "type": "column", "value": "movieid" }, { "id": 5, "type": "value", "...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 11 ] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-VALUE", "O" ]
4,179
city_record
spider:train_spider.json:6276
What is the venue of the competition "1994 FIFA World Cup qualification" hosted by "Nanjing ( Jiangsu )"?
SELECT T3.venue FROM city AS T1 JOIN hosting_city AS T2 ON T1.city_id = T2.host_city JOIN MATCH AS T3 ON T2.match_id = T3.match_id WHERE T1.city = "Nanjing ( Jiangsu )" AND T3.competition = "1994 FIFA World Cup qualification"
[ "What", "is", "the", "venue", "of", "the", "competition", "\"", "1994", "FIFA", "World", "Cup", "qualification", "\"", "hosted", "by", "\"", "Nanjing", "(", "Jiangsu", ")", "\"", "?" ]
[ { "id": 8, "type": "column", "value": "1994 FIFA World Cup qualification" }, { "id": 6, "type": "column", "value": "Nanjing ( Jiangsu )" }, { "id": 3, "type": "table", "value": "hosting_city" }, { "id": 7, "type": "column", "value": "competition" }, { ...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { ...
[ "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O" ]
4,180
works_cycles
bird:train.json:7273
What is the highest amount of difference between the ordered quantity and actual quantity received in a single purchase order and to which vendor was the purchase order made?
SELECT T2.OrderQty - T2.ReceivedQty, VendorID FROM PurchaseOrderHeader AS T1 INNER JOIN PurchaseOrderDetail AS T2 ON T1.PurchaseOrderID = T2.PurchaseOrderID ORDER BY T2.OrderQty - T2.ReceivedQty DESC LIMIT 1
[ "What", "is", "the", "highest", "amount", "of", "difference", "between", "the", "ordered", "quantity", "and", "actual", "quantity", "received", "in", "a", "single", "purchase", "order", "and", "to", "which", "vendor", "was", "the", "purchase", "order", "made",...
[ { "id": 1, "type": "table", "value": "purchaseorderheader" }, { "id": 2, "type": "table", "value": "purchaseorderdetail" }, { "id": 5, "type": "column", "value": "purchaseorderid" }, { "id": 4, "type": "column", "value": "receivedqty" }, { "id": 0,...
[ { "entity_id": 0, "token_idxs": [ 23 ] }, { "entity_id": 1, "token_idxs": [ 28 ] }, { "entity_id": 2, "token_idxs": [ 18, 19 ] }, { "entity_id": 3, "token_idxs": [ 27 ] }, { "entity_id": 4, "token_idxs": [ 14...
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "I-TABLE", "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "B-COLUMN", "B-TABLE", "O" ]
4,181
shipping
bird:train.json:5651
How many shipments were shipped to customers living in California in year 2016?
SELECT COUNT(*) AS per FROM customer AS T1 INNER JOIN shipment AS T2 ON T1.cust_id = T2.cust_id WHERE STRFTIME('%Y', T2.ship_date) = '2016' AND T1.state = 'CA'
[ "How", "many", "shipments", "were", "shipped", "to", "customers", "living", "in", "California", "in", "year", "2016", "?" ]
[ { "id": 7, "type": "column", "value": "ship_date" }, { "id": 0, "type": "table", "value": "customer" }, { "id": 1, "type": "table", "value": "shipment" }, { "id": 2, "type": "column", "value": "cust_id" }, { "id": 4, "type": "column", "valu...
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 12 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "B-TABLE", "O", "B-COLUMN", "I-COLUMN", "B-TABLE", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
4,182
network_2
spider:train_spider.json:4463
What are the names of all friends who are from New York?
SELECT T2.name FROM Person AS T1 JOIN PersonFriend AS T2 ON T1.name = T2.friend WHERE T1.city = 'new york city'
[ "What", "are", "the", "names", "of", "all", "friends", "who", "are", "from", "New", "York", "?" ]
[ { "id": 4, "type": "value", "value": "new york city" }, { "id": 2, "type": "table", "value": "personfriend" }, { "id": 1, "type": "table", "value": "person" }, { "id": 5, "type": "column", "value": "friend" }, { "id": 0, "type": "column", "...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 10, 11 ] }, { "entity_id": 5, "to...
[ "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "O", "B-VALUE", "I-VALUE", "O" ]
4,183
flight_1
spider:train_spider.json:375
Show the name of employees with three lowest salaries.
SELECT name FROM Employee ORDER BY salary ASC LIMIT 3
[ "Show", "the", "name", "of", "employees", "with", "three", "lowest", "salaries", "." ]
[ { "id": 0, "type": "table", "value": "employee" }, { "id": 2, "type": "column", "value": "salary" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "O" ]
4,184
public_review_platform
bird:train.json:4121
What is the total number of active businesses in AZ with a medium review count?
SELECT COUNT(business_id) FROM Business WHERE review_count = 'Medium' AND state = 'AZ' AND active = 'true'
[ "What", "is", "the", "total", "number", "of", "active", "businesses", "in", "AZ", "with", "a", "medium", "review", "count", "?" ]
[ { "id": 2, "type": "column", "value": "review_count" }, { "id": 1, "type": "column", "value": "business_id" }, { "id": 0, "type": "table", "value": "business" }, { "id": 3, "type": "value", "value": "Medium" }, { "id": 6, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 13, 14 ] }, { "entity_id": 3, "token_idxs": [ 12 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_i...
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "B-TABLE", "O", "B-VALUE", "O", "O", "B-VALUE", "B-COLUMN", "I-COLUMN", "O" ]
4,185
train_station
spider:train_spider.json:6603
Show the names and main services for train stations that have the top three total number of passengers.
SELECT name , main_services FROM station ORDER BY total_passengers DESC LIMIT 3
[ "Show", "the", "names", "and", "main", "services", "for", "train", "stations", "that", "have", "the", "top", "three", "total", "number", "of", "passengers", "." ]
[ { "id": 3, "type": "column", "value": "total_passengers" }, { "id": 2, "type": "column", "value": "main_services" }, { "id": 0, "type": "table", "value": "station" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 4, 5 ] }, { "entity_id": 3, "token_idxs": [ 17 ] }, { "entity_id": 4, "token_idxs": [] }, { ...
[ "O", "O", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O" ]
4,186
region_building
bird:test.json:354
Sort buildings in descending order of the number of stories, and return their completion years.
SELECT Completed_Year FROM building ORDER BY Number_of_Stories DESC
[ "Sort", "buildings", "in", "descending", "order", "of", "the", "number", "of", "stories", ",", "and", "return", "their", "completion", "years", "." ]
[ { "id": 2, "type": "column", "value": "number_of_stories" }, { "id": 1, "type": "column", "value": "completed_year" }, { "id": 0, "type": "table", "value": "building" } ]
[ { "entity_id": 0, "token_idxs": [ 1 ] }, { "entity_id": 1, "token_idxs": [ 14, 15 ] }, { "entity_id": 2, "token_idxs": [ 7, 8, 9 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, ...
[ "O", "B-TABLE", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O" ]
4,187
works_cycles
bird:train.json:7229
List all active vendors who offer a purchasing web service.
SELECT Name FROM Vendor WHERE ActiveFlag = 1
[ "List", "all", "active", "vendors", "who", "offer", "a", "purchasing", "web", "service", "." ]
[ { "id": 2, "type": "column", "value": "activeflag" }, { "id": 0, "type": "table", "value": "vendor" }, { "id": 1, "type": "column", "value": "name" }, { "id": 3, "type": "value", "value": "1" } ]
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 2 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-COLUMN", "B-TABLE", "O", "O", "O", "O", "O", "O", "O" ]
4,188
restaurant
bird:train.json:1701
What cities are located in Northern California?
SELECT city FROM geographic WHERE region = 'northern california'
[ "What", "cities", "are", "located", "in", "Northern", "California", "?" ]
[ { "id": 3, "type": "value", "value": "northern california" }, { "id": 0, "type": "table", "value": "geographic" }, { "id": 2, "type": "column", "value": "region" }, { "id": 1, "type": "column", "value": "city" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 1 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 5, 6 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "toke...
[ "O", "B-COLUMN", "O", "O", "O", "B-VALUE", "I-VALUE", "O" ]
4,189
airline
bird:train.json:5879
Which flight carrier operator has the most cancelled flights?
SELECT T1.Description FROM `Air Carriers` AS T1 INNER JOIN Airlines AS T2 ON T1.Code = T2.OP_CARRIER_AIRLINE_ID ORDER BY T2.CANCELLED DESC LIMIT 1
[ "Which", "flight", "carrier", "operator", "has", "the", "most", "cancelled", "flights", "?" ]
[ { "id": 5, "type": "column", "value": "op_carrier_airline_id" }, { "id": 1, "type": "table", "value": "Air Carriers" }, { "id": 0, "type": "column", "value": "description" }, { "id": 3, "type": "column", "value": "cancelled" }, { "id": 2, "type...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 7 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-TABLE", "O", "O", "O", "O", "B-COLUMN", "O", "O" ]
4,190
protein_institute
spider:train_spider.json:1920
Show the name of buildings that do not have any institution.
SELECT name FROM building WHERE building_id NOT IN (SELECT building_id FROM institution)
[ "Show", "the", "name", "of", "buildings", "that", "do", "not", "have", "any", "institution", "." ]
[ { "id": 2, "type": "column", "value": "building_id" }, { "id": 3, "type": "table", "value": "institution" }, { "id": 0, "type": "table", "value": "building" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 10 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-TABLE", "O" ]
4,191
student_assessment
spider:train_spider.json:74
What is the id of the candidate whose email is stanley.monahan@example.org?
SELECT T2.candidate_id FROM people AS T1 JOIN candidates AS T2 ON T1.person_id = T2.candidate_id WHERE T1.email_address = "stanley.monahan@example.org"
[ "What", "is", "the", "i", "d", "of", "the", "candidate", "whose", "email", "is", "stanley.monahan@example.org", "?" ]
[ { "id": 4, "type": "column", "value": "stanley.monahan@example.org" }, { "id": 3, "type": "column", "value": "email_address" }, { "id": 0, "type": "column", "value": "candidate_id" }, { "id": 2, "type": "table", "value": "candidates" }, { "id": 5, ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 11 ] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "O" ]
4,192
european_football_2
bird:dev.json:1085
Which of these players performs the best in crossing actions, Alexis, Ariel Borysiuk or Arouna Kone?
SELECT t1.player_name, t2.crossing FROM Player AS t1 INNER JOIN Player_Attributes AS t2 ON t1.player_api_id = t2.player_api_id WHERE t1.player_name IN ('Alexis', 'Ariel Borysiuk', 'Arouna Kone') ORDER BY t2.crossing DESC LIMIT 1
[ "Which", "of", "these", "players", "performs", "the", "best", "in", "crossing", "actions", ",", "Alexis", ",", "Ariel", "Borysiuk", "or", "Arouna", "Kone", "?" ]
[ { "id": 3, "type": "table", "value": "player_attributes" }, { "id": 5, "type": "value", "value": "Ariel Borysiuk" }, { "id": 7, "type": "column", "value": "player_api_id" }, { "id": 0, "type": "column", "value": "player_name" }, { "id": 6, "typ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 8 ] }, { "entity_id": 2, "token_idxs": [ 3 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 11 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "O", "B-VALUE", "I-VALUE", "O", "B-VALUE", "I-VALUE", "O" ]