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,733
books
bird:train.json:6109
What are the language and title of the ordered books with price less than 20% of the average price of all ordered books?
SELECT DISTINCT T3.language_name, T2.title FROM order_line AS T1 INNER JOIN book AS T2 ON T1.book_id = T2.book_id INNER JOIN book_language AS T3 ON T3.language_id = T2.language_id WHERE T1.price * 100 < ( SELECT AVG(price) FROM order_line ) * 20
[ "What", "are", "the", "language", "and", "title", "of", "the", "ordered", "books", "with", "price", "less", "than", "20", "%", "of", "the", "average", "price", "of", "all", "ordered", "books", "?" ]
[ { "id": 0, "type": "column", "value": "language_name" }, { "id": 2, "type": "table", "value": "book_language" }, { "id": 5, "type": "column", "value": "language_id" }, { "id": 3, "type": "table", "value": "order_line" }, { "id": 9, "type": "col...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [ 23 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "O" ]
4,734
college_1
spider:train_spider.json:3225
how many schools exist in total?
SELECT count(DISTINCT school_code) FROM department
[ "how", "many", "schools", "exist", "in", "total", "?" ]
[ { "id": 1, "type": "column", "value": "school_code" }, { "id": 0, "type": "table", "value": "department" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { ...
[ "O", "O", "B-COLUMN", "O", "O", "O", "O" ]
4,735
works_cycles
bird:train.json:7098
If we discount the products that do not have any type of offer, how many different products have been sold in an amount greater than 2 units per order?
SELECT COUNT(DISTINCT T1.ProductID) FROM SalesOrderDetail AS T1 INNER JOIN SpecialOfferProduct AS T2 ON T1.SpecialOfferID = T2.SpecialOfferID INNER JOIN SpecialOffer AS T3 ON T2.SpecialOfferID = T3.SpecialOfferID WHERE T1.OrderQty > 2 AND T1.UnitPriceDiscount = 0
[ "If", "we", "discount", "the", "products", "that", "do", "not", "have", "any", "type", "of", "offer", ",", "how", "many", "different", "products", "have", "been", "sold", "in", "an", "amount", "greater", "than", "2", "units", "per", "order", "?" ]
[ { "id": 3, "type": "table", "value": "specialofferproduct" }, { "id": 7, "type": "column", "value": "unitpricediscount" }, { "id": 2, "type": "table", "value": "salesorderdetail" }, { "id": 4, "type": "column", "value": "specialofferid" }, { "id": ...
[ { "entity_id": 0, "token_idxs": [ 12 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 16, 17 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_i...
[ "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-TABLE", "I-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "B-COLUMN", "O" ]
4,736
retail_world
bird:train.json:6375
Which territories is the employee with a doctorate in charge of? List all of the territory descriptions.
SELECT T3.TerritoryDescription FROM Employees AS T1 INNER JOIN EmployeeTerritories AS T2 ON T1.EmployeeID = T2.EmployeeID INNER JOIN Territories AS T3 ON T2.TerritoryID = T3.TerritoryID WHERE T1.TitleOfCourtesy = 'Dr.'
[ "Which", "territories", "is", "the", "employee", "with", "a", "doctorate", "in", "charge", "of", "?", "List", "all", "of", "the", "territory", "descriptions", "." ]
[ { "id": 0, "type": "column", "value": "territorydescription" }, { "id": 5, "type": "table", "value": "employeeterritories" }, { "id": 2, "type": "column", "value": "titleofcourtesy" }, { "id": 1, "type": "table", "value": "territories" }, { "id": 6...
[ { "entity_id": 0, "token_idxs": [ 17 ] }, { "entity_id": 1, "token_idxs": [ 1 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 4 ] }, { "entity_id": 5, ...
[ "O", "B-TABLE", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "B-COLUMN", "O" ]
4,737
world
bird:train.json:7871
Calculate the average GNP of all countries that use Arabic language.
SELECT AVG(T1.GNP) FROM Country AS T1 INNER JOIN CountryLanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = 'Arabic'
[ "Calculate", "the", "average", "GNP", "of", "all", "countries", "that", "use", "Arabic", "language", "." ]
[ { "id": 1, "type": "table", "value": "countrylanguage" }, { "id": 6, "type": "column", "value": "countrycode" }, { "id": 2, "type": "column", "value": "language" }, { "id": 0, "type": "table", "value": "country" }, { "id": 3, "type": "value", ...
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [ 3 ] }, { "entity...
[ "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "B-VALUE", "B-COLUMN", "O" ]
4,738
music_platform_2
bird:train.json:7980
Which category is the podcast "Scaling Global" under?
SELECT category FROM categories WHERE podcast_id IN ( SELECT podcast_id FROM podcasts WHERE title = 'Scaling Global' )
[ "Which", "category", "is", "the", "podcast", "\"", "Scaling", "Global", "\"", "under", "?" ]
[ { "id": 5, "type": "value", "value": "Scaling Global" }, { "id": 0, "type": "table", "value": "categories" }, { "id": 2, "type": "column", "value": "podcast_id" }, { "id": 1, "type": "column", "value": "category" }, { "id": 3, "type": "table", ...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 1 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 4 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "B-COLUMN", "B-TABLE", "O", "B-TABLE", "O", "B-VALUE", "I-VALUE", "O", "O", "O" ]
4,739
movie_3
bird:train.json:9238
What is the store and inventory ID of the film with the longest duration?
SELECT T2.store_id, T2.inventory_id FROM film AS T1 INNER JOIN inventory AS T2 ON T1.film_id = T2.film_id ORDER BY T1.length DESC LIMIT 1
[ "What", "is", "the", "store", "and", "inventory", "ID", "of", "the", "film", "with", "the", "longest", "duration", "?" ]
[ { "id": 1, "type": "column", "value": "inventory_id" }, { "id": 3, "type": "table", "value": "inventory" }, { "id": 0, "type": "column", "value": "store_id" }, { "id": 5, "type": "column", "value": "film_id" }, { "id": 4, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [ 9 ] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [ 12 ] }, ...
[ "O", "O", "O", "B-COLUMN", "O", "B-TABLE", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "B-COLUMN", "O", "O" ]
4,740
ice_hockey_draft
bird:train.json:6927
What is the BMI of David Bornhammar?
SELECT CAST(T2.weight_in_kg AS REAL) / (CAST(T3.height_in_cm AS REAL) / 100 * (CAST(T3.height_in_cm AS REAL) / 100)) FROM PlayerInfo AS T1 INNER JOIN weight_info AS T2 ON T1.weight = T2.weight_id INNER JOIN height_info AS T3 ON T1.height = T3.height_id WHERE T1.PlayerName = 'David Bornhammar'
[ "What", "is", "the", "BMI", "of", "David", "Bornhammar", "?" ]
[ { "id": 2, "type": "value", "value": "David Bornhammar" }, { "id": 7, "type": "column", "value": "weight_in_kg" }, { "id": 11, "type": "column", "value": "height_in_cm" }, { "id": 0, "type": "table", "value": "height_info" }, { "id": 4, "type":...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 5, 6 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] ...
[ "B-COLUMN", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "O" ]
4,742
food_inspection
bird:train.json:8826
When did eateries from San Bruno city get highest score in inspection?
SELECT T1.`date` FROM inspections AS T1 INNER JOIN businesses AS T2 ON T1.business_id = T2.business_id WHERE T2.city = 'SAN BRUNO' ORDER BY T1.score DESC LIMIT 1
[ "When", "did", "eateries", "from", "San", "Bruno", "city", "get", "highest", "score", "in", "inspection", "?" ]
[ { "id": 1, "type": "table", "value": "inspections" }, { "id": 6, "type": "column", "value": "business_id" }, { "id": 2, "type": "table", "value": "businesses" }, { "id": 4, "type": "value", "value": "SAN BRUNO" }, { "id": 5, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 11 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [ 4, 5 ] }, { "entity_id"...
[ "O", "O", "O", "O", "B-VALUE", "I-VALUE", "B-COLUMN", "O", "O", "B-COLUMN", "O", "B-TABLE", "O" ]
4,743
online_exams
bird:test.json:221
List each gender and the corresponding number of students.
SELECT Gender_MFU , COUNT(*) FROM Students GROUP BY Gender_MFU
[ "List", "each", "gender", "and", "the", "corresponding", "number", "of", "students", "." ]
[ { "id": 1, "type": "column", "value": "gender_mfu" }, { "id": 0, "type": "table", "value": "students" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O" ]
4,744
movie_platform
bird:train.json:114
How many movies did the director of the highest movie popularity make?
SELECT COUNT(movie_id) FROM movies WHERE director_id = ( SELECT director_id FROM movies ORDER BY movie_popularity DESC LIMIT 1 )
[ "How", "many", "movies", "did", "the", "director", "of", "the", "highest", "movie", "popularity", "make", "?" ]
[ { "id": 3, "type": "column", "value": "movie_popularity" }, { "id": 1, "type": "column", "value": "director_id" }, { "id": 2, "type": "column", "value": "movie_id" }, { "id": 0, "type": "table", "value": "movies" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [ 3 ] }, { "entity_id": 3, "token_idxs": [ 9, 10 ] }, { "entity_id": 4, "token_idxs": [] }, { ...
[ "O", "O", "B-TABLE", "B-COLUMN", "O", "B-COLUMN", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O" ]
4,745
ice_hockey_draft
bird:train.json:6991
Name the player who had the most goals for team Rimouski Oceanic in playoff.
SELECT T1.PlayerName FROM PlayerInfo AS T1 INNER JOIN SeasonStatus AS T2 ON T1.ELITEID = T2.ELITEID WHERE T2.TEAM = 'Rimouski Oceanic' AND T2.GAMETYPE = 'Playoffs' ORDER BY T2.G DESC LIMIT 1
[ "Name", "the", "player", "who", "had", "the", "most", "goals", "for", "team", "Rimouski", "Oceanic", "in", "playoff", "." ]
[ { "id": 6, "type": "value", "value": "Rimouski Oceanic" }, { "id": 2, "type": "table", "value": "seasonstatus" }, { "id": 0, "type": "column", "value": "playername" }, { "id": 1, "type": "table", "value": "playerinfo" }, { "id": 7, "type": "col...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 9 ...
[ "B-COLUMN", "I-COLUMN", "B-TABLE", "O", "O", "O", "O", "O", "O", "B-COLUMN", "B-VALUE", "I-VALUE", "O", "B-VALUE", "O" ]
4,746
simpson_episodes
bird:train.json:4250
Please list the name of crew that were born before 1970.
SELECT name FROM Person WHERE SUBSTR(birthdate, 1, 4) < '1970';
[ "Please", "list", "the", "name", "of", "crew", "that", "were", "born", "before", "1970", "." ]
[ { "id": 3, "type": "column", "value": "birthdate" }, { "id": 0, "type": "table", "value": "person" }, { "id": 1, "type": "column", "value": "name" }, { "id": 2, "type": "value", "value": "1970" }, { "id": 4, "type": "value", "value": "1" ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "O", "B-VALUE", "O" ]
4,747
image_and_language
bird:train.json:7550
How many samples of clouds are there in the image no.2315533?
SELECT SUM(CASE WHEN T1.IMG_ID = 2315533 THEN 1 ELSE 0 END) FROM IMG_OBJ AS T1 INNER JOIN OBJ_CLASSES AS T2 ON T1.OBJ_CLASS_ID = T2.OBJ_CLASS_ID WHERE T2.OBJ_CLASS = 'clouds'
[ "How", "many", "samples", "of", "clouds", "are", "there", "in", "the", "image", "no.2315533", "?" ]
[ { "id": 4, "type": "column", "value": "obj_class_id" }, { "id": 1, "type": "table", "value": "obj_classes" }, { "id": 2, "type": "column", "value": "obj_class" }, { "id": 0, "type": "table", "value": "img_obj" }, { "id": 8, "type": "value", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 4 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { ...
[ "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
4,748
mondial_geo
bird:train.json:8422
In which lake flows the river that is, in turn, the mouth of the Manicouagan River?
SELECT NAME FROM lake WHERE river = ( SELECT river FROM river WHERE NAME = 'Manicouagan' )
[ "In", "which", "lake", "flows", "the", "river", "that", "is", ",", "in", "turn", ",", "the", "mouth", "of", "the", "Manicouagan", "River", "?" ]
[ { "id": 4, "type": "value", "value": "Manicouagan" }, { "id": 2, "type": "column", "value": "river" }, { "id": 3, "type": "table", "value": "river" }, { "id": 0, "type": "table", "value": "lake" }, { "id": 1, "type": "column", "value": "nam...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [ 16 ] }, { "entity_id": 5, ...
[ "O", "O", "B-TABLE", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "O" ]
4,749
local_govt_in_alabama
spider:train_spider.json:2140
How many events have each participants attended? List the participant id, type and the number.
SELECT T1.Participant_ID , T1.Participant_Type_Code , count(*) FROM Participants AS T1 JOIN Participants_in_Events AS T2 ON T1.Participant_ID = T2.Participant_ID GROUP BY T1.Participant_ID
[ "How", "many", "events", "have", "each", "participants", "attended", "?", "List", "the", "participant", "i", "d", ",", "type", "and", "the", "number", "." ]
[ { "id": 3, "type": "table", "value": "participants_in_events" }, { "id": 1, "type": "column", "value": "participant_type_code" }, { "id": 0, "type": "column", "value": "participant_id" }, { "id": 2, "type": "table", "value": "participants" } ]
[ { "entity_id": 0, "token_idxs": [ 10, 11, 12 ] }, { "entity_id": 1, "token_idxs": [ 13, 14 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] ...
[ "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O" ]
4,750
tracking_share_transactions
spider:train_spider.json:5860
Return the lot details and investor ids.
SELECT lot_details , investor_id FROM LOTS
[ "Return", "the", "lot", "details", "and", "investor", "ids", "." ]
[ { "id": 1, "type": "column", "value": "lot_details" }, { "id": 2, "type": "column", "value": "investor_id" }, { "id": 0, "type": "table", "value": "lots" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 5, 6 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id":...
[ "O", "O", "B-TABLE", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "O" ]
4,751
public_review_platform
bird:train.json:3853
Please list the business IDs of all the Yelp_Businesses that are good for kids.
SELECT T2.business_id FROM Attributes AS T1 INNER JOIN Business_Attributes AS T2 ON T1.attribute_id = T2.attribute_id WHERE T1.attribute_name LIKE 'Good for Kids' AND T2.attribute_value LIKE 'TRUE'
[ "Please", "list", "the", "business", "IDs", "of", "all", "the", "Yelp_Businesses", "that", "are", "good", "for", "kids", "." ]
[ { "id": 2, "type": "table", "value": "business_attributes" }, { "id": 6, "type": "column", "value": "attribute_value" }, { "id": 4, "type": "column", "value": "attribute_name" }, { "id": 5, "type": "value", "value": "Good for Kids" }, { "id": 3, ...
[ { "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", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O" ]
4,752
language_corpus
bird:train.json:5813
Among the wikipedia pages on Catalan with more than 300 different words, how many of them have a revision ID of over 28330000?
SELECT COUNT(lid) FROM pages WHERE lid = 1 AND words > 300 AND revision > 28330000
[ "Among", "the", "wikipedia", "pages", "on", "Catalan", "with", "more", "than", "300", "different", "words", ",", "how", "many", "of", "them", "have", "a", "revision", "ID", "of", "over", "28330000", "?" ]
[ { "id": 5, "type": "column", "value": "revision" }, { "id": 6, "type": "value", "value": "28330000" }, { "id": 0, "type": "table", "value": "pages" }, { "id": 3, "type": "column", "value": "words" }, { "id": 1, "type": "column", "value": "l...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 20 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 11 ] }, { "entity_id": 4, "token_idxs": [ 9 ] }, { "entit...
[ "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-VALUE", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "B-COLUMN", "O", "O", "B-VALUE", "O" ]
4,753
cinema
spider:train_spider.json:1938
Show all the cinema names and opening years in descending order of opening year.
SELECT name , openning_year FROM cinema ORDER BY openning_year DESC
[ "Show", "all", "the", "cinema", "names", "and", "opening", "years", "in", "descending", "order", "of", "opening", "year", "." ]
[ { "id": 2, "type": "column", "value": "openning_year" }, { "id": 0, "type": "table", "value": "cinema" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [ 12, 13 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id...
[ "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O" ]
4,754
aan_1
bird:test.json:1044
How many papers has each affiliation published?
SELECT count(DISTINCT T2.paper_id) , T1.name FROM Affiliation AS T1 JOIN Author_list AS T2 ON T1.affiliation_id = T2.affiliation_id GROUP BY T1.affiliation_id
[ "How", "many", "papers", "has", "each", "affiliation", "published", "?" ]
[ { "id": 0, "type": "column", "value": "affiliation_id" }, { "id": 2, "type": "table", "value": "affiliation" }, { "id": 3, "type": "table", "value": "author_list" }, { "id": 4, "type": "column", "value": "paper_id" }, { "id": 1, "type": "column...
[ { "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": [ 2 ] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O" ]
4,755
restaurant
bird:train.json:1758
Among the bakeries, what is total number of bakery located at University Avenue, Palo Alto?
SELECT COUNT(T1.id_restaurant) FROM location AS T1 INNER JOIN generalinfo AS T2 ON T1.id_restaurant = T2.id_restaurant WHERE T2.food_type = 'bakery' AND T2.city = 'palo alto' AND T1.street_name = 'university ave.'
[ "Among", "the", "bakeries", ",", "what", "is", "total", "number", "of", "bakery", "located", "at", "University", "Avenue", ",", "Palo", "Alto", "?" ]
[ { "id": 8, "type": "value", "value": "university ave." }, { "id": 2, "type": "column", "value": "id_restaurant" }, { "id": 1, "type": "table", "value": "generalinfo" }, { "id": 7, "type": "column", "value": "street_name" }, { "id": 3, "type": "...
[ { "entity_id": 0, "token_idxs": [ 10 ] }, { "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", "O", "O", "B-VALUE", "B-TABLE", "O", "B-VALUE", "I-VALUE", "O", "B-VALUE", "I-VALUE", "O" ]
4,756
local_govt_in_alabama
spider:train_spider.json:2143
List the type of the services in alphabetical order.
SELECT service_type_code FROM services ORDER BY service_type_code
[ "List", "the", "type", "of", "the", "services", "in", "alphabetical", "order", "." ]
[ { "id": 1, "type": "column", "value": "service_type_code" }, { "id": 0, "type": "table", "value": "services" } ]
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "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", "O", "O", "O", "O" ]
4,757
hockey
bird:train.json:7644
What is given name for player 'aebisda01'. Calculate the average time in minutes for the all his games played as goaltender.
SELECT T1.nameGiven, CAST(SUM(T2.Min) AS REAL) / SUM(T2.GP) FROM Master AS T1 INNER JOIN Goalies AS T2 ON T1.playerID = T2.playerID WHERE T1.playerID = 'aebisda01' GROUP BY T1.nameGiven
[ "What", "is", "given", "name", "for", "player", "'", "aebisda01", "'", ".", "Calculate", "the", "average", "time", "in", "minutes", "for", "the", "all", "his", "games", "played", "as", "goaltender", "." ]
[ { "id": 0, "type": "column", "value": "namegiven" }, { "id": 4, "type": "value", "value": "aebisda01" }, { "id": 3, "type": "column", "value": "playerid" }, { "id": 2, "type": "table", "value": "goalies" }, { "id": 1, "type": "table", "valu...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 20 ] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [ 7 ] }, { "entity...
[ "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O" ]
4,758
authors
bird:train.json:3680
Mention the name of author for paper id 5 and state the keyword of this page.
SELECT T1.Name, T3.Keyword FROM Author AS T1 INNER JOIN PaperAuthor AS T2 ON T1.Id = T2.AuthorId INNER JOIN Paper AS T3 ON T2.PaperId = T3.Id WHERE T2.PaperId = 5
[ "Mention", "the", "name", "of", "author", "for", "paper", "i", "d", "5", "and", "state", "the", "keyword", "of", "this", "page", "." ]
[ { "id": 6, "type": "table", "value": "paperauthor" }, { "id": 8, "type": "column", "value": "authorid" }, { "id": 1, "type": "column", "value": "keyword" }, { "id": 3, "type": "column", "value": "paperid" }, { "id": 5, "type": "table", "val...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 13 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 9 ] }, { "entity...
[ "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "B-TABLE", "B-COLUMN", "I-COLUMN", "B-VALUE", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O" ]
4,759
codebase_community
bird:dev.json:697
What is the reputation and view count of the user, who is known by his or her display name 'Jarrod Dixon'?
SELECT Reputation, Views FROM users WHERE DisplayName = 'Jarrod Dixon'
[ "What", "is", "the", "reputation", "and", "view", "count", "of", "the", "user", ",", "who", "is", "known", "by", "his", "or", "her", "display", "name", "'", "Jarrod", "Dixon", "'", "?" ]
[ { "id": 4, "type": "value", "value": "Jarrod Dixon" }, { "id": 3, "type": "column", "value": "displayname" }, { "id": 1, "type": "column", "value": "reputation" }, { "id": 0, "type": "table", "value": "users" }, { "id": 2, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [ 18, 19 ] }, { "entity_id": 4, "token_idxs": [ 21, ...
[ "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-VALUE", "I-VALUE", "O", "O" ]
4,760
bbc_channels
bird:test.json:128
Find the name and website link of the channels that have more than one program.
SELECT t1.name , t1.internet FROM channel AS t1 JOIN program AS t2 ON t1.channel_id = t2.channel_id GROUP BY t1.channel_id HAVING count(*) > 1
[ "Find", "the", "name", "and", "website", "link", "of", "the", "channels", "that", "have", "more", "than", "one", "program", "." ]
[ { "id": 0, "type": "column", "value": "channel_id" }, { "id": 2, "type": "column", "value": "internet" }, { "id": 3, "type": "table", "value": "channel" }, { "id": 4, "type": "table", "value": "program" }, { "id": 1, "type": "column", "valu...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [ 14 ] }, { "entity_id": 5, ...
[ "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-TABLE", "O" ]
4,761
authors
bird:train.json:3598
List the names of authors affiliated with the University of Oxford in alphabetical order.
SELECT Name FROM Author WHERE Affiliation = 'University of Oxford' ORDER BY Name ASC
[ "List", "the", "names", "of", "authors", "affiliated", "with", "the", "University", "of", "Oxford", "in", "alphabetical", "order", "." ]
[ { "id": 3, "type": "value", "value": "University of Oxford" }, { "id": 2, "type": "column", "value": "affiliation" }, { "id": 0, "type": "table", "value": "author" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [ 8, 9, 10 ] }, { "entity_id": 4, "token_idxs": [] ...
[ "O", "O", "B-COLUMN", "O", "B-TABLE", "B-COLUMN", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O", "O", "O", "O" ]
4,762
pilot_1
bird:test.json:1141
What are the names and ages of pilots who own plane Piper Cub and are older than 35, or have F-14 Fighter and are younger than 30?
SELECT pilot_name , age FROM pilotskills WHERE plane_name = 'Piper Cub' AND age > 35 UNION SELECT pilot_name , age FROM pilotskills WHERE plane_name = 'F-14 Fighter' AND age < 30
[ "What", "are", "the", "names", "and", "ages", "of", "pilots", "who", "own", "plane", "Piper", "Cub", "and", "are", "older", "than", "35", ",", "or", "have", "F-14", "Fighter", "and", "are", "younger", "than", "30", "?" ]
[ { "id": 6, "type": "value", "value": "F-14 Fighter" }, { "id": 0, "type": "table", "value": "pilotskills" }, { "id": 1, "type": "column", "value": "pilot_name" }, { "id": 3, "type": "column", "value": "plane_name" }, { "id": 4, "type": "value",...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [ 10 ] }, { "entity_id": 4, "token_idxs": [ 11, 12 ] }, { ...
[ "O", "O", "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "O", "B-COLUMN", "B-VALUE", "I-VALUE", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "B-VALUE", "I-VALUE", "O", "O", "O", "O", "B-VALUE", "O" ]
4,763
works_cycles
bird:train.json:7410
What is the hashed password of David Bradley?
SELECT T2.PasswordHash FROM Person AS T1 INNER JOIN Password AS T2 ON T1.BusinessEntityID = T2.BusinessEntityID WHERE T1.FirstName = 'David' AND T1.LastName = 'Bradley'
[ "What", "is", "the", "hashed", "password", "of", "David", "Bradley", "?" ]
[ { "id": 3, "type": "column", "value": "businessentityid" }, { "id": 0, "type": "column", "value": "passwordhash" }, { "id": 4, "type": "column", "value": "firstname" }, { "id": 2, "type": "table", "value": "password" }, { "id": 6, "type": "colu...
[ { "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": [] }, { "entity_id": 5, "token_idxs": [ 6 ...
[ "O", "O", "O", "O", "B-TABLE", "O", "B-VALUE", "B-VALUE", "O" ]
4,764
card_games
bird:dev.json:459
Which card costs more converted mana, "Serra Angel" or "Shrine Keeper"?
SELECT name FROM cards WHERE name IN ('Serra Angel', 'Shrine Keeper') ORDER BY convertedManaCost DESC LIMIT 1
[ "Which", "card", "costs", "more", "converted", "mana", ",", "\"", "Serra", "Angel", "\"", "or", "\"", "Shrine", "Keeper", "\"", "?" ]
[ { "id": 4, "type": "column", "value": "convertedmanacost" }, { "id": 3, "type": "value", "value": "Shrine Keeper" }, { "id": 2, "type": "value", "value": "Serra Angel" }, { "id": 0, "type": "table", "value": "cards" }, { "id": 1, "type": "colum...
[ { "entity_id": 0, "token_idxs": [ 1 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 8, 9 ] }, { "entity_id": 3, "token_idxs": [ 13, 14 ] }, { "entity_id": 4, "token_idxs": [ 4, ...
[ "O", "B-TABLE", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-VALUE", "I-VALUE", "O", "O", "O", "B-VALUE", "I-VALUE", "O", "O" ]
4,765
bike_share_1
bird:train.json:9025
List down the trip IDs when bike no. 10 was used by subscribers and the weather's mean temperature is no less than 62 degress Fahrenheit.
SELECT T1.id FROM trip AS T1 INNER JOIN weather AS T2 ON T2.zip_code = T1.zip_code WHERE T1.bike_id = 10 AND T2.mean_temperature_f > 62 AND T1.subscription_type = 'Subscriber'
[ "List", "down", "the", "trip", "IDs", "when", "bike", "no", ".", "10", "was", "used", "by", "subscribers", "and", "the", "weather", "'s", "mean", "temperature", "is", "no", "less", "than", "62", "degress", "Fahrenheit", "." ]
[ { "id": 6, "type": "column", "value": "mean_temperature_f" }, { "id": 8, "type": "column", "value": "subscription_type" }, { "id": 9, "type": "value", "value": "Subscriber" }, { "id": 3, "type": "column", "value": "zip_code" }, { "id": 2, "type...
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 16 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 6 ] }, { "entity...
[ "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "B-COLUMN", "O", "O", "B-VALUE", "O", "O", "O", "B-VALUE", "O", "O", "B-TABLE", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-VALUE", "O", "O", "O" ]
4,766
coinmarketcap
bird:train.json:6278
What's the descripition of BitBar?
SELECT description FROM coins WHERE name = 'BitBar'
[ "What", "'s", "the", "descripition", "of", "BitBar", "?" ]
[ { "id": 1, "type": "column", "value": "description" }, { "id": 3, "type": "value", "value": "BitBar" }, { "id": 0, "type": "table", "value": "coins" }, { "id": 2, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "B-COLUMN", "O", "B-VALUE", "O" ]
4,767
medicine_enzyme_interaction
spider:train_spider.json:936
What are the names of enzymes in descending order?
SELECT name FROM enzyme ORDER BY name DESC
[ "What", "are", "the", "names", "of", "enzymes", "in", "descending", "order", "?" ]
[ { "id": 0, "type": "table", "value": "enzyme" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "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", "B-TABLE", "O", "O", "O", "O" ]
4,768
products_gen_characteristics
spider:train_spider.json:5579
Return the unit of measure for 'Herb' products.
SELECT unit_of_measure FROM ref_product_categories WHERE product_category_code = "Herbs"
[ "Return", "the", "unit", "of", "measure", "for", "'", "Herb", "'", "products", "." ]
[ { "id": 0, "type": "table", "value": "ref_product_categories" }, { "id": 2, "type": "column", "value": "product_category_code" }, { "id": 1, "type": "column", "value": "unit_of_measure" }, { "id": 3, "type": "column", "value": "Herbs" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2, 3, 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 7 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "B-COLUMN", "O", "O", "O" ]
4,769
retail_world
bird:train.json:6319
Of all the products ordered in order no. 10248, which product has the highest user satisfaction?
SELECT T1.ProductName FROM Products AS T1 INNER JOIN `Order Details` AS T2 ON T1.ProductID = T2.ProductID WHERE T2.OrderID = 10248 ORDER BY T1.ReorderLevel DESC LIMIT 1
[ "Of", "all", "the", "products", "ordered", "in", "order", "no", ".", "10248", ",", "which", "product", "has", "the", "highest", "user", "satisfaction", "?" ]
[ { "id": 2, "type": "table", "value": "Order Details" }, { "id": 5, "type": "column", "value": "reorderlevel" }, { "id": 0, "type": "column", "value": "productname" }, { "id": 6, "type": "column", "value": "productid" }, { "id": 1, "type": "tabl...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [ 4 ] }, { "entity_id": 4, "token_idxs": [ 9 ] }, { "entity_...
[ "O", "O", "O", "B-TABLE", "B-COLUMN", "B-TABLE", "O", "O", "O", "B-VALUE", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O" ]
4,770
baseball_1
spider:train_spider.json:3689
How many games were played in park "Columbia Park" in 1907?
SELECT count(*) FROM home_game AS T1 JOIN park AS T2 ON T1.park_id = T2.park_id WHERE T1.year = 1907 AND T2.park_name = 'Columbia Park';
[ "How", "many", "games", "were", "played", "in", "park", "\"", "Columbia", "Park", "\"", "in", "1907", "?" ]
[ { "id": 6, "type": "value", "value": "Columbia Park" }, { "id": 0, "type": "table", "value": "home_game" }, { "id": 5, "type": "column", "value": "park_name" }, { "id": 2, "type": "column", "value": "park_id" }, { "id": 1, "type": "table", ...
[ { "entity_id": 0, "token_idxs": [ 0, 1, 2 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [ 9 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 12 ] ...
[ "B-TABLE", "I-TABLE", "I-TABLE", "O", "O", "O", "B-TABLE", "O", "B-VALUE", "B-COLUMN", "O", "O", "B-VALUE", "O" ]
4,771
inn_1
spider:train_spider.json:2597
For each bed type, find the average base price of different bed type.
SELECT bedType , avg(basePrice) FROM Rooms GROUP BY bedType;
[ "For", "each", "bed", "type", ",", "find", "the", "average", "base", "price", "of", "different", "bed", "type", "." ]
[ { "id": 2, "type": "column", "value": "baseprice" }, { "id": 1, "type": "column", "value": "bedtype" }, { "id": 0, "type": "table", "value": "rooms" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2, 3 ] }, { "entity_id": 2, "token_idxs": [ 8, 9 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O" ]
4,772
card_games
bird:dev.json:417
What percentage of Japanese translated sets are expansion sets?
SELECT CAST(SUM(CASE WHEN T2.language = 'Japanese' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(T1.id) FROM sets AS T1 INNER JOIN set_translations AS T2 ON T1.code = T2.setCode WHERE T1.type = 'expansion'
[ "What", "percentage", "of", "Japanese", "translated", "sets", "are", "expansion", "sets", "?" ]
[ { "id": 1, "type": "table", "value": "set_translations" }, { "id": 3, "type": "value", "value": "expansion" }, { "id": 10, "type": "column", "value": "language" }, { "id": 11, "type": "value", "value": "Japanese" }, { "id": 5, "type": "column",...
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 7 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "O", "B-VALUE", "B-TABLE", "B-TABLE", "O", "B-VALUE", "O", "O" ]
4,773
restaurant
bird:train.json:1780
In which region can you find the highest number of Baskin Robbins restaurants?
SELECT T2.region AS num FROM generalinfo AS T1 INNER JOIN geographic AS T2 ON T1.city = T2.city WHERE T1.label = 'baskin robbins' GROUP BY T2.region ORDER BY COUNT(T1.city) DESC LIMIT 1
[ "In", "which", "region", "can", "you", "find", "the", "highest", "number", "of", "Baskin", "Robbins", "restaurants", "?" ]
[ { "id": 4, "type": "value", "value": "baskin robbins" }, { "id": 1, "type": "table", "value": "generalinfo" }, { "id": 2, "type": "table", "value": "geographic" }, { "id": 0, "type": "column", "value": "region" }, { "id": 3, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "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", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "O", "O" ]
4,774
driving_school
spider:train_spider.json:6677
How many lessons did the customer Ryan Goodwin complete?
SELECT count(*) FROM Lessons AS T1 JOIN Customers AS T2 ON T1.customer_id = T2.customer_id WHERE T2.first_name = "Rylan" AND T2.last_name = "Goodwin" AND T1.lesson_status_code = "Completed";
[ "How", "many", "lessons", "did", "the", "customer", "Ryan", "Goodwin", "complete", "?" ]
[ { "id": 7, "type": "column", "value": "lesson_status_code" }, { "id": 2, "type": "column", "value": "customer_id" }, { "id": 3, "type": "column", "value": "first_name" }, { "id": 1, "type": "table", "value": "customers" }, { "id": 5, "type": "c...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 6 ] }, { "entity_id": 5, "...
[ "O", "O", "B-TABLE", "O", "O", "B-TABLE", "B-COLUMN", "B-COLUMN", "B-COLUMN", "O" ]
4,775
institution_sports
bird:test.json:1645
List the names of institutions in ascending order of founded year.
SELECT Name FROM institution ORDER BY Founded ASC
[ "List", "the", "names", "of", "institutions", "in", "ascending", "order", "of", "founded", "year", "." ]
[ { "id": 0, "type": "table", "value": "institution" }, { "id": 2, "type": "column", "value": "founded" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 9 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "O", "O", "B-COLUMN", "O", "O" ]
4,776
public_review_platform
bird:train.json:3822
How many users who started yelping since 2012 have sent a high number of funny votes?
SELECT COUNT(user_id) FROM Users WHERE user_yelping_since_year = 2012 AND user_votes_funny LIKE 'High'
[ "How", "many", "users", "who", "started", "yelping", "since", "2012", "have", "sent", "a", "high", "number", "of", "funny", "votes", "?" ]
[ { "id": 2, "type": "column", "value": "user_yelping_since_year" }, { "id": 4, "type": "column", "value": "user_votes_funny" }, { "id": 1, "type": "column", "value": "user_id" }, { "id": 0, "type": "table", "value": "users" }, { "id": 3, "type":...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 5, 6 ] }, { "entity_id": 3, "token_idxs": [ 7 ] }, { "entity_id": 4, "token_idxs": [ 12, 13, ...
[ "O", "O", "B-TABLE", "O", "O", "B-COLUMN", "I-COLUMN", "B-VALUE", "O", "O", "O", "B-VALUE", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O" ]
4,777
student_1
spider:train_spider.json:4040
Find the grade studying in room 105.
SELECT DISTINCT grade FROM list WHERE classroom = 105
[ "Find", "the", "grade", "studying", "in", "room", "105", "." ]
[ { "id": 2, "type": "column", "value": "classroom" }, { "id": 1, "type": "column", "value": "grade" }, { "id": 0, "type": "table", "value": "list" }, { "id": 3, "type": "value", "value": "105" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "B-VALUE", "O" ]
4,778
pilot_1
bird:test.json:1152
What are the names of pilots who have either the Piper Cub or the F-14 Fighter?
SELECT pilot_name FROM pilotskills WHERE plane_name = 'Piper Cub' OR plane_name = 'F-14 Fighter'
[ "What", "are", "the", "names", "of", "pilots", "who", "have", "either", "the", "Piper", "Cub", "or", "the", "F-14", "Fighter", "?" ]
[ { "id": 4, "type": "value", "value": "F-14 Fighter" }, { "id": 0, "type": "table", "value": "pilotskills" }, { "id": 1, "type": "column", "value": "pilot_name" }, { "id": 2, "type": "column", "value": "plane_name" }, { "id": 3, "type": "value",...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 10, 11 ] }, { "entity_id": 4, "token_idxs": [ 14, 15 ] }, { ...
[ "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "O", "O", "B-VALUE", "I-VALUE", "O" ]
4,779
airline
bird:train.json:5837
How many flights on average does American Airlines Inc. operate every day in August, 2018?
SELECT CAST( SUM(CASE WHEN T2.FL_DATE LIKE '2018/8%' THEN 1 ELSE 0 END) AS REAL) / 31 FROM Airports AS T1 INNER JOIN Airlines AS T2 ON T1.Code = T2.ORIGIN INNER JOIN `Air Carriers` AS T3 ON T2.OP_CARRIER_AIRLINE_ID = T3.Code WHERE T3.Description = 'American Airlines Inc.: AA'
[ "How", "many", "flights", "on", "average", "does", "American", "Airlines", "Inc.", "operate", "every", "day", "in", "August", ",", "2018", "?" ]
[ { "id": 2, "type": "value", "value": "American Airlines Inc.: AA" }, { "id": 6, "type": "column", "value": "op_carrier_airline_id" }, { "id": 0, "type": "table", "value": "Air Carriers" }, { "id": 1, "type": "column", "value": "description" }, { "i...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 6, 8 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ ...
[ "O", "O", "O", "O", "O", "O", "B-VALUE", "B-TABLE", "B-VALUE", "O", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
4,780
gymnast
spider:train_spider.json:1773
Count the number of different hometowns of these people.
SELECT count(DISTINCT Hometown) FROM people
[ "Count", "the", "number", "of", "different", "hometowns", "of", "these", "people", "." ]
[ { "id": 1, "type": "column", "value": "hometown" }, { "id": 0, "type": "table", "value": "people" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "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-COLUMN", "O", "O", "B-TABLE", "O" ]
4,781
icfp_1
spider:train_spider.json:2859
Count the number of authors.
SELECT count(*) FROM authors
[ "Count", "the", "number", "of", "authors", "." ]
[ { "id": 0, "type": "table", "value": "authors" } ]
[ { "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" ]
4,782
olympics
bird:train.json:5044
What is the name of medal that competitor id 9 obtained?
SELECT DISTINCT T1.medal_name FROM medal AS T1 INNER JOIN competitor_event AS T2 ON T1.id = T2.medal_id WHERE T2.competitor_id = 9
[ "What", "is", "the", "name", "of", "medal", "that", "competitor", "i", "d", "9", "obtained", "?" ]
[ { "id": 2, "type": "table", "value": "competitor_event" }, { "id": 3, "type": "column", "value": "competitor_id" }, { "id": 0, "type": "column", "value": "medal_name" }, { "id": 6, "type": "column", "value": "medal_id" }, { "id": 1, "type": "ta...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 7 ] }, { "entity_id": 4, "token_idxs": [ 10 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "O", "B-TABLE", "O", "B-COLUMN", "B-COLUMN", "I-COLUMN", "B-VALUE", "O", "O" ]
4,783
bike_share_1
bird:train.json:9039
List the name and city of starting stations which has an above-average duration trips.
SELECT DISTINCT T1.start_station_name, T2.city FROM trip AS T1 INNER JOIN station AS T2 ON T2.name = T1.start_station_name WHERE T1.duration > ( SELECT AVG(T1.duration) FROM trip AS T1 LEFT JOIN station AS T2 ON T2.name = T1.start_station_name )
[ "List", "the", "name", "and", "city", "of", "starting", "stations", "which", "has", "an", "above", "-", "average", "duration", "trips", "." ]
[ { "id": 0, "type": "column", "value": "start_station_name" }, { "id": 4, "type": "column", "value": "duration" }, { "id": 3, "type": "table", "value": "station" }, { "id": 1, "type": "column", "value": "city" }, { "id": 2, "type": "table", ...
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [ 15 ] }, { "entity_id": 3, "token_idxs": [ 7 ] }, { "entity_id": 4, "token_idxs": [ 14 ] }, ...
[ "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "B-COLUMN", "B-TABLE", "O", "O", "O", "O", "O", "O", "B-COLUMN", "B-TABLE", "O" ]
4,784
public_review_platform
bird:train.json:3838
How many businesses in AZ state do not open on Thursday?
SELECT COUNT(T1.business_id) FROM Business AS T1 INNER JOIN Checkins AS T2 ON T1.business_id = T2.business_id INNER JOIN Days AS T3 ON T2.day_id = T3.day_id WHERE T2.label_time_4 LIKE 'None' AND T1.state LIKE 'AZ' AND T3.day_of_week LIKE 'Thursday'
[ "How", "many", "businesses", "in", "AZ", "state", "do", "not", "open", "on", "Thursday", "?" ]
[ { "id": 5, "type": "column", "value": "label_time_4" }, { "id": 1, "type": "column", "value": "business_id" }, { "id": 9, "type": "column", "value": "day_of_week" }, { "id": 2, "type": "table", "value": "business" }, { "id": 3, "type": "table",...
[ { "entity_id": 0, "token_idxs": [] }, { "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-TABLE", "O", "B-VALUE", "B-COLUMN", "O", "O", "O", "B-VALUE", "B-VALUE", "O" ]
4,785
retail_world
bird:train.json:6351
Which region is "Columbia" in?
SELECT T2.RegionDescription FROM Territories AS T1 INNER JOIN Region AS T2 ON T1.RegionID = T2.RegionID WHERE T1.TerritoryDescription = 'Columbia'
[ "Which", "region", "is", "\"", "Columbia", "\"", "in", "?" ]
[ { "id": 3, "type": "column", "value": "territorydescription" }, { "id": 0, "type": "column", "value": "regiondescription" }, { "id": 1, "type": "table", "value": "territories" }, { "id": 4, "type": "value", "value": "Columbia" }, { "id": 5, "ty...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 1 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 4 ] }, { "entity_id": 5, "token_idxs": ...
[ "O", "B-TABLE", "O", "O", "B-VALUE", "O", "O", "O" ]
4,786
bike_1
spider:train_spider.json:186
What are the dates that have the 5 highest cloud cover rates and what are the rates?
SELECT date , cloud_cover FROM weather ORDER BY cloud_cover DESC LIMIT 5
[ "What", "are", "the", "dates", "that", "have", "the", "5", "highest", "cloud", "cover", "rates", "and", "what", "are", "the", "rates", "?" ]
[ { "id": 2, "type": "column", "value": "cloud_cover" }, { "id": 0, "type": "table", "value": "weather" }, { "id": 1, "type": "column", "value": "date" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 9, 10 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id"...
[ "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "O" ]
4,787
soccer_2
spider:train_spider.json:4982
Find the name of different colleges involved in the tryout in alphabetical order.
SELECT DISTINCT cName FROM tryout ORDER BY cName
[ "Find", "the", "name", "of", "different", "colleges", "involved", "in", "the", "tryout", "in", "alphabetical", "order", "." ]
[ { "id": 0, "type": "table", "value": "tryout" }, { "id": 1, "type": "column", "value": "cname" } ]
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O" ]
4,788
tracking_share_transactions
spider:train_spider.json:5871
Show the average amount of transactions for different lots.
SELECT T2.lot_id , avg(amount_of_transaction) FROM TRANSACTIONS AS T1 JOIN Transactions_Lots AS T2 ON T1.transaction_id = T2.transaction_id GROUP BY T2.lot_id
[ "Show", "the", "average", "amount", "of", "transactions", "for", "different", "lots", "." ]
[ { "id": 3, "type": "column", "value": "amount_of_transaction" }, { "id": 2, "type": "table", "value": "transactions_lots" }, { "id": 4, "type": "column", "value": "transaction_id" }, { "id": 1, "type": "table", "value": "transactions" }, { "id": 0,...
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 3, 4 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id":...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "B-TABLE", "O", "O", "B-COLUMN", "O" ]
4,789
codebase_community
bird:dev.json:569
Give the number of votes for the post about data visualization.
SELECT COUNT(T1.Id) FROM posts AS T1 INNER JOIN votes AS T2 ON T1.Id = T2.PostId WHERE T1.Title LIKE '%data visualization%'
[ "Give", "the", "number", "of", "votes", "for", "the", "post", "about", "data", "visualization", "." ]
[ { "id": 3, "type": "value", "value": "%data visualization%" }, { "id": 5, "type": "column", "value": "postid" }, { "id": 0, "type": "table", "value": "posts" }, { "id": 1, "type": "table", "value": "votes" }, { "id": 2, "type": "column", "v...
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 9, 10 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id"...
[ "O", "O", "O", "O", "B-TABLE", "O", "O", "B-TABLE", "O", "B-VALUE", "I-VALUE", "O" ]
4,790
conference
bird:test.json:1071
Show the institution name and location of institution that is most recently founded.
SELECT institution_name , LOCATION FROM institution ORDER BY founded DESC LIMIT 1
[ "Show", "the", "institution", "name", "and", "location", "of", "institution", "that", "is", "most", "recently", "founded", "." ]
[ { "id": 1, "type": "column", "value": "institution_name" }, { "id": 0, "type": "table", "value": "institution" }, { "id": 2, "type": "column", "value": "location" }, { "id": 3, "type": "column", "value": "founded" } ]
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "entity_id": 1, "token_idxs": [ 2, 3 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [ 12 ] }, { "entity_id": 4, "token_idxs": [] }, { ...
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "O", "O", "B-COLUMN", "O" ]
4,791
ship_mission
spider:train_spider.json:4021
What are the names of ships that were involved in a mission launched after 1928?
SELECT T2.Name FROM mission AS T1 JOIN ship AS T2 ON T1.Ship_ID = T2.Ship_ID WHERE T1.Launched_Year > 1928
[ "What", "are", "the", "names", "of", "ships", "that", "were", "involved", "in", "a", "mission", "launched", "after", "1928", "?" ]
[ { "id": 3, "type": "column", "value": "launched_year" }, { "id": 1, "type": "table", "value": "mission" }, { "id": 5, "type": "column", "value": "ship_id" }, { "id": 0, "type": "column", "value": "name" }, { "id": 2, "type": "table", "value...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 11 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [ 12 ] }, { "entity_id": 4, "token_idxs": [ 14 ] }, ...
[ "O", "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "B-VALUE", "O" ]
4,792
hockey
bird:train.json:7790
Among the players who had 10 empty net goals in their career, who is the tallest? Show his full name.
SELECT T2.firstName, T2.lastName FROM Goalies AS T1 INNER JOIN Master AS T2 ON T1.playerID = T2.playerID WHERE T1.ENG = 10 ORDER BY T2.height DESC LIMIT 1
[ "Among", "the", "players", "who", "had", "10", "empty", "net", "goals", "in", "their", "career", ",", "who", "is", "the", "tallest", "?", "Show", "his", "full", "name", "." ]
[ { "id": 0, "type": "column", "value": "firstname" }, { "id": 1, "type": "column", "value": "lastname" }, { "id": 7, "type": "column", "value": "playerid" }, { "id": 2, "type": "table", "value": "goalies" }, { "id": 3, "type": "table", "valu...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 21 ] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O" ]
4,793
debit_card_specializing
bird:dev.json:1483
How much did customer 6 consume in total between August and November 2013?
SELECT SUM(Consumption) FROM yearmonth WHERE CustomerID = 6 AND Date BETWEEN '201308' AND '201311'
[ "How", "much", "did", "customer", "6", "consume", "in", "total", "between", "August", "and", "November", "2013", "?" ]
[ { "id": 1, "type": "column", "value": "consumption" }, { "id": 2, "type": "column", "value": "customerid" }, { "id": 0, "type": "table", "value": "yearmonth" }, { "id": 5, "type": "value", "value": "201308" }, { "id": 6, "type": "value", "v...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5, 6 ] }, { "entity_id": 2, "token_idxs": [ 3 ] }, { "entity_id": 3, "token_idxs": [ 4 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id":...
[ "O", "O", "O", "B-COLUMN", "B-VALUE", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
4,794
ship_1
spider:train_spider.json:6227
What are the names of captains, sorted by age descending?
SELECT name FROM captain ORDER BY age DESC
[ "What", "are", "the", "names", "of", "captains", ",", "sorted", "by", "age", "descending", "?" ]
[ { "id": 0, "type": "table", "value": "captain" }, { "id": 1, "type": "column", "value": "name" }, { "id": 2, "type": "column", "value": "age" } ]
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 9 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "O", "O" ]
4,795
country_language
bird:test.json:1370
How many different official languages are there?
SELECT count(DISTINCT language_id) FROM official_languages
[ "How", "many", "different", "official", "languages", "are", "there", "?" ]
[ { "id": 0, "type": "table", "value": "official_languages" }, { "id": 1, "type": "column", "value": "language_id" } ]
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "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", "B-TABLE", "B-COLUMN", "O", "O", "O" ]
4,796
driving_school
spider:train_spider.json:6686
What is zip code of customer with first name as Carole and last name as Bernhard?
SELECT T2.zip_postcode FROM Customers AS T1 JOIN Addresses AS T2 ON T1.customer_address_id = T2.address_id WHERE T1.first_name = "Carole" AND T1.last_name = "Bernhard"
[ "What", "is", "zip", "code", "of", "customer", "with", "first", "name", "as", "Carole", "and", "last", "name", "as", "Bernhard", "?" ]
[ { "id": 3, "type": "column", "value": "customer_address_id" }, { "id": 0, "type": "column", "value": "zip_postcode" }, { "id": 4, "type": "column", "value": "address_id" }, { "id": 5, "type": "column", "value": "first_name" }, { "id": 1, "type"...
[ { "entity_id": 0, "token_idxs": [ 2, 3 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "toke...
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-TABLE", "O", "B-COLUMN", "I-COLUMN", "O", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "O", "B-COLUMN", "O" ]
4,797
cre_Docs_and_Epenses
spider:train_spider.json:6390
Count the number of statements.
SELECT count(*) FROM Statements
[ "Count", "the", "number", "of", "statements", "." ]
[ { "id": 0, "type": "table", "value": "statements" } ]
[ { "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" ]
4,798
shakespeare
bird:train.json:2984
Gives the average number of chapters in Shakespeare's 1599 work.
SELECT CAST(COUNT(T1.id) AS REAL) / COUNT(DISTINCT T2.id) FROM chapters AS T1 INNER JOIN works AS T2 ON T1.work_id = T2.id WHERE T2.Date = '1599'
[ "Gives", "the", "average", "number", "of", "chapters", "in", "Shakespeare", "'s", "1599", "work", "." ]
[ { "id": 0, "type": "table", "value": "chapters" }, { "id": 4, "type": "column", "value": "work_id" }, { "id": 1, "type": "table", "value": "works" }, { "id": 2, "type": "column", "value": "date" }, { "id": 3, "type": "value", "value": "1599...
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [ 10 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-VALUE", "B-TABLE", "O" ]
4,799
donor
bird:train.json:3279
How many schools in Brooklyn with urban metro and donations for an honoree have requested TT992 - Refill Pack for Safety Name Tags as a resource?
SELECT COUNT(T2.schoolid) FROM resources AS T1 INNER JOIN projects AS T2 ON T1.projectid = T2.projectid INNER JOIN donations AS T3 ON T2.projectid = T3.projectid WHERE T2.school_city = 'Brooklyn' AND T2.school_metro = 'urban' AND T3.for_honoree = 't' AND T1.item_name = 'TT992 - Refill Pack for Safety Name Tags'
[ "How", "many", "schools", "in", "Brooklyn", "with", "urban", "metro", "and", "donations", "for", "an", "honoree", "have", "requested", "TT992", "-", "Refill", "Pack", "for", "Safety", "Name", "Tags", "as", "a", "resource", "?" ]
[ { "id": 12, "type": "value", "value": "TT992 - Refill Pack for Safety Name Tags" }, { "id": 7, "type": "column", "value": "school_metro" }, { "id": 5, "type": "column", "value": "school_city" }, { "id": 9, "type": "column", "value": "for_honoree" }, { ...
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 25 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "B-COLUMN", "B-COLUMN", "B-VALUE", "O", "B-VALUE", "O", "O", "B-TABLE", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "B-COLUMN", "B-VALUE", "O", "O", "B-TABLE", "O" ]
4,800
professional_basketball
bird:train.json:2815
Between the years 1990 and 2007, of the total rebounds achieved by each player, how many managed to exceed 75% of defensive rebounds?
SELECT COUNT(DISTINCT playerID) FROM player_allstar WHERE CAST(d_rebounds AS REAL) * 100 / rebounds > 75 AND season_id BETWEEN 1990 AND 2007
[ "Between", "the", "years", "1990", "and", "2007", ",", "of", "the", "total", "rebounds", "achieved", "by", "each", "player", ",", "how", "many", "managed", "to", "exceed", "75", "%", "of", "defensive", "rebounds", "?" ]
[ { "id": 0, "type": "table", "value": "player_allstar" }, { "id": 8, "type": "column", "value": "d_rebounds" }, { "id": 3, "type": "column", "value": "season_id" }, { "id": 1, "type": "column", "value": "playerid" }, { "id": 6, "type": "column",...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 14 ] }, { "entity_id": 2, "token_idxs": [ 21 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 3 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "B-VALUE", "O", "B-VALUE", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "B-COLUMN", "O" ]
4,801
regional_sales
bird:train.json:2649
Which product was ordered the most in 2018?
SELECT T2.`Product Name` FROM `Sales Orders` AS T1 INNER JOIN Products AS T2 ON T2.ProductID = T1._ProductID WHERE T1.OrderDate LIKE '%/%/18' GROUP BY T1._ProductID ORDER BY COUNT(T1._ProductID) DESC LIMIT 1
[ "Which", "product", "was", "ordered", "the", "most", "in", "2018", "?" ]
[ { "id": 1, "type": "column", "value": "Product Name" }, { "id": 2, "type": "table", "value": "Sales Orders" }, { "id": 0, "type": "column", "value": "_productid" }, { "id": 4, "type": "column", "value": "orderdate" }, { "id": 6, "type": "column...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 2 ] }, { "entity_id": 3, "token_idxs": [ 1 ] }, { "entity_id": 4, "token_idxs": [ 3, 4 ] }, { "entity_id":...
[ "O", "B-TABLE", "B-TABLE", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O" ]
4,802
olympics
bird:train.json:4923
In which year did London hold its earliest Olympic game?
SELECT T3.games_year 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 WHERE T2.city_name = 'London' ORDER BY T3.games_year LIMIT 1
[ "In", "which", "year", "did", "London", "hold", "its", "earliest", "Olympic", "game", "?" ]
[ { "id": 0, "type": "column", "value": "games_year" }, { "id": 4, "type": "table", "value": "games_city" }, { "id": 2, "type": "column", "value": "city_name" }, { "id": 6, "type": "column", "value": "games_id" }, { "id": 8, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 9 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 4 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "B-COLUMN", "B-VALUE", "O", "O", "O", "O", "B-TABLE", "O" ]
4,804
superstore
bird:train.json:2347
Among all the orders made by Aimee Bixby, how many of them chose the slowest delivery speed?
SELECT COUNT(DISTINCT T2.`Order ID`) FROM people AS T1 INNER JOIN central_superstore AS T2 ON T1.`Customer ID` = T2.`Customer ID` WHERE T1.`Customer Name` = 'Aimee Bixby' AND T2.`Ship Mode` = 'Standard Class'
[ "Among", "all", "the", "orders", "made", "by", "Aimee", "Bixby", ",", "how", "many", "of", "them", "chose", "the", "slowest", "delivery", "speed", "?" ]
[ { "id": 1, "type": "table", "value": "central_superstore" }, { "id": 7, "type": "value", "value": "Standard Class" }, { "id": 4, "type": "column", "value": "Customer Name" }, { "id": 3, "type": "column", "value": "Customer ID" }, { "id": 5, "ty...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 3, 4 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ ...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-VALUE", "I-VALUE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
4,805
university_basketball
spider:train_spider.json:1014
What are the different affiliations, and how many schools with each have an enrollment size of above 20000?
SELECT count(*) , affiliation FROM university WHERE enrollment > 20000 GROUP BY affiliation
[ "What", "are", "the", "different", "affiliations", ",", "and", "how", "many", "schools", "with", "each", "have", "an", "enrollment", "size", "of", "above", "20000", "?" ]
[ { "id": 1, "type": "column", "value": "affiliation" }, { "id": 0, "type": "table", "value": "university" }, { "id": 2, "type": "column", "value": "enrollment" }, { "id": 3, "type": "value", "value": "20000" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [ 14 ] }, { "entity_id": 3, "token_idxs": [ 18 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "B-VALUE", "O" ]
4,806
driving_school
spider:train_spider.json:6708
How many lesson does customer with first name Ray took?
SELECT count(*) FROM Lessons AS T1 JOIN Customers AS T2 ON T1.customer_id = T2.customer_id WHERE T2.first_name = "Ray"
[ "How", "many", "lesson", "does", "customer", "with", "first", "name", "Ray", "took", "?" ]
[ { "id": 4, "type": "column", "value": "customer_id" }, { "id": 2, "type": "column", "value": "first_name" }, { "id": 1, "type": "table", "value": "customers" }, { "id": 0, "type": "table", "value": "lessons" }, { "id": 3, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [ 6, 7 ] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [] }, { ...
[ "O", "O", "B-TABLE", "O", "B-TABLE", "O", "B-COLUMN", "I-COLUMN", "B-COLUMN", "O", "O" ]
4,807
wrestler
spider:train_spider.json:1880
What is the number of distinct teams that suffer elimination?
SELECT COUNT (DISTINCT team) FROM elimination
[ "What", "is", "the", "number", "of", "distinct", "teams", "that", "suffer", "elimination", "?" ]
[ { "id": 0, "type": "table", "value": "elimination" }, { "id": 1, "type": "column", "value": "team" } ]
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "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": ...
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O" ]
4,809
college_3
spider:train_spider.json:4666
What are the last names of female students, ordered by age descending?
SELECT LName FROM STUDENT WHERE Sex = "F" ORDER BY Age DESC
[ "What", "are", "the", "last", "names", "of", "female", "students", ",", "ordered", "by", "age", "descending", "?" ]
[ { "id": 0, "type": "table", "value": "student" }, { "id": 1, "type": "column", "value": "lname" }, { "id": 2, "type": "column", "value": "sex" }, { "id": 4, "type": "column", "value": "age" }, { "id": 3, "type": "column", "value": "F" } ]
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [ 11 ] }, { "entity...
[ "O", "O", "O", "O", "B-COLUMN", "B-COLUMN", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "O", "O" ]
4,810
retails
bird:train.json:6708
How many customers are in the automobile market segment?
SELECT COUNT(c_custkey) FROM customer WHERE c_mktsegment = 'AUTOMOBILE'
[ "How", "many", "customers", "are", "in", "the", "automobile", "market", "segment", "?" ]
[ { "id": 1, "type": "column", "value": "c_mktsegment" }, { "id": 2, "type": "value", "value": "AUTOMOBILE" }, { "id": 3, "type": "column", "value": "c_custkey" }, { "id": 0, "type": "table", "value": "customer" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 7, 8 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id":...
[ "O", "O", "B-TABLE", "O", "O", "O", "B-VALUE", "B-COLUMN", "I-COLUMN", "O" ]
4,811
synthea
bird:train.json:1414
Among the patients that died, what is the condition of the oldest patient?
SELECT T1.DESCRIPTION FROM conditions AS T1 INNER JOIN patients AS T2 ON T1.PATIENT = T2.patient WHERE T2.deathdate IS NOT NULL ORDER BY strftime('%Y', T2.deathdate) - strftime('%Y', T2.birthdate) DESC LIMIT 1
[ "Among", "the", "patients", "that", "died", ",", "what", "is", "the", "condition", "of", "the", "oldest", "patient", "?" ]
[ { "id": 0, "type": "column", "value": "description" }, { "id": 1, "type": "table", "value": "conditions" }, { "id": 3, "type": "column", "value": "deathdate" }, { "id": 6, "type": "column", "value": "birthdate" }, { "id": 2, "type": "table", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 9 ] }, { "entity_id": 2, "token_idxs": [ 2 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 13 ] }, { "entity_id": 5, ...
[ "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "O" ]
4,812
college_1
spider:train_spider.json:3265
What is the first, last name, gpa of the youngest one among students whose GPA is above 3?
SELECT stu_fname , stu_lname , stu_gpa FROM student WHERE stu_gpa > 3 ORDER BY stu_dob DESC LIMIT 1
[ "What", "is", "the", "first", ",", "last", "name", ",", "gpa", "of", "the", "youngest", "one", "among", "students", "whose", "GPA", "is", "above", "3", "?" ]
[ { "id": 1, "type": "column", "value": "stu_fname" }, { "id": 2, "type": "column", "value": "stu_lname" }, { "id": 0, "type": "table", "value": "student" }, { "id": 3, "type": "column", "value": "stu_gpa" }, { "id": 5, "type": "column", "val...
[ { "entity_id": 0, "token_idxs": [ 14 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 5, 6 ] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [ 19 ] }, { ...
[ "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-VALUE", "O" ]
4,813
car_racing
bird:test.json:1620
Find all the countries where some drivers have points above 150.
SELECT T1.Country FROM country AS T1 JOIN driver AS T2 ON T1.Country_ID = T2.Country WHERE T2.Points > 150
[ "Find", "all", "the", "countries", "where", "some", "drivers", "have", "points", "above", "150", "." ]
[ { "id": 5, "type": "column", "value": "country_id" }, { "id": 0, "type": "column", "value": "country" }, { "id": 1, "type": "table", "value": "country" }, { "id": 2, "type": "table", "value": "driver" }, { "id": 3, "type": "column", "value"...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [ 10 ] }, { "entity...
[ "O", "O", "O", "B-TABLE", "O", "O", "B-TABLE", "O", "B-COLUMN", "O", "B-VALUE", "O" ]
4,814
food_inspection_2
bird:train.json:6157
What is the average number of inspections done by the top 5 employees with the highest salary? List the names of the said employees.
SELECT CAST(COUNT(DISTINCT T2.inspection_id) AS REAL) / 5, T1.first_name, T1.last_name FROM employee AS T1 INNER JOIN inspection AS T2 ON T1.employee_id = T2.employee_id WHERE T1.title = 'Sanitarian' ORDER BY T1.salary DESC LIMIT 5
[ "What", "is", "the", "average", "number", "of", "inspections", "done", "by", "the", "top", "5", "employees", "with", "the", "highest", "salary", "?", "List", "the", "names", "of", "the", "said", "employees", "." ]
[ { "id": 9, "type": "column", "value": "inspection_id" }, { "id": 8, "type": "column", "value": "employee_id" }, { "id": 0, "type": "column", "value": "first_name" }, { "id": 3, "type": "table", "value": "inspection" }, { "id": 5, "type": "value...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 18, 19, 20 ] }, { "entity_id": 2, "token_idxs": [ 24 ] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [] }, { ...
[ "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "B-TABLE", "O" ]
4,815
shakespeare
bird:train.json:3033
What are the character names for a senator of Venice?
SELECT CharName FROM characters WHERE Description = 'a senator of Venice'
[ "What", "are", "the", "character", "names", "for", "a", "senator", "of", "Venice", "?" ]
[ { "id": 3, "type": "value", "value": "a senator of Venice" }, { "id": 2, "type": "column", "value": "description" }, { "id": 0, "type": "table", "value": "characters" }, { "id": 1, "type": "column", "value": "charname" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 6, 7, 8, 9 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity...
[ "O", "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "O" ]
4,816
body_builder
spider:train_spider.json:1161
What is the average total score of body builders with height bigger than 200?
SELECT avg(T1.Total) FROM body_builder AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200
[ "What", "is", "the", "average", "total", "score", "of", "body", "builders", "with", "height", "bigger", "than", "200", "?" ]
[ { "id": 0, "type": "table", "value": "body_builder" }, { "id": 5, "type": "column", "value": "people_id" }, { "id": 1, "type": "table", "value": "people" }, { "id": 2, "type": "column", "value": "height" }, { "id": 4, "type": "column", "val...
[ { "entity_id": 0, "token_idxs": [ 7, 8 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [ 13 ] }, { "entity_id": 4, "token_idxs": [ 4 ] }, { ...
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "I-TABLE", "O", "B-COLUMN", "O", "O", "B-VALUE", "O" ]
4,817
authors
bird:train.json:3628
At which conference was the paper "Skew-Circulant Preconditioners for Systems of LMF-Based ODE Codes" presented?
SELECT T2.FullName FROM Paper AS T1 INNER JOIN Conference AS T2 ON T1.ConferenceId = T2.Id WHERE T1.Title = 'Skew-Circulant Preconditioners for Systems of LMF-Based ODE Codes'
[ "At", "which", "conference", "was", "the", "paper", "\"", "Skew", "-", "Circulant", "Preconditioners", "for", "Systems", "of", "LMF", "-", "Based", "ODE", "Codes", "\"", "presented", "?" ]
[ { "id": 4, "type": "value", "value": "Skew-Circulant Preconditioners for Systems of LMF-Based ODE Codes" }, { "id": 5, "type": "column", "value": "conferenceid" }, { "id": 2, "type": "table", "value": "conference" }, { "id": 0, "type": "column", "value": "...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [ 2 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 7, 8, 9, 10, 11, ...
[ "O", "O", "B-TABLE", "O", "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", "O" ]
4,818
wrestler
spider:train_spider.json:1852
What are the names and location of the wrestlers?
SELECT Name , LOCATION FROM wrestler
[ "What", "are", "the", "names", "and", "location", "of", "the", "wrestlers", "?" ]
[ { "id": 0, "type": "table", "value": "wrestler" }, { "id": 2, "type": "column", "value": "location" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "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,819
cre_Doc_Control_Systems
spider:train_spider.json:2106
How many employees do we have?
SELECT count(*) FROM Employees;
[ "How", "many", "employees", "do", "we", "have", "?" ]
[ { "id": 0, "type": "table", "value": "employees" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "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-TABLE", "O", "O", "O", "O" ]
4,820
menu
bird:train.json:5556
Among the menus that include baked apples with cream, who is the sponsor of the menu with the highest price?
SELECT T4.sponsor FROM MenuPage AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.menu_page_id INNER JOIN Dish AS T3 ON T2.dish_id = T3.id INNER JOIN Menu AS T4 ON T4.id = T1.menu_id WHERE T3.name = 'Baked apples with cream' AND T3.id = 107 ORDER BY T2.price DESC LIMIT 1
[ "Among", "the", "menus", "that", "include", "baked", "apples", "with", "cream", ",", "who", "is", "the", "sponsor", "of", "the", "menu", "with", "the", "highest", "price", "?" ]
[ { "id": 7, "type": "value", "value": "Baked apples with cream" }, { "id": 12, "type": "column", "value": "menu_page_id" }, { "id": 9, "type": "table", "value": "menupage" }, { "id": 10, "type": "table", "value": "menuitem" }, { "id": 0, "type":...
[ { "entity_id": 0, "token_idxs": [ 13 ] }, { "entity_id": 1, "token_idxs": [ 16 ] }, { "entity_id": 2, "token_idxs": [ 20 ] }, { "entity_id": 3, "token_idxs": [ 11 ] }, { "entity_id": 4, "token_idxs": [] }, { "ent...
[ "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "O", "O", "B-TABLE", "O", "B-COLUMN", "O", "O", "B-TABLE", "B-TABLE", "O", "O", "B-COLUMN", "O" ]
4,821
law_episode
bird:train.json:1348
Who played the role of a teleplay in the episode that won "Best Television Episode"?
SELECT T2.name FROM Award AS T1 INNER JOIN Person AS T2 ON T1.person_id = T2.person_id WHERE T1.result = 'Winner' AND T1.award = 'Best Television Episode'
[ "Who", "played", "the", "role", "of", "a", "teleplay", "in", "the", "episode", "that", "won", "\"", "Best", "Television", "Episode", "\"", "?" ]
[ { "id": 7, "type": "value", "value": "Best Television Episode" }, { "id": 3, "type": "column", "value": "person_id" }, { "id": 2, "type": "table", "value": "person" }, { "id": 4, "type": "column", "value": "result" }, { "id": 5, "type": "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": [ 13 ] }, { "entity_id": 5, "token_idxs": [] }, { ...
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "B-VALUE", "I-VALUE", "O", "O" ]
4,822
mondial_geo
bird:train.json:8495
When did the country whose capital is Nouakchott attained it's independence?
SELECT T2.Independence FROM country AS T1 INNER JOIN politics AS T2 ON T1.Code = T2.Country WHERE T1.Capital = 'Nouakchott'
[ "When", "did", "the", "country", "whose", "capital", "is", "Nouakchott", "attained", "it", "'s", "independence", "?" ]
[ { "id": 0, "type": "column", "value": "independence" }, { "id": 4, "type": "value", "value": "Nouakchott" }, { "id": 2, "type": "table", "value": "politics" }, { "id": 1, "type": "table", "value": "country" }, { "id": 3, "type": "column", "...
[ { "entity_id": 0, "token_idxs": [ 11 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [ 7 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "B-VALUE", "O", "O", "O", "B-COLUMN", "O" ]
4,823
works_cycles
bird:train.json:7063
What is the job position of the oldest employee?
SELECT T2.PersonType FROM Employee AS T1 INNER JOIN Person AS T2 ON T1.BusinessEntityID = T2.BusinessEntityID ORDER BY T1.BirthDate ASC LIMIT 1
[ "What", "is", "the", "job", "position", "of", "the", "oldest", "employee", "?" ]
[ { "id": 4, "type": "column", "value": "businessentityid" }, { "id": 0, "type": "column", "value": "persontype" }, { "id": 3, "type": "column", "value": "birthdate" }, { "id": 1, "type": "table", "value": "employee" }, { "id": 2, "type": "table"...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 8 ] }, { "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", "O", "O", "O", "B-TABLE", "O" ]
4,824
customers_and_orders
bird:test.json:286
What are the ids and product types for all products, sorted alphabetically by product name?
SELECT product_id , product_type_code FROM Products ORDER BY product_name
[ "What", "are", "the", "ids", "and", "product", "types", "for", "all", "products", ",", "sorted", "alphabetically", "by", "product", "name", "?" ]
[ { "id": 2, "type": "column", "value": "product_type_code" }, { "id": 3, "type": "column", "value": "product_name" }, { "id": 1, "type": "column", "value": "product_id" }, { "id": 0, "type": "table", "value": "products" } ]
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [ 14, 15 ] }, { "entity_id": 4, "token_idxs": [] }, { ...
[ "O", "O", "O", "O", "O", "B-COLUMN", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O" ]
4,825
airline
bird:train.json:5896
Give the actual elapsed time of the flights with air carrier named Semo Aviation Inc.: SEM.
SELECT T2.ACTUAL_ELAPSED_TIME FROM `Air Carriers` AS T1 INNER JOIN Airlines AS T2 ON T1.Code = T2.OP_CARRIER_AIRLINE_ID WHERE T1.Description = 'Semo Aviation Inc.: SEM'
[ "Give", "the", "actual", "elapsed", "time", "of", "the", "flights", "with", "air", "carrier", "named", "Semo", "Aviation", "Inc.", ":", "SEM", "." ]
[ { "id": 4, "type": "value", "value": "Semo Aviation Inc.: SEM" }, { "id": 6, "type": "column", "value": "op_carrier_airline_id" }, { "id": 0, "type": "column", "value": "actual_elapsed_time" }, { "id": 1, "type": "table", "value": "Air Carriers" }, { ...
[ { "entity_id": 0, "token_idxs": [ 2, 3, 4 ] }, { "entity_id": 1, "token_idxs": [ 9, 10 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 12, 13, ...
[ "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-TABLE", "I-TABLE", "B-COLUMN", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "O" ]
4,826
software_company
bird:train.json:8562
In geographic identifier from 10 to 30, how many of them has an income below 2000?
SELECT COUNT(GEOID) FROM Demog WHERE INCOME_K < 2000 AND GEOID >= 10 AND GEOID <= 30
[ "In", "geographic", "identifier", "from", "10", "to", "30", ",", "how", "many", "of", "them", "has", "an", "income", "below", "2000", "?" ]
[ { "id": 2, "type": "column", "value": "income_k" }, { "id": 0, "type": "table", "value": "demog" }, { "id": 1, "type": "column", "value": "geoid" }, { "id": 3, "type": "value", "value": "2000" }, { "id": 4, "type": "value", "value": "10" ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 14 ] }, { "entity_id": 3, "token_idxs": [ 16 ] }, { "entity_id": 4, "token_idxs": [ 4 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "B-VALUE", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "B-VALUE", "O" ]
4,827
car_retails
bird:train.json:1618
For the productline where the product No.S18_2949 was produced, what's the text description for that product line?
SELECT t1.textDescription FROM productlines AS t1 INNER JOIN products AS t2 ON t1.productLine = t2.productLine WHERE t2.productCode = 'S18_2949'
[ "For", "the", "productline", "where", "the", "product", "No", ".", "S18_2949", "was", "produced", ",", "what", "'s", "the", "text", "description", "for", "that", "product", "line", "?" ]
[ { "id": 0, "type": "column", "value": "textdescription" }, { "id": 1, "type": "table", "value": "productlines" }, { "id": 3, "type": "column", "value": "productcode" }, { "id": 5, "type": "column", "value": "productline" }, { "id": 2, "type": "...
[ { "entity_id": 0, "token_idxs": [ 15, 16 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 19 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 8 ] }, { "entity_i...
[ "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "O", "O" ]
4,828
mondial_geo
bird:train.json:8471
State the area and population of the country where Asia Pacific Economic Cooperation headquarter is located.
SELECT T2.Name, T2.Population FROM organization AS T1 INNER JOIN country AS T2 ON T1.Country = T2.Code WHERE T1.Name = 'Asia Pacific Economic Cooperation'
[ "State", "the", "area", "and", "population", "of", "the", "country", "where", "Asia", "Pacific", "Economic", "Cooperation", "headquarter", "is", "located", "." ]
[ { "id": 4, "type": "value", "value": "Asia Pacific Economic Cooperation" }, { "id": 2, "type": "table", "value": "organization" }, { "id": 1, "type": "column", "value": "population" }, { "id": 3, "type": "table", "value": "country" }, { "id": 5, ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [ 12 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 9, 10, 11 ] }, { ...
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "B-VALUE", "I-VALUE", "I-VALUE", "B-TABLE", "O", "O", "O", "O" ]
4,829
works_cycles
bird:train.json:7045
How many accounts have an address that is too long?
SELECT COUNT(*) FROM Address WHERE AddressLine2 <> ''
[ "How", "many", "accounts", "have", "an", "address", "that", "is", "too", "long", "?" ]
[ { "id": 1, "type": "column", "value": "addressline2" }, { "id": 0, "type": "table", "value": "address" } ]
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "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", "O", "O", "O", "O", "O" ]
4,830
professional_basketball
bird:train.json:2924
How many first round draft player in 1996 NBA draft became an All-Star?
SELECT COUNT(T2.playerID) FROM draft AS T1 INNER JOIN player_allstar AS T2 ON T1.playerID = T2.playerID WHERE T1.draftYear = 1996 AND T1.draftRound = 1
[ "How", "many", "first", "round", "draft", "player", "in", "1996", "NBA", "draft", "became", "an", "All", "-", "Star", "?" ]
[ { "id": 1, "type": "table", "value": "player_allstar" }, { "id": 5, "type": "column", "value": "draftround" }, { "id": 3, "type": "column", "value": "draftyear" }, { "id": 2, "type": "column", "value": "playerid" }, { "id": 0, "type": "table", ...
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [ 11, 12, 13, 14 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [ 4 ] }, { "entity_id": 4, "token_...
[ "O", "O", "B-COLUMN", "I-COLUMN", "B-COLUMN", "B-COLUMN", "O", "B-VALUE", "O", "B-TABLE", "O", "B-TABLE", "I-TABLE", "I-TABLE", "I-TABLE", "O" ]
4,831
donor
bird:train.json:3206
Which item provided to a project whose main subject area is Literacy & Language has the highest unit price?
SELECT T1.item_name FROM resources AS T1 INNER JOIN projects AS T2 ON T1.projectid = T2.projectid WHERE T2.primary_focus_area = 'Literacy & Language' ORDER BY T1.item_unit_price DESC LIMIT 1
[ "Which", "item", "provided", "to", "a", "project", "whose", "main", "subject", "area", "is", "Literacy", "&", "Language", "has", "the", "highest", "unit", "price", "?" ]
[ { "id": 4, "type": "value", "value": "Literacy & Language" }, { "id": 3, "type": "column", "value": "primary_focus_area" }, { "id": 5, "type": "column", "value": "item_unit_price" }, { "id": 0, "type": "column", "value": "item_name" }, { "id": 1, ...
[ { "entity_id": 0, "token_idxs": [ 1 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 11, 12, 13 ] }, { ...
[ "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O" ]
4,832
activity_1
spider:train_spider.json:6763
Show ids for the faculty members who don't advise any student.
SELECT FacID FROM Faculty EXCEPT SELECT advisor FROM Student
[ "Show", "ids", "for", "the", "faculty", "members", "who", "do", "n't", "advise", "any", "student", "." ]
[ { "id": 0, "type": "table", "value": "faculty" }, { "id": 1, "type": "table", "value": "student" }, { "id": 3, "type": "column", "value": "advisor" }, { "id": 2, "type": "column", "value": "facid" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 11 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-COLUMN", "O", "B-TABLE", "O" ]
4,833
simpson_episodes
bird:train.json:4274
Please list the three episodes with the highest number of votes for the worst star rating.
SELECT T1.title FROM Episode AS T1 INNER JOIN Vote AS T2 ON T2.episode_id = T1.episode_id WHERE T2.stars = ( SELECT MIN(stars) FROM Vote ) ORDER BY T2.votes DESC LIMIT 3;
[ "Please", "list", "the", "three", "episodes", "with", "the", "highest", "number", "of", "votes", "for", "the", "worst", "star", "rating", "." ]
[ { "id": 5, "type": "column", "value": "episode_id" }, { "id": 1, "type": "table", "value": "episode" }, { "id": 0, "type": "column", "value": "title" }, { "id": 3, "type": "column", "value": "stars" }, { "id": 4, "type": "column", "value": ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [ 14 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "O", "O" ]
4,834
real_estate_rentals
bird:test.json:1402
How is the feature rooftop described?
SELECT feature_description FROM Features WHERE feature_name = 'rooftop';
[ "How", "is", "the", "feature", "rooftop", "described", "?" ]
[ { "id": 1, "type": "column", "value": "feature_description" }, { "id": 2, "type": "column", "value": "feature_name" }, { "id": 0, "type": "table", "value": "features" }, { "id": 3, "type": "value", "value": "rooftop" } ]
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 4 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "B-TABLE", "B-VALUE", "O", "O" ]
4,835
movie_1
spider:train_spider.json:2487
For all directors who have directed more than one movie, what movies have they directed and what are their names?
SELECT T1.title , T1.director FROM Movie AS T1 JOIN Movie AS T2 ON T1.director = T2.director WHERE T1.title != T2.title ORDER BY T1.director , T1.title
[ "For", "all", "directors", "who", "have", "directed", "more", "than", "one", "movie", ",", "what", "movies", "have", "they", "directed", "and", "what", "are", "their", "names", "?" ]
[ { "id": 1, "type": "column", "value": "director" }, { "id": 0, "type": "column", "value": "title" }, { "id": 2, "type": "table", "value": "movie" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 9 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]