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,836
cre_Doc_and_collections
bird:test.json:726
What is the number of document object ids in the collection named Best?
SELECT T2.Document_Object_ID FROM Collections AS T1 JOIN Documents_in_Collections AS T2 ON T1.Collection_ID = T2.Collection_ID WHERE T1.Collection_Name = "Best";
[ "What", "is", "the", "number", "of", "document", "object", "ids", "in", "the", "collection", "named", "Best", "?" ]
[ { "id": 2, "type": "table", "value": "documents_in_collections" }, { "id": 0, "type": "column", "value": "document_object_id" }, { "id": 3, "type": "column", "value": "collection_name" }, { "id": 5, "type": "column", "value": "collection_id" }, { "...
[ { "entity_id": 0, "token_idxs": [ 5, 6, 7 ] }, { "entity_id": 1, "token_idxs": [ 10 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 11 ] }, { "entity_id": 4, "token_idxs": [ 12 ] ...
[ "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "B-COLUMN", "B-COLUMN", "O" ]
4,837
vehicle_driver
bird:test.json:182
Return the ids and models of vehicles that have been driven by more than 2 drivers or been driven by the Jeff Gordon.
SELECT T1.vehicle_id , T1.model FROM vehicle AS T1 JOIN vehicle_driver AS T2 ON T1.vehicle_id = T2.vehicle_id JOIN driver AS T3 ON T2.driver_id = T3.driver_id WHERE T3.name = 'Jeff Gordon' UNION SELECT T1.vehicle_id , T1.model FROM vehicle AS T1 JOIN vehicle_driver AS T2 ON T1.vehicle_id = T2.vehicle_id GROUP...
[ "Return", "the", "ids", "and", "models", "of", "vehicles", "that", "have", "been", "driven", "by", "more", "than", "2", "drivers", "or", "been", "driven", "by", "the", "Jeff", "Gordon", "." ]
[ { "id": 6, "type": "table", "value": "vehicle_driver" }, { "id": 4, "type": "value", "value": "Jeff Gordon" }, { "id": 0, "type": "column", "value": "vehicle_id" }, { "id": 8, "type": "column", "value": "driver_id" }, { "id": 5, "type": "table"...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [ 15 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 21, 22 ] }, { "entity_i...
[ "O", "O", "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "B-TABLE", "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "O" ]
4,838
soccer_2016
bird:train.json:1950
What is the date of the match that has the highest wager on the final result of a game?
SELECT Match_Date FROM `Match` ORDER BY Win_Margin DESC LIMIT 1
[ "What", "is", "the", "date", "of", "the", "match", "that", "has", "the", "highest", "wager", "on", "the", "final", "result", "of", "a", "game", "?" ]
[ { "id": 1, "type": "column", "value": "match_date" }, { "id": 2, "type": "column", "value": "win_margin" }, { "id": 0, "type": "table", "value": "Match" } ]
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "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-TABLE", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
4,839
legislator
bird:train.json:4829
List the full name of legislators whose born in 1960.
SELECT official_full_name FROM current WHERE birthday_bio LIKE '1960%'
[ "List", "the", "full", "name", "of", "legislators", "whose", "born", "in", "1960", "." ]
[ { "id": 1, "type": "column", "value": "official_full_name" }, { "id": 2, "type": "column", "value": "birthday_bio" }, { "id": 0, "type": "table", "value": "current" }, { "id": 3, "type": "value", "value": "1960%" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2, 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "toke...
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
4,840
cre_Drama_Workshop_Groups
spider:train_spider.json:5111
Tell me the name of the most pricy product.
SELECT Product_Name FROM PRODUCTS ORDER BY Product_Price DESC LIMIT 1
[ "Tell", "me", "the", "name", "of", "the", "most", "pricy", "product", "." ]
[ { "id": 2, "type": "column", "value": "product_price" }, { "id": 1, "type": "column", "value": "product_name" }, { "id": 0, "type": "table", "value": "products" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "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", "O", "O", "O", "B-TABLE", "O" ]
4,841
aan_1
bird:test.json:1008
What is the title of the paper which cites the most other papers?
SELECT T2.title FROM Citation AS T1 JOIN Paper AS T2 ON T2.paper_id = T1.paper_id GROUP BY T1.paper_id ORDER BY count(*) DESC LIMIT 1
[ "What", "is", "the", "title", "of", "the", "paper", "which", "cites", "the", "most", "other", "papers", "?" ]
[ { "id": 0, "type": "column", "value": "paper_id" }, { "id": 2, "type": "table", "value": "citation" }, { "id": 1, "type": "column", "value": "title" }, { "id": 3, "type": "table", "value": "paper" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O" ]
4,842
talkingdata
bird:train.json:1068
Provide the phone brands and models of the users who were at the coordinates of (80,44).
SELECT DISTINCT T1.phone_brand, T1.device_model FROM phone_brand_device_model2 AS T1 INNER JOIN events AS T2 ON T2.device_id = T1.device_id WHERE T2.longitude = 80 AND T2.latitude = 44
[ "Provide", "the", "phone", "brands", "and", "models", "of", "the", "users", "who", "were", "at", "the", "coordinates", "of", "(", "80,44", ")", "." ]
[ { "id": 2, "type": "table", "value": "phone_brand_device_model2" }, { "id": 1, "type": "column", "value": "device_model" }, { "id": 0, "type": "column", "value": "phone_brand" }, { "id": 4, "type": "column", "value": "device_id" }, { "id": 5, "...
[ { "entity_id": 0, "token_idxs": [ 2, 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 4, 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "B-COLUMN", "I-COLUMN", "B-TABLE", "I-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
4,843
authors
bird:train.json:3660
State the name and affiliation of author for the 'Education, democracy and growth' paper?
SELECT T2.Name, T2.Affiliation FROM Paper AS T1 INNER JOIN PaperAuthor AS T2 ON T1.Id = T2.PaperId WHERE T1.Title = 'Education, democracy and growth'
[ "State", "the", "name", "and", "affiliation", "of", "author", "for", "the", "'", "Education", ",", "democracy", "and", "growth", "'", "paper", "?" ]
[ { "id": 5, "type": "value", "value": "Education, democracy and growth" }, { "id": 1, "type": "column", "value": "affiliation" }, { "id": 3, "type": "table", "value": "paperauthor" }, { "id": 7, "type": "column", "value": "paperid" }, { "id": 2, ...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [ 16 ] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [ 0 ] }, ...
[ "B-COLUMN", "O", "B-COLUMN", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "O", "B-TABLE", "O" ]
4,845
shooting
bird:train.json:2470
For case(s) where officer 'Evenden, George' is in charged, state the case number and the grand jury disposition?
SELECT T1.case_number, T1.grand_jury_disposition FROM incidents AS T1 INNER JOIN officers AS T2 ON T1.case_number = T2.case_number WHERE T2.first_name = 'George' AND T2.last_name = 'Evenden'
[ "For", "case(s", ")", "where", "officer", "'", "Evenden", ",", "George", "'", "is", "in", "charged", ",", "state", "the", "case", "number", "and", "the", "grand", "jury", "disposition", "?" ]
[ { "id": 1, "type": "column", "value": "grand_jury_disposition" }, { "id": 0, "type": "column", "value": "case_number" }, { "id": 4, "type": "column", "value": "first_name" }, { "id": 2, "type": "table", "value": "incidents" }, { "id": 6, "type"...
[ { "entity_id": 0, "token_idxs": [ 16, 17 ] }, { "entity_id": 1, "token_idxs": [ 20, 21, 22 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 4 ] }, { "entity_id": 4, "token_idxs": [] ...
[ "O", "O", "O", "O", "B-TABLE", "O", "B-VALUE", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O" ]
4,846
movielens
bird:train.json:2274
What is the percentage of female audiences who viewed movies with rating 2?
SELECT CAST(SUM(IIF(T2.u_gender = 'F', 1, 0)) AS REAL) * 100 / COUNT(T2.userid) FROM u2base AS T1 INNER JOIN users AS T2 ON T1.userid = T2.userid WHERE T1.rating = 2
[ "What", "is", "the", "percentage", "of", "female", "audiences", "who", "viewed", "movies", "with", "rating", "2", "?" ]
[ { "id": 8, "type": "column", "value": "u_gender" }, { "id": 0, "type": "table", "value": "u2base" }, { "id": 2, "type": "column", "value": "rating" }, { "id": 4, "type": "column", "value": "userid" }, { "id": 1, "type": "table", "value": "u...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 11 ] }, { "entity_id": 3, "token_idxs": [ 12 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs"...
[ "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "B-COLUMN", "B-VALUE", "O" ]
4,847
law_episode
bird:train.json:1265
For the episode with the most votes, give its air date.
SELECT T2.air_date FROM Vote AS T1 INNER JOIN Episode AS T2 ON T2.episode_id = T1.episode_id GROUP BY T2.episode_id ORDER BY SUM(T1.votes) DESC LIMIT 1
[ "For", "the", "episode", "with", "the", "most", "votes", ",", "give", "its", "air", "date", "." ]
[ { "id": 0, "type": "column", "value": "episode_id" }, { "id": 1, "type": "column", "value": "air_date" }, { "id": 3, "type": "table", "value": "episode" }, { "id": 4, "type": "column", "value": "votes" }, { "id": 2, "type": "table", "value"...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 10, 11 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [ 2 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id...
[ "O", "O", "B-TABLE", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O" ]
4,848
apartment_rentals
spider:train_spider.json:1234
Show the start dates and end dates of all the apartment bookings made by guests with gender code "Female".
SELECT T1.booking_start_date , T1.booking_start_date FROM Apartment_Bookings AS T1 JOIN Guests AS T2 ON T1.guest_id = T2.guest_id WHERE T2.gender_code = "Female"
[ "Show", "the", "start", "dates", "and", "end", "dates", "of", "all", "the", "apartment", "bookings", "made", "by", "guests", "with", "gender", "code", "\"", "Female", "\"", "." ]
[ { "id": 0, "type": "column", "value": "booking_start_date" }, { "id": 1, "type": "table", "value": "apartment_bookings" }, { "id": 3, "type": "column", "value": "gender_code" }, { "id": 5, "type": "column", "value": "guest_id" }, { "id": 2, "ty...
[ { "entity_id": 0, "token_idxs": [ 12 ] }, { "entity_id": 1, "token_idxs": [ 10, 11 ] }, { "entity_id": 2, "token_idxs": [ 14 ] }, { "entity_id": 3, "token_idxs": [ 16, 17 ] }, { "entity_id": 4, "token_idxs": ...
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "I-TABLE", "B-COLUMN", "O", "B-TABLE", "O", "B-COLUMN", "I-COLUMN", "O", "B-COLUMN", "O", "O" ]
4,849
world
bird:train.json:7864
Who is the head of state of the country where the city of Pyongyang is under?
SELECT T1.HeadOfState FROM Country AS T1 INNER JOIN City AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = 'Pyongyang'
[ "Who", "is", "the", "head", "of", "state", "of", "the", "country", "where", "the", "city", "of", "Pyongyang", "is", "under", "?" ]
[ { "id": 0, "type": "column", "value": "headofstate" }, { "id": 6, "type": "column", "value": "countrycode" }, { "id": 4, "type": "value", "value": "Pyongyang" }, { "id": 1, "type": "table", "value": "country" }, { "id": 2, "type": "table", ...
[ { "entity_id": 0, "token_idxs": [ 3, 4, 5 ] }, { "entity_id": 1, "token_idxs": [ 8 ] }, { "entity_id": 2, "token_idxs": [ 11 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 13 ] ...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "O", "O", "B-TABLE", "O", "B-VALUE", "O", "O", "O" ]
4,850
network_2
spider:train_spider.json:4442
Find the name and age of the person who is a friend of Dan or Alice.
SELECT DISTINCT T1.name , T1.age FROM Person AS T1 JOIN PersonFriend AS T2 ON T1.name = T2.name WHERE T2.friend = 'Dan' OR T2.friend = 'Alice'
[ "Find", "the", "name", "and", "age", "of", "the", "person", "who", "is", "a", "friend", "of", "Dan", "or", "Alice", "." ]
[ { "id": 3, "type": "table", "value": "personfriend" }, { "id": 2, "type": "table", "value": "person" }, { "id": 4, "type": "column", "value": "friend" }, { "id": 6, "type": "value", "value": "Alice" }, { "id": 0, "type": "column", "value": ...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [ 8, 9, 10 ] }, { "entity_id": 4, "token_idxs": [ ...
[ "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "O", "B-TABLE", "B-TABLE", "I-TABLE", "I-TABLE", "B-COLUMN", "O", "B-VALUE", "O", "B-VALUE", "O" ]
4,851
shakespeare
bird:train.json:3038
How many chapters have the name Gratiano as a character for "friend to Antonio and Bassiano"?
SELECT COUNT(DISTINCT T2.chapter_id) FROM characters AS T1 INNER JOIN paragraphs AS T2 ON T1.id = T2.character_id WHERE T1.CharName = 'Gratiano' AND T1.Description = 'friend to Antonio and Bassiano'
[ "How", "many", "chapters", "have", "the", "name", "Gratiano", "as", "a", "character", "for", "\"", "friend", "to", "Antonio", "and", "Bassiano", "\"", "?" ]
[ { "id": 8, "type": "value", "value": "friend to Antonio and Bassiano" }, { "id": 4, "type": "column", "value": "character_id" }, { "id": 7, "type": "column", "value": "description" }, { "id": 0, "type": "table", "value": "characters" }, { "id": 1, ...
[ { "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": [ 9 ...
[ "O", "O", "B-COLUMN", "O", "O", "O", "B-VALUE", "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "O", "O" ]
4,852
e_learning
spider:train_spider.json:3829
Find the enrollment date for all the tests that have "Pass" result.
SELECT T1.date_of_enrolment FROM Student_Course_Enrolment AS T1 JOIN Student_Tests_Taken AS T2 ON T1.registration_id = T2.registration_id WHERE T2.test_result = "Pass"
[ "Find", "the", "enrollment", "date", "for", "all", "the", "tests", "that", "have", "\"", "Pass", "\"", "result", "." ]
[ { "id": 1, "type": "table", "value": "student_course_enrolment" }, { "id": 2, "type": "table", "value": "student_tests_taken" }, { "id": 0, "type": "column", "value": "date_of_enrolment" }, { "id": 5, "type": "column", "value": "registration_id" }, { ...
[ { "entity_id": 0, "token_idxs": [ 1, 2 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 13 ] }, { "entity_id": 4, "token_idxs": [ 11 ] }, { "entity_id...
[ "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "O" ]
4,853
college_3
spider:train_spider.json:4640
What are the names of courses with 1 credit?
SELECT CName FROM COURSE WHERE Credits = 1
[ "What", "are", "the", "names", "of", "courses", "with", "1", "credit", "?" ]
[ { "id": 2, "type": "column", "value": "credits" }, { "id": 0, "type": "table", "value": "course" }, { "id": 1, "type": "column", "value": "cname" }, { "id": 3, "type": "value", "value": "1" } ]
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [ 7 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_...
[ "O", "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "B-VALUE", "B-COLUMN", "O" ]
4,854
food_inspection
bird:train.json:8774
How many restaurants have met all requirements in the inspection?
SELECT COUNT(score) FROM inspections WHERE score = 100
[ "How", "many", "restaurants", "have", "met", "all", "requirements", "in", "the", "inspection", "?" ]
[ { "id": 0, "type": "table", "value": "inspections" }, { "id": 1, "type": "column", "value": "score" }, { "id": 2, "type": "value", "value": "100" } ]
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "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", "O", "O", "O", "O", "B-TABLE", "O" ]
4,855
e_learning
spider:train_spider.json:3769
Find the total number of courses offered.
SELECT count(*) FROM COURSES
[ "Find", "the", "total", "number", "of", "courses", "offered", "." ]
[ { "id": 0, "type": "table", "value": "courses" } ]
[ { "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" ]
4,856
olympics
bird:train.json:5032
What is the percentage of female competitors whose heights are over 170 that participated in the game in 1988?
SELECT CAST(COUNT(CASE WHEN T3.gender = 'F' AND T3.height > 170 THEN 1 END) AS REAL) * 100 / COUNT(T2.person_id) FROM games AS T1 INNER JOIN games_competitor AS T2 ON T1.id = T2.games_id INNER JOIN person AS T3 ON T2.person_id = T3.id WHERE T1.games_year = 1988
[ "What", "is", "the", "percentage", "of", "female", "competitors", "whose", "heights", "are", "over", "170", "that", "participated", "in", "the", "game", "in", "1988", "?" ]
[ { "id": 4, "type": "table", "value": "games_competitor" }, { "id": 1, "type": "column", "value": "games_year" }, { "id": 5, "type": "column", "value": "person_id" }, { "id": 8, "type": "column", "value": "games_id" }, { "id": 0, "type": "table"...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 18 ] }, { "entity_id": 3, "token_idxs": [ 16 ] }, { "entity_id": 4, "token_idxs": [ 6 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "B-VALUE", "O", "B-TABLE", "O", "B-COLUMN", "O", "O", "B-VALUE", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "B-VALUE", "O" ]
4,857
cre_Doc_and_collections
bird:test.json:671
What is the parent document of document owned by Marlin? List the document id.
SELECT Parent_Document_Object_ID FROM Document_Objects WHERE OWNER = 'Marlin'
[ "What", "is", "the", "parent", "document", "of", "document", "owned", "by", "Marlin", "?", "List", "the", "document", "i", "d." ]
[ { "id": 1, "type": "column", "value": "parent_document_object_id" }, { "id": 0, "type": "table", "value": "document_objects" }, { "id": 3, "type": "value", "value": "Marlin" }, { "id": 2, "type": "column", "value": "owner" } ]
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [ 3, 4, 5 ] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [] }...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "B-TABLE", "B-COLUMN", "O", "B-VALUE", "O", "O", "O", "O", "O", "O" ]
4,858
retail_complains
bird:train.json:347
Among the elderlies, state the last name of whose complaint is handled in server YIFAT?
SELECT T1.last FROM client AS T1 INNER JOIN callcenterlogs AS T2 ON T1.client_id = T2.`rand client` WHERE T1.age > 65 AND T2.server = 'YIFAT'
[ "Among", "the", "elderlies", ",", "state", "the", "last", "name", "of", "whose", "complaint", "is", "handled", "in", "server", "YIFAT", "?" ]
[ { "id": 2, "type": "table", "value": "callcenterlogs" }, { "id": 4, "type": "column", "value": "rand client" }, { "id": 3, "type": "column", "value": "client_id" }, { "id": 1, "type": "table", "value": "client" }, { "id": 7, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [ 10 ] }, { "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", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "B-VALUE", "O" ]
4,859
movielens
bird:train.json:2260
Among the worst actresses, how many of them got a rating of more than 3 to the movies they starred?
SELECT COUNT(T1.userid) FROM u2base AS T1 INNER JOIN movies2actors AS T2 ON T1.movieid = T2.movieid INNER JOIN actors AS T3 ON T2.actorid = T3.actorid INNER JOIN users AS T4 ON T1.userid = T4.userid WHERE T3.a_quality = 0 AND T1.rating > 3 AND T4.u_gender = 'F'
[ "Among", "the", "worst", "actresses", ",", "how", "many", "of", "them", "got", "a", "rating", "of", "more", "than", "3", "to", "the", "movies", "they", "starred", "?" ]
[ { "id": 10, "type": "table", "value": "movies2actors" }, { "id": 3, "type": "column", "value": "a_quality" }, { "id": 7, "type": "column", "value": "u_gender" }, { "id": 11, "type": "column", "value": "actorid" }, { "id": 12, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 3 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 11 ...
[ "O", "O", "O", "B-TABLE", "O", "O", "O", "B-VALUE", "O", "O", "O", "B-COLUMN", "O", "O", "O", "B-VALUE", "O", "O", "B-COLUMN", "O", "O", "O" ]
4,860
coinmarketcap
bird:train.json:6277
Please list the names of coins that has been disappeared.
SELECT name FROM coins WHERE status = 'extinct'
[ "Please", "list", "the", "names", "of", "coins", "that", "has", "been", "disappeared", "." ]
[ { "id": 3, "type": "value", "value": "extinct" }, { "id": 2, "type": "column", "value": "status" }, { "id": 0, "type": "table", "value": "coins" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "O", "B-COLUMN", "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "O" ]
4,862
works_cycles
bird:train.json:7091
What is the credit rating of the company whose average lead time is 16 days for a standard price of 18.9900 and whose last receipt date is August 27, 2011?
SELECT T2.CreditRating FROM ProductVendor AS T1 INNER JOIN Vendor AS T2 ON T1.BusinessEntityID = T2.BusinessEntityID WHERE T1.StandardPrice = 18.9900 AND T1.AverageLeadTime = 16 AND STRFTIME('%Y-%m-%d', T1.LastReceiptDate) = '2011-08-27'
[ "What", "is", "the", "credit", "rating", "of", "the", "company", "whose", "average", "lead", "time", "is", "16", "days", "for", "a", "standard", "price", "of", "18.9900", "and", "whose", "last", "receipt", "date", "is", "August", "27", ",", "2011", "?" ]
[ { "id": 3, "type": "column", "value": "businessentityid" }, { "id": 6, "type": "column", "value": "averageleadtime" }, { "id": 10, "type": "column", "value": "lastreceiptdate" }, { "id": 1, "type": "table", "value": "productvendor" }, { "id": 4, ...
[ { "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": [ 17, 18 ] }, { "entity_id": 5...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "B-VALUE", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-VALUE", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O" ]
4,863
store_product
spider:train_spider.json:4919
What are the names of all the stores in the largest district by population?
SELECT t1.store_name FROM store AS t1 JOIN store_district AS t2 ON t1.store_id = t2.store_id WHERE district_id = (SELECT district_id FROM district ORDER BY city_population DESC LIMIT 1)
[ "What", "are", "the", "names", "of", "all", "the", "stores", "in", "the", "largest", "district", "by", "population", "?" ]
[ { "id": 6, "type": "column", "value": "city_population" }, { "id": 2, "type": "table", "value": "store_district" }, { "id": 3, "type": "column", "value": "district_id" }, { "id": 0, "type": "column", "value": "store_name" }, { "id": 4, "type": ...
[ { "entity_id": 0, "token_idxs": [ 2, 3 ] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 8 ] }, { "entity_id":...
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "B-TABLE", "O", "B-COLUMN", "O" ]
4,864
airline
bird:train.json:5880
What is the actual departure time of JetBlue Airways with the plane's tail number N903JB to Fort Lauderdale-Hollywood International Airport on the 20th of August 2018?
SELECT T1.DEP_TIME FROM Airlines AS T1 INNER JOIN `Air Carriers` AS T2 ON T1.OP_CARRIER_AIRLINE_ID = T2.Code INNER JOIN Airports AS T3 ON T1.DEST = T3.Code WHERE T1.FL_DATE = '2018/8/20' AND T1.TAIL_NUM = 'N903JB' AND T2.Description LIKE '%JetBlue Airways%' AND T3.Description LIKE '%Fort Lauderdale-Hollywood%'
[ "What", "is", "the", "actual", "departure", "time", "of", "JetBlue", "Airways", "with", "the", "plane", "'s", "tail", "number", "N903JB", "to", "Fort", "Lauderdale", "-", "Hollywood", "International", "Airport", "on", "the", "20th", "of", "August", "2018", "...
[ { "id": 12, "type": "value", "value": "%Fort Lauderdale-Hollywood%" }, { "id": 13, "type": "column", "value": "op_carrier_airline_id" }, { "id": 11, "type": "value", "value": "%JetBlue Airways%" }, { "id": 3, "type": "table", "value": "Air Carriers" }, ...
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [ 22 ] }, { "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", "B-VALUE", "I-VALUE", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "B-VALUE", "O", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
4,865
olympics
bird:train.json:4952
How many athletes competed in the 1992 Summer Olympics?
SELECT COUNT(T2.person_id) FROM games AS T1 INNER JOIN games_competitor AS T2 ON T1.id = T2.games_id WHERE T1.games_name = '1928 Summer'
[ "How", "many", "athletes", "competed", "in", "the", "1992", "Summer", "Olympics", "?" ]
[ { "id": 1, "type": "table", "value": "games_competitor" }, { "id": 3, "type": "value", "value": "1928 Summer" }, { "id": 2, "type": "column", "value": "games_name" }, { "id": 4, "type": "column", "value": "person_id" }, { "id": 6, "type": "colu...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 6, 7 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] ...
[ "O", "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "O", "O" ]
4,866
chicago_crime
bird:train.json:8762
Please list the location coordinates of all the incidents that had happened in the ward represented by alderman Pat Dowell.
SELECT T2.latitude, T2.longitude FROM Ward AS T1 INNER JOIN Crime AS T2 ON T1.ward_no = T2.ward_no WHERE T1.alderman_first_name = 'Pat' AND T1.alderman_last_name = 'Dowell' AND T2.latitude IS NOT NULL AND T2.longitude IS NOT NULL
[ "Please", "list", "the", "location", "coordinates", "of", "all", "the", "incidents", "that", "had", "happened", "in", "the", "ward", "represented", "by", "alderman", "Pat", "Dowell", "." ]
[ { "id": 5, "type": "column", "value": "alderman_first_name" }, { "id": 7, "type": "column", "value": "alderman_last_name" }, { "id": 1, "type": "column", "value": "longitude" }, { "id": 0, "type": "column", "value": "latitude" }, { "id": 4, "ty...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 14 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { ...
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "B-COLUMN", "B-VALUE", "B-VALUE", "O" ]
4,867
synthea
bird:train.json:1477
List out patient names with calcium deficiency.
SELECT DISTINCT T1.first, T1.last FROM patients AS T1 INNER JOIN observations AS T2 ON T1.patient = T2.PATIENT WHERE T2.DESCRIPTION = 'Calcium' AND T2.VALUE < 8.6
[ "List", "out", "patient", "names", "with", "calcium", "deficiency", "." ]
[ { "id": 3, "type": "table", "value": "observations" }, { "id": 5, "type": "column", "value": "description" }, { "id": 2, "type": "table", "value": "patients" }, { "id": 4, "type": "column", "value": "patient" }, { "id": 6, "type": "value", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 0 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 2 ] }, { "entity_id": 5, "token_idxs": ...
[ "B-COLUMN", "O", "B-COLUMN", "O", "O", "B-VALUE", "O", "O" ]
4,868
mondial_geo
bird:train.json:8372
What are the names of the cities along the Euphrat River's course? Indicate the capital city of the nation where the Euphrat River flows.
SELECT T2.City, T1.Capital FROM country AS T1 INNER JOIN located AS T2 ON T1.Code = T2.Country INNER JOIN river AS T3 ON T3.Name = T2.River WHERE T3.Name = 'Euphrat'
[ "What", "are", "the", "names", "of", "the", "cities", "along", "the", "Euphrat", "River", "'s", "course", "?", "Indicate", "the", "capital", "city", "of", "the", "nation", "where", "the", "Euphrat", "River", "flows", "." ]
[ { "id": 1, "type": "column", "value": "capital" }, { "id": 4, "type": "value", "value": "Euphrat" }, { "id": 5, "type": "table", "value": "country" }, { "id": 6, "type": "table", "value": "located" }, { "id": 9, "type": "column", "value": "...
[ { "entity_id": 0, "token_idxs": [ 17 ] }, { "entity_id": 1, "token_idxs": [ 16 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 3 ] }, { "entity_id": 4, "token_idxs": [ 23 ] }, { "enti...
[ "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "O", "O", "B-COLUMN", "B-COLUMN", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "O" ]
4,869
movie_3
bird:train.json:9293
What is the category of the film Agent Truman?
SELECT T3.name FROM film AS T1 INNER JOIN film_category AS T2 ON T1.film_id = T2.film_id INNER JOIN category AS T3 ON T2.category_id = T3.category_id WHERE T1.title = 'AGENT TRUMAN'
[ "What", "is", "the", "category", "of", "the", "film", "Agent", "Truman", "?" ]
[ { "id": 5, "type": "table", "value": "film_category" }, { "id": 3, "type": "value", "value": "AGENT TRUMAN" }, { "id": 6, "type": "column", "value": "category_id" }, { "id": 1, "type": "table", "value": "category" }, { "id": 7, "type": "column"...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 7, 8 ] }, { "entity_id": 4, "token_idxs": [ 6 ] }, { "entity_id":...
[ "O", "O", "O", "B-TABLE", "O", "O", "B-TABLE", "B-VALUE", "I-VALUE", "O" ]
4,870
scientist_1
spider:train_spider.json:6474
Count the number of different scientists assigned to any project.
SELECT count(DISTINCT scientist) FROM assignedto
[ "Count", "the", "number", "of", "different", "scientists", "assigned", "to", "any", "project", "." ]
[ { "id": 0, "type": "table", "value": "assignedto" }, { "id": 1, "type": "column", "value": "scientist" } ]
[ { "entity_id": 0, "token_idxs": [ 6, 7 ] }, { "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", "O", "O", "O", "B-COLUMN", "B-TABLE", "I-TABLE", "O", "O", "O" ]
4,871
hr_1
spider:train_spider.json:3416
On what dates were employees without the letter M in their first names hired?
SELECT hire_date FROM employees WHERE first_name NOT LIKE '%M%'
[ "On", "what", "dates", "were", "employees", "without", "the", "letter", "M", "in", "their", "first", "names", "hired", "?" ]
[ { "id": 2, "type": "column", "value": "first_name" }, { "id": 0, "type": "table", "value": "employees" }, { "id": 1, "type": "column", "value": "hire_date" }, { "id": 3, "type": "value", "value": "%M%" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 13 ] }, { "entity_id": 2, "token_idxs": [ 11, 12 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_i...
[ "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "B-COLUMN", "O" ]
4,872
works_cycles
bird:train.json:7248
What are the top 5 types of products with the highest selling price? ?
SELECT Name FROM Product ORDER BY ListPrice DESC LIMIT 5
[ "What", "are", "the", "top", "5", "types", "of", "products", "with", "the", "highest", "selling", "price", "?", "?" ]
[ { "id": 2, "type": "column", "value": "listprice" }, { "id": 0, "type": "table", "value": "product" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 12 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-COLUMN", "O", "O" ]
4,873
retail_complains
bird:train.json:255
Please list the full names of all the male clients in the Pacific division.
SELECT T1.first, T1.middle, T1.last FROM client AS T1 INNER JOIN district AS T2 ON T1.district_id = T2.district_id WHERE T2.division = 'Pacific' AND T1.sex = 'Male'
[ "Please", "list", "the", "full", "names", "of", "all", "the", "male", "clients", "in", "the", "Pacific", "division", "." ]
[ { "id": 5, "type": "column", "value": "district_id" }, { "id": 4, "type": "table", "value": "district" }, { "id": 6, "type": "column", "value": "division" }, { "id": 7, "type": "value", "value": "Pacific" }, { "id": 1, "type": "column", "va...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 1 ] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "B-VALUE", "B-TABLE", "O", "O", "B-VALUE", "B-COLUMN", "O" ]
4,874
works_cycles
bird:train.json:7283
Among the products that are purchased, how many of them have never received the highest rating?
SELECT COUNT(T1.ProductID) FROM ProductReview AS T1 INNER JOIN Product AS T2 ON T1.ProductID = T2.ProductID WHERE T2.MakeFlag = 0 AND T1.Rating != 5
[ "Among", "the", "products", "that", "are", "purchased", ",", "how", "many", "of", "them", "have", "never", "received", "the", "highest", "rating", "?" ]
[ { "id": 0, "type": "table", "value": "productreview" }, { "id": 2, "type": "column", "value": "productid" }, { "id": 3, "type": "column", "value": "makeflag" }, { "id": 1, "type": "table", "value": "product" }, { "id": 5, "type": "column", ...
[ { "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": [ 16 ...
[ "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O" ]
4,875
movie_3
bird:train.json:9163
Give the email address of the person who lives in "1411 Lillydale Drive".
SELECT T2.email FROM address AS T1 INNER JOIN staff AS T2 ON T1.address_id = T2.address_id WHERE T1.address = '1411 Lillydale Drive'
[ "Give", "the", "email", "address", "of", "the", "person", "who", "lives", "in", "\"", "1411", "Lillydale", "Drive", "\"", "." ]
[ { "id": 4, "type": "value", "value": "1411 Lillydale Drive" }, { "id": 5, "type": "column", "value": "address_id" }, { "id": 1, "type": "table", "value": "address" }, { "id": 3, "type": "column", "value": "address" }, { "id": 0, "type": "column...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 3 ] }, { "entity_id": 4, "token_idxs": [ 11, 12, 13 ] }, { ...
[ "O", "O", "B-COLUMN", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O", "O" ]
4,876
student_loan
bird:train.json:4513
What is the school and organization enrolled by student211?
SELECT T2.school, T1.organ FROM enlist AS T1 INNER JOIN enrolled AS T2 ON T2.name = T1.name WHERE T1.name = 'student211'
[ "What", "is", "the", "school", "and", "organization", "enrolled", "by", "student211", "?" ]
[ { "id": 5, "type": "value", "value": "student211" }, { "id": 3, "type": "table", "value": "enrolled" }, { "id": 0, "type": "column", "value": "school" }, { "id": 2, "type": "table", "value": "enlist" }, { "id": 1, "type": "column", "value":...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "B-TABLE", "O", "B-VALUE", "O" ]
4,877
movie_platform
bird:train.json:107
Which film rated by user 59988436 that received 21 comments?
SELECT T2.movie_title FROM ratings AS T1 INNER JOIN movies AS T2 ON T1.movie_id = T2.movie_id WHERE T1.user_id = 59988436 AND T1.critic_comments = 21
[ "Which", "film", "rated", "by", "user", "59988436", "that", "received", "21", "comments", "?" ]
[ { "id": 6, "type": "column", "value": "critic_comments" }, { "id": 0, "type": "column", "value": "movie_title" }, { "id": 3, "type": "column", "value": "movie_id" }, { "id": 5, "type": "value", "value": "59988436" }, { "id": 1, "type": "table",...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 4 ] }, { "entity_id": 5, "token_idxs": [ 5 ...
[ "O", "O", "O", "O", "B-COLUMN", "B-VALUE", "O", "O", "B-VALUE", "B-COLUMN", "O" ]
4,878
college_completion
bird:train.json:3717
Give the post name of "Idaho" state.
SELECT T FROM ( SELECT DISTINCT CASE WHEN state = 'Idaho' THEN state_post ELSE NULL END AS T FROM state_sector_details ) WHERE T IS NOT NULL
[ "Give", "the", "post", "name", "of", "\"", "Idaho", "\"", "state", "." ]
[ { "id": 1, "type": "table", "value": "state_sector_details" }, { "id": 2, "type": "column", "value": "state_post" }, { "id": 3, "type": "column", "value": "state" }, { "id": 4, "type": "value", "value": "Idaho" }, { "id": 0, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 1, 2 ] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [ 6 ] }, { "entity_id":...
[ "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "B-VALUE", "O", "B-COLUMN", "O" ]
4,879
retails
bird:train.json:6702
What is the percentage of the European countries among the given countries?
SELECT CAST(SUM(IIF(T2.r_name = 'EUROPE', 1, 0)) AS REAL) * 100 / COUNT(T1.n_name) FROM nation AS T1 INNER JOIN region AS T2 ON T1.n_regionkey = T2.r_regionkey
[ "What", "is", "the", "percentage", "of", "the", "European", "countries", "among", "the", "given", "countries", "?" ]
[ { "id": 2, "type": "column", "value": "n_regionkey" }, { "id": 3, "type": "column", "value": "r_regionkey" }, { "id": 0, "type": "table", "value": "nation" }, { "id": 1, "type": "table", "value": "region" }, { "id": 5, "type": "column", "va...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id...
[ "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "O" ]
4,880
movies_4
bird:train.json:416
Please list the names of all the producers in the movie "Pirates of the Caribbean: At World's End".
SELECT T3.person_name FROM movie AS T1 INNER JOIN movie_crew AS T2 ON T1.movie_id = T2.movie_id INNER JOIN person AS T3 ON T2.person_id = T3.person_id WHERE T1.title LIKE 'Pirates of the Caribbean: At World%s End' AND T2.job = 'Producer'
[ "Please", "list", "the", "names", "of", "all", "the", "producers", "in", "the", "movie", "\"", "Pirates", "of", "the", "Caribbean", ":", "At", "World", "'s", "End", "\"", "." ]
[ { "id": 6, "type": "value", "value": "Pirates of the Caribbean: At World%s End" }, { "id": 0, "type": "column", "value": "person_name" }, { "id": 3, "type": "table", "value": "movie_crew" }, { "id": 4, "type": "column", "value": "person_id" }, { "i...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { ...
[ "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "B-TABLE", "O", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "O", "O" ]
4,881
retail_world
bird:train.json:6516
In August of 1996, how many orders were placed by the customer with the highest amount of orders?
SELECT COUNT(OrderID) FROM Orders WHERE OrderDate LIKE '1996-08%' GROUP BY CustomerID ORDER BY COUNT(OrderID) DESC LIMIT 1
[ "In", "August", "of", "1996", ",", "how", "many", "orders", "were", "placed", "by", "the", "customer", "with", "the", "highest", "amount", "of", "orders", "?" ]
[ { "id": 1, "type": "column", "value": "customerid" }, { "id": 2, "type": "column", "value": "orderdate" }, { "id": 3, "type": "value", "value": "1996-08%" }, { "id": 4, "type": "column", "value": "orderid" }, { "id": 0, "type": "table", "va...
[ { "entity_id": 0, "token_idxs": [ 18 ] }, { "entity_id": 1, "token_idxs": [ 12 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 3 ] }, { "entity_id": 4, "token_idxs": [ 7 ] }, { "entit...
[ "O", "O", "O", "B-VALUE", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O" ]
4,882
movie_1
spider:train_spider.json:2524
What are names of the movies that are either made after 2000 or reviewed by Brittany Harris?
SELECT DISTINCT T2.title FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID JOIN Reviewer AS T3 ON T1.rID = T3.rID WHERE T3.name = 'Brittany Harris' OR T2.year > 2000
[ "What", "are", "names", "of", "the", "movies", "that", "are", "either", "made", "after", "2000", "or", "reviewed", "by", "Brittany", "Harris", "?" ]
[ { "id": 6, "type": "value", "value": "Brittany Harris" }, { "id": 1, "type": "table", "value": "reviewer" }, { "id": 2, "type": "table", "value": "rating" }, { "id": 0, "type": "column", "value": "title" }, { "id": 3, "type": "table", "valu...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 13 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-VALUE", "O", "B-TABLE", "O", "B-VALUE", "I-VALUE", "O" ]
4,883
codebase_community
bird:dev.json:704
What is the excerpt post ID and wiki post ID of the tag named sample?
SELECT ExcerptPostId, WikiPostId FROM tags WHERE TagName = 'sample'
[ "What", "is", "the", "excerpt", "post", "ID", "and", "wiki", "post", "ID", "of", "the", "tag", "named", "sample", "?" ]
[ { "id": 1, "type": "column", "value": "excerptpostid" }, { "id": 2, "type": "column", "value": "wikipostid" }, { "id": 3, "type": "column", "value": "tagname" }, { "id": 4, "type": "value", "value": "sample" }, { "id": 0, "type": "table", "...
[ { "entity_id": 0, "token_idxs": [ 12 ] }, { "entity_id": 1, "token_idxs": [ 3, 4, 5 ] }, { "entity_id": 2, "token_idxs": [ 7, 8, 9 ] }, { "entity_id": 3, "token_idxs": [ 13 ] }, { "entity_id": 4, ...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "B-COLUMN", "B-VALUE", "O" ]
4,884
thrombosis_prediction
bird:dev.json:1232
Provide ID, sex and age of patient who has blood glucose (GLU) not within normal range but with total cholesterol(T-CHO) within normal range.
SELECT DISTINCT T1.ID, T1.SEX , STRFTIME('%Y', CURRENT_TIMESTAMP) - STRFTIME('%Y', T1.Birthday) FROM Patient AS T1 INNER JOIN Laboratory AS T2 ON T1.ID = T2.ID WHERE T2.GLU >= 180 AND T2.`T-CHO` < 250
[ "Provide", "ID", ",", "sex", "and", "age", "of", "patient", "who", "has", "blood", "glucose", "(", "GLU", ")", "not", "within", "normal", "range", "but", "with", "total", "cholesterol(T", "-", "CHO", ")", "within", "normal", "range", "." ]
[ { "id": 3, "type": "table", "value": "laboratory" }, { "id": 9, "type": "column", "value": "birthday" }, { "id": 2, "type": "table", "value": "patient" }, { "id": 6, "type": "column", "value": "T-CHO" }, { "id": 1, "type": "column", "value"...
[ { "entity_id": 0, "token_idxs": [ 1 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 13 ] }, { "entity...
[ "O", "B-COLUMN", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O" ]
4,885
movie_3
bird:train.json:9273
How many actors acted in movies in the Music category?
SELECT COUNT(T1.actor_id) FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id INNER JOIN film_category AS T4 ON T3.film_id = T4.film_id INNER JOIN category AS T5 ON T4.category_id = T5.category_id WHERE T5.name = 'Music'
[ "How", "many", "actors", "acted", "in", "movies", "in", "the", "Music", "category", "?" ]
[ { "id": 4, "type": "table", "value": "film_category" }, { "id": 5, "type": "column", "value": "category_id" }, { "id": 9, "type": "table", "value": "film_actor" }, { "id": 0, "type": "table", "value": "category" }, { "id": 3, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-VALUE", "B-TABLE", "O" ]
4,886
codebase_community
bird:dev.json:643
What are the display names and ages of user who got the highest in views?
SELECT DisplayName, Age FROM users WHERE Views = ( SELECT MAX(Views) FROM users )
[ "What", "are", "the", "display", "names", "and", "ages", "of", "user", "who", "got", "the", "highest", "in", "views", "?" ]
[ { "id": 1, "type": "column", "value": "displayname" }, { "id": 0, "type": "table", "value": "users" }, { "id": 3, "type": "column", "value": "views" }, { "id": 2, "type": "column", "value": "age" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 3, 4 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [ 14 ] }, { "entity_id": 4, "token_idxs": [] }, { ...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-COLUMN", "O" ]
4,887
address_1
bird:test.json:796
How many students live in each city?
SELECT T1.city_name , count(*) FROM City AS T1 JOIN Student AS T2 ON T1.city_code = T2.city_code GROUP BY T1.city_code
[ "How", "many", "students", "live", "in", "each", "city", "?" ]
[ { "id": 0, "type": "column", "value": "city_code" }, { "id": 1, "type": "column", "value": "city_name" }, { "id": 3, "type": "table", "value": "student" }, { "id": 2, "type": "table", "value": "city" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [ 2 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-TABLE", "O", "O", "O", "B-TABLE", "O" ]
4,888
voter_2
spider:train_spider.json:5495
What are the distinct first names of the students who have vice president votes and reside in a city whose city code is not PIT?
SELECT DISTINCT T1.Fname FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID = T2.VICE_PRESIDENT_Vote EXCEPT SELECT DISTINCT Fname FROM STUDENT WHERE city_code = "PIT"
[ "What", "are", "the", "distinct", "first", "names", "of", "the", "students", "who", "have", "vice", "president", "votes", "and", "reside", "in", "a", "city", "whose", "city", "code", "is", "not", "PIT", "?" ]
[ { "id": 6, "type": "column", "value": "vice_president_vote" }, { "id": 2, "type": "table", "value": "voting_record" }, { "id": 3, "type": "column", "value": "city_code" }, { "id": 0, "type": "table", "value": "student" }, { "id": 1, "type": "co...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 20, 21 ] }, { "entity_id": 4, "token_idxs": [ 24 ] }, { "entity_i...
[ "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-COLUMN", "O" ]
4,890
workshop_paper
spider:train_spider.json:5839
Which authors have submitted to more than one workshop?
SELECT T2.Author FROM acceptance AS T1 JOIN submission AS T2 ON T1.Submission_ID = T2.Submission_ID GROUP BY T2.Author HAVING COUNT(DISTINCT T1.workshop_id) > 1
[ "Which", "authors", "have", "submitted", "to", "more", "than", "one", "workshop", "?" ]
[ { "id": 4, "type": "column", "value": "submission_id" }, { "id": 5, "type": "column", "value": "workshop_id" }, { "id": 1, "type": "table", "value": "acceptance" }, { "id": 2, "type": "table", "value": "submission" }, { "id": 0, "type": "column...
[ { "entity_id": 0, "token_idxs": [ 1 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 8 ...
[ "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O" ]
4,891
manufactory_1
spider:train_spider.json:5307
What is the total revenue of companies started by founder?
SELECT sum(revenue) , founder FROM manufacturers GROUP BY founder
[ "What", "is", "the", "total", "revenue", "of", "companies", "started", "by", "founder", "?" ]
[ { "id": 0, "type": "table", "value": "manufacturers" }, { "id": 1, "type": "column", "value": "founder" }, { "id": 2, "type": "column", "value": "revenue" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 9 ] }, { "entity_id": 2, "token_idxs": [ 4 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-COLUMN", "O" ]
4,893
image_and_language
bird:train.json:7565
What is the ratio between the number of object samples in image 1 and the number of object samples in image 6?
SELECT CAST(SUM(CASE WHEN IMG_ID = 1 THEN 1 ELSE 0 END) AS REAL) / SUM(CASE WHEN IMG_ID = 6 THEN 1 ELSE 0 END) FROM IMG_OBJ
[ "What", "is", "the", "ratio", "between", "the", "number", "of", "object", "samples", "in", "image", "1", "and", "the", "number", "of", "object", "samples", "in", "image", "6", "?" ]
[ { "id": 0, "type": "table", "value": "img_obj" }, { "id": 3, "type": "column", "value": "img_id" }, { "id": 1, "type": "value", "value": "0" }, { "id": 2, "type": "value", "value": "1" }, { "id": 4, "type": "value", "value": "6" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 12 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 21 ] }, { "entity_id": 5, "token_idxs"...
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
4,894
art_1
bird:test.json:1232
What are the widths of the paintings that were created by the artist who was born before 1850?
SELECT T2.width_mm FROM artists AS T1 JOIN paintings AS T2 ON T1.artistID = T2.painterID WHERE T1.birthYear < 1850
[ "What", "are", "the", "widths", "of", "the", "paintings", "that", "were", "created", "by", "the", "artist", "who", "was", "born", "before", "1850", "?" ]
[ { "id": 2, "type": "table", "value": "paintings" }, { "id": 3, "type": "column", "value": "birthyear" }, { "id": 6, "type": "column", "value": "painterid" }, { "id": 0, "type": "column", "value": "width_mm" }, { "id": 5, "type": "column", "...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 12 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 17 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-VALUE", "O" ]
4,895
movie_platform
bird:train.json:39
What is the URL to the rating on Mubi of the Riff-Raff movie that was given the highest rating score by user 22030372?
SELECT T2.rating_url FROM movies AS T1 INNER JOIN ratings AS T2 ON T1.movie_id = T2.movie_id WHERE T2.user_id = 22030372 AND T2.rating_score = 5 AND T1.movie_title = 'Riff-Raff'
[ "What", "is", "the", "URL", "to", "the", "rating", "on", "Mubi", "of", "the", "Riff", "-", "Raff", "movie", "that", "was", "given", "the", "highest", "rating", "score", "by", "user", "22030372", "?" ]
[ { "id": 6, "type": "column", "value": "rating_score" }, { "id": 8, "type": "column", "value": "movie_title" }, { "id": 0, "type": "column", "value": "rating_url" }, { "id": 9, "type": "value", "value": "Riff-Raff" }, { "id": 3, "type": "column"...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 14 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 23 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "B-TABLE", "B-COLUMN", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-COLUMN", "B-VALUE", "O" ]
4,896
cre_Doc_Tracking_DB
spider:train_spider.json:4208
Show all role codes with at least 3 employees.
SELECT role_code FROM Employees GROUP BY role_code HAVING count(*) >= 3
[ "Show", "all", "role", "codes", "with", "at", "least", "3", "employees", "." ]
[ { "id": 0, "type": "table", "value": "employees" }, { "id": 1, "type": "column", "value": "role_code" }, { "id": 2, "type": "value", "value": "3" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 2, 3 ] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id":...
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "B-VALUE", "B-TABLE", "O" ]
4,897
european_football_2
bird:dev.json:1052
Among all the players whose weight is under 130, how many of them preferred foot in attacking is left?
SELECT COUNT(DISTINCT t1.id) FROM Player AS t1 INNER JOIN Player_Attributes AS t2 ON t1.player_api_id = t2.player_api_id WHERE t1.weight < 130 AND t2.preferred_foot = 'left'
[ "Among", "all", "the", "players", "whose", "weight", "is", "under", "130", ",", "how", "many", "of", "them", "preferred", "foot", "in", "attacking", "is", "left", "?" ]
[ { "id": 1, "type": "table", "value": "player_attributes" }, { "id": 6, "type": "column", "value": "preferred_foot" }, { "id": 3, "type": "column", "value": "player_api_id" }, { "id": 0, "type": "table", "value": "player" }, { "id": 4, "type": "...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 5 ] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "B-TABLE", "O", "B-COLUMN", "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "B-VALUE", "O" ]
4,898
csu_1
spider:train_spider.json:2350
Which campus has the most faculties in year 2003?
SELECT T1.campus FROM campuses AS T1 JOIN faculty AS T2 ON T1.id = T2.campus WHERE T2.year = 2003 ORDER BY T2.faculty DESC LIMIT 1
[ "Which", "campus", "has", "the", "most", "faculties", "in", "year", "2003", "?" ]
[ { "id": 1, "type": "table", "value": "campuses" }, { "id": 2, "type": "table", "value": "faculty" }, { "id": 5, "type": "column", "value": "faculty" }, { "id": 0, "type": "column", "value": "campus" }, { "id": 3, "type": "column", "value": ...
[ { "entity_id": 0, "token_idxs": [ 1 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 7 ] }, { "entity_id": 4, "token_idxs": [ 8 ] }, { "entity_id": 5, "...
[ "O", "B-COLUMN", "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "B-VALUE", "O" ]
4,899
shakespeare
bird:train.json:2980
Give the description for the Act No.2, Scene No.2 of Midsummer Night's Dream.
SELECT T2.Description FROM works AS T1 INNER JOIN chapters AS T2 ON T1.id = T2.work_id WHERE T2.Act = '2' AND T2.Scene = '2' AND T1.Title = 'Midsummer Night''s Dream'
[ "Give", "the", "description", "for", "the", "Act", "No.2", ",", "Scene", "No.2", "of", "Midsummer", "Night", "'s", "Dream", "." ]
[ { "id": 9, "type": "value", "value": "Midsummer Night's Dream" }, { "id": 0, "type": "column", "value": "description" }, { "id": 2, "type": "table", "value": "chapters" }, { "id": 4, "type": "column", "value": "work_id" }, { "id": 1, "type": "t...
[ { "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": [ 5 ...
[ "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "O" ]
4,900
manufactory_1
spider:train_spider.json:5278
What are the average, maximum and total revenues of all companies?
SELECT avg(revenue) , max(revenue) , sum(revenue) FROM manufacturers
[ "What", "are", "the", "average", ",", "maximum", "and", "total", "revenues", "of", "all", "companies", "?" ]
[ { "id": 0, "type": "table", "value": "manufacturers" }, { "id": 1, "type": "column", "value": "revenue" } ]
[ { "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-COLUMN", "O", "O", "O", "O" ]
4,901
formula_1
bird:dev.json:889
When was the last f1 season whereby Brands Hatch hosted the British Grand Prix?
SELECT T2.date FROM circuits AS T1 INNER JOIN races AS T2 ON T2.circuitID = T1.circuitId WHERE T1.name = 'Brands Hatch' AND T2.name = 'British Grand Prix' ORDER BY T2.year DESC LIMIT 1
[ "When", "was", "the", "last", "f1", "season", "whereby", "Brands", "Hatch", "hosted", "the", "British", "Grand", "Prix", "?" ]
[ { "id": 7, "type": "value", "value": "British Grand Prix" }, { "id": 6, "type": "value", "value": "Brands Hatch" }, { "id": 4, "type": "column", "value": "circuitid" }, { "id": 1, "type": "table", "value": "circuits" }, { "id": 2, "type": "tabl...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id...
[ "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O" ]
4,902
authors
bird:train.json:3544
Write down the author's name and IDs who are affiliated with Univeristiy of Oulu.
SELECT Name, id FROM Author WHERE Affiliation = 'University of Oulu'
[ "Write", "down", "the", "author", "'s", "name", "and", "IDs", "who", "are", "affiliated", "with", "Univeristiy", "of", "Oulu", "." ]
[ { "id": 4, "type": "value", "value": "University of Oulu" }, { "id": 3, "type": "column", "value": "affiliation" }, { "id": 0, "type": "table", "value": "author" }, { "id": 1, "type": "column", "value": "name" }, { "id": 2, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [ 10 ] }, { "entity_id": 4, "token_idxs": [ 12, 13, ...
[ "O", "O", "O", "B-TABLE", "O", "B-COLUMN", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O" ]
4,903
professional_basketball
bird:train.json:2867
What is the full name of the team with the fastest growth in winning rate in the 'ABA' league from 1972 to 1973?
SELECT T1.name FROM teams AS T1 INNER JOIN ( SELECT * FROM teams WHERE lgID = 'ABA' AND year = 1972 ) AS T2 ON T1.tmID = T2.tmID WHERE T1.lgID = 'ABA' AND T1.year = 1973 ORDER BY (CAST(T1.won AS REAL) / (T1.won + T1.lost) - (CAST(T2.won AS REAL) / (T2.won + T2.lost))) DESC LIMIT 1
[ "What", "is", "the", "full", "name", "of", "the", "team", "with", "the", "fastest", "growth", "in", "winning", "rate", "in", "the", "'", "ABA", "'", "league", "from", "1972", "to", "1973", "?" ]
[ { "id": 1, "type": "table", "value": "teams" }, { "id": 0, "type": "column", "value": "name" }, { "id": 2, "type": "column", "value": "tmid" }, { "id": 3, "type": "column", "value": "lgid" }, { "id": 5, "type": "column", "value": "year" }...
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 18 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "B-VALUE", "O", "B-VALUE", "O" ]
4,904
protein_institute
spider:train_spider.json:1921
Show the names of buildings except for those having an institution founded in 2003.
SELECT name FROM building EXCEPT SELECT T1.name FROM building AS T1 JOIN institution AS T2 ON T1.building_id = T2.building_id WHERE T2.founded = 2003
[ "Show", "the", "names", "of", "buildings", "except", "for", "those", "having", "an", "institution", "founded", "in", "2003", "." ]
[ { "id": 2, "type": "table", "value": "institution" }, { "id": 5, "type": "column", "value": "building_id" }, { "id": 0, "type": "table", "value": "building" }, { "id": 3, "type": "column", "value": "founded" }, { "id": 1, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [ 11 ] }, { "entity_id": 4, "token_idxs": [ 13 ] }, ...
[ "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "B-VALUE", "O" ]
4,906
student_loan
bird:train.json:4570
Which organization has the highest number of male students? Calculate for the percentage of the male students in the said organization.
SELECT T.organ, T.per FROM ( SELECT T1.organ, CAST(COUNT(T3.name) AS REAL) / COUNT(T2.name) AS per , COUNT(T3.name) AS num FROM enlist AS T1 INNER JOIN person AS T2 ON T1.name = T2.name LEFT JOIN male AS T3 ON T2.name = T3.name GROUP BY T1.organ ) T ORDER BY T.num DESC LIMIT 1
[ "Which", "organization", "has", "the", "highest", "number", "of", "male", "students", "?", "Calculate", "for", "the", "percentage", "of", "the", "male", "students", "in", "the", "said", "organization", "." ]
[ { "id": 5, "type": "table", "value": "enlist" }, { "id": 6, "type": "table", "value": "person" }, { "id": 0, "type": "column", "value": "organ" }, { "id": 3, "type": "table", "value": "male" }, { "id": 4, "type": "column", "value": "name" ...
[ { "entity_id": 0, "token_idxs": [ 21 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [ 16 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-COLUMN", "O" ]
4,907
retail_world
bird:train.json:6454
Provide the name of the contact person who made the orders that shipped to Switzerland.
SELECT T1.ContactName FROM Customers AS T1 INNER JOIN Orders AS T2 ON T1.CustomerID = T2.CustomerID WHERE T2.ShipCountry = 'Switzerland' GROUP BY T1.ContactName
[ "Provide", "the", "name", "of", "the", "contact", "person", "who", "made", "the", "orders", "that", "shipped", "to", "Switzerland", "." ]
[ { "id": 0, "type": "column", "value": "contactname" }, { "id": 3, "type": "column", "value": "shipcountry" }, { "id": 4, "type": "value", "value": "Switzerland" }, { "id": 5, "type": "column", "value": "customerid" }, { "id": 1, "type": "table"...
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 14 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-VALUE", "O" ]
4,908
soccer_2016
bird:train.json:1878
List down the name of teams that won the toss of the coin from matches with ID from 336010 to 336020.
SELECT T2.Team_Name FROM Match AS T1 INNER JOIN Team AS T2 ON T2.Team_Id = T1.Toss_Winner WHERE T1.Match_Id BETWEEN 336010 AND 336020
[ "List", "down", "the", "name", "of", "teams", "that", "won", "the", "toss", "of", "the", "coin", "from", "matches", "with", "ID", "from", "336010", "to", "336020", "." ]
[ { "id": 7, "type": "column", "value": "toss_winner" }, { "id": 0, "type": "column", "value": "team_name" }, { "id": 3, "type": "column", "value": "match_id" }, { "id": 6, "type": "column", "value": "team_id" }, { "id": 4, "type": "value", "...
[ { "entity_id": 0, "token_idxs": [ 2, 3 ] }, { "entity_id": 1, "token_idxs": [ 14 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 18 ] }, { ...
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-VALUE", "O", "B-VALUE", "O" ]
4,909
cre_Docs_and_Epenses
spider:train_spider.json:6400
Count the number of documents.
SELECT count(*) FROM Documents
[ "Count", "the", "number", "of", "documents", "." ]
[ { "id": 0, "type": "table", "value": "documents" } ]
[ { "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,910
public_review_platform
bird:train.json:3897
List the closing time and day of week of active businesses in Tempe with stars greater than the 70% of average age of star rating.
SELECT T2.closing_time, T3.day_of_week FROM Business AS T1 INNER JOIN Business_Hours AS T2 ON T1.business_id = T2.business_id INNER JOIN Days AS T3 ON T2.day_id = T3.day_id WHERE T1.city LIKE 'Tempe' AND T1.active LIKE 'TRUE' AND T1.stars > 0.7 * ( SELECT AVG(T1.stars) FROM Business AS T1 INNER JOIN Business_Hours AS T...
[ "List", "the", "closing", "time", "and", "day", "of", "week", "of", "active", "businesses", "in", "Tempe", "with", "stars", "greater", "than", "the", "70", "%", "of", "average", "age", "of", "star", "rating", "." ]
[ { "id": 4, "type": "table", "value": "business_hours" }, { "id": 0, "type": "column", "value": "closing_time" }, { "id": 1, "type": "column", "value": "day_of_week" }, { "id": 11, "type": "column", "value": "business_id" }, { "id": 3, "type": "...
[ { "entity_id": 0, "token_idxs": [ 2, 3 ] }, { "entity_id": 1, "token_idxs": [ 6, 7 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [ 10 ] }, { "entity_id": 4, "token_idxs": [] ...
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-TABLE", "B-COLUMN", "I-COLUMN", "O", "B-COLUMN", "B-TABLE", "O", "B-VALUE", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
4,911
regional_sales
bird:train.json:2729
Between 2018 to 2020, what is the average amount of shipped orders per year under Carl Nguyen?
SELECT CAST(COUNT(T1.OrderNumber) AS REAL) / 3 FROM `Sales Orders` AS T1 INNER JOIN `Sales Team` AS T2 ON T2.SalesTeamID = T1._SalesTeamID WHERE (T2.`Sales Team` = 'Carl Nguyen' AND ShipDate LIKE '%/%/18') OR (T2.`Sales Team` = 'Carl Nguyen' AND ShipDate LIKE '%/%/19') OR (T2.`Sales Team` = 'Carl Nguyen' AND ShipDate L...
[ "Between", "2018", "to", "2020", ",", "what", "is", "the", "average", "amount", "of", "shipped", "orders", "per", "year", "under", "Carl", "Nguyen", "?" ]
[ { "id": 0, "type": "table", "value": "Sales Orders" }, { "id": 4, "type": "column", "value": "_salesteamid" }, { "id": 3, "type": "column", "value": "salesteamid" }, { "id": 6, "type": "value", "value": "Carl Nguyen" }, { "id": 11, "type": "col...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id...
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "B-COLUMN", "I-COLUMN", "O", "O", "B-VALUE", "I-VALUE", "O" ]
4,912
perpetrator
spider:train_spider.json:2303
How many perpetrators are there?
SELECT count(*) FROM perpetrator
[ "How", "many", "perpetrators", "are", "there", "?" ]
[ { "id": 0, "type": "table", "value": "perpetrator" } ]
[ { "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" ]
4,913
retails
bird:train.json:6850
Name customers in India with account balances over $5000.
SELECT T1.c_name FROM customer AS T1 INNER JOIN nation AS T2 ON T1.c_nationkey = T2.n_nationkey WHERE T1.c_acctbal > 5000 AND T2.n_name = 'INDIA'
[ "Name", "customers", "in", "India", "with", "account", "balances", "over", "$", "5000", "." ]
[ { "id": 3, "type": "column", "value": "c_nationkey" }, { "id": 4, "type": "column", "value": "n_nationkey" }, { "id": 5, "type": "column", "value": "c_acctbal" }, { "id": 1, "type": "table", "value": "customer" }, { "id": 0, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 1 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { ...
[ "B-COLUMN", "B-TABLE", "O", "B-VALUE", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
4,914
movies_4
bird:train.json:414
Please list the names of all the crew members of the movie "Pirates of the Caribbean: At World's End".
SELECT T3.person_name FROM movie AS T1 INNER JOIN movie_crew AS T2 ON T1.movie_id = T2.movie_id INNER JOIN person AS T3 ON T2.person_id = T3.person_id WHERE T1.title LIKE 'Pirates of the Caribbean: At World%s End'
[ "Please", "list", "the", "names", "of", "all", "the", "crew", "members", "of", "the", "movie", "\"", "Pirates", "of", "the", "Caribbean", ":", "At", "World", "'s", "End", "\"", "." ]
[ { "id": 3, "type": "value", "value": "Pirates of the Caribbean: At World%s End" }, { "id": 0, "type": "column", "value": "person_name" }, { "id": 5, "type": "table", "value": "movie_crew" }, { "id": 6, "type": "column", "value": "person_id" }, { "i...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 13, 14, 15, 16, 17, 18, 19, 20, 21 ] }, { "entity_id": 4, ...
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "O", "O" ]
4,916
retail_world
bird:train.json:6386
Give the full name and contact number of employees in descending order of age.
SELECT FirstName, LastName, HomePhone FROM Employees ORDER BY BirthDate DESC
[ "Give", "the", "full", "name", "and", "contact", "number", "of", "employees", "in", "descending", "order", "of", "age", "." ]
[ { "id": 0, "type": "table", "value": "employees" }, { "id": 1, "type": "column", "value": "firstname" }, { "id": 3, "type": "column", "value": "homephone" }, { "id": 4, "type": "column", "value": "birthdate" }, { "id": 2, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 3 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O" ]
4,917
ship_mission
spider:train_spider.json:4019
What are the mission codes, fates, and names of the ships involved?
SELECT T1.Code , T1.Fate , T2.Name FROM mission AS T1 JOIN ship AS T2 ON T1.Ship_ID = T2.Ship_ID
[ "What", "are", "the", "mission", "codes", ",", "fates", ",", "and", "names", "of", "the", "ships", "involved", "?" ]
[ { "id": 3, "type": "table", "value": "mission" }, { "id": 5, "type": "column", "value": "ship_id" }, { "id": 0, "type": "column", "value": "code" }, { "id": 1, "type": "column", "value": "fate" }, { "id": 2, "type": "column", "value": "name...
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [ 9 ] }, { "entity_id": 3, "token_idxs": [ 3 ] }, { "entity_id": 4, "token_idxs": [ 12 ] }, ...
[ "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O" ]
4,918
swimming
spider:train_spider.json:5626
Find the names of the swimmers who have no record.
SELECT name FROM swimmer WHERE id NOT IN (SELECT swimmer_id FROM record)
[ "Find", "the", "names", "of", "the", "swimmers", "who", "have", "no", "record", "." ]
[ { "id": 4, "type": "column", "value": "swimmer_id" }, { "id": 0, "type": "table", "value": "swimmer" }, { "id": 3, "type": "table", "value": "record" }, { "id": 1, "type": "column", "value": "name" }, { "id": 2, "type": "column", "value": "...
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 0 ] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_...
[ "B-COLUMN", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "B-TABLE", "O" ]
4,919
device
spider:train_spider.json:5068
Show names of shops and the carriers of devices they have in stock.
SELECT T3.Shop_Name , T2.Carrier FROM stock AS T1 JOIN device AS T2 ON T1.Device_ID = T2.Device_ID JOIN shop AS T3 ON T1.Shop_ID = T3.Shop_ID
[ "Show", "names", "of", "shops", "and", "the", "carriers", "of", "devices", "they", "have", "in", "stock", "." ]
[ { "id": 0, "type": "column", "value": "shop_name" }, { "id": 6, "type": "column", "value": "device_id" }, { "id": 1, "type": "column", "value": "carrier" }, { "id": 5, "type": "column", "value": "shop_id" }, { "id": 4, "type": "table", "val...
[ { "entity_id": 0, "token_idxs": [ 0, 1 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [ 3 ] }, { "entity_id": 3, "token_idxs": [ 12 ] }, { "entity_id": 4, "token_idxs": [ 8 ...
[ "B-COLUMN", "I-COLUMN", "O", "B-TABLE", "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "O", "B-TABLE", "O" ]
4,921
video_game
bird:test.json:1945
List all player names in ascending alphabetical order.
SELECT Player_name FROM player ORDER BY Player_name ASC
[ "List", "all", "player", "names", "in", "ascending", "alphabetical", "order", "." ]
[ { "id": 1, "type": "column", "value": "player_name" }, { "id": 0, "type": "table", "value": "player" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "O", "O" ]
4,922
retail_world
bird:train.json:6333
Who is the newest hired employee? Give the full name.
SELECT FirstName, LastName FROM Employees WHERE HireDate = ( SELECT MAX(HireDate) FROM Employees )
[ "Who", "is", "the", "newest", "hired", "employee", "?", "Give", "the", "full", "name", "." ]
[ { "id": 0, "type": "table", "value": "employees" }, { "id": 1, "type": "column", "value": "firstname" }, { "id": 2, "type": "column", "value": "lastname" }, { "id": 3, "type": "column", "value": "hiredate" } ]
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [ 4 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "B-COLUMN", "B-TABLE", "O", "O", "O", "O", "B-COLUMN", "O" ]
4,923
race_track
spider:train_spider.json:768
What are the different classes of races, and how many races correspond to each?
SELECT CLASS , count(*) FROM race GROUP BY CLASS
[ "What", "are", "the", "different", "classes", "of", "races", ",", "and", "how", "many", "races", "correspond", "to", "each", "?" ]
[ { "id": 1, "type": "column", "value": "class" }, { "id": 0, "type": "table", "value": "race" } ]
[ { "entity_id": 0, "token_idxs": [ 11 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O" ]
4,924
books
bird:train.json:5932
How many books were published by Kensington?
SELECT COUNT(T1.book_id) FROM book AS T1 INNER JOIN publisher AS T2 ON T1.publisher_id = T2.publisher_id WHERE T2.publisher_name = 'Kensington'
[ "How", "many", "books", "were", "published", "by", "Kensington", "?" ]
[ { "id": 2, "type": "column", "value": "publisher_name" }, { "id": 5, "type": "column", "value": "publisher_id" }, { "id": 3, "type": "value", "value": "Kensington" }, { "id": 1, "type": "table", "value": "publisher" }, { "id": 4, "type": "colum...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "B-TABLE", "O", "B-TABLE", "O", "B-VALUE", "O" ]
4,925
theme_gallery
spider:train_spider.json:1674
Return the names of artists and the themes of their exhibitions that had a ticket price higher than average.
SELECT T1.theme , T2.name FROM exhibition AS T1 JOIN artist AS T2 ON T1.artist_id = T2.artist_id WHERE T1.ticket_price > (SELECT avg(ticket_price) FROM exhibition)
[ "Return", "the", "names", "of", "artists", "and", "the", "themes", "of", "their", "exhibitions", "that", "had", "a", "ticket", "price", "higher", "than", "average", "." ]
[ { "id": 4, "type": "column", "value": "ticket_price" }, { "id": 2, "type": "table", "value": "exhibition" }, { "id": 5, "type": "column", "value": "artist_id" }, { "id": 3, "type": "table", "value": "artist" }, { "id": 0, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [ 4 ] }, { "entity_id": 4, "token_idxs": [ 14, 15 ...
[ "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O" ]
4,926
university
bird:train.json:8065
Calculate the average score per university under Alumni criteria in 2008.
SELECT AVG(T2.score) FROM ranking_criteria AS T1 INNER JOIN university_ranking_year AS T2 ON T1.id = T2.ranking_criteria_id WHERE T1.criteria_name = 'Alumni' AND T2.year = 2008
[ "Calculate", "the", "average", "score", "per", "university", "under", "Alumni", "criteria", "in", "2008", "." ]
[ { "id": 1, "type": "table", "value": "university_ranking_year" }, { "id": 4, "type": "column", "value": "ranking_criteria_id" }, { "id": 0, "type": "table", "value": "ranking_criteria" }, { "id": 5, "type": "column", "value": "criteria_name" }, { "...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5, 6 ] }, { "entity_id": 2, "token_idxs": [ 3 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 9 ] }, { "entity_id":...
[ "O", "O", "O", "B-COLUMN", "O", "B-TABLE", "I-TABLE", "B-VALUE", "B-COLUMN", "B-COLUMN", "B-VALUE", "O" ]
4,927
theme_gallery
spider:train_spider.json:1662
Return the name of the artist who has the latest join year.
SELECT name FROM artist ORDER BY year_join DESC LIMIT 1
[ "Return", "the", "name", "of", "the", "artist", "who", "has", "the", "latest", "join", "year", "." ]
[ { "id": 2, "type": "column", "value": "year_join" }, { "id": 0, "type": "table", "value": "artist" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 11 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-COLUMN", "O" ]
4,928
car_road_race
bird:test.json:1320
Who are the constructors of drivers sorted by drivers' age in ascending order?
SELECT DISTINCT CONSTRUCTOR FROM driver ORDER BY Age ASC
[ "Who", "are", "the", "constructors", "of", "drivers", "sorted", "by", "drivers", "'", "age", "in", "ascending", "order", "?" ]
[ { "id": 1, "type": "column", "value": "constructor" }, { "id": 0, "type": "table", "value": "driver" }, { "id": 2, "type": "column", "value": "age" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-TABLE", "O", "B-COLUMN", "O", "O", "O", "O" ]
4,929
soccer_2016
bird:train.json:1787
How many players were born after the year 1985?
SELECT COUNT(Player_Id) FROM Player WHERE SUBSTR(DOB, 1, 4) > 1985
[ "How", "many", "players", "were", "born", "after", "the", "year", "1985", "?" ]
[ { "id": 2, "type": "column", "value": "player_id" }, { "id": 0, "type": "table", "value": "player" }, { "id": 1, "type": "value", "value": "1985" }, { "id": 3, "type": "column", "value": "dob" }, { "id": 4, "type": "value", "value": "1" }...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "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", "B-TABLE", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
4,931
hockey
bird:train.json:7767
Please give the height of the tallest coach of the Montreal Canadiens.
SELECT T3.height FROM Coaches AS T1 INNER JOIN Teams AS T2 ON T1.year = T2.year AND T1.tmID = T2.tmID INNER JOIN Master AS T3 ON T1.coachID = T3.coachID WHERE T2.name = 'Montreal Canadiens' AND T3.coachID IS NOT NULL ORDER BY T3.height DESC LIMIT 1
[ "Please", "give", "the", "height", "of", "the", "tallest", "coach", "of", "the", "Montreal", "Canadiens", "." ]
[ { "id": 6, "type": "value", "value": "Montreal Canadiens" }, { "id": 2, "type": "table", "value": "coaches" }, { "id": 4, "type": "column", "value": "coachid" }, { "id": 0, "type": "column", "value": "height" }, { "id": 1, "type": "table", ...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 7 ] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "B-COLUMN", "O", "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "I-VALUE", "O" ]
4,932
simpson_episodes
bird:train.json:4187
Calculate the difference between the highest votes for episode and the lowest votes for episode.
SELECT MAX(votes) - MIN(votes) FROM Vote;
[ "Calculate", "the", "difference", "between", "the", "highest", "votes", "for", "episode", "and", "the", "lowest", "votes", "for", "episode", "." ]
[ { "id": 1, "type": "column", "value": "votes" }, { "id": 0, "type": "table", "value": "vote" } ]
[ { "entity_id": 0, "token_idxs": [ 12 ] }, { "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", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O" ]
4,933
voter_2
spider:train_spider.json:5506
For each election cycle, report the number of voting records.
SELECT Election_Cycle , count(*) FROM VOTING_RECORD GROUP BY Election_Cycle
[ "For", "each", "election", "cycle", ",", "report", "the", "number", "of", "voting", "records", "." ]
[ { "id": 1, "type": "column", "value": "election_cycle" }, { "id": 0, "type": "table", "value": "voting_record" } ]
[ { "entity_id": 0, "token_idxs": [ 9, 10 ] }, { "entity_id": 1, "token_idxs": [ 2, 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5,...
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "I-TABLE", "O" ]
4,934
car_retails
bird:train.json:1555
Which of the customers, whose Tokyo-based sales representative reports to the Vice President of Sales whose employee number is 1056, has paid the highest payment? List the customer's name, the contact person and calculate the total amount of that customer's total payments.
SELECT T2.customerName, T2.contactFirstName, T2.contactLastName, SUM(T3.amount) FROM employees AS T1 INNER JOIN customers AS T2 ON T2.salesRepEmployeeNumber = T1.employeeNumber INNER JOIN payments AS T3 ON T2.customerNumber = T3.customerNumber INNER JOIN offices AS T4 ON T1.officeCode = T4.officeCode WHERE T4.city = 'T...
[ "Which", "of", "the", "customers", ",", "whose", "Tokyo", "-", "based", "sales", "representative", "reports", "to", "the", "Vice", "President", "of", "Sales", "whose", "employee", "number", "is", "1056", ",", "has", "paid", "the", "highest", "payment", "?", ...
[ { "id": 14, "type": "column", "value": "salesrepemployeenumber" }, { "id": 1, "type": "column", "value": "contactfirstname" }, { "id": 2, "type": "column", "value": "contactlastname" }, { "id": 13, "type": "column", "value": "customernumber" }, { "...
[ { "entity_id": 0, "token_idxs": [ 32, 33, 34 ] }, { "entity_id": 1, "token_idxs": [ 38 ] }, { "entity_id": 2, "token_idxs": [ 37 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 43 ...
[ "O", "O", "O", "B-TABLE", "O", "O", "B-VALUE", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "B-TABLE", "B-COLUMN", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-CO...
4,935
works_cycles
bird:train.json:7252
How many departments did Sheela Ward work in between 1/1/2011 to 12/31/2012
SELECT COUNT(T3.Name) FROM Person AS T1 INNER JOIN EmployeeDepartmentHistory AS T2 ON T1.BusinessEntityID = T2.BusinessEntityID INNER JOIN Department AS T3 ON T2.DepartmentID = T3.DepartmentID WHERE T1.FirstName = 'Sheela' AND T1.LastName = 'Word' AND STRFTIME('%Y', T3.ModifiedDate) BETWEEN '2011' AND '2012'
[ "How", "many", "departments", "did", "Sheela", "Ward", "work", "in", "between", "1/1/2011", "to", "12/31/2012" ]
[ { "id": 3, "type": "table", "value": "employeedepartmenthistory" }, { "id": 11, "type": "column", "value": "businessentityid" }, { "id": 4, "type": "column", "value": "departmentid" }, { "id": 13, "type": "column", "value": "modifieddate" }, { "id"...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 1 ] }, { "entity_id": 4, "token_idxs": [ 3 ] }, { "entity_id": 5, "...
[ "O", "B-TABLE", "B-TABLE", "B-COLUMN", "B-VALUE", "O", "B-VALUE", "O", "O", "B-VALUE", "O", "O" ]
4,936
retail_world
bird:train.json:6398
Which employee handled the most amount of orders in 1996? Give the full name, title, and address of this employee.
SELECT FirstName, LastName, Title, address FROM Employees WHERE EmployeeID = ( SELECT T1.EmployeeID FROM Employees AS T1 INNER JOIN Orders AS T2 ON T1.EmployeeID = T2.EmployeeID WHERE T2.OrderDate BETWEEN '1996-01-01 00:00:00' AND '1997-01-01 00:00:00' GROUP BY T1.EmployeeID ORDER BY COUNT(T2.OrderID) DESC LIMIT 1 )
[ "Which", "employee", "handled", "the", "most", "amount", "of", "orders", "in", "1996", "?", "Give", "the", "full", "name", ",", "title", ",", "and", "address", "of", "this", "employee", "." ]
[ { "id": 8, "type": "value", "value": "1996-01-01 00:00:00" }, { "id": 9, "type": "value", "value": "1997-01-01 00:00:00" }, { "id": 5, "type": "column", "value": "employeeid" }, { "id": 0, "type": "table", "value": "employees" }, { "id": 1, "ty...
[ { "entity_id": 0, "token_idxs": [ 22 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 14 ] }, { "entity_id": 3, "token_idxs": [ 16 ] }, { "entity_id": 4, "token_idxs": [ 19 ] }, { "ent...
[ "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O" ]
4,937
device
spider:train_spider.json:5058
What is the average quantity of stocks?
SELECT avg(Quantity) FROM stock
[ "What", "is", "the", "average", "quantity", "of", "stocks", "?" ]
[ { "id": 1, "type": "column", "value": "quantity" }, { "id": 0, "type": "table", "value": "stock" } ]
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "O", "B-COLUMN", "O", "B-TABLE", "O" ]
4,938
movie_3
bird:train.json:9334
List the descriptions of movies under the category Travel.
SELECT T1.description FROM film AS T1 INNER JOIN film_category AS T2 ON T1.film_id = T2.film_id INNER JOIN category AS T3 ON T2.category_id = T3.category_id WHERE T3.`name` = 'Travel'
[ "List", "the", "descriptions", "of", "movies", "under", "the", "category", "Travel", "." ]
[ { "id": 5, "type": "table", "value": "film_category" }, { "id": 0, "type": "column", "value": "description" }, { "id": 6, "type": "column", "value": "category_id" }, { "id": 1, "type": "table", "value": "category" }, { "id": 7, "type": "column"...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-TABLE", "B-VALUE", "O" ]
4,939
voter_2
spider:train_spider.json:5461
Tell me the ages of the oldest and youngest students studying major 600.
SELECT max(Age) , min(Age) FROM STUDENT WHERE Major = 600
[ "Tell", "me", "the", "ages", "of", "the", "oldest", "and", "youngest", "students", "studying", "major", "600", "." ]
[ { "id": 0, "type": "table", "value": "student" }, { "id": 1, "type": "column", "value": "major" }, { "id": 2, "type": "value", "value": "600" }, { "id": 3, "type": "column", "value": "age" } ]
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [ 11 ] }, { "entity_id": 2, "token_idxs": [ 12 ] }, { "entity_id": 3, "token_idxs": [ 3 ] }, { "entity_id": 4, "token_idxs": [] }, { "entit...
[ "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O", "B-COLUMN", "B-VALUE", "O" ]
4,940
college_completion
bird:train.json:3708
Among the public institutes in the state of Alabama, how many of them have over 30 students who graduated within 100 percent of normal/expected time in 2011?
SELECT COUNT(T1.chronname) FROM institution_details AS T1 INNER JOIN institution_grads AS T2 ON T2.unitid = T1.unitid WHERE T1.state = 'Alabama' AND T1.control = 'Public' AND T2.year = 2011 AND T2.grad_100 > 30
[ "Among", "the", "public", "institutes", "in", "the", "state", "of", "Alabama", ",", "how", "many", "of", "them", "have", "over", "30", "students", "who", "graduated", "within", "100", "percent", "of", "normal", "/", "expected", "time", "in", "2011", "?" ]
[ { "id": 0, "type": "table", "value": "institution_details" }, { "id": 1, "type": "table", "value": "institution_grads" }, { "id": 2, "type": "column", "value": "chronname" }, { "id": 10, "type": "column", "value": "grad_100" }, { "id": 5, "type...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3, 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 6 ] }, { "entity_id": 5, "toke...
[ "O", "O", "B-VALUE", "B-TABLE", "I-TABLE", "O", "B-COLUMN", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
4,941
hr_1
spider:train_spider.json:3482
What is all the information regarding employees who are managers?
SELECT DISTINCT * FROM employees AS T1 JOIN departments AS T2 ON T1.department_id = T2.department_id WHERE T1.employee_id = T2.manager_id
[ "What", "is", "all", "the", "information", "regarding", "employees", "who", "are", "managers", "?" ]
[ { "id": 4, "type": "column", "value": "department_id" }, { "id": 1, "type": "table", "value": "departments" }, { "id": 2, "type": "column", "value": "employee_id" }, { "id": 3, "type": "column", "value": "manager_id" }, { "id": 0, "type": "tabl...
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "B-COLUMN", "O" ]
4,942
sports_competition
spider:train_spider.json:3348
What are the maximum and minimum number of silver medals for all the clubs?
SELECT max(Silver) , min(Silver) FROM club_rank
[ "What", "are", "the", "maximum", "and", "minimum", "number", "of", "silver", "medals", "for", "all", "the", "clubs", "?" ]
[ { "id": 0, "type": "table", "value": "club_rank" }, { "id": 1, "type": "column", "value": "silver" } ]
[ { "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-COLUMN", "O", "O", "O", "O", "O", "O" ]
4,943
chinook_1
spider:train_spider.json:849
What is the first name and last name employee helps the customer with first name Leonie?
SELECT T2.FirstName , T2.LastName FROM CUSTOMER AS T1 JOIN EMPLOYEE AS T2 ON T1.SupportRepId = T2.EmployeeId WHERE T1.FirstName = "Leonie"
[ "What", "is", "the", "first", "name", "and", "last", "name", "employee", "helps", "the", "customer", "with", "first", "name", "Leonie", "?" ]
[ { "id": 5, "type": "column", "value": "supportrepid" }, { "id": 6, "type": "column", "value": "employeeid" }, { "id": 0, "type": "column", "value": "firstname" }, { "id": 1, "type": "column", "value": "lastname" }, { "id": 2, "type": "table", ...
[ { "entity_id": 0, "token_idxs": [ 3, 4 ] }, { "entity_id": 1, "token_idxs": [ 6, 7 ] }, { "entity_id": 2, "token_idxs": [ 11 ] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [ ...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-COLUMN", "I-COLUMN", "B-TABLE", "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "O" ]