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
11,557
college_1
spider:train_spider.json:3317
Find names of all students who took some course and the course description.
SELECT T1.stu_fname , T1.stu_lname , T4.crs_description FROM student AS T1 JOIN enroll AS T2 ON T1.stu_num = T2.stu_num JOIN CLASS AS T3 ON T2.class_code = T3.class_code JOIN course AS T4 ON T3.crs_code = T4.crs_code
[ "Find", "names", "of", "all", "students", "who", "took", "some", "course", "and", "the", "course", "description", "." ]
[ { "id": 2, "type": "column", "value": "crs_description" }, { "id": 8, "type": "column", "value": "class_code" }, { "id": 0, "type": "column", "value": "stu_fname" }, { "id": 1, "type": "column", "value": "stu_lname" }, { "id": 5, "type": "colum...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 11, 12 ] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "to...
[ "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-TABLE", "O", "O", "B-COLUMN", "I-COLUMN", "O" ]
11,558
cs_semester
bird:train.json:890
Among the most important courses, what is the name of the most difficult course?
SELECT name FROM course WHERE credit = ( SELECT MAX(credit) FROM course ) AND diff = ( SELECT MAX(diff) FROM course )
[ "Among", "the", "most", "important", "courses", ",", "what", "is", "the", "name", "of", "the", "most", "difficult", "course", "?" ]
[ { "id": 0, "type": "table", "value": "course" }, { "id": 2, "type": "column", "value": "credit" }, { "id": 1, "type": "column", "value": "name" }, { "id": 3, "type": "column", "value": "diff" } ]
[ { "entity_id": 0, "token_idxs": [ 14 ] }, { "entity_id": 1, "token_idxs": [ 9 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 13 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "B-COLUMN", "B-TABLE", "O" ]
11,559
soccer_2
spider:train_spider.json:4946
What is the average enrollment number?
SELECT avg(enr) FROM College
[ "What", "is", "the", "average", "enrollment", "number", "?" ]
[ { "id": 0, "type": "table", "value": "college" }, { "id": 1, "type": "column", "value": "enr" } ]
[ { "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" ]
11,560
pilot_1
bird:test.json:1159
What are the names of oldest pilots for each type of plane?
SELECT pilot_name , plane_name , max(age) FROM pilotskills GROUP BY plane_name
[ "What", "are", "the", "names", "of", "oldest", "pilots", "for", "each", "type", "of", "plane", "?" ]
[ { "id": 0, "type": "table", "value": "pilotskills" }, { "id": 1, "type": "column", "value": "plane_name" }, { "id": 2, "type": "column", "value": "pilot_name" }, { "id": 3, "type": "column", "value": "age" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 11 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [ 1 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "B-COLUMN", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-COLUMN", "O" ]
11,562
olympics
bird:train.json:4939
Calculate the bmi of the competitor id 147420.
SELECT CAST(T1.weight AS REAL) / (T1.height * T1.height) FROM person AS T1 INNER JOIN games_competitor AS T2 ON T1.id = T2.person_id WHERE T2.id = 147420
[ "Calculate", "the", "bmi", "of", "the", "competitor", "i", "d", "147420", "." ]
[ { "id": 1, "type": "table", "value": "games_competitor" }, { "id": 4, "type": "column", "value": "person_id" }, { "id": 0, "type": "table", "value": "person" }, { "id": 3, "type": "value", "value": "147420" }, { "id": 5, "type": "column", "...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [ 6, 7 ] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id":...
[ "O", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "I-COLUMN", "B-VALUE", "O" ]
11,563
soccer_3
bird:test.json:6
List the name of clubs whose manufacturer is not "Nike"
SELECT Name FROM club WHERE Manufacturer != "Nike"
[ "List", "the", "name", "of", "clubs", "whose", "manufacturer", "is", "not", "\"", "Nike", "\"" ]
[ { "id": 2, "type": "column", "value": "manufacturer" }, { "id": 0, "type": "table", "value": "club" }, { "id": 1, "type": "column", "value": "name" }, { "id": 3, "type": "column", "value": "Nike" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [ 10 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity...
[ "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "B-COLUMN", "O", "O", "O", "B-COLUMN", "O" ]
11,564
cre_Drama_Workshop_Groups
spider:train_spider.json:5104
What are the distinct payment method codes in all the invoices?
SELECT DISTINCT payment_method_code FROM INVOICES
[ "What", "are", "the", "distinct", "payment", "method", "codes", "in", "all", "the", "invoices", "?" ]
[ { "id": 1, "type": "column", "value": "payment_method_code" }, { "id": 0, "type": "table", "value": "invoices" } ]
[ { "entity_id": 0, "token_idxs": [ 10 ] }, { "entity_id": 1, "token_idxs": [ 4, 5, 6 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5,...
[ "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "B-TABLE", "O" ]
11,565
airline
bird:train.json:5898
List the air carrier's description of the flights with 0 departure delay.
SELECT T1.Description FROM `Air Carriers` AS T1 INNER JOIN Airlines AS T2 ON T1.Code = T2.OP_CARRIER_AIRLINE_ID WHERE T2.DEP_DELAY = 0 GROUP BY T1.Description
[ "List", "the", "air", "carrier", "'s", "description", "of", "the", "flights", "with", "0", "departure", "delay", "." ]
[ { "id": 6, "type": "column", "value": "op_carrier_airline_id" }, { "id": 1, "type": "table", "value": "Air Carriers" }, { "id": 0, "type": "column", "value": "description" }, { "id": 3, "type": "column", "value": "dep_delay" }, { "id": 2, "type...
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 3, 4 ] }, { "entity_id": 3, "token_idxs": [ 12 ] }, { "entity_id": 4, "token_idxs": [ 10 ...
[ "O", "O", "B-TABLE", "B-TABLE", "I-TABLE", "B-COLUMN", "O", "O", "O", "O", "B-VALUE", "O", "B-COLUMN", "O" ]
11,566
manufacturer
spider:train_spider.json:3403
Find the market shares and names of furnitures which no any company is producing in our records.
SELECT Market_Rate , name FROM furniture WHERE Furniture_ID NOT IN (SELECT Furniture_ID FROM furniture_manufacte)
[ "Find", "the", "market", "shares", "and", "names", "of", "furnitures", "which", "no", "any", "company", "is", "producing", "in", "our", "records", "." ]
[ { "id": 4, "type": "table", "value": "furniture_manufacte" }, { "id": 3, "type": "column", "value": "furniture_id" }, { "id": 1, "type": "column", "value": "market_rate" }, { "id": 0, "type": "table", "value": "furniture" }, { "id": 2, "type": ...
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
11,567
wine_1
spider:train_spider.json:6537
How many wines are produced at Robert Biale winery?
SELECT count(*) FROM WINE WHERE Winery = "Robert Biale"
[ "How", "many", "wines", "are", "produced", "at", "Robert", "Biale", "winery", "?" ]
[ { "id": 2, "type": "column", "value": "Robert Biale" }, { "id": 1, "type": "column", "value": "winery" }, { "id": 0, "type": "table", "value": "wine" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 8 ] }, { "entity_id": 2, "token_idxs": [ 6, 7 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id":...
[ "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "I-COLUMN", "B-COLUMN", "O" ]
11,568
loan_1
spider:train_spider.json:3049
What is the name of the customer with the worst credit score?
SELECT cust_name FROM customer ORDER BY credit_score LIMIT 1
[ "What", "is", "the", "name", "of", "the", "customer", "with", "the", "worst", "credit", "score", "?" ]
[ { "id": 2, "type": "column", "value": "credit_score" }, { "id": 1, "type": "column", "value": "cust_name" }, { "id": 0, "type": "table", "value": "customer" } ]
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 10, 11 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "to...
[ "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O" ]
11,569
software_company
bird:train.json:8551
List the geographic id of places where the income is above average.
SELECT AVG(INCOME_K) FROM Demog
[ "List", "the", "geographic", "i", "d", "of", "places", "where", "the", "income", "is", "above", "average", "." ]
[ { "id": 1, "type": "column", "value": "income_k" }, { "id": 0, "type": "table", "value": "demog" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 9 ] }, { "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-COLUMN", "O", "O", "O", "O" ]
11,570
hockey
bird:train.json:7616
For all the deceased players who are good at both left and right hand, list the player's name and the age when he died.
SELECT firstName, lastName, deathYear - birthYear FROM Master WHERE shootCatch IS NULL AND deathYear IS NOT NULL
[ "For", "all", "the", "deceased", "players", "who", "are", "good", "at", "both", "left", "and", "right", "hand", ",", "list", "the", "player", "'s", "name", "and", "the", "age", "when", "he", "died", "." ]
[ { "id": 5, "type": "column", "value": "shootcatch" }, { "id": 1, "type": "column", "value": "firstname" }, { "id": 3, "type": "column", "value": "deathyear" }, { "id": 4, "type": "column", "value": "birthyear" }, { "id": 2, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 17, 18, 19 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token...
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "O" ]
11,571
icfp_1
spider:train_spider.json:2863
Count the number of total papers.
SELECT count(*) FROM papers
[ "Count", "the", "number", "of", "total", "papers", "." ]
[ { "id": 0, "type": "table", "value": "papers" } ]
[ { "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" ]
11,572
farm
spider:train_spider.json:29
Count the number of different statuses.
SELECT count(DISTINCT Status) FROM city
[ "Count", "the", "number", "of", "different", "statuses", "." ]
[ { "id": 1, "type": "column", "value": "status" }, { "id": 0, "type": "table", "value": "city" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { ...
[ "O", "O", "O", "O", "O", "B-COLUMN", "O" ]
11,574
codebase_comments
bird:train.json:584
How much is the processed time of the method whose tokenized name is "about box1 dispose"? Indicate the language of the method.
SELECT DISTINCT T1.ProcessedTime, T2.Lang FROM Solution AS T1 INNER JOIN Method AS T2 ON T1.Id = T2.SolutionId WHERE T2.NameTokenized = 'about box1 dispose'
[ "How", "much", "is", "the", "processed", "time", "of", "the", "method", "whose", "tokenized", "name", "is", "\"", "about", "box1", "dispose", "\"", "?", "Indicate", "the", "language", "of", "the", "method", "." ]
[ { "id": 5, "type": "value", "value": "about box1 dispose" }, { "id": 0, "type": "column", "value": "processedtime" }, { "id": 4, "type": "column", "value": "nametokenized" }, { "id": 7, "type": "column", "value": "solutionid" }, { "id": 2, "typ...
[ { "entity_id": 0, "token_idxs": [ 4, 5 ] }, { "entity_id": 1, "token_idxs": [ 21 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [ 10 ] }, { ...
[ "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "O", "B-COLUMN", "O", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O" ]
11,575
allergy_1
spider:train_spider.json:498
How many students live in each city?
SELECT city_code , count(*) FROM Student GROUP BY city_code
[ "How", "many", "students", "live", "in", "each", "city", "?" ]
[ { "id": 1, "type": "column", "value": "city_code" }, { "id": 0, "type": "table", "value": "student" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "O" ]
11,576
public_review_platform
bird:train.json:3932
What is the opening time of the active businesses in Surprise that has a low review count.
SELECT T2.opening_time 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 'Surprise' AND T1.active LIKE 'TRUE' AND T1.review_count LIKE 'Low' GROUP BY T2.opening_time
[ "What", "is", "the", "opening", "time", "of", "the", "active", "businesses", "in", "Surprise", "that", "has", "a", "low", "review", "count", "." ]
[ { "id": 3, "type": "table", "value": "business_hours" }, { "id": 0, "type": "column", "value": "opening_time" }, { "id": 9, "type": "column", "value": "review_count" }, { "id": 11, "type": "column", "value": "business_id" }, { "id": 2, "type": ...
[ { "entity_id": 0, "token_idxs": [ 3, 4 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "toke...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-COLUMN", "B-TABLE", "O", "B-VALUE", "O", "O", "O", "B-VALUE", "B-COLUMN", "I-COLUMN", "O" ]
11,577
formula_1
spider:train_spider.json:2195
Find the distinct driver id and the stop number of all drivers that have a shorter pit stop duration than some drivers in the race with id 841.
SELECT DISTINCT driverid , STOP FROM pitstops WHERE duration < (SELECT max(duration) FROM pitstops WHERE raceid = 841)
[ "Find", "the", "distinct", "driver", "i", "d", "and", "the", "stop", "number", "of", "all", "drivers", "that", "have", "a", "shorter", "pit", "stop", "duration", "than", "some", "drivers", "in", "the", "race", "with", "i", "d", "841", "." ]
[ { "id": 0, "type": "table", "value": "pitstops" }, { "id": 1, "type": "column", "value": "driverid" }, { "id": 3, "type": "column", "value": "duration" }, { "id": 4, "type": "column", "value": "raceid" }, { "id": 2, "type": "column", "value...
[ { "entity_id": 0, "token_idxs": [ 17 ] }, { "entity_id": 1, "token_idxs": [ 3, 4, 5 ] }, { "entity_id": 2, "token_idxs": [ 18 ] }, { "entity_id": 3, "token_idxs": [ 19 ] }, { "entity_id": 4, "token_idxs": [ ...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "B-COLUMN", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "B-VALUE", "O" ]
11,578
law_episode
bird:train.json:1260
How many nominations did Law and Order season 9, episode 20 get?
SELECT COUNT(T2.award_id) FROM Episode AS T1 INNER JOIN Award AS T2 ON T1.episode_id = T2.episode_id WHERE T2.series = 'Law and Order' AND T1.season = 9 AND T1.episode = 20
[ "How", "many", "nominations", "did", "Law", "and", "Order", "season", "9", ",", "episode", "20", "get", "?" ]
[ { "id": 5, "type": "value", "value": "Law and Order" }, { "id": 3, "type": "column", "value": "episode_id" }, { "id": 2, "type": "column", "value": "award_id" }, { "id": 0, "type": "table", "value": "episode" }, { "id": 8, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 4, 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ ...
[ "O", "O", "O", "O", "B-TABLE", "I-TABLE", "B-VALUE", "B-COLUMN", "B-VALUE", "O", "B-COLUMN", "B-VALUE", "O", "O" ]
11,579
cre_Theme_park
spider:train_spider.json:5891
Show the names and details of all the staff members.
SELECT Name , Other_Details FROM Staff
[ "Show", "the", "names", "and", "details", "of", "all", "the", "staff", "members", "." ]
[ { "id": 2, "type": "column", "value": "other_details" }, { "id": 0, "type": "table", "value": "staff" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 4 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "O", "O" ]
11,580
hr_1
spider:train_spider.json:3429
Find job id and date of hire for those employees who was hired between November 5th, 2007 and July 5th, 2009.
SELECT job_id , hire_date FROM employees WHERE hire_date BETWEEN '2007-11-05' AND '2009-07-05'
[ "Find", "job", "i", "d", "and", "date", "of", "hire", "for", "those", "employees", "who", "was", "hired", "between", "November", "5th", ",", "2007", "and", "July", "5th", ",", "2009", "." ]
[ { "id": 3, "type": "value", "value": "2007-11-05" }, { "id": 4, "type": "value", "value": "2009-07-05" }, { "id": 0, "type": "table", "value": "employees" }, { "id": 2, "type": "column", "value": "hire_date" }, { "id": 1, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 10 ] }, { "entity_id": 1, "token_idxs": [ 1, 2, 3 ] }, { "entity_id": 2, "token_idxs": [ 13 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "...
[ "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
11,581
hospital_1
spider:train_spider.json:3922
Find the name of medication used on the patient who stays in room 111?
SELECT T4.name FROM stay AS T1 JOIN patient AS T2 ON T1.Patient = T2.SSN JOIN Prescribes AS T3 ON T3.Patient = T2.SSN JOIN Medication AS T4 ON T3.Medication = T4.Code WHERE room = 111
[ "Find", "the", "name", "of", "medication", "used", "on", "the", "patient", "who", "stays", "in", "room", "111", "?" ]
[ { "id": 1, "type": "table", "value": "medication" }, { "id": 4, "type": "table", "value": "prescribes" }, { "id": 5, "type": "column", "value": "medication" }, { "id": 8, "type": "table", "value": "patient" }, { "id": 9, "type": "column", "...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 12 ] }, { "entity_id": 3, "token_idxs": [ 13 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "B-COLUMN", "B-VALUE", "O" ]
11,582
retail_complains
bird:train.json:310
How many complaints from female clients born in the year 2000 were not sent through the web?
SELECT COUNT(T2.`Submitted via`) FROM client AS T1 INNER JOIN events AS T2 ON T1.client_id = T2.Client_ID WHERE T1.sex = 'Female' AND T1.year = 2000 AND T2.`Submitted via` != 'Web'
[ "How", "many", "complaints", "from", "female", "clients", "born", "in", "the", "year", "2000", "were", "not", "sent", "through", "the", "web", "?" ]
[ { "id": 2, "type": "column", "value": "Submitted via" }, { "id": 3, "type": "column", "value": "client_id" }, { "id": 0, "type": "table", "value": "client" }, { "id": 1, "type": "table", "value": "events" }, { "id": 5, "type": "value", "val...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 4 ...
[ "O", "O", "O", "O", "B-VALUE", "B-TABLE", "O", "O", "O", "B-COLUMN", "B-VALUE", "O", "O", "O", "O", "O", "B-VALUE", "O" ]
11,583
restaurant
bird:train.json:1716
What is the name of the restaurant that is located in El Dorado County, Lake Tahoe region?
SELECT T2.label FROM geographic AS T1 INNER JOIN generalinfo AS T2 ON T1.city = T2.city WHERE T1.region = 'lake tahoe' AND T1.county = 'el dorado county'
[ "What", "is", "the", "name", "of", "the", "restaurant", "that", "is", "located", "in", "El", "Dorado", "County", ",", "Lake", "Tahoe", "region", "?" ]
[ { "id": 7, "type": "value", "value": "el dorado county" }, { "id": 2, "type": "table", "value": "generalinfo" }, { "id": 1, "type": "table", "value": "geographic" }, { "id": 5, "type": "value", "value": "lake tahoe" }, { "id": 4, "type": "colum...
[ { "entity_id": 0, "token_idxs": [ 15 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 13 ] }, { "entity_id": 4, "token_idxs": [ 17 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "B-COLUMN", "O", "B-COLUMN", "B-VALUE", "B-COLUMN", "O" ]
11,584
store_1
spider:train_spider.json:538
What are the top 5 countries by number of invoices and how many do they have?
SELECT billing_country , COUNT(*) FROM invoices GROUP BY billing_country ORDER BY count(*) DESC LIMIT 5;
[ "What", "are", "the", "top", "5", "countries", "by", "number", "of", "invoices", "and", "how", "many", "do", "they", "have", "?" ]
[ { "id": 1, "type": "column", "value": "billing_country" }, { "id": 0, "type": "table", "value": "invoices" } ]
[ { "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", "O", "O", "O", "O", "O", "O" ]
11,585
books
bird:train.json:6009
Other than zero, what is the lowest price paid by a customer for an order?
SELECT MIN(price) FROM order_line WHERE price <> 0
[ "Other", "than", "zero", ",", "what", "is", "the", "lowest", "price", "paid", "by", "a", "customer", "for", "an", "order", "?" ]
[ { "id": 0, "type": "table", "value": "order_line" }, { "id": 1, "type": "column", "value": "price" }, { "id": 2, "type": "value", "value": "0" } ]
[ { "entity_id": 0, "token_idxs": [ 15 ] }, { "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", "B-TABLE", "O" ]
11,586
music_tracker
bird:train.json:2052
What is the tag and the artist of the most downloaded single?
SELECT T2.tag, T1.artist FROM torrents AS T1 INNER JOIN tags AS T2 ON T1.id = T2.id WHERE T1.releaseType = 'single' ORDER BY T1.totalSnatched DESC LIMIT 1
[ "What", "is", "the", "tag", "and", "the", "artist", "of", "the", "most", "downloaded", "single", "?" ]
[ { "id": 6, "type": "column", "value": "totalsnatched" }, { "id": 4, "type": "column", "value": "releasetype" }, { "id": 2, "type": "table", "value": "torrents" }, { "id": 1, "type": "column", "value": "artist" }, { "id": 5, "type": "value", ...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-VALUE", "O" ]
11,587
tracking_share_transactions
spider:train_spider.json:5854
Show the minimum amount of transactions whose type code is "PUR" and whose share count is bigger than 50.
SELECT min(amount_of_transaction) FROM TRANSACTIONS WHERE transaction_type_code = "PUR" AND share_count > 50
[ "Show", "the", "minimum", "amount", "of", "transactions", "whose", "type", "code", "is", "\"", "PUR", "\"", "and", "whose", "share", "count", "is", "bigger", "than", "50", "." ]
[ { "id": 1, "type": "column", "value": "amount_of_transaction" }, { "id": 2, "type": "column", "value": "transaction_type_code" }, { "id": 0, "type": "table", "value": "transactions" }, { "id": 4, "type": "column", "value": "share_count" }, { "id": ...
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [ 3, 4 ] }, { "entity_id": 2, "token_idxs": [ 6, 7, 8 ] }, { "entity_id": 3, "token_idxs": [ 11 ] }, { "entity_id": 4, "token_idx...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "B-TABLE", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "B-COLUMN", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "B-VALUE", "O" ]
11,588
disney
bird:train.json:4668
Provide a list of directors from the 1990s.
SELECT T2.director FROM movies_total_gross AS T1 INNER JOIN director AS T2 ON T1.movie_title = T2.name AND CAST(SUBSTR(release_date, INSTR(release_date, ', ') + 1) AS int) BETWEEN 1990 AND 2000 GROUP BY T2.director
[ "Provide", "a", "list", "of", "directors", "from", "the", "1990s", "." ]
[ { "id": 1, "type": "table", "value": "movies_total_gross" }, { "id": 7, "type": "column", "value": "release_date" }, { "id": 3, "type": "column", "value": "movie_title" }, { "id": 0, "type": "column", "value": "director" }, { "id": 2, "type": "...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 4 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 7 ...
[ "O", "O", "O", "O", "B-TABLE", "O", "O", "B-VALUE", "O" ]
11,589
simpson_episodes
bird:train.json:4298
List all of the information about the music department's casts and crews.
SELECT DISTINCT person, name, birthdate, birth_name, birth_place , birth_region, birth_country, height_meters, nickname FROM Person AS T1 INNER JOIN Credit AS T2 ON T1.name = T2.person WHERE T2.category = 'Music Department';
[ "List", "all", "of", "the", "information", "about", "the", "music", "department", "'s", "casts", "and", "crews", "." ]
[ { "id": 12, "type": "value", "value": "Music Department" }, { "id": 6, "type": "column", "value": "birth_country" }, { "id": 7, "type": "column", "value": "height_meters" }, { "id": 5, "type": "column", "value": "birth_region" }, { "id": 4, "ty...
[ { "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", "O", "O", "O" ]
11,590
retail_world
bird:train.json:6646
Provide employees' ID who are in-charge of territory ID from 1000 to 2000.
SELECT EmployeeID FROM EmployeeTerritories WHERE TerritoryID BETWEEN 1000 AND 2000
[ "Provide", "employees", "'", "ID", "who", "are", "in", "-", "charge", "of", "territory", "ID", "from", "1000", "to", "2000", "." ]
[ { "id": 0, "type": "table", "value": "employeeterritories" }, { "id": 2, "type": "column", "value": "territoryid" }, { "id": 1, "type": "column", "value": "employeeid" }, { "id": 3, "type": "value", "value": "1000" }, { "id": 4, "type": "value"...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 1, 2, 3 ] }, { "entity_id": 2, "token_idxs": [ 10, 11 ] }, { "entity_id": 3, "token_idxs": [ 13 ] }, { "entity_id": 4, "token_idxs": [ ...
[ "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-VALUE", "O", "B-VALUE", "O" ]
11,591
public_review_platform
bird:train.json:3783
Does Yelp business No."4960" have TV?
SELECT DISTINCT CASE WHEN T1.attribute_name LIKE 'Has TV' THEN 'yes' ELSE 'no' END FROM Attributes AS T1 INNER JOIN Business_Attributes AS T2 ON T1.attribute_id = T2.attribute_id WHERE T2.business_id = 4960
[ "Does", "Yelp", "business", "No", ".", "\"4960", "\"", "have", "TV", "?" ]
[ { "id": 1, "type": "table", "value": "business_attributes" }, { "id": 7, "type": "column", "value": "attribute_name" }, { "id": 5, "type": "column", "value": "attribute_id" }, { "id": 2, "type": "column", "value": "business_id" }, { "id": 0, "t...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 2 ] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [ 3 ] }, { "entity_id": 5, "...
[ "O", "O", "B-COLUMN", "B-VALUE", "O", "B-VALUE", "O", "B-VALUE", "I-VALUE", "O" ]
11,592
computer_student
bird:train.json:1008
List the course IDs and levels of person IDs from 40 to 50.
SELECT T1.course_id, T1.courseLevel FROM course AS T1 INNER JOIN taughtBy AS T2 ON T1.course_id = T2.course_id WHERE T2.p_id BETWEEN 40 AND 50
[ "List", "the", "course", "IDs", "and", "levels", "of", "person", "IDs", "from", "40", "to", "50", "." ]
[ { "id": 1, "type": "column", "value": "courselevel" }, { "id": 0, "type": "column", "value": "course_id" }, { "id": 3, "type": "table", "value": "taughtby" }, { "id": 2, "type": "table", "value": "course" }, { "id": 4, "type": "column", "va...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 2 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "B-VALUE", "O" ]
11,593
works_cycles
bird:train.json:7347
Which work order transaction number has the highest product quantity?
SELECT TransactionID FROM TransactionHistory WHERE TransactionType = 'W' ORDER BY Quantity DESC LIMIT 1
[ "Which", "work", "order", "transaction", "number", "has", "the", "highest", "product", "quantity", "?" ]
[ { "id": 0, "type": "table", "value": "transactionhistory" }, { "id": 2, "type": "column", "value": "transactiontype" }, { "id": 1, "type": "column", "value": "transactionid" }, { "id": 4, "type": "column", "value": "quantity" }, { "id": 3, "typ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 9 ] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-COLUMN", "O" ]
11,594
art_1
bird:test.json:1311
What are the first and last names of the artists who did not sculpt but could paint.
SELECT T1.lname , T1.fname FROM artists AS T1 JOIN paintings AS T2 ON T1.artistID = T2.painterID EXCEPT SELECT T3.lname , T3.fname FROM artists AS T3 JOIN sculptures AS T4 ON T3.artistID = T4.sculptorID
[ "What", "are", "the", "first", "and", "last", "names", "of", "the", "artists", "who", "did", "not", "sculpt", "but", "could", "paint", "." ]
[ { "id": 4, "type": "table", "value": "sculptures" }, { "id": 7, "type": "column", "value": "sculptorid" }, { "id": 3, "type": "table", "value": "paintings" }, { "id": 6, "type": "column", "value": "painterid" }, { "id": 5, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [ 9 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O" ]
11,595
formula_1
bird:dev.json:949
Which constructor has the highest point?
SELECT T2.name FROM constructorStandings AS T1 INNER JOIN constructors AS T2 on T1.constructorId = T2.constructorId ORDER BY T1.points DESC LIMIT 1
[ "Which", "constructor", "has", "the", "highest", "point", "?" ]
[ { "id": 1, "type": "table", "value": "constructorstandings" }, { "id": 4, "type": "column", "value": "constructorid" }, { "id": 2, "type": "table", "value": "constructors" }, { "id": 3, "type": "column", "value": "points" }, { "id": 0, "type": ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 1 ] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "B-TABLE", "B-TABLE", "O", "O", "B-COLUMN", "O" ]
11,596
works_cycles
bird:train.json:7409
Please list the phone numbers of all the store contacts.
SELECT T2.PhoneNumber FROM Person AS T1 INNER JOIN PersonPhone AS T2 ON T1.BusinessEntityID = T2.BusinessEntityID WHERE T1.PersonType = 'SC'
[ "Please", "list", "the", "phone", "numbers", "of", "all", "the", "store", "contacts", "." ]
[ { "id": 5, "type": "column", "value": "businessentityid" }, { "id": 0, "type": "column", "value": "phonenumber" }, { "id": 2, "type": "table", "value": "personphone" }, { "id": 3, "type": "column", "value": "persontype" }, { "id": 1, "type": "t...
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "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-TABLE", "B-COLUMN", "O", "O", "O", "O", "O", "O" ]
11,598
train_station
spider:train_spider.json:6602
Show the names and total passengers for all train stations not in London.
SELECT name , total_passengers FROM station WHERE LOCATION != 'London'
[ "Show", "the", "names", "and", "total", "passengers", "for", "all", "train", "stations", "not", "in", "London", "." ]
[ { "id": 2, "type": "column", "value": "total_passengers" }, { "id": 3, "type": "column", "value": "location" }, { "id": 0, "type": "table", "value": "station" }, { "id": 4, "type": "value", "value": "London" }, { "id": 1, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 4, 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 12 ] }, { ...
[ "O", "O", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "B-TABLE", "O", "O", "B-VALUE", "O" ]
11,599
mondial_geo
bird:train.json:8383
Which three countries does the Amazonas flow through? Give the full name of the countries.
SELECT DISTINCT T4.Name FROM city AS T1 INNER JOIN located AS T2 ON T1.Name = T2.City INNER JOIN river AS T3 ON T3.Name = T2.River INNER JOIN country AS T4 ON T4.Code = T2.Country WHERE T3.Name = 'Amazonas'
[ "Which", "three", "countries", "does", "the", "Amazonas", "flow", "through", "?", "Give", "the", "full", "name", "of", "the", "countries", "." ]
[ { "id": 2, "type": "value", "value": "Amazonas" }, { "id": 1, "type": "table", "value": "country" }, { "id": 5, "type": "column", "value": "country" }, { "id": 7, "type": "table", "value": "located" }, { "id": 3, "type": "table", "value": "...
[ { "entity_id": 0, "token_idxs": [ 12 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "O", "O" ]
11,600
card_games
bird:dev.json:450
Of all the cards that are designed by Aaron Miller, how many of them are incredibly powerful?
SELECT SUM(CASE WHEN artist = 'Aaron Miller' AND cardKingdomFoilId IS NOT NULL AND cardKingdomId IS NOT NULL THEN 1 ELSE 0 END) FROM cards
[ "Of", "all", "the", "cards", "that", "are", "designed", "by", "Aaron", "Miller", ",", "how", "many", "of", "them", "are", "incredibly", "powerful", "?" ]
[ { "id": 5, "type": "column", "value": "cardkingdomfoilid" }, { "id": 6, "type": "column", "value": "cardkingdomid" }, { "id": 4, "type": "value", "value": "Aaron Miller" }, { "id": 3, "type": "column", "value": "artist" }, { "id": 0, "type": "t...
[ { "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": [ 8, 9 ] }, { "entity_id": 5, "toke...
[ "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
11,601
formula_1
spider:train_spider.json:2197
Find the distinct driver id of all drivers that have a longer stop duration than some drivers in the race whose id is 841?
SELECT DISTINCT driverid , STOP FROM pitstops WHERE duration > (SELECT min(duration) FROM pitstops WHERE raceid = 841)
[ "Find", "the", "distinct", "driver", "i", "d", "of", "all", "drivers", "that", "have", "a", "longer", "stop", "duration", "than", "some", "drivers", "in", "the", "race", "whose", "i", "d", "is", "841", "?" ]
[ { "id": 0, "type": "table", "value": "pitstops" }, { "id": 1, "type": "column", "value": "driverid" }, { "id": 3, "type": "column", "value": "duration" }, { "id": 4, "type": "column", "value": "raceid" }, { "id": 2, "type": "column", "value...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3, 4, 5 ] }, { "entity_id": 2, "token_idxs": [ 13 ] }, { "entity_id": 3, "token_idxs": [ 14 ] }, { "entity_id": 4, "token_idxs": [ 20 ] ...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "B-COLUMN", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-VALUE", "O" ]
11,602
european_football_1
bird:train.json:2773
Which country had the game that Away team made the most goals?
SELECT T2.country FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division GROUP BY T2.country ORDER BY SUM(T1.FTAG) DESC LIMIT 1
[ "Which", "country", "had", "the", "game", "that", "Away", "team", "made", "the", "most", "goals", "?" ]
[ { "id": 2, "type": "table", "value": "divisions" }, { "id": 4, "type": "column", "value": "division" }, { "id": 0, "type": "column", "value": "country" }, { "id": 1, "type": "table", "value": "matchs" }, { "id": 5, "type": "column", "value"...
[ { "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": [] }, { ...
[ "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
11,603
party_people
spider:train_spider.json:2064
What are the names of parties that have no members?
SELECT party_name FROM party WHERE party_id NOT IN (SELECT party_id FROM Member)
[ "What", "are", "the", "names", "of", "parties", "that", "have", "no", "members", "?" ]
[ { "id": 1, "type": "column", "value": "party_name" }, { "id": 2, "type": "column", "value": "party_id" }, { "id": 3, "type": "table", "value": "member" }, { "id": 0, "type": "table", "value": "party" } ]
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [ 1, 2, 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [] }, { "en...
[ "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "B-TABLE", "O", "O", "O", "B-TABLE", "O" ]
11,604
public_review_platform
bird:train.json:4059
Please indicate the closing hours and business days of the businesses with the category named Doctors.
SELECT DISTINCT T3.opening_time, T3.day_id FROM Business_Categories AS T1 INNER JOIN Categories AS T2 ON T1.category_id = T2.category_id INNER JOIN Business_Hours AS T3 ON T1.business_id = T3.business_id INNER JOIN Days AS T4 ON T3.day_id = T4.day_id WHERE T2.category_name = 'Doctors'
[ "Please", "indicate", "the", "closing", "hours", "and", "business", "days", "of", "the", "businesses", "with", "the", "category", "named", "Doctors", "." ]
[ { "id": 6, "type": "table", "value": "business_categories" }, { "id": 5, "type": "table", "value": "business_hours" }, { "id": 3, "type": "column", "value": "category_name" }, { "id": 0, "type": "column", "value": "opening_time" }, { "id": 8, "...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [ 14 ] }, { "entity_id": 4, "token_idxs": [ 15 ] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "B-TABLE", "O", "O", "B-TABLE", "O", "O", "B-TABLE", "B-COLUMN", "B-VALUE", "O" ]
11,605
phone_market
spider:train_spider.json:1986
Show the carriers that have both phones with memory smaller than 32 and phones with memory bigger than 64.
SELECT Carrier FROM phone WHERE Memory_in_G < 32 INTERSECT SELECT Carrier FROM phone WHERE Memory_in_G > 64
[ "Show", "the", "carriers", "that", "have", "both", "phones", "with", "memory", "smaller", "than", "32", "and", "phones", "with", "memory", "bigger", "than", "64", "." ]
[ { "id": 2, "type": "column", "value": "memory_in_g" }, { "id": 1, "type": "column", "value": "carrier" }, { "id": 0, "type": "table", "value": "phone" }, { "id": 3, "type": "value", "value": "32" }, { "id": 4, "type": "value", "value": "64"...
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 15 ] }, { "entity_id": 3, "token_idxs": [ 11 ] }, { "entity_id": 4, "token_idxs": [ 18 ] }, ...
[ "O", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "O" ]
11,606
chicago_crime
bird:train.json:8721
In the least populated community, what is the most common location of all the reported crime incidents?
SELECT T2.location_description FROM Community_Area AS T1 INNER JOIN Crime AS T2 ON T1.community_area_no = T2.community_area_no WHERE T1.population = ( SELECT MIN(population) FROM Community_Area ) AND T2.location_description IS NOT NULL GROUP BY T2.location_description
[ "In", "the", "least", "populated", "community", ",", "what", "is", "the", "most", "common", "location", "of", "all", "the", "reported", "crime", "incidents", "?" ]
[ { "id": 0, "type": "column", "value": "location_description" }, { "id": 3, "type": "column", "value": "community_area_no" }, { "id": 1, "type": "table", "value": "community_area" }, { "id": 4, "type": "column", "value": "population" }, { "id": 2, ...
[ { "entity_id": 0, "token_idxs": [ 11, 12 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [ 16 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 3 ] }, { ...
[ "O", "O", "O", "B-COLUMN", "B-TABLE", "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "B-TABLE", "O", "O" ]
11,607
movie_platform
bird:train.json:90
Please list the id of the director of the movie "It's Winter".
SELECT director_id FROM movies WHERE movie_title = 'It''s Winter'
[ "Please", "list", "the", "i", "d", "of", "the", "director", "of", "the", "movie", "\"", "It", "'s", "Winter", "\"", "." ]
[ { "id": 1, "type": "column", "value": "director_id" }, { "id": 2, "type": "column", "value": "movie_title" }, { "id": 3, "type": "value", "value": "It's Winter" }, { "id": 0, "type": "table", "value": "movies" } ]
[ { "entity_id": 0, "token_idxs": [ 10 ] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [ 11 ] }, { "entity_id": 3, "token_idxs": [ 12, 13, 14 ] }, { "entity_id": 4, "token_idxs": [...
[ "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "B-COLUMN", "B-VALUE", "I-VALUE", "I-VALUE", "O", "O" ]
11,608
soccer_2016
bird:train.json:1987
How many of the matches are Superover?
SELECT SUM(CASE WHEN T2.win_type = 'wickets' THEN 1 ELSE 0 END) FROM `Match` AS T1 INNER JOIN Win_By AS T2 ON T1.Win_Type = T2.Win_Id
[ "How", "many", "of", "the", "matches", "are", "Superover", "?" ]
[ { "id": 2, "type": "column", "value": "win_type" }, { "id": 6, "type": "value", "value": "wickets" }, { "id": 1, "type": "table", "value": "win_by" }, { "id": 3, "type": "column", "value": "win_id" }, { "id": 0, "type": "table", "value": "M...
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { ...
[ "O", "O", "O", "O", "B-TABLE", "O", "O", "O" ]
11,609
real_estate_rentals
bird:test.json:1456
What is the description of the most common property type? List the description and code.
SELECT T1.property_type_description , T1.property_type_code FROM Ref_Property_Types AS T1 JOIN Properties AS T2 ON T1.property_type_code = T2.property_type_code GROUP BY T1.property_type_code ORDER BY count(*) DESC LIMIT 1;
[ "What", "is", "the", "description", "of", "the", "most", "common", "property", "type", "?", "List", "the", "description", "and", "code", "." ]
[ { "id": 1, "type": "column", "value": "property_type_description" }, { "id": 0, "type": "column", "value": "property_type_code" }, { "id": 2, "type": "table", "value": "ref_property_types" }, { "id": 3, "type": "table", "value": "properties" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 12, 13 ] }, { "entity_id": 2, "token_idxs": [ 9 ] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id...
[ "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "B-TABLE", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O" ]
11,611
flight_4
spider:train_spider.json:6878
What is the id of the routes whose source and destination airports are in the United States?
SELECT rid FROM routes WHERE dst_apid IN (SELECT apid FROM airports WHERE country = 'United States') AND src_apid IN (SELECT apid FROM airports WHERE country = 'United States')
[ "What", "is", "the", "i", "d", "of", "the", "routes", "whose", "source", "and", "destination", "airports", "are", "in", "the", "United", "States", "?" ]
[ { "id": 7, "type": "value", "value": "United States" }, { "id": 2, "type": "column", "value": "dst_apid" }, { "id": 3, "type": "column", "value": "src_apid" }, { "id": 4, "type": "table", "value": "airports" }, { "id": 6, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "entity_id": 1, "token_idxs": [ 3, 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 12 ] }, { "entity_id"...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-VALUE", "I-VALUE", "O" ]
11,613
formula_1
spider:train_spider.json:2200
What are the first names of all the different drivers in alphabetical order?
SELECT DISTINCT forename FROM drivers ORDER BY forename ASC
[ "What", "are", "the", "first", "names", "of", "all", "the", "different", "drivers", "in", "alphabetical", "order", "?" ]
[ { "id": 1, "type": "column", "value": "forename" }, { "id": 0, "type": "table", "value": "drivers" } ]
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [ 3, 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "toke...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O" ]
11,614
regional_sales
bird:train.json:2672
Find the average yearly order by customer Weimei Corp for 2018, 2019 and 2020.
SELECT COUNT(T1.OrderNumber) / 3 FROM `Sales Orders` AS T1 INNER JOIN Customers AS T2 ON T2.CustomerID = T1._CustomerID WHERE (T1.OrderDate LIKE '%/%/18' AND T2.`Customer Names` = 'Weimei Corp') OR (T1.OrderDate LIKE '%/%/19' AND T2.`Customer Names` = 'Weimei Corp') OR (T1.OrderDate LIKE '%/%/20' AND T2.`Customer Names...
[ "Find", "the", "average", "yearly", "order", "by", "customer", "Weimei", "Corp", "for", "2018", ",", "2019", "and", "2020", "." ]
[ { "id": 8, "type": "column", "value": "Customer Names" }, { "id": 0, "type": "table", "value": "Sales Orders" }, { "id": 4, "type": "column", "value": "_customerid" }, { "id": 5, "type": "column", "value": "ordernumber" }, { "id": 9, "type": "v...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "B-TABLE", "B-COLUMN", "B-COLUMN", "B-TABLE", "B-VALUE", "I-VALUE", "O", "O", "O", "O", "O", "O", "O" ]
11,615
formula_1
bird:dev.json:881
For the drivers who took part in the race in 1983/7/16, what's their race completion rate?
SELECT CAST(COUNT(CASE WHEN T2.time IS NOT NULL THEN T2.driverId END) AS REAL) * 100 / COUNT(T2.driverId) FROM races AS T1 INNER JOIN results AS T2 ON T2.raceId = T1.raceId WHERE T1.date = '1983-07-16'
[ "For", "the", "drivers", "who", "took", "part", "in", "the", "race", "in", "1983/7/16", ",", "what", "'s", "their", "race", "completion", "rate", "?" ]
[ { "id": 3, "type": "value", "value": "1983-07-16" }, { "id": 6, "type": "column", "value": "driverid" }, { "id": 1, "type": "table", "value": "results" }, { "id": 4, "type": "column", "value": "raceid" }, { "id": 0, "type": "table", "value"...
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 17 ] }, { "entity_id": 3, "token_idxs": [ 10 ] }, { "entity_id": 4, "token_idxs": [ 15 ] }, { "enti...
[ "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O", "B-VALUE", "O", "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "O" ]
11,616
bike_1
spider:train_spider.json:167
In zip code 94107, on which day neither Fog nor Rain was not observed?
SELECT date FROM weather WHERE zip_code = 94107 AND EVENTS != "Fog" AND EVENTS != "Rain"
[ "In", "zip", "code", "94107", ",", "on", "which", "day", "neither", "Fog", "nor", "Rain", "was", "not", "observed", "?" ]
[ { "id": 2, "type": "column", "value": "zip_code" }, { "id": 0, "type": "table", "value": "weather" }, { "id": 4, "type": "column", "value": "events" }, { "id": 3, "type": "value", "value": "94107" }, { "id": 1, "type": "column", "value": "d...
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 1, 2 ] }, { "entity_id": 3, "token_idxs": [ 3 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id":...
[ "O", "B-COLUMN", "I-COLUMN", "B-VALUE", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "B-COLUMN", "O", "O", "O", "O" ]
11,617
bike_share_1
bird:train.json:9080
Are all stations with zip code 94107 located in San Francisco city?
SELECT DISTINCT T2.city FROM trip AS T1 INNER JOIN station AS T2 ON T2.name = T1.start_station_name WHERE T1.zip_code = 94107
[ "Are", "all", "stations", "with", "zip", "code", "94107", "located", "in", "San", "Francisco", "city", "?" ]
[ { "id": 6, "type": "column", "value": "start_station_name" }, { "id": 3, "type": "column", "value": "zip_code" }, { "id": 2, "type": "table", "value": "station" }, { "id": 4, "type": "value", "value": "94107" }, { "id": 0, "type": "column", ...
[ { "entity_id": 0, "token_idxs": [ 11 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 2 ] }, { "entity_id": 3, "token_idxs": [ 4, 5 ] }, { "entity_id": 4, "token_idxs": [ 6 ] }, { ...
[ "O", "O", "B-TABLE", "O", "B-COLUMN", "I-COLUMN", "B-VALUE", "O", "O", "O", "O", "B-COLUMN", "O" ]
11,618
movie_3
bird:train.json:9175
How many customers paid over the amount of 10 on August 2005?
SELECT COUNT(customer_id) FROM payment WHERE SUBSTR(payment_date, 1, 7) LIKE '2005-08'
[ "How", "many", "customers", "paid", "over", "the", "amount", "of", "10", "on", "August", "2005", "?" ]
[ { "id": 3, "type": "column", "value": "payment_date" }, { "id": 2, "type": "column", "value": "customer_id" }, { "id": 0, "type": "table", "value": "payment" }, { "id": 1, "type": "value", "value": "2005-08" }, { "id": 4, "type": "value", "...
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [ 11 ] }, { "entity_id": 2, "token_idxs": [ 2, 3 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 8 ] }, { ...
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "O", "B-VALUE", "O", "O", "B-VALUE", "O" ]
11,619
cre_Doc_Tracking_DB
spider:train_spider.json:4162
Show all calendar dates and day Numbers.
SELECT calendar_date , day_Number FROM Ref_calendar
[ "Show", "all", "calendar", "dates", "and", "day", "Numbers", "." ]
[ { "id": 1, "type": "column", "value": "calendar_date" }, { "id": 0, "type": "table", "value": "ref_calendar" }, { "id": 2, "type": "column", "value": "day_number" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 5, 6 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id":...
[ "O", "O", "B-TABLE", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "O" ]
11,620
works_cycles
bird:train.json:7192
Among the sales people, who are hired prior to 2010?
SELECT COUNT(T1.BusinessEntityID) FROM Employee AS T1 INNER JOIN Person AS T2 ON T1.BusinessEntityID = T2.BusinessEntityID WHERE T2.PersonType = 'SP' AND SUBSTR(T1.HireDate, 0, 4) < 2010
[ "Among", "the", "sales", "people", ",", "who", "are", "hired", "prior", "to", "2010", "?" ]
[ { "id": 2, "type": "column", "value": "businessentityid" }, { "id": 3, "type": "column", "value": "persontype" }, { "id": 0, "type": "table", "value": "employee" }, { "id": 6, "type": "column", "value": "hiredate" }, { "id": 1, "type": "table",...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 3 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 10 ...
[ "O", "O", "O", "B-COLUMN", "O", "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "O" ]
11,621
financial
bird:dev.json:89
How many accounts who choose issuance after transaction are staying in East Bohemia region?
SELECT COUNT(T2.account_id) FROM district AS T1 INNER JOIN account AS T2 ON T1.district_id = T2.district_id WHERE T1.A3 = 'east Bohemia' AND T2.frequency = 'POPLATEK PO OBRATU'
[ "How", "many", "accounts", "who", "choose", "issuance", "after", "transaction", "are", "staying", "in", "East", "Bohemia", "region", "?" ]
[ { "id": 7, "type": "value", "value": "POPLATEK PO OBRATU" }, { "id": 5, "type": "value", "value": "east Bohemia" }, { "id": 3, "type": "column", "value": "district_id" }, { "id": 2, "type": "column", "value": "account_id" }, { "id": 6, "type": ...
[ { "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": [ 11, ...
[ "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "O", "O" ]
11,622
address_1
bird:test.json:828
Give the name of the nearest city to Chicago.
SELECT T3.city_name FROM Direct_distance AS T1 JOIN City AS T2 ON T1.city1_code = T2.city_code JOIN City AS T3 ON T1.city2_code = T3.city_code WHERE T2.city_name = "Chicago" ORDER BY distance LIMIT 1
[ "Give", "the", "name", "of", "the", "nearest", "city", "to", "Chicago", "." ]
[ { "id": 4, "type": "table", "value": "direct_distance" }, { "id": 5, "type": "column", "value": "city2_code" }, { "id": 7, "type": "column", "value": "city1_code" }, { "id": 0, "type": "column", "value": "city_name" }, { "id": 6, "type": "colum...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "B-COLUMN", "B-COLUMN", "O" ]
11,623
olympics
bird:train.json:5043
State the event name of Basketball.
SELECT T2.event_name FROM sport AS T1 INNER JOIN event AS T2 ON T1.id = T2.sport_id WHERE T1.sport_name = 'Basketball'
[ "State", "the", "event", "name", "of", "Basketball", "." ]
[ { "id": 0, "type": "column", "value": "event_name" }, { "id": 3, "type": "column", "value": "sport_name" }, { "id": 4, "type": "value", "value": "Basketball" }, { "id": 6, "type": "column", "value": "sport_id" }, { "id": 1, "type": "table", ...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 2 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 5 ] }, { "entity_id": 5, "...
[ "O", "O", "B-TABLE", "B-COLUMN", "O", "B-VALUE", "O" ]
11,624
professional_basketball
bird:train.json:2925
Which team did the MVP of 1997 NBA season play in?
SELECT DISTINCT T3.tmID FROM players_teams AS T1 INNER JOIN awards_players AS T2 ON T1.playerID = T2.playerID INNER JOIN teams AS T3 ON T1.tmID = T3.tmID AND T1.year = T3.year WHERE T2.year = 1997 AND T2.award = 'Finals MVP' LIMIT 1
[ "Which", "team", "did", "the", "MVP", "of", "1997", "NBA", "season", "play", "in", "?" ]
[ { "id": 3, "type": "table", "value": "awards_players" }, { "id": 2, "type": "table", "value": "players_teams" }, { "id": 7, "type": "value", "value": "Finals MVP" }, { "id": 8, "type": "column", "value": "playerid" }, { "id": 1, "type": "table"...
[ { "entity_id": 0, "token_idxs": [ 1, 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", "B-COLUMN", "I-COLUMN", "O", "O", "O", "B-VALUE", "O", "O", "B-COLUMN", "I-COLUMN", "O" ]
11,625
retail_complains
bird:train.json:249
For how long did the complaint filed on 2017/3/27 by Rachel Hicks last?
SELECT T2.ser_time FROM client AS T1 INNER JOIN callcenterlogs AS T2 ON T1.client_id = T2.`rand client` WHERE T1.first = 'Rachel' AND T1.last = 'Hicks' AND T2.`Date received` = '2017-03-27'
[ "For", "how", "long", "did", "the", "complaint", "filed", "on", "2017/3/27", "by", "Rachel", "Hicks", "last", "?" ]
[ { "id": 2, "type": "table", "value": "callcenterlogs" }, { "id": 9, "type": "column", "value": "Date received" }, { "id": 4, "type": "column", "value": "rand client" }, { "id": 10, "type": "value", "value": "2017-03-27" }, { "id": 3, "type": "c...
[ { "entity_id": 0, "token_idxs": [] }, { "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, "token_idxs": ...
[ "O", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "B-VALUE", "O", "B-VALUE", "B-VALUE", "B-COLUMN", "O" ]
11,626
sales_in_weather
bird:train.json:8185
Among the stores in weather station 14 in February 2014, which store had sold no less than 300 quantities for item number 44 in a single day?
SELECT T1.store_nbr FROM sales_in_weather AS T1 INNER JOIN relation AS T2 ON T1.store_nbr = T2.store_nbr WHERE T2.station_nbr = 14 AND T1.`date` LIKE '%2014-02%' AND T1.item_nbr = 44 AND units >= 300
[ "Among", "the", "stores", "in", "weather", "station", "14", "in", "February", "2014", ",", "which", "store", "had", "sold", "no", "less", "than", "300", "quantities", "for", "item", "number", "44", "in", "a", "single", "day", "?" ]
[ { "id": 1, "type": "table", "value": "sales_in_weather" }, { "id": 3, "type": "column", "value": "station_nbr" }, { "id": 0, "type": "column", "value": "store_nbr" }, { "id": 6, "type": "value", "value": "%2014-02%" }, { "id": 2, "type": "table...
[ { "entity_id": 0, "token_idxs": [ 12 ] }, { "entity_id": 1, "token_idxs": [ 2, 3, 4 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 6 ] ...
[ "O", "O", "B-TABLE", "I-TABLE", "I-TABLE", "B-TABLE", "B-VALUE", "O", "O", "B-VALUE", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-VALUE", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "B-VALUE", "O", "O", "O", "O", "O" ]
11,627
allergy_1
spider:train_spider.json:444
What are the different allergy types?
SELECT DISTINCT allergytype FROM Allergy_type
[ "What", "are", "the", "different", "allergy", "types", "?" ]
[ { "id": 0, "type": "table", "value": "allergy_type" }, { "id": 1, "type": "column", "value": "allergytype" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 4, 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] ...
[ "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O" ]
11,628
airline
bird:train.json:5884
How many airports have a code starting with the letter C?
SELECT COUNT(*) FROM Airports WHERE Code LIKE 'C%'
[ "How", "many", "airports", "have", "a", "code", "starting", "with", "the", "letter", "C", "?" ]
[ { "id": 0, "type": "table", "value": "airports" }, { "id": 1, "type": "column", "value": "code" }, { "id": 2, "type": "value", "value": "C%" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "B-TABLE", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-VALUE", "O" ]
11,629
movielens
bird:train.json:2341
What are the genres of all the English-language foreign films having a runtime of two hours or less? List each one.
SELECT T2.genre FROM movies AS T1 INNER JOIN movies2directors AS T2 ON T1.movieid = T2.movieid WHERE T1.runningtime <= 2 AND T1.isEnglish = 'T' AND T1.country = 'other'
[ "What", "are", "the", "genres", "of", "all", "the", "English", "-", "language", "foreign", "films", "having", "a", "runtime", "of", "two", "hours", "or", "less", "?", "List", "each", "one", "." ]
[ { "id": 2, "type": "table", "value": "movies2directors" }, { "id": 4, "type": "column", "value": "runningtime" }, { "id": 6, "type": "column", "value": "isenglish" }, { "id": 3, "type": "column", "value": "movieid" }, { "id": 8, "type": "column...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 14 ] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "B-VALUE", "B-COLUMN", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
11,630
activity_1
spider:train_spider.json:6789
Show the ids for all the students who participate in an activity and are under 20.
SELECT StuID FROM Participates_in INTERSECT SELECT StuID FROM Student WHERE age < 20
[ "Show", "the", "ids", "for", "all", "the", "students", "who", "participate", "in", "an", "activity", "and", "are", "under", "20", "." ]
[ { "id": 0, "type": "table", "value": "participates_in" }, { "id": 1, "type": "table", "value": "student" }, { "id": 2, "type": "column", "value": "stuid" }, { "id": 3, "type": "column", "value": "age" }, { "id": 4, "type": "value", "value":...
[ { "entity_id": 0, "token_idxs": [ 8, 9 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [ 13 ] }, { "entity_id": 4, "token_idxs": [ 15 ] }, { ...
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "B-TABLE", "I-TABLE", "O", "O", "O", "B-COLUMN", "O", "B-VALUE", "O" ]
11,631
race_track
spider:train_spider.json:782
What is the name of the track that has had the greatest number of races?
SELECT T2.name FROM race AS T1 JOIN track AS T2 ON T1.track_id = T2.track_id GROUP BY T1.track_id ORDER BY count(*) DESC LIMIT 1
[ "What", "is", "the", "name", "of", "the", "track", "that", "has", "had", "the", "greatest", "number", "of", "races", "?" ]
[ { "id": 0, "type": "column", "value": "track_id" }, { "id": 3, "type": "table", "value": "track" }, { "id": 1, "type": "column", "value": "name" }, { "id": 2, "type": "table", "value": "race" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 14 ] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O" ]
11,632
wine_1
spider:train_spider.json:6598
What is the county that produces the most wines scoring higher than 90?
SELECT T1.County FROM APPELLATIONS AS T1 JOIN WINE AS T2 ON T1.Appelation = T2.Appelation WHERE T2.Score > 90 GROUP BY T1.County ORDER BY count(*) DESC LIMIT 1
[ "What", "is", "the", "county", "that", "produces", "the", "most", "wines", "scoring", "higher", "than", "90", "?" ]
[ { "id": 1, "type": "table", "value": "appellations" }, { "id": 5, "type": "column", "value": "appelation" }, { "id": 0, "type": "column", "value": "county" }, { "id": 3, "type": "column", "value": "score" }, { "id": 2, "type": "table", "val...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [ 12 ] }, { "entity...
[ "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "B-VALUE", "O" ]
11,633
retail_world
bird:train.json:6589
Indicate the address of the company Eastern Connection whose contact name is Ann Devon.
SELECT Address FROM Customers WHERE CompanyName = 'Eastern Connection' AND ContactName = 'Ann Devon'
[ "Indicate", "the", "address", "of", "the", "company", "Eastern", "Connection", "whose", "contact", "name", "is", "Ann", "Devon", "." ]
[ { "id": 3, "type": "value", "value": "Eastern Connection" }, { "id": 2, "type": "column", "value": "companyname" }, { "id": 4, "type": "column", "value": "contactname" }, { "id": 0, "type": "table", "value": "customers" }, { "id": 5, "type": "v...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [ 6, 7 ] }, { "entity_id": 4, "token_idxs": [ 9, 10 ] ...
[ "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "B-VALUE", "I-VALUE", "O", "B-COLUMN", "I-COLUMN", "O", "B-VALUE", "I-VALUE", "O" ]
11,634
news_report
spider:train_spider.json:2818
Find the average age and experience working length of journalists working on different role type.
SELECT avg(t1.age) , avg(Years_working) , t2.work_type FROM journalist AS t1 JOIN news_report AS t2 ON t1.journalist_id = t2.journalist_id GROUP BY t2.work_type
[ "Find", "the", "average", "age", "and", "experience", "working", "length", "of", "journalists", "working", "on", "different", "role", "type", "." ]
[ { "id": 4, "type": "column", "value": "years_working" }, { "id": 5, "type": "column", "value": "journalist_id" }, { "id": 2, "type": "table", "value": "news_report" }, { "id": 1, "type": "table", "value": "journalist" }, { "id": 0, "type": "col...
[ { "entity_id": 0, "token_idxs": [ 14 ] }, { "entity_id": 1, "token_idxs": [ 9 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 3 ] }, { "entity_id": 4, "token_idxs": [ 6 ] }, { "entity...
[ "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-COLUMN", "O" ]
11,635
department_store
spider:train_spider.json:4796
What is the name of the hardware product with the greatest price?
SELECT product_name FROM products WHERE product_type_code = 'Hardware' ORDER BY product_price DESC LIMIT 1
[ "What", "is", "the", "name", "of", "the", "hardware", "product", "with", "the", "greatest", "price", "?" ]
[ { "id": 2, "type": "column", "value": "product_type_code" }, { "id": 4, "type": "column", "value": "product_price" }, { "id": 1, "type": "column", "value": "product_name" }, { "id": 0, "type": "table", "value": "products" }, { "id": 3, "type": ...
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "O", "O", "O", "B-VALUE", "B-TABLE", "O", "O", "O", "O", "O" ]
11,636
codebase_comments
bird:train.json:627
How many percent more of the Forks for the repository of solution No.53546 than No.1502?
SELECT CAST(SUM(CASE WHEN T2.Id = 53546 THEN T1.Forks ELSE 0 END) - SUM(CASE WHEN T2.Id = 1502 THEN T1.Forks ELSE 0 END) AS REAL) * 100 / SUM(CASE WHEN T2.Id = 1502 THEN T1.Forks ELSE 0 END) FROM Repo AS T1 INNER JOIN Solution AS T2 ON T1.Id = T2.RepoId
[ "How", "many", "percent", "more", "of", "the", "Forks", "for", "the", "repository", "of", "solution", "No.53546", "than", "No.1502", "?" ]
[ { "id": 1, "type": "table", "value": "solution" }, { "id": 3, "type": "column", "value": "repoid" }, { "id": 6, "type": "column", "value": "forks" }, { "id": 8, "type": "value", "value": "53546" }, { "id": 0, "type": "table", "value": "repo...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 11 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs":...
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "B-TABLE", "B-VALUE", "O", "B-VALUE", "O" ]
11,637
products_gen_characteristics
spider:train_spider.json:5593
Give the color description that is least common across products.
SELECT t2.color_description FROM products AS t1 JOIN ref_colors AS t2 ON t1.color_code = t2.color_code GROUP BY t2.color_description ORDER BY count(*) ASC LIMIT 1
[ "Give", "the", "color", "description", "that", "is", "least", "common", "across", "products", "." ]
[ { "id": 0, "type": "column", "value": "color_description" }, { "id": 2, "type": "table", "value": "ref_colors" }, { "id": 3, "type": "column", "value": "color_code" }, { "id": 1, "type": "table", "value": "products" } ]
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 9 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 2 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "B-COLUMN", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O" ]
11,638
formula_1
spider:train_spider.json:2177
Find the forename and surname of drivers whose nationality is German?
SELECT forename , surname FROM drivers WHERE nationality = "German"
[ "Find", "the", "forename", "and", "surname", "of", "drivers", "whose", "nationality", "is", "German", "?" ]
[ { "id": 3, "type": "column", "value": "nationality" }, { "id": 1, "type": "column", "value": "forename" }, { "id": 0, "type": "table", "value": "drivers" }, { "id": 2, "type": "column", "value": "surname" }, { "id": 4, "type": "column", "va...
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 4 ] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [ 10 ] }, ...
[ "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "B-TABLE", "O", "B-COLUMN", "O", "B-COLUMN", "O" ]
11,639
perpetrator
spider:train_spider.json:2310
What are the names of perpetrators whose country is not "China"?
SELECT T1.Name FROM people AS T1 JOIN perpetrator AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Country != "China"
[ "What", "are", "the", "names", "of", "perpetrators", "whose", "country", "is", "not", "\"", "China", "\"", "?" ]
[ { "id": 2, "type": "table", "value": "perpetrator" }, { "id": 5, "type": "column", "value": "people_id" }, { "id": 3, "type": "column", "value": "country" }, { "id": 1, "type": "table", "value": "people" }, { "id": 4, "type": "column", "val...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [ 7 ] }, { "entity_id": 4, "token_idxs": [ 11 ] }, { "entity...
[ "O", "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "B-COLUMN", "O", "O", "O", "B-COLUMN", "O", "O" ]
11,640
college_2
spider:train_spider.json:1474
List in alphabetic order the names of all distinct instructors.
SELECT DISTINCT name FROM instructor ORDER BY name
[ "List", "in", "alphabetic", "order", "the", "names", "of", "all", "distinct", "instructors", "." ]
[ { "id": 0, "type": "table", "value": "instructor" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "O" ]
11,641
image_and_language
bird:train.json:7545
What is the caption for the prediction class id 12?
SELECT PRED_CLASS FROM PRED_CLASSES WHERE PRED_CLASS_ID = 12
[ "What", "is", "the", "caption", "for", "the", "prediction", "class", "i", "d", "12", "?" ]
[ { "id": 2, "type": "column", "value": "pred_class_id" }, { "id": 0, "type": "table", "value": "pred_classes" }, { "id": 1, "type": "column", "value": "pred_class" }, { "id": 3, "type": "value", "value": "12" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 6, 7 ] }, { "entity_id": 2, "token_idxs": [ 8, 9 ] }, { "entity_id": 3, "token_idxs": [ 10 ] }, { "entity_id": 4, "token_idxs": [] }, { "e...
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "B-COLUMN", "I-COLUMN", "B-VALUE", "O" ]
11,642
cre_Drama_Workshop_Groups
spider:train_spider.json:5149
Find the number of distinct currency codes used in drama workshop groups.
SELECT count(DISTINCT Currency_Code) FROM Drama_Workshop_Groups
[ "Find", "the", "number", "of", "distinct", "currency", "codes", "used", "in", "drama", "workshop", "groups", "." ]
[ { "id": 0, "type": "table", "value": "drama_workshop_groups" }, { "id": 1, "type": "column", "value": "currency_code" } ]
[ { "entity_id": 0, "token_idxs": [ 9, 10, 11 ] }, { "entity_id": 1, "token_idxs": [ 5, 6 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "enti...
[ "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "I-TABLE", "I-TABLE", "O" ]
11,643
legislator
bird:train.json:4765
List the last name of all current legislators who live in California.
SELECT T1.last_name FROM current AS T1 INNER JOIN `current-terms` AS T2 ON T1.bioguide_id = T2.bioguide WHERE T2.state = 'CA' GROUP BY T1.last_name
[ "List", "the", "last", "name", "of", "all", "current", "legislators", "who", "live", "in", "California", "." ]
[ { "id": 2, "type": "table", "value": "current-terms" }, { "id": 5, "type": "column", "value": "bioguide_id" }, { "id": 0, "type": "column", "value": "last_name" }, { "id": 6, "type": "column", "value": "bioguide" }, { "id": 1, "type": "table", ...
[ { "entity_id": 0, "token_idxs": [ 2, 3 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 0, 1 ] }, { "entity_id": 4, "token_idxs": [] }, { "en...
[ "B-COLUMN", "I-COLUMN", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O" ]
11,644
card_games
bird:dev.json:365
What is the type of card "Benalish Knight"?
SELECT DISTINCT T1.type FROM cards AS T1 INNER JOIN foreign_data AS T2 ON T1.uuid = T2.uuid WHERE T1.name = 'Benalish Knight'
[ "What", "is", "the", "type", "of", "card", "\"", "Benalish", "Knight", "\"", "?" ]
[ { "id": 4, "type": "value", "value": "Benalish Knight" }, { "id": 2, "type": "table", "value": "foreign_data" }, { "id": 1, "type": "table", "value": "cards" }, { "id": 0, "type": "column", "value": "type" }, { "id": 3, "type": "column", "v...
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 7, 8 ] }, { "entity_id":...
[ "O", "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "B-VALUE", "I-VALUE", "O", "O" ]
11,645
authors
bird:train.json:3672
How many publications were published by author named 'Howard F. Lipson'?
SELECT COUNT(PaperId) FROM PaperAuthor WHERE Name = 'Howard F. Lipson'
[ "How", "many", "publications", "were", "published", "by", "author", "named", "'", "Howard", "F.", "Lipson", "'", "?" ]
[ { "id": 2, "type": "value", "value": "Howard F. Lipson" }, { "id": 0, "type": "table", "value": "paperauthor" }, { "id": 3, "type": "column", "value": "paperid" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [ 9, 10, 11 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "...
[ "O", "O", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O", "O" ]
11,646
book_1
bird:test.json:560
Give the maximum and minimum sale price of books.
SELECT max(saleprice) , min(saleprice) FROM Book
[ "Give", "the", "maximum", "and", "minimum", "sale", "price", "of", "books", "." ]
[ { "id": 1, "type": "column", "value": "saleprice" }, { "id": 0, "type": "table", "value": "book" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 5, 6 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "toke...
[ "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-TABLE", "O" ]
11,647
movie_platform
bird:train.json:128
Give the url of movie which was rated 5 on 2013/5/3 5:11:17.
SELECT T2.movie_url FROM ratings AS T1 INNER JOIN movies AS T2 ON T1.movie_id = T2.movie_id WHERE rating_score = 5 AND rating_timestamp_utc LIKE '2013-05-03 05:11:17'
[ "Give", "the", "url", "of", "movie", "which", "was", "rated", "5", "on", "2013/5/3", "5:11:17", "." ]
[ { "id": 6, "type": "column", "value": "rating_timestamp_utc" }, { "id": 7, "type": "value", "value": "2013-05-03 05:11:17" }, { "id": 4, "type": "column", "value": "rating_score" }, { "id": 0, "type": "column", "value": "movie_url" }, { "id": 3, ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 4 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 8 ...
[ "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-VALUE", "O", "B-VALUE", "I-VALUE", "O" ]
11,648
planet_1
bird:test.json:1913
List package number of package shipped in planet Omicron Persei 8 and sent by Zapp Brannigan.
SELECT T1.PackageNumber FROM PACKAGE AS T1 JOIN Client AS T2 ON T1.Sender = T2.AccountNumber JOIN Shipment AS T3 ON T1.Shipment = T3.ShipmentID JOIN Planet AS T4 ON T3.Planet = T4.PlanetID WHERE T2.Name = "Zapp Brannigan" AND T4.Name = "Omicron Persei 8";
[ "List", "package", "number", "of", "package", "shipped", "in", "planet", "Omicron", "Persei", "8", "and", "sent", "by", "Zapp", "Brannigan", "." ]
[ { "id": 7, "type": "column", "value": "Omicron Persei 8" }, { "id": 6, "type": "column", "value": "Zapp Brannigan" }, { "id": 0, "type": "column", "value": "packagenumber" }, { "id": 13, "type": "column", "value": "accountnumber" }, { "id": 11, ...
[ { "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": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "B-COLUMN", "B-COLUMN", "O", "B-TABLE", "B-COLUMN", "O", "B-COLUMN", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "O" ]
11,649
tracking_share_transactions
spider:train_spider.json:5855
Show the maximum share count of transactions where the amount is smaller than 10000
SELECT max(share_count) FROM TRANSACTIONS WHERE amount_of_transaction < 10000
[ "Show", "the", "maximum", "share", "count", "of", "transactions", "where", "the", "amount", "is", "smaller", "than", "10000" ]
[ { "id": 1, "type": "column", "value": "amount_of_transaction" }, { "id": 0, "type": "table", "value": "transactions" }, { "id": 3, "type": "column", "value": "share_count" }, { "id": 2, "type": "value", "value": "10000" } ]
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [ 13 ] }, { "entity_id": 3, "token_idxs": [ 3, 4 ] }, { "entity_id": 4, "token_idxs": [] }, { ...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "B-COLUMN", "B-TABLE", "O", "O", "O", "O", "O", "O", "B-VALUE" ]
11,650
address_1
bird:test.json:820
What are the city codes of cities with distance greater than average?
SELECT city1_code , city2_code FROM Direct_distance WHERE distance > (SELECT avg(distance) FROM Direct_distance)
[ "What", "are", "the", "city", "codes", "of", "cities", "with", "distance", "greater", "than", "average", "?" ]
[ { "id": 0, "type": "table", "value": "direct_distance" }, { "id": 1, "type": "column", "value": "city1_code" }, { "id": 2, "type": "column", "value": "city2_code" }, { "id": 3, "type": "column", "value": "distance" } ]
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 3, 4 ] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id":...
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "O" ]
11,651
simpson_episodes
bird:train.json:4182
How many episodes have more than 1000 votes?
SELECT COUNT(episode_id) FROM Episode WHERE votes > 1000;
[ "How", "many", "episodes", "have", "more", "than", "1000", "votes", "?" ]
[ { "id": 3, "type": "column", "value": "episode_id" }, { "id": 0, "type": "table", "value": "episode" }, { "id": 1, "type": "column", "value": "votes" }, { "id": 2, "type": "value", "value": "1000" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "...
[ "O", "O", "B-TABLE", "O", "O", "O", "B-VALUE", "B-COLUMN", "O" ]
11,652
works_cycles
bird:train.json:7299
Among the products from the mountain product line, how many of them are sold by over 2 vendors?
SELECT SUM(CASE WHEN T1.ProductLine = 'M' THEN 1 ELSE 0 END) FROM Product AS T1 INNER JOIN ProductVendor AS T2 ON T1.ProductID = T2.ProductID INNER JOIN Vendor AS T3 ON T2.BusinessEntityID = T3.BusinessEntityID GROUP BY T1.ProductID HAVING COUNT(T1.Name) > 2
[ "Among", "the", "products", "from", "the", "mountain", "product", "line", ",", "how", "many", "of", "them", "are", "sold", "by", "over", "2", "vendors", "?" ]
[ { "id": 5, "type": "column", "value": "businessentityid" }, { "id": 4, "type": "table", "value": "productvendor" }, { "id": 9, "type": "column", "value": "productline" }, { "id": 0, "type": "column", "value": "productid" }, { "id": 3, "type": "...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 18 ] }, { "entity_id": 2, "token_idxs": [ 17 ] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, ...
[ "O", "O", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "B-TABLE", "O" ]
11,653
restaurant_1
spider:train_spider.json:2820
Show me all the restaurants.
SELECT ResName FROM Restaurant;
[ "Show", "me", "all", "the", "restaurants", "." ]
[ { "id": 0, "type": "table", "value": "restaurant" }, { "id": 1, "type": "column", "value": "resname" } ]
[ { "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" ]
11,654
college_2
spider:train_spider.json:1465
What are the names of all instructors in the Comp. Sci. department?
SELECT name FROM instructor WHERE dept_name = 'Comp. Sci.'
[ "What", "are", "the", "names", "of", "all", "instructors", "in", "the", "Comp", ".", "Sci", ".", "department", "?" ]
[ { "id": 0, "type": "table", "value": "instructor" }, { "id": 3, "type": "value", "value": "Comp. Sci." }, { "id": 2, "type": "column", "value": "dept_name" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 13 ] }, { "entity_id": 3, "token_idxs": [ 9, 10, 11, 12 ] }, { "entity_id": 4, "token_...
[ "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "B-COLUMN", "O" ]
11,655
ice_hockey_draft
bird:train.json:6995
Who is the oldest player that participated in OHL league in the 1997 - 2000 season?
SELECT T1.PlayerName FROM PlayerInfo AS T1 INNER JOIN SeasonStatus AS T2 ON T1.ELITEID = T2.ELITEID WHERE T2.LEAGUE = 'OHL' AND T2.SEASON = '1999-2000' ORDER BY T1.birthdate LIMIT 1
[ "Who", "is", "the", "oldest", "player", "that", "participated", "in", "OHL", "league", "in", "the", "1997", "-", "2000", "season", "?" ]
[ { "id": 2, "type": "table", "value": "seasonstatus" }, { "id": 0, "type": "column", "value": "playername" }, { "id": 1, "type": "table", "value": "playerinfo" }, { "id": 3, "type": "column", "value": "birthdate" }, { "id": 8, "type": "value", ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "B-VALUE", "B-COLUMN", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "B-COLUMN", "O" ]
11,656
tracking_orders
spider:train_spider.json:6910
Which customers have both "On Road" and "Shipped" as order status? List the customer names.
SELECT T1.customer_name FROM customers AS T1 JOIN orders AS T2 ON T1.customer_id = T2.customer_id WHERE T2.order_status = "On Road" INTERSECT SELECT T1.customer_name FROM customers AS T1 JOIN orders AS T2 ON T1.customer_id = T2.customer_id WHERE T2.order_status = "Shipped"
[ "Which", "customers", "have", "both", "\"", "On", "Road", "\"", "and", "\"", "Shipped", "\"", "as", "order", "status", "?", "List", "the", "customer", "names", "." ]
[ { "id": 0, "type": "column", "value": "customer_name" }, { "id": 3, "type": "column", "value": "order_status" }, { "id": 6, "type": "column", "value": "customer_id" }, { "id": 1, "type": "table", "value": "customers" }, { "id": 4, "type": "colu...
[ { "entity_id": 0, "token_idxs": [ 19 ] }, { "entity_id": 1, "token_idxs": [ 1 ] }, { "entity_id": 2, "token_idxs": [ 13 ] }, { "entity_id": 3, "token_idxs": [ 14 ] }, { "entity_id": 4, "token_idxs": [ 5, 6 ...
[ "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "B-COLUMN", "B-COLUMN", "O" ]
11,657
superstore
bird:train.json:2398
Compare the numbers of orders between the Eastern and Western stores in 2015.
SELECT east, west FROM ( SELECT COUNT(`Order ID`) AS east , ( SELECT COUNT(`Order ID`) FROM west_superstore WHERE `Order Date` LIKE '2015%' ) AS west FROM east_superstore WHERE `Order Date` LIKE '2015%' )
[ "Compare", "the", "numbers", "of", "orders", "between", "the", "Eastern", "and", "Western", "stores", "in", "2015", "." ]
[ { "id": 2, "type": "table", "value": "east_superstore" }, { "id": 6, "type": "table", "value": "west_superstore" }, { "id": 3, "type": "column", "value": "Order Date" }, { "id": 5, "type": "column", "value": "Order ID" }, { "id": 4, "type": "va...
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "entity_id": 1, "token_idxs": [ 9 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [ 12 ] }, { "entity...
[ "O", "O", "O", "O", "B-COLUMN", "B-COLUMN", "O", "B-COLUMN", "O", "B-COLUMN", "B-TABLE", "O", "B-VALUE", "O" ]
11,658
retail_world
bird:train.json:6305
The sales of how many territories is Nancy Davolio in charge of?
SELECT COUNT(T2.TerritoryID) FROM Employees AS T1 INNER JOIN EmployeeTerritories AS T2 ON T1.EmployeeID = T2.EmployeeID WHERE T1.FirstName = 'Nancy' AND T1.LastName = 'Davolio'
[ "The", "sales", "of", "how", "many", "territories", "is", "Nancy", "Davolio", "in", "charge", "of", "?" ]
[ { "id": 1, "type": "table", "value": "employeeterritories" }, { "id": 2, "type": "column", "value": "territoryid" }, { "id": 3, "type": "column", "value": "employeeid" }, { "id": 0, "type": "table", "value": "employees" }, { "id": 4, "type": "c...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": ...
[ "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "B-VALUE", "B-VALUE", "O", "O", "O", "O" ]
11,659
cre_Doc_and_collections
bird:test.json:728
For ever collection named 'Best', what is the name and id of the one with the most documents, and how many documents does it have?
SELECT T1.Collection_Name , T1.Collection_ID , count(*) FROM Collections AS T1 JOIN Documents_in_Collections AS T2 ON T1.Collection_ID = T2.Collection_ID WHERE T1.Collection_Name = "Best" GROUP BY T1.Collection_ID ORDER BY count(*) DESC LIMIT 1;
[ "For", "ever", "collection", "named", "'", "Best", "'", ",", "what", "is", "the", "name", "and", "i", "d", "of", "the", "one", "with", "the", "most", "documents", ",", "and", "how", "many", "documents", "does", "it", "have", "?" ]
[ { "id": 3, "type": "table", "value": "documents_in_collections" }, { "id": 1, "type": "column", "value": "collection_name" }, { "id": 0, "type": "column", "value": "collection_id" }, { "id": 2, "type": "table", "value": "collections" }, { "id": 4, ...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 2 ] }, { "entity_id": 3, "token_idxs": [ 26, 27 ] }, { "entity_id": 4, "token_idxs": [ 5 ] }, { ...
[ "O", "O", "B-TABLE", "B-COLUMN", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "I-TABLE", "O", "O", "O" ]
11,660
products_gen_characteristics
spider:train_spider.json:5564
How many characteristics does the product named "laurel" have?
SELECT count(*) FROM products AS t1 JOIN product_characteristics AS t2 ON t1.product_id = t2.product_id JOIN CHARACTERISTICS AS t3 ON t2.characteristic_id = t3.characteristic_id WHERE t1.product_name = "laurel"
[ "How", "many", "characteristics", "does", "the", "product", "named", "\"", "laurel", "\"", "have", "?" ]
[ { "id": 4, "type": "table", "value": "product_characteristics" }, { "id": 5, "type": "column", "value": "characteristic_id" }, { "id": 0, "type": "table", "value": "characteristics" }, { "id": 1, "type": "column", "value": "product_name" }, { "id":...
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_...
[ "O", "O", "B-TABLE", "O", "O", "B-TABLE", "B-COLUMN", "O", "B-COLUMN", "O", "O", "O" ]
11,661
pilot_1
bird:test.json:1131
Find the names of all pilots with age between 30 and 40 sorted by their ages in ascending order.
SELECT pilot_name FROM pilotskills WHERE age BETWEEN 30 AND 40 ORDER BY age
[ "Find", "the", "names", "of", "all", "pilots", "with", "age", "between", "30", "and", "40", "sorted", "by", "their", "ages", "in", "ascending", "order", "." ]
[ { "id": 0, "type": "table", "value": "pilotskills" }, { "id": 1, "type": "column", "value": "pilot_name" }, { "id": 2, "type": "column", "value": "age" }, { "id": 3, "type": "value", "value": "30" }, { "id": 4, "type": "value", "value": "40...
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [ 11 ] }, { "entity...
[ "O", "O", "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "B-VALUE", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "O", "O" ]