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
2,358
restaurant
bird:train.json:1676
List by its ID number all restaurants on 11th Street in Oakland.
SELECT id_restaurant FROM location WHERE city = 'oakland' AND street_name = '11th street'
[ "List", "by", "its", "ID", "number", "all", "restaurants", "on", "11th", "Street", "in", "Oakland", "." ]
[ { "id": 1, "type": "column", "value": "id_restaurant" }, { "id": 4, "type": "column", "value": "street_name" }, { "id": 5, "type": "value", "value": "11th street" }, { "id": 0, "type": "table", "value": "location" }, { "id": 3, "type": "value", "value": "oakland" }, { "id": 2, "type": "column", "value": "city" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 11 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 8, 9 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "B-VALUE", "I-VALUE", "O", "B-VALUE", "O" ]
2,359
cookbook
bird:train.json:8922
How many dairy recipes can serve more than 10 people?
SELECT COUNT(*) FROM Recipe AS T1 INNER JOIN Quantity AS T2 ON T1.recipe_id = T2.recipe_id INNER JOIN Ingredient AS T3 ON T3.ingredient_id = T2.ingredient_id WHERE T3.category = 'dairy' AND T1.servings > 10
[ "How", "many", "dairy", "recipes", "can", "serve", "more", "than", "10", "people", "?" ]
[ { "id": 3, "type": "column", "value": "ingredient_id" }, { "id": 0, "type": "table", "value": "ingredient" }, { "id": 8, "type": "column", "value": "recipe_id" }, { "id": 2, "type": "table", "value": "quantity" }, { "id": 4, "type": "column", "value": "category" }, { "id": 6, "type": "column", "value": "servings" }, { "id": 1, "type": "table", "value": "recipe" }, { "id": 5, "type": "value", "value": "dairy" }, { "id": 7, "type": "value", "value": "10" } ]
[ { "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": [] }, { "entity_id": 5, "token_idxs": [ 2 ] }, { "entity_id": 6, "token_idxs": [ 5 ] }, { "entity_id": 7, "token_idxs": [ 8 ] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-VALUE", "B-TABLE", "O", "B-COLUMN", "O", "O", "B-VALUE", "O", "O" ]
2,360
cre_Docs_and_Epenses
spider:train_spider.json:6449
Show the budget type code and description and the corresponding document id.
SELECT T2.budget_type_code , T2.budget_type_description , T1.document_id FROM Documents_with_expenses AS T1 JOIN Ref_budget_codes AS T2 ON T1.budget_type_code = T2.budget_type_code
[ "Show", "the", "budget", "type", "code", "and", "description", "and", "the", "corresponding", "document", "i", "d." ]
[ { "id": 1, "type": "column", "value": "budget_type_description" }, { "id": 3, "type": "table", "value": "documents_with_expenses" }, { "id": 0, "type": "column", "value": "budget_type_code" }, { "id": 4, "type": "table", "value": "ref_budget_codes" }, { "id": 2, "type": "column", "value": "document_id" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 5, 6 ] }, { "entity_id": 2, "token_idxs": [ 10, 11, 12 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 2, 3, 4 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-TABLE", "I-TABLE", "I-TABLE", "B-COLUMN", "I-COLUMN", "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN" ]
2,361
real_estate_rentals
bird:test.json:1455
Return the date stamp and property name for each property history event, sorted by date stamp.
SELECT T1.datestamp , T2.property_name FROM User_Property_History AS T1 JOIN Properties AS T2 ON T1.property_id = T2.property_id ORDER BY datestamp;
[ "Return", "the", "date", "stamp", "and", "property", "name", "for", "each", "property", "history", "event", ",", "sorted", "by", "date", "stamp", "." ]
[ { "id": 2, "type": "table", "value": "user_property_history" }, { "id": 1, "type": "column", "value": "property_name" }, { "id": 4, "type": "column", "value": "property_id" }, { "id": 3, "type": "table", "value": "properties" }, { "id": 0, "type": "column", "value": "datestamp" } ]
[ { "entity_id": 0, "token_idxs": [ 2, 3 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [ 9, 10 ] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-TABLE", "B-COLUMN", "O", "O", "B-TABLE", "I-TABLE", "O", "O", "O", "O", "O", "O", "O" ]
2,362
simpson_episodes
bird:train.json:4278
Please provide any two episodes' names that have the same keyword of "1930s to 2020s".
SELECT T1.title FROM Episode AS T1 INNER JOIN Keyword AS T2 ON T1.episode_id = T2.episode_id WHERE T2.keyword = '1930s to 2020s' LIMIT 2;
[ "Please", "provide", "any", "two", "episodes", "'", "names", "that", "have", "the", "same", "keyword", "of", "\"", "1930s", "to", "2020s", "\"", "." ]
[ { "id": 4, "type": "value", "value": "1930s to 2020s" }, { "id": 5, "type": "column", "value": "episode_id" }, { "id": 1, "type": "table", "value": "episode" }, { "id": 2, "type": "table", "value": "keyword" }, { "id": 3, "type": "column", "value": "keyword" }, { "id": 0, "type": "column", "value": "title" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 11 ] }, { "entity_id": 4, "token_idxs": [ 14, 15, 16 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O", "O" ]
2,363
public_review_platform
bird:train.json:3835
Please list any two user numbers that have an "Uber" number of cute compliments.
SELECT T1.user_id FROM Users_Compliments AS T1 INNER JOIN Compliments AS T2 ON T1.compliment_id = T2.compliment_id WHERE T1.number_of_compliments LIKE 'Uber' AND T2.compliment_type LIKE 'cute' LIMIT 2
[ "Please", "list", "any", "two", "user", "numbers", "that", "have", "an", "\"", "Uber", "\"", "number", "of", "cute", "compliments", "." ]
[ { "id": 4, "type": "column", "value": "number_of_compliments" }, { "id": 1, "type": "table", "value": "users_compliments" }, { "id": 6, "type": "column", "value": "compliment_type" }, { "id": 3, "type": "column", "value": "compliment_id" }, { "id": 2, "type": "table", "value": "compliments" }, { "id": 0, "type": "column", "value": "user_id" }, { "id": 5, "type": "value", "value": "Uber" }, { "id": 7, "type": "value", "value": "cute" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 15 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 12, 13 ] }, { "entity_id": 5, "token_idxs": [ 10 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [ 14 ] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-VALUE", "O", "B-COLUMN", "I-COLUMN", "B-VALUE", "B-TABLE", "O" ]
2,364
soccer_2016
bird:train.json:1880
List down names of teams that have played as second team against Pune Warriors.
SELECT T2.Team_Name FROM Match AS T1 INNER JOIN Team AS T2 ON T2.Team_Id = T1.Team_2 WHERE T1.Team_1 = ( SELECT Team_Id FROM Team WHERE Team_Name = 'Pune Warriors' ) GROUP BY T2.Team_Name
[ "List", "down", "names", "of", "teams", "that", "have", "played", "as", "second", "team", "against", "Pune", "Warriors", "." ]
[ { "id": 6, "type": "value", "value": "Pune Warriors" }, { "id": 0, "type": "column", "value": "team_name" }, { "id": 4, "type": "column", "value": "team_id" }, { "id": 3, "type": "column", "value": "team_1" }, { "id": 5, "type": "column", "value": "team_2" }, { "id": 1, "type": "table", "value": "match" }, { "id": 2, "type": "table", "value": "team" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 10 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [ 12, 13 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "B-VALUE", "I-VALUE", "O" ]
2,365
works_cycles
bird:train.json:7139
Where is the address 15873 located, in what city and state? Does that city belong to a province where the code exists?
SELECT T2.City, T1.Name, T1.IsOnlyStateProvinceFlag FROM StateProvince AS T1 INNER JOIN Address AS T2 ON T1.StateProvinceID = T2.StateProvinceID WHERE T2.AddressID = 15873
[ "Where", "is", "the", "address", "15873", "located", ",", "in", "what", "city", "and", "state", "?", "Does", "that", "city", "belong", "to", "a", "province", "where", "the", "code", "exists", "?" ]
[ { "id": 2, "type": "column", "value": "isonlystateprovinceflag" }, { "id": 7, "type": "column", "value": "stateprovinceid" }, { "id": 3, "type": "table", "value": "stateprovince" }, { "id": 5, "type": "column", "value": "addressid" }, { "id": 4, "type": "table", "value": "address" }, { "id": 6, "type": "value", "value": "15873" }, { "id": 0, "type": "column", "value": "city" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 18, 19 ] }, { "entity_id": 4, "token_idxs": [ 3 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [ 4 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-TABLE", "B-VALUE", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "I-TABLE", "O", "O", "O", "O", "O" ]
2,366
insurance_policies
spider:train_spider.json:3892
List the details of the customers who do not have any policies.
SELECT customer_details FROM Customers EXCEPT SELECT T1.customer_details FROM Customers AS T1 JOIN Customer_Policies AS T2 ON T1.customer_id = T2.customer_id
[ "List", "the", "details", "of", "the", "customers", "who", "do", "not", "have", "any", "policies", "." ]
[ { "id": 2, "type": "table", "value": "customer_policies" }, { "id": 1, "type": "column", "value": "customer_details" }, { "id": 3, "type": "column", "value": "customer_id" }, { "id": 0, "type": "table", "value": "customers" } ]
[ { "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": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O" ]
2,367
olympics
bird:train.json:5025
What is the percentage of champions at the age of over 30?
SELECT CAST(COUNT(CASE WHEN T2.age > 30 THEN 1 END) AS REAL) * 100 / COUNT(T2.person_id) FROM competitor_event AS T1 INNER JOIN games_competitor AS T2 ON T1.competitor_id = T2.id WHERE T1.medal_id = 1
[ "What", "is", "the", "percentage", "of", "champions", "at", "the", "age", "of", "over", "30", "?" ]
[ { "id": 0, "type": "table", "value": "competitor_event" }, { "id": 1, "type": "table", "value": "games_competitor" }, { "id": 4, "type": "column", "value": "competitor_id" }, { "id": 7, "type": "column", "value": "person_id" }, { "id": 2, "type": "column", "value": "medal_id" }, { "id": 6, "type": "value", "value": "100" }, { "id": 8, "type": "column", "value": "age" }, { "id": 5, "type": "column", "value": "id" }, { "id": 9, "type": "value", "value": "30" }, { "id": 3, "type": "value", "value": "1" } ]
[ { "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": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [ 8 ] }, { "entity_id": 9, "token_idxs": [ 11 ] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "O" ]
2,368
customers_and_orders
bird:test.json:307
How many customers have ordered the product named Monitor?
SELECT count(DISTINCT T3.customer_id) FROM Order_items AS T1 JOIN Products AS T2 ON T1.product_id = T2.product_id JOIN Customer_orders AS T3 ON T3.order_id = T1.order_id WHERE T2.product_name = "Monitor"
[ "How", "many", "customers", "have", "ordered", "the", "product", "named", "Monitor", "?" ]
[ { "id": 0, "type": "table", "value": "customer_orders" }, { "id": 1, "type": "column", "value": "product_name" }, { "id": 3, "type": "column", "value": "customer_id" }, { "id": 4, "type": "table", "value": "order_items" }, { "id": 7, "type": "column", "value": "product_id" }, { "id": 5, "type": "table", "value": "products" }, { "id": 6, "type": "column", "value": "order_id" }, { "id": 2, "type": "column", "value": "Monitor" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [ 2 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 6 ] }, { "entity_id": 6, "token_idxs": [ 4 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "O", "B-COLUMN", "O", "B-TABLE", "B-COLUMN", "B-COLUMN", "O" ]
2,369
restaurant
bird:train.json:1775
In which region can you find the top 4 most popular restaurants?
SELECT T2.region FROM generalinfo AS T1 INNER JOIN geographic AS T2 ON T1.city = T2.city ORDER BY T1.review DESC LIMIT 4
[ "In", "which", "region", "can", "you", "find", "the", "top", "4", "most", "popular", "restaurants", "?" ]
[ { "id": 1, "type": "table", "value": "generalinfo" }, { "id": 2, "type": "table", "value": "geographic" }, { "id": 0, "type": "column", "value": "region" }, { "id": 3, "type": "column", "value": "review" }, { "id": 4, "type": "column", "value": "city" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
2,370
ship_1
spider:train_spider.json:6234
Find the name of captains whose rank are either Midshipman or Lieutenant.
SELECT name FROM captain WHERE rank = 'Midshipman' OR rank = 'Lieutenant'
[ "Find", "the", "name", "of", "captains", "whose", "rank", "are", "either", "Midshipman", "or", "Lieutenant", "." ]
[ { "id": 3, "type": "value", "value": "Midshipman" }, { "id": 4, "type": "value", "value": "Lieutenant" }, { "id": 0, "type": "table", "value": "captain" }, { "id": 1, "type": "column", "value": "name" }, { "id": 2, "type": "column", "value": "rank" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [ 9 ] }, { "entity_id": 4, "token_idxs": [ 11 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "B-COLUMN", "O", "O", "B-VALUE", "O", "B-VALUE", "O" ]
2,371
customers_and_addresses
spider:train_spider.json:6121
Find the customer name and date of the orders that have the status "Delivered".
SELECT t1.customer_name , t2.order_date FROM customers AS t1 JOIN customer_orders AS t2 ON t1.customer_id = t2.customer_id WHERE order_status = "Delivered"
[ "Find", "the", "customer", "name", "and", "date", "of", "the", "orders", "that", "have", "the", "status", "\"", "Delivered", "\"", "." ]
[ { "id": 3, "type": "table", "value": "customer_orders" }, { "id": 0, "type": "column", "value": "customer_name" }, { "id": 4, "type": "column", "value": "order_status" }, { "id": 6, "type": "column", "value": "customer_id" }, { "id": 1, "type": "column", "value": "order_date" }, { "id": 2, "type": "table", "value": "customers" }, { "id": 5, "type": "column", "value": "Delivered" } ]
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 8, 9 ] }, { "entity_id": 2, "token_idxs": [ 2 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 14 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-COLUMN", "O", "O" ]
2,372
cre_Docs_and_Epenses
spider:train_spider.json:6439
How many budget types do we have?
SELECT count(*) FROM Ref_budget_codes
[ "How", "many", "budget", "types", "do", "we", "have", "?" ]
[ { "id": 0, "type": "table", "value": "ref_budget_codes" } ]
[ { "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": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "O", "O" ]
2,373
book_press
bird:test.json:1995
Find the book series that have some book selling more than 1000 and some book less 500.
SELECT book_series FROM book WHERE sale_amount > 1000 INTERSECT SELECT book_series FROM book WHERE sale_amount < 500
[ "Find", "the", "book", "series", "that", "have", "some", "book", "selling", "more", "than", "1000", "and", "some", "book", "less", "500", "." ]
[ { "id": 1, "type": "column", "value": "book_series" }, { "id": 2, "type": "column", "value": "sale_amount" }, { "id": 0, "type": "table", "value": "book" }, { "id": 3, "type": "value", "value": "1000" }, { "id": 4, "type": "value", "value": "500" } ]
[ { "entity_id": 0, "token_idxs": [ 14 ] }, { "entity_id": 1, "token_idxs": [ 2, 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 11 ] }, { "entity_id": 4, "token_idxs": [ 16 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "B-TABLE", "O", "B-VALUE", "O" ]
2,374
e_learning
spider:train_spider.json:3774
List the addresses of all the course authors or tutors.
SELECT address_line_1 FROM Course_Authors_and_Tutors
[ "List", "the", "addresses", "of", "all", "the", "course", "authors", "or", "tutors", "." ]
[ { "id": 0, "type": "table", "value": "course_authors_and_tutors" }, { "id": 1, "type": "column", "value": "address_line_1" } ]
[ { "entity_id": 0, "token_idxs": [ 6, 7, 8, 9 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "I-TABLE", "I-TABLE", "I-TABLE", "O" ]
2,375
flight_1
spider:train_spider.json:390
What are the departure and arrival dates of all flights from LA to Honolulu?
SELECT departure_date , arrival_date FROM Flight WHERE origin = "Los Angeles" AND destination = "Honolulu"
[ "What", "are", "the", "departure", "and", "arrival", "dates", "of", "all", "flights", "from", "LA", "to", "Honolulu", "?" ]
[ { "id": 1, "type": "column", "value": "departure_date" }, { "id": 2, "type": "column", "value": "arrival_date" }, { "id": 4, "type": "column", "value": "Los Angeles" }, { "id": 5, "type": "column", "value": "destination" }, { "id": 6, "type": "column", "value": "Honolulu" }, { "id": 0, "type": "table", "value": "flight" }, { "id": 3, "type": "column", "value": "origin" } ]
[ { "entity_id": 0, "token_idxs": [ 9 ] }, { "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": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [ 13 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "O" ]
2,376
books
bird:train.json:5942
What is the average number of pages of David Coward's books?
SELECT AVG(T1.num_pages) FROM book AS T1 INNER JOIN book_author AS T2 ON T1.book_id = T2.book_id INNER JOIN author AS T3 ON T3.author_id = T2.author_id WHERE T3.author_name = 'David Coward'
[ "What", "is", "the", "average", "number", "of", "pages", "of", "David", "Coward", "'s", "books", "?" ]
[ { "id": 2, "type": "value", "value": "David Coward" }, { "id": 1, "type": "column", "value": "author_name" }, { "id": 5, "type": "table", "value": "book_author" }, { "id": 3, "type": "column", "value": "num_pages" }, { "id": 6, "type": "column", "value": "author_id" }, { "id": 7, "type": "column", "value": "book_id" }, { "id": 0, "type": "table", "value": "author" }, { "id": 4, "type": "table", "value": "book" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 8, 9 ] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [ 11 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "B-VALUE", "I-VALUE", "O", "B-TABLE", "O" ]
2,377
regional_sales
bird:train.json:2692
In which city is the store with the highest sales order unit price located?
SELECT T2.`City Name` FROM `Sales Orders` AS T1 INNER JOIN `Store Locations` AS T2 ON T2.StoreID = T1._StoreID WHERE REPLACE(T1.`Unit Price`, ',', '') = ( SELECT REPLACE(T1.`Unit Price`, ',', '') FROM `Sales Orders` AS T1 INNER JOIN `Store Locations` AS T2 ON T2.StoreID = T1._StoreID ORDER BY REPLACE(T1.`Unit Price`, ',', '') DESC LIMIT 1 ) ORDER BY REPLACE(T1.`Unit Price`, ',', '') DESC LIMIT 1
[ "In", "which", "city", "is", "the", "store", "with", "the", "highest", "sales", "order", "unit", "price", "located", "?" ]
[ { "id": 2, "type": "table", "value": "Store Locations" }, { "id": 1, "type": "table", "value": "Sales Orders" }, { "id": 5, "type": "column", "value": "Unit Price" }, { "id": 0, "type": "column", "value": "City Name" }, { "id": 4, "type": "column", "value": "_storeid" }, { "id": 3, "type": "column", "value": "storeid" }, { "id": 6, "type": "value", "value": "," } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 9, 10 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 11, 12 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "I-TABLE", "B-COLUMN", "I-COLUMN", "O", "O" ]
2,378
behavior_monitoring
spider:train_spider.json:3091
What are the start and end dates for incidents with incident type code "NOISE"?
SELECT date_incident_start , date_incident_end FROM Behavior_Incident WHERE incident_type_code = "NOISE"
[ "What", "are", "the", "start", "and", "end", "dates", "for", "incidents", "with", "incident", "type", "code", "\"", "NOISE", "\"", "?" ]
[ { "id": 1, "type": "column", "value": "date_incident_start" }, { "id": 3, "type": "column", "value": "incident_type_code" }, { "id": 0, "type": "table", "value": "behavior_incident" }, { "id": 2, "type": "column", "value": "date_incident_end" }, { "id": 4, "type": "column", "value": "NOISE" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 6, 7, 8 ] }, { "entity_id": 3, "token_idxs": [ 10, 11, 12 ] }, { "entity_id": 4, "token_idxs": [ 14 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "B-COLUMN", "O", "O" ]
2,379
flight_1
spider:train_spider.json:345
Show name and distance for all aircrafts.
SELECT name , distance FROM Aircraft
[ "Show", "name", "and", "distance", "for", "all", "aircrafts", "." ]
[ { "id": 0, "type": "table", "value": "aircraft" }, { "id": 2, "type": "column", "value": "distance" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [ 1 ] }, { "entity_id": 2, "token_idxs": [ 3 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "B-COLUMN", "O", "B-COLUMN", "O", "O", "B-TABLE", "O" ]
2,380
university
bird:train.json:8064
Provide the ranking criteria and scores in 2005 that were received by Harvard University.
SELECT T1.criteria_name, T2.score FROM ranking_criteria AS T1 INNER JOIN university_ranking_year AS T2 ON T1.id = T2.ranking_criteria_id INNER JOIN university AS T3 ON T3.id = T2.university_id WHERE T3.university_name = 'Harvard University' AND T2.year = 2005
[ "Provide", "the", "ranking", "criteria", "and", "scores", "in", "2005", "that", "were", "received", "by", "Harvard", "University", "." ]
[ { "id": 4, "type": "table", "value": "university_ranking_year" }, { "id": 11, "type": "column", "value": "ranking_criteria_id" }, { "id": 8, "type": "value", "value": "Harvard University" }, { "id": 3, "type": "table", "value": "ranking_criteria" }, { "id": 7, "type": "column", "value": "university_name" }, { "id": 0, "type": "column", "value": "criteria_name" }, { "id": 6, "type": "column", "value": "university_id" }, { "id": 2, "type": "table", "value": "university" }, { "id": 1, "type": "column", "value": "score" }, { "id": 9, "type": "column", "value": "year" }, { "id": 10, "type": "value", "value": "2005" }, { "id": 5, "type": "column", "value": "id" } ]
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [ 13 ] }, { "entity_id": 3, "token_idxs": [ 2 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [ 12 ] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [ 7 ] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-TABLE", "B-COLUMN", "O", "B-COLUMN", "O", "B-VALUE", "O", "O", "O", "O", "B-VALUE", "B-TABLE", "O" ]
2,381
network_2
spider:train_spider.json:4421
How old is each gender, on average?
SELECT avg(age) , gender FROM Person GROUP BY gender
[ "How", "old", "is", "each", "gender", ",", "on", "average", "?" ]
[ { "id": 0, "type": "table", "value": "person" }, { "id": 1, "type": "column", "value": "gender" }, { "id": 2, "type": "column", "value": "age" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O" ]
2,382
music_platform_2
bird:train.json:7930
Which podcast was reviewed the latest? State the date of creation, podcast tile and rating.
SELECT T1.podcast_id, T2.created_at, T2.title, T2.rating FROM podcasts AS T1 INNER JOIN reviews AS T2 ON T2.podcast_id = T1.podcast_id ORDER BY T2.created_at DESC LIMIT 1
[ "Which", "podcast", "was", "reviewed", "the", "latest", "?", "State", "the", "date", "of", "creation", ",", "podcast", "tile", "and", "rating", "." ]
[ { "id": 0, "type": "column", "value": "podcast_id" }, { "id": 1, "type": "column", "value": "created_at" }, { "id": 4, "type": "table", "value": "podcasts" }, { "id": 5, "type": "table", "value": "reviews" }, { "id": 3, "type": "column", "value": "rating" }, { "id": 2, "type": "column", "value": "title" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 11, 12 ] }, { "entity_id": 2, "token_idxs": [ 14 ] }, { "entity_id": 3, "token_idxs": [ 16 ] }, { "entity_id": 4, "token_idxs": [ 13 ] }, { "entity_id": 5, "token_idxs": [ 3 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "B-TABLE", "B-COLUMN", "O", "B-COLUMN", "O" ]
2,383
e_learning
spider:train_spider.json:3847
What are the login names used both by some course authors and some students?
SELECT login_name FROM Course_Authors_and_Tutors INTERSECT SELECT login_name FROM Students
[ "What", "are", "the", "login", "names", "used", "both", "by", "some", "course", "authors", "and", "some", "students", "?" ]
[ { "id": 0, "type": "table", "value": "course_authors_and_tutors" }, { "id": 2, "type": "column", "value": "login_name" }, { "id": 1, "type": "table", "value": "students" } ]
[ { "entity_id": 0, "token_idxs": [ 9, 10, 11 ] }, { "entity_id": 1, "token_idxs": [ 13 ] }, { "entity_id": 2, "token_idxs": [ 3, 4 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-TABLE", "I-TABLE", "I-TABLE", "O", "B-TABLE", "O" ]
2,384
workshop_paper
spider:train_spider.json:5843
Which authors did not submit to any workshop?
SELECT Author FROM submission WHERE Submission_ID NOT IN (SELECT Submission_ID FROM acceptance)
[ "Which", "authors", "did", "not", "submit", "to", "any", "workshop", "?" ]
[ { "id": 2, "type": "column", "value": "submission_id" }, { "id": 0, "type": "table", "value": "submission" }, { "id": 3, "type": "table", "value": "acceptance" }, { "id": 1, "type": "column", "value": "author" } ]
[ { "entity_id": 0, "token_idxs": [ 4, 5 ] }, { "entity_id": 1, "token_idxs": [ 1 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "B-COLUMN", "O", "O", "B-TABLE", "I-TABLE", "O", "O", "O" ]
2,385
thrombosis_prediction
bird:dev.json:1262
How many patients with a normal level of complement 3 have a P pattern observed in the sheet of ANA examination?
SELECT COUNT(DISTINCT T1.ID) FROM Examination AS T1 INNER JOIN Laboratory AS T2 ON T1.ID = T2.ID WHERE T2.C3 > 35 AND T1.`ANA Pattern` = 'P'
[ "How", "many", "patients", "with", "a", "normal", "level", "of", "complement", "3", "have", "a", "P", "pattern", "observed", "in", "the", "sheet", "of", "ANA", "examination", "?" ]
[ { "id": 0, "type": "table", "value": "examination" }, { "id": 5, "type": "column", "value": "ANA Pattern" }, { "id": 1, "type": "table", "value": "laboratory" }, { "id": 2, "type": "column", "value": "id" }, { "id": 3, "type": "column", "value": "c3" }, { "id": 4, "type": "value", "value": "35" }, { "id": 6, "type": "value", "value": "P" } ]
[ { "entity_id": 0, "token_idxs": [ 20 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 9 ] }, { "entity_id": 5, "token_idxs": [ 11, 13 ] }, { "entity_id": 6, "token_idxs": [ 12 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "B-COLUMN", "B-VALUE", "B-COLUMN", "O", "O", "O", "O", "O", "O", "B-TABLE", "O" ]
2,386
book_publishing_company
bird:train.json:199
What is the publisher's information of New Moon Books?
SELECT T1.pr_info FROM pub_info AS T1 INNER JOIN publishers AS T2 ON T1.pub_id = T2.pub_id WHERE T2.pub_name = 'New Moon Books'
[ "What", "is", "the", "publisher", "'s", "information", "of", "New", "Moon", "Books", "?" ]
[ { "id": 4, "type": "value", "value": "New Moon Books" }, { "id": 2, "type": "table", "value": "publishers" }, { "id": 1, "type": "table", "value": "pub_info" }, { "id": 3, "type": "column", "value": "pub_name" }, { "id": 0, "type": "column", "value": "pr_info" }, { "id": 5, "type": "column", "value": "pub_id" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 3, 4 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 7, 8, 9 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-TABLE", "I-TABLE", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O" ]
2,387
student_loan
bird:train.json:4397
How many male students have no due payments?
SELECT COUNT(T1.name) FROM no_payment_due AS T1 INNER JOIN male AS T2 ON T1.name = T2.name WHERE T1.bool = 'neg'
[ "How", "many", "male", "students", "have", "no", "due", "payments", "?" ]
[ { "id": 0, "type": "table", "value": "no_payment_due" }, { "id": 1, "type": "table", "value": "male" }, { "id": 2, "type": "column", "value": "bool" }, { "id": 4, "type": "column", "value": "name" }, { "id": 3, "type": "value", "value": "neg" } ]
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "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": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-TABLE", "O", "O", "O", "O", "B-TABLE", "O" ]
2,388
hr_1
spider:train_spider.json:3409
Display the first name, and department number for all employees whose last name is "McEwen".
SELECT first_name , department_id FROM employees WHERE last_name = 'McEwen'
[ "Display", "the", "first", "name", ",", "and", "department", "number", "for", "all", "employees", "whose", "last", "name", "is", "\"", "McEwen", "\"", "." ]
[ { "id": 2, "type": "column", "value": "department_id" }, { "id": 1, "type": "column", "value": "first_name" }, { "id": 0, "type": "table", "value": "employees" }, { "id": 3, "type": "column", "value": "last_name" }, { "id": 4, "type": "value", "value": "McEwen" } ]
[ { "entity_id": 0, "token_idxs": [ 10 ] }, { "entity_id": 1, "token_idxs": [ 2, 3 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [ 12, 13 ] }, { "entity_id": 4, "token_idxs": [ 16 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-VALUE", "O", "O" ]
2,389
movies_4
bird:train.json:554
How many adventure movies are there that were released in 2000?
SELECT COUNT(T1.movie_id) FROM movie AS T1 INNER JOIN movie_genres AS T2 ON T1.movie_id = T2.movie_id INNER JOIN genre AS T3 ON T2.genre_id = T3.genre_id WHERE T3.genre_name = 'Adventure' AND CAST(STRFTIME('%Y', T1.release_date) AS INT) = 2000
[ "How", "many", "adventure", "movies", "are", "there", "that", "were", "released", "in", "2000", "?" ]
[ { "id": 3, "type": "table", "value": "movie_genres" }, { "id": 9, "type": "column", "value": "release_date" }, { "id": 5, "type": "column", "value": "genre_name" }, { "id": 6, "type": "value", "value": "Adventure" }, { "id": 1, "type": "column", "value": "movie_id" }, { "id": 4, "type": "column", "value": "genre_id" }, { "id": 0, "type": "table", "value": "genre" }, { "id": 2, "type": "table", "value": "movie" }, { "id": 7, "type": "value", "value": "2000" }, { "id": 8, "type": "value", "value": "%Y" } ]
[ { "entity_id": 0, "token_idxs": [ 7 ] }, { "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": [] }, { "entity_id": 6, "token_idxs": [ 2 ] }, { "entity_id": 7, "token_idxs": [ 10 ] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [ 8 ] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-VALUE", "B-TABLE", "O", "O", "O", "B-TABLE", "B-COLUMN", "O", "B-VALUE", "O" ]
2,390
club_1
spider:train_spider.json:4272
Find all the male members of club "Hopkins Student Enterprises". Show the first name and last name.
SELECT t3.fname , t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Hopkins Student Enterprises" AND t3.sex = "M"
[ "Find", "all", "the", "male", "members", "of", "club", "\"", "Hopkins", "Student", "Enterprises", "\"", ".", "Show", "the", "first", "name", "and", "last", "name", "." ]
[ { "id": 7, "type": "column", "value": "Hopkins Student Enterprises" }, { "id": 4, "type": "table", "value": "member_of_club" }, { "id": 6, "type": "column", "value": "clubname" }, { "id": 2, "type": "table", "value": "student" }, { "id": 10, "type": "column", "value": "clubid" }, { "id": 0, "type": "column", "value": "fname" }, { "id": 1, "type": "column", "value": "lname" }, { "id": 5, "type": "column", "value": "stuid" }, { "id": 3, "type": "table", "value": "club" }, { "id": 8, "type": "column", "value": "sex" }, { "id": 9, "type": "column", "value": "M" } ]
[ { "entity_id": 0, "token_idxs": [ 19 ] }, { "entity_id": 1, "token_idxs": [ 16 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [ 4, 5 ] }, { "entity_id": 5, "token_idxs": [ 9 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [ 8, 10 ] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "B-TABLE", "I-TABLE", "B-TABLE", "O", "B-COLUMN", "B-COLUMN", "B-COLUMN", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O" ]
2,391
retail_complains
bird:train.json:345
What is the first name of clients who have the highest priority?
SELECT T1.first FROM client AS T1 INNER JOIN callcenterlogs AS T2 ON T1.client_id = T2.`rand client` WHERE T2.priority = ( SELECT MAX(priority) FROM callcenterlogs )
[ "What", "is", "the", "first", "name", "of", "clients", "who", "have", "the", "highest", "priority", "?" ]
[ { "id": 2, "type": "table", "value": "callcenterlogs" }, { "id": 5, "type": "column", "value": "rand client" }, { "id": 4, "type": "column", "value": "client_id" }, { "id": 3, "type": "column", "value": "priority" }, { "id": 1, "type": "table", "value": "client" }, { "id": 0, "type": "column", "value": "first" } ]
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 6 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 11 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 5 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "B-TABLE", "O", "O", "O", "O", "B-COLUMN", "O" ]
2,392
e_government
spider:train_spider.json:6312
Find the name of the most popular party form.
SELECT t1.form_name FROM forms AS t1 JOIN party_forms AS t2 ON t1.form_id = t2.form_id GROUP BY t2.form_id ORDER BY count(*) DESC LIMIT 1
[ "Find", "the", "name", "of", "the", "most", "popular", "party", "form", "." ]
[ { "id": 3, "type": "table", "value": "party_forms" }, { "id": 1, "type": "column", "value": "form_name" }, { "id": 0, "type": "column", "value": "form_id" }, { "id": 2, "type": "table", "value": "forms" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [ 7 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-TABLE", "B-TABLE", "O" ]
2,393
formula_1
bird:dev.json:995
What is the average score of Lewis Hamilton among all the Turkish Grand Prix?
SELECT AVG(T2.points) FROM drivers AS T1 INNER JOIN driverStandings AS T2 ON T1.driverId = T2.driverId INNER JOIN races AS T3 ON T3.raceId = T2.raceId WHERE T1.forename = 'Lewis' AND T1.surname = 'Hamilton' AND T3.name = 'Turkish Grand Prix'
[ "What", "is", "the", "average", "score", "of", "Lewis", "Hamilton", "among", "all", "the", "Turkish", "Grand", "Prix", "?" ]
[ { "id": 10, "type": "value", "value": "Turkish Grand Prix" }, { "id": 3, "type": "table", "value": "driverstandings" }, { "id": 5, "type": "column", "value": "forename" }, { "id": 8, "type": "value", "value": "Hamilton" }, { "id": 11, "type": "column", "value": "driverid" }, { "id": 2, "type": "table", "value": "drivers" }, { "id": 7, "type": "column", "value": "surname" }, { "id": 1, "type": "column", "value": "points" }, { "id": 4, "type": "column", "value": "raceid" }, { "id": 0, "type": "table", "value": "races" }, { "id": 6, "type": "value", "value": "Lewis" }, { "id": 9, "type": "column", "value": "name" } ]
[ { "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": 6, "token_idxs": [ 6 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [ 7 ] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [ 11, 12, 13 ] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "B-VALUE", "B-VALUE", "O", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O" ]
2,394
election
spider:train_spider.json:2783
Which county has the largest population? Give me the name of the county.
SELECT County_name FROM county ORDER BY Population DESC LIMIT 1
[ "Which", "county", "has", "the", "largest", "population", "?", "Give", "me", "the", "name", "of", "the", "county", "." ]
[ { "id": 1, "type": "column", "value": "county_name" }, { "id": 2, "type": "column", "value": "population" }, { "id": 0, "type": "table", "value": "county" } ]
[ { "entity_id": 0, "token_idxs": [ 1 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
2,395
simpson_episodes
bird:train.json:4176
List down all the roles of Matt Groening on the episode titled 'In the Name of the Grandfather' along with the episode number and series number.
SELECT T2.role, T1.episode, T1.number_in_series FROM Episode AS T1 INNER JOIN Credit AS T2 ON T1.episode_id = T2.episode_id WHERE T2.person = 'Matt Groening' AND T1.title = 'In the Name of the Grandfather';
[ "List", "down", "all", "the", "roles", "of", "Matt", "Groening", "on", "the", "episode", "titled", "'", "In", "the", "Name", "of", "the", "Grandfather", "'", "along", "with", "the", "episode", "number", "and", "series", "number", "." ]
[ { "id": 9, "type": "value", "value": "In the Name of the Grandfather" }, { "id": 2, "type": "column", "value": "number_in_series" }, { "id": 7, "type": "value", "value": "Matt Groening" }, { "id": 5, "type": "column", "value": "episode_id" }, { "id": 1, "type": "column", "value": "episode" }, { "id": 3, "type": "table", "value": "episode" }, { "id": 4, "type": "table", "value": "credit" }, { "id": 6, "type": "column", "value": "person" }, { "id": 8, "type": "column", "value": "title" }, { "id": 0, "type": "column", "value": "role" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 24, 25, 26 ] }, { "entity_id": 3, "token_idxs": [ 23 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [ 6, 7 ] }, { "entity_id": 8, "token_idxs": [ 11 ] }, { "entity_id": 9, "token_idxs": [ 13, 14, 15, 16, 17, 18 ] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "B-COLUMN", "O", "B-VALUE", "I-VALUE", "O", "O", "O", "B-COLUMN", "O", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O" ]
2,396
world_development_indicators
bird:train.json:2236
Which country's indicator for Adolescent fertility rate is the highest in 1960, please give its special notes.
SELECT DISTINCT T1.CountryCode, T1.SpecialNotes FROM Country AS T1 INNER JOIN Indicators AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Value = ( SELECT Value FROM Indicators WHERE IndicatorName = 'Adolescent fertility rate (births per 1,000 women ages 15-19)' AND Year = 1960 ORDER BY Value DESC LIMIT 1 )
[ "Which", "country", "'s", "indicator", "for", "Adolescent", "fertility", "rate", "is", "the", "highest", "in", "1960", ",", "please", "give", "its", "special", "notes", "." ]
[ { "id": 6, "type": "value", "value": "Adolescent fertility rate (births per 1,000 women ages 15-19)" }, { "id": 5, "type": "column", "value": "indicatorname" }, { "id": 1, "type": "column", "value": "specialnotes" }, { "id": 0, "type": "column", "value": "countrycode" }, { "id": 3, "type": "table", "value": "indicators" }, { "id": 2, "type": "table", "value": "country" }, { "id": 4, "type": "column", "value": "value" }, { "id": 7, "type": "column", "value": "year" }, { "id": 8, "type": "value", "value": "1960" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 17, 18 ] }, { "entity_id": 2, "token_idxs": [ 1 ] }, { "entity_id": 3, "token_idxs": [ 3 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [ 5, 6, 7, 8, 9, 10, 11 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [ 12 ] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "B-TABLE", "O", "B-TABLE", "O", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "B-VALUE", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O" ]
2,397
image_and_language
bird:train.json:7576
Calculate the percentage of object samples that are related to street lights.
SELECT CAST(SUM(CASE WHEN T2.OBJ_CLASS = 'street lights' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(T1.OBJ_SAMPLE_ID) FROM IMG_OBJ AS T1 INNER JOIN OBJ_CLASSES AS T2 ON T1.OBJ_CLASS_ID = T2.OBJ_CLASS_ID
[ "Calculate", "the", "percentage", "of", "object", "samples", "that", "are", "related", "to", "street", "lights", "." ]
[ { "id": 4, "type": "column", "value": "obj_sample_id" }, { "id": 8, "type": "value", "value": "street lights" }, { "id": 2, "type": "column", "value": "obj_class_id" }, { "id": 1, "type": "table", "value": "obj_classes" }, { "id": 7, "type": "column", "value": "obj_class" }, { "id": 0, "type": "table", "value": "img_obj" }, { "id": 3, "type": "value", "value": "100" }, { "id": 5, "type": "value", "value": "0" }, { "id": 6, "type": "value", "value": "1" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 4, 5 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [ 10, 11 ] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "O" ]
2,398
food_inspection_2
bird:train.json:6151
What is the assumed name of the business that has the highest total fine in 2014?
SELECT T.dba_name FROM ( SELECT T1.dba_name, SUM(T3.fine) FROM establishment AS T1 INNER JOIN inspection AS T2 ON T1.license_no = T2.license_no INNER JOIN violation AS T3 ON T2.inspection_id = T3.inspection_id WHERE strftime('%Y', T2.inspection_date) = '2014' GROUP BY T1.dba_name ORDER BY SUM(T3.fine) DESC LIMIT 1 ) AS T
[ "What", "is", "the", "assumed", "name", "of", "the", "business", "that", "has", "the", "highest", "total", "fine", "in", "2014", "?" ]
[ { "id": 8, "type": "column", "value": "inspection_date" }, { "id": 4, "type": "table", "value": "establishment" }, { "id": 6, "type": "column", "value": "inspection_id" }, { "id": 5, "type": "table", "value": "inspection" }, { "id": 9, "type": "column", "value": "license_no" }, { "id": 1, "type": "table", "value": "violation" }, { "id": 0, "type": "column", "value": "dba_name" }, { "id": 2, "type": "value", "value": "2014" }, { "id": 3, "type": "column", "value": "fine" }, { "id": 7, "type": "value", "value": "%Y" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 15 ] }, { "entity_id": 3, "token_idxs": [ 13 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 14 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "B-TABLE", "B-VALUE", "O" ]
2,399
airline
bird:train.json:5843
How many flights from American Airlines were cancelled due to a type A cancellation code?
SELECT COUNT(*) FROM Airlines AS T1 INNER JOIN `Air Carriers` AS T2 ON T1.OP_CARRIER_AIRLINE_ID = T2.Code WHERE T1.CANCELLATION_CODE = 'A' AND T2.Description = 'American Airlines Inc.: AA' AND T1.CANCELLED = 1
[ "How", "many", "flights", "from", "American", "Airlines", "were", "cancelled", "due", "to", "a", "type", "A", "cancellation", "code", "?" ]
[ { "id": 7, "type": "value", "value": "American Airlines Inc.: AA" }, { "id": 2, "type": "column", "value": "op_carrier_airline_id" }, { "id": 4, "type": "column", "value": "cancellation_code" }, { "id": 1, "type": "table", "value": "Air Carriers" }, { "id": 6, "type": "column", "value": "description" }, { "id": 8, "type": "column", "value": "cancelled" }, { "id": 0, "type": "table", "value": "airlines" }, { "id": 3, "type": "column", "value": "code" }, { "id": 5, "type": "value", "value": "A" }, { "id": 9, "type": "value", "value": "1" } ]
[ { "entity_id": 0, "token_idxs": [ 5 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 14 ] }, { "entity_id": 4, "token_idxs": [ 13 ] }, { "entity_id": 5, "token_idxs": [ 10 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [ 4 ] }, { "entity_id": 8, "token_idxs": [ 7 ] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "B-VALUE", "B-TABLE", "O", "B-COLUMN", "O", "O", "B-VALUE", "O", "O", "B-COLUMN", "B-COLUMN", "O" ]
2,400
codebase_comments
bird:train.json:580
What is the average processed time of the solution paths inside the "https://github.com/zphingphong/DiscardCustomerApp.git"?
SELECT CAST(SUM(T2.ProcessedTime) AS REAL) / COUNT(T2.RepoId) FROM Repo AS T1 INNER JOIN Solution AS T2 ON T1.Id = T2.RepoId WHERE T1.Url = 'https://github.com/zphingphong/DiscardCustomerApp.git'
[ "What", "is", "the", "average", "processed", "time", "of", "the", "solution", "paths", "inside", "the", "\"", "https://github.com/zphingphong/DiscardCustomerApp.git", "\"", "?" ]
[ { "id": 3, "type": "value", "value": "https://github.com/zphingphong/DiscardCustomerApp.git" }, { "id": 6, "type": "column", "value": "processedtime" }, { "id": 1, "type": "table", "value": "solution" }, { "id": 5, "type": "column", "value": "repoid" }, { "id": 0, "type": "table", "value": "repo" }, { "id": 2, "type": "column", "value": "url" }, { "id": 4, "type": "column", "value": "id" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 8 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 13 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [ 4, 5 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-VALUE", "O", "O" ]
2,401
world_development_indicators
bird:train.json:2154
List out the series code and country code of the poor countries that located in Latin American & Carribbean.
SELECT T2.SeriesCode, T2.CountryCode FROM Country AS T1 INNER JOIN CountryNotes AS T2 ON T1.CountryCode = T2.Countrycode WHERE T1.Region = 'Latin America & Caribbean' AND t1.incomegroup = 'Low income'
[ "List", "out", "the", "series", "code", "and", "country", "code", "of", "the", "poor", "countries", "that", "located", "in", "Latin", "American", "&", "Carribbean", "." ]
[ { "id": 5, "type": "value", "value": "Latin America & Caribbean" }, { "id": 3, "type": "table", "value": "countrynotes" }, { "id": 1, "type": "column", "value": "countrycode" }, { "id": 6, "type": "column", "value": "incomegroup" }, { "id": 0, "type": "column", "value": "seriescode" }, { "id": 7, "type": "value", "value": "Low income" }, { "id": 2, "type": "table", "value": "country" }, { "id": 4, "type": "column", "value": "region" } ]
[ { "entity_id": 0, "token_idxs": [ 3, 4 ] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [ 11 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 15, 16, 17, 18 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "I-VALUE", "O" ]
2,402
toxicology
bird:dev.json:265
List down the molecule id for non carcinogenic molecules.
SELECT T.molecule_id FROM molecule AS T WHERE T.label = '-'
[ "List", "down", "the", "molecule", "i", "d", "for", "non", "carcinogenic", "molecules", "." ]
[ { "id": 1, "type": "column", "value": "molecule_id" }, { "id": 0, "type": "table", "value": "molecule" }, { "id": 2, "type": "column", "value": "label" }, { "id": 3, "type": "value", "value": "-" } ]
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "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": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-TABLE", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O" ]
2,403
beer_factory
bird:train.json:5339
How many bottles of beer have been bought by Jim Breech?
SELECT COUNT(T3.ContainerType) FROM customers AS T1 INNER JOIN `transaction` AS T2 ON T2.CustomerID = T1.CustomerID INNER JOIN rootbeer AS T3 ON T3.RootBeerID = T2.RootBeerID WHERE T3.ContainerType = 'Bottle' AND T1.First = 'Jim' AND T1.Last = 'Breech'
[ "How", "many", "bottles", "of", "beer", "have", "been", "bought", "by", "Jim", "Breech", "?" ]
[ { "id": 1, "type": "column", "value": "containertype" }, { "id": 3, "type": "table", "value": "transaction" }, { "id": 4, "type": "column", "value": "rootbeerid" }, { "id": 10, "type": "column", "value": "customerid" }, { "id": 2, "type": "table", "value": "customers" }, { "id": 0, "type": "table", "value": "rootbeer" }, { "id": 5, "type": "value", "value": "Bottle" }, { "id": 9, "type": "value", "value": "Breech" }, { "id": 6, "type": "column", "value": "first" }, { "id": 8, "type": "column", "value": "last" }, { "id": 7, "type": "value", "value": "Jim" } ]
[ { "entity_id": 0, "token_idxs": [ 3, 4 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 2 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [ 9 ] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [ 10 ] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-VALUE", "B-TABLE", "I-TABLE", "O", "O", "O", "O", "B-VALUE", "B-VALUE", "O" ]
2,404
hr_1
spider:train_spider.json:3512
What are total salaries and department id for each department that has more than 2 employees?
SELECT department_id , SUM(salary) FROM employees GROUP BY department_id HAVING count(*) >= 2
[ "What", "are", "total", "salaries", "and", "department", "i", "d", "for", "each", "department", "that", "has", "more", "than", "2", "employees", "?" ]
[ { "id": 1, "type": "column", "value": "department_id" }, { "id": 0, "type": "table", "value": "employees" }, { "id": 3, "type": "column", "value": "salary" }, { "id": 2, "type": "value", "value": "2" } ]
[ { "entity_id": 0, "token_idxs": [ 16 ] }, { "entity_id": 1, "token_idxs": [ 5, 6, 7 ] }, { "entity_id": 2, "token_idxs": [ 15 ] }, { "entity_id": 3, "token_idxs": [ 3 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "B-TABLE", "O" ]
2,405
soccer_2016
bird:train.json:1791
How many players are from Australia?
SELECT COUNT(CASE WHEN T2.Country_Name = 'Australia' THEN T1.Player_Id ELSE NULL END) FROM Player AS T1 INNER JOIN Country AS T2 ON T1.Country_Name = T2.Country_Id
[ "How", "many", "players", "are", "from", "Australia", "?" ]
[ { "id": 2, "type": "column", "value": "country_name" }, { "id": 3, "type": "column", "value": "country_id" }, { "id": 4, "type": "column", "value": "player_id" }, { "id": 5, "type": "value", "value": "Australia" }, { "id": 1, "type": "table", "value": "country" }, { "id": 0, "type": "table", "value": "player" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 5 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-TABLE", "O", "O", "B-VALUE", "O" ]
2,406
college_completion
bird:train.json:3692
Compare the graduate cohort for Auburn University from 2011 to 2013?
SELECT SUM(CASE WHEN T2.year = 2011 THEN T2.grad_cohort ELSE 0 END), SUM(CASE WHEN T2.year = 2012 THEN T2.grad_cohort ELSE 0 END), SUM(CASE WHEN T2.year = 2013 THEN T2.grad_cohort ELSE 0 END) FROM institution_details AS T1 INNER JOIN institution_grads AS T2 ON T1.unitid = T2.unitid WHERE T2.gender = 'B' AND T2.race = 'X' AND T1.chronname = 'Auburn University'
[ "Compare", "the", "graduate", "cohort", "for", "Auburn", "University", "from", "2011", "to", "2013", "?" ]
[ { "id": 0, "type": "table", "value": "institution_details" }, { "id": 1, "type": "table", "value": "institution_grads" }, { "id": 8, "type": "value", "value": "Auburn University" }, { "id": 10, "type": "column", "value": "grad_cohort" }, { "id": 7, "type": "column", "value": "chronname" }, { "id": 2, "type": "column", "value": "unitid" }, { "id": 3, "type": "column", "value": "gender" }, { "id": 5, "type": "column", "value": "race" }, { "id": 11, "type": "column", "value": "year" }, { "id": 12, "type": "value", "value": "2011" }, { "id": 13, "type": "value", "value": "2012" }, { "id": 14, "type": "value", "value": "2013" }, { "id": 4, "type": "value", "value": "B" }, { "id": 6, "type": "value", "value": "X" }, { "id": 9, "type": "value", "value": "0" } ]
[ { "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": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [ 5, 6 ] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [ 2, 3 ] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [ 8 ] }, { "entity_id": 14, "token_idxs": [ 10 ] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-VALUE", "I-VALUE", "O", "B-VALUE", "O", "B-VALUE", "O" ]
2,407
chicago_crime
bird:train.json:8616
How many different neighborhoods are there in Roseland community?
SELECT SUM(CASE WHEN T1.community_area_name = 'Roseland' THEN 1 ELSE 0 END) FROM Community_Area AS T1 INNER JOIN Neighborhood AS T2 ON T1.community_area_no = T2.community_area_no
[ "How", "many", "different", "neighborhoods", "are", "there", "in", "Roseland", "community", "?" ]
[ { "id": 5, "type": "column", "value": "community_area_name" }, { "id": 2, "type": "column", "value": "community_area_no" }, { "id": 0, "type": "table", "value": "community_area" }, { "id": 1, "type": "table", "value": "neighborhood" }, { "id": 6, "type": "value", "value": "Roseland" }, { "id": 3, "type": "value", "value": "0" }, { "id": 4, "type": "value", "value": "1" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [ 7 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-TABLE", "O", "O", "O", "B-VALUE", "B-TABLE", "O" ]
2,408
social_media
bird:train.json:831
State the country where the most positive sentiment tweets were posted.
SELECT T.Country FROM ( SELECT T2.Country, SUM(T1.Sentiment) AS num FROM twitter AS T1 INNER JOIN location AS T2 ON T1.LocationID = T2.LocationID WHERE T1.Sentiment > 0 GROUP BY T2.Country ) T ORDER BY T.num DESC LIMIT 1
[ "State", "the", "country", "where", "the", "most", "positive", "sentiment", "tweets", "were", "posted", "." ]
[ { "id": 6, "type": "column", "value": "locationid" }, { "id": 4, "type": "column", "value": "sentiment" }, { "id": 3, "type": "table", "value": "location" }, { "id": 0, "type": "column", "value": "country" }, { "id": 2, "type": "table", "value": "twitter" }, { "id": 1, "type": "column", "value": "num" }, { "id": 5, "type": "value", "value": "0" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 7 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O" ]
2,409
movie_3
bird:train.json:9239
List the titles of the films starred by Elvis Marx.
SELECT T3.title FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id WHERE T3.length BETWEEN 110 AND 150 AND T1.first_name = 'Russell' AND T1.last_name = 'Close'
[ "List", "the", "titles", "of", "the", "films", "starred", "by", "Elvis", "Marx", "." ]
[ { "id": 3, "type": "table", "value": "film_actor" }, { "id": 8, "type": "column", "value": "first_name" }, { "id": 10, "type": "column", "value": "last_name" }, { "id": 12, "type": "column", "value": "actor_id" }, { "id": 4, "type": "column", "value": "film_id" }, { "id": 9, "type": "value", "value": "Russell" }, { "id": 5, "type": "column", "value": "length" }, { "id": 0, "type": "column", "value": "title" }, { "id": 2, "type": "table", "value": "actor" }, { "id": 11, "type": "value", "value": "Close" }, { "id": 1, "type": "table", "value": "film" }, { "id": 6, "type": "value", "value": "110" }, { "id": 7, "type": "value", "value": "150" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "O" ]
2,410
bike_share_1
bird:train.json:9068
Among the bike trips started on the days with a fog in 2013, how many of those trips started from the station "2nd at Townsend"?
SELECT COUNT(T1.start_station_name) FROM trip AS T1 INNER JOIN weather AS T2 ON T2.zip_code = T1.zip_code WHERE T2.date LIKE '%2013%' AND T2.events = 'Fog' AND T1.start_station_name = '2nd at Townsend' AND T2.zip_code = 94107
[ "Among", "the", "bike", "trips", "started", "on", "the", "days", "with", "a", "fog", "in", "2013", ",", "how", "many", "of", "those", "trips", "started", "from", "the", "station", "\"", "2nd", "at", "Townsend", "\"", "?" ]
[ { "id": 2, "type": "column", "value": "start_station_name" }, { "id": 8, "type": "value", "value": "2nd at Townsend" }, { "id": 3, "type": "column", "value": "zip_code" }, { "id": 1, "type": "table", "value": "weather" }, { "id": 5, "type": "value", "value": "%2013%" }, { "id": 6, "type": "column", "value": "events" }, { "id": 9, "type": "value", "value": "94107" }, { "id": 0, "type": "table", "value": "trip" }, { "id": 4, "type": "column", "value": "date" }, { "id": 7, "type": "value", "value": "Fog" } ]
[ { "entity_id": 0, "token_idxs": [ 3 ] }, { "entity_id": 1, "token_idxs": [ 1 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 25 ] }, { "entity_id": 5, "token_idxs": [ 12 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [ 10 ] }, { "entity_id": 8, "token_idxs": [ 24, 26 ] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "B-TABLE", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "B-COLUMN", "B-VALUE", "O", "O" ]
2,411
wrestler
spider:train_spider.json:1875
Which locations are shared by more than two wrestlers?
SELECT LOCATION FROM wrestler GROUP BY LOCATION HAVING COUNT(*) > 2
[ "Which", "locations", "are", "shared", "by", "more", "than", "two", "wrestlers", "?" ]
[ { "id": 0, "type": "table", "value": "wrestler" }, { "id": 1, "type": "column", "value": "location" }, { "id": 2, "type": "value", "value": "2" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 1 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "B-TABLE", "O" ]
2,412
customers_and_invoices
spider:train_spider.json:1584
Return the average, minimum, maximum, and total transaction amounts.
SELECT avg(transaction_amount) , min(transaction_amount) , max(transaction_amount) , sum(transaction_amount) FROM Financial_transactions
[ "Return", "the", "average", ",", "minimum", ",", "maximum", ",", "and", "total", "transaction", "amounts", "." ]
[ { "id": 0, "type": "table", "value": "financial_transactions" }, { "id": 1, "type": "column", "value": "transaction_amount" } ]
[ { "entity_id": 0, "token_idxs": [ 8, 9 ] }, { "entity_id": 1, "token_idxs": [ 10, 11 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "I-TABLE", "B-COLUMN", "I-COLUMN", "O" ]
2,413
california_schools
bird:dev.json:67
What is the total amount of Community College District closure in 1989 in the city of San Francisco?
SELECT COUNT(School) FROM schools WHERE strftime('%Y', ClosedDate) = '1989' AND City = 'San Francisco' AND DOCType = 'Community College District'
[ "What", "is", "the", "total", "amount", "of", "Community", "College", "District", "closure", "in", "1989", "in", "the", "city", "of", "San", "Francisco", "?" ]
[ { "id": 6, "type": "value", "value": "Community College District" }, { "id": 4, "type": "value", "value": "San Francisco" }, { "id": 8, "type": "column", "value": "closeddate" }, { "id": 0, "type": "table", "value": "schools" }, { "id": 5, "type": "column", "value": "doctype" }, { "id": 1, "type": "column", "value": "school" }, { "id": 2, "type": "value", "value": "1989" }, { "id": 3, "type": "column", "value": "city" }, { "id": 7, "type": "value", "value": "%Y" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 11 ] }, { "entity_id": 3, "token_idxs": [ 14 ] }, { "entity_id": 4, "token_idxs": [ 16, 17 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [ 6, 7, 8 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [ 9 ] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "B-COLUMN", "O", "B-VALUE", "O", "O", "B-COLUMN", "O", "B-VALUE", "I-VALUE", "O" ]
2,415
cre_Students_Information_Systems
bird:test.json:443
List the details of the teachers who teach some class whose detail has the substring 'data' but do not teach a class whose detail contains the prefix 'net'
SELECT T1.teacher_details FROM Teachers AS T1 JOIN Classes AS T2 ON T1.teacher_id = T2.teacher_id WHERE T2.class_details LIKE '%data%' EXCEPT SELECT T1.teacher_details FROM Teachers AS T1 JOIN Classes AS T2 ON T1.teacher_id = T2.teacher_id WHERE T2.class_details LIKE 'net%'
[ "List", "the", "details", "of", "the", "teachers", "who", "teach", "some", "class", "whose", "detail", "has", "the", "substring", "'", "data", "'", "but", "do", "not", "teach", "a", "class", "whose", "detail", "contains", "the", "prefix", "'", "net", "'" ]
[ { "id": 0, "type": "column", "value": "teacher_details" }, { "id": 3, "type": "column", "value": "class_details" }, { "id": 6, "type": "column", "value": "teacher_id" }, { "id": 1, "type": "table", "value": "teachers" }, { "id": 2, "type": "table", "value": "classes" }, { "id": 4, "type": "value", "value": "%data%" }, { "id": 5, "type": "value", "value": "net%" } ]
[ { "entity_id": 0, "token_idxs": [ 1, 2 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [ 23 ] }, { "entity_id": 3, "token_idxs": [ 24, 25 ] }, { "entity_id": 4, "token_idxs": [ 16 ] }, { "entity_id": 5, "token_idxs": [ 30 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "B-VALUE", "O" ]
2,416
formula_1
spider:train_spider.json:2211
What is the id and last name of the driver who participated in the most races after 2010?
SELECT T1.driverid , T1.surname FROM drivers AS T1 JOIN results AS T2 ON T1.driverid = T2.driverid JOIN races AS T3 ON T2.raceid = T3.raceid WHERE T3.year > 2010 GROUP BY T1.driverid ORDER BY count(*) DESC LIMIT 1
[ "What", "is", "the", "i", "d", "and", "last", "name", "of", "the", "driver", "who", "participated", "in", "the", "most", "races", "after", "2010", "?" ]
[ { "id": 0, "type": "column", "value": "driverid" }, { "id": 1, "type": "column", "value": "surname" }, { "id": 5, "type": "table", "value": "drivers" }, { "id": 6, "type": "table", "value": "results" }, { "id": 7, "type": "column", "value": "raceid" }, { "id": 2, "type": "table", "value": "races" }, { "id": 3, "type": "column", "value": "year" }, { "id": 4, "type": "value", "value": "2010" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [ 16 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 18 ] }, { "entity_id": 5, "token_idxs": [ 10 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "B-TABLE", "O", "B-VALUE", "O" ]
2,418
retail_complains
bird:train.json:360
Write down the date received of complaints sent via Fax.
SELECT T1.`Date received` FROM callcenterlogs AS T1 INNER JOIN events AS T2 ON T1.`Complaint ID` = T2.`Complaint ID` WHERE T2.`Submitted via` = 'Fax'
[ "Write", "down", "the", "date", "received", "of", "complaints", "sent", "via", "Fax", "." ]
[ { "id": 1, "type": "table", "value": "callcenterlogs" }, { "id": 0, "type": "column", "value": "Date received" }, { "id": 3, "type": "column", "value": "Submitted via" }, { "id": 5, "type": "column", "value": "Complaint ID" }, { "id": 2, "type": "table", "value": "events" }, { "id": 4, "type": "value", "value": "Fax" } ]
[ { "entity_id": 0, "token_idxs": [ 3, 4 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 9 ] }, { "entity_id": 5, "token_idxs": [ 6 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "B-COLUMN", "B-TABLE", "O", "B-VALUE", "O" ]
2,419
olympics
bird:train.json:5007
What is Vijay Singh Chauhan's region name?
SELECT T1.region_name FROM noc_region AS T1 INNER JOIN person_region AS T2 ON T1.id = T2.region_id INNER JOIN person AS T3 ON T2.person_id = T3.id WHERE T3.full_name = 'Vijay Singh Chauhan'
[ "What", "is", "Vijay", "Singh", "Chauhan", "'s", "region", "name", "?" ]
[ { "id": 3, "type": "value", "value": "Vijay Singh Chauhan" }, { "id": 5, "type": "table", "value": "person_region" }, { "id": 0, "type": "column", "value": "region_name" }, { "id": 4, "type": "table", "value": "noc_region" }, { "id": 2, "type": "column", "value": "full_name" }, { "id": 6, "type": "column", "value": "person_id" }, { "id": 8, "type": "column", "value": "region_id" }, { "id": 1, "type": "table", "value": "person" }, { "id": 7, "type": "column", "value": "id" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [ 2, 3, 4 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 5 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [ 6 ] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "B-TABLE", "B-COLUMN", "B-COLUMN", "O" ]
2,420
university_basketball
spider:train_spider.json:1001
Find the total student enrollment for different affiliation type schools.
SELECT sum(enrollment) , affiliation FROM university GROUP BY affiliation
[ "Find", "the", "total", "student", "enrollment", "for", "different", "affiliation", "type", "schools", "." ]
[ { "id": 1, "type": "column", "value": "affiliation" }, { "id": 0, "type": "table", "value": "university" }, { "id": 2, "type": "column", "value": "enrollment" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 7 ] }, { "entity_id": 2, "token_idxs": [ 4 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "O" ]
2,421
works_cycles
bird:train.json:7327
Name the sales person for store Area Bike Accessories. Which territory is he / she in?
SELECT T4.Name FROM Store AS T1 INNER JOIN SalesPerson AS T2 ON T1.SalesPersonID = T2.BusinessEntityID INNER JOIN Person AS T3 ON T2.BusinessEntityID = T3.BusinessEntityID INNER JOIN SalesTerritory AS T4 ON T2.TerritoryID = T4.TerritoryID WHERE T1.Name = 'Area Bike Accessories'
[ "Name", "the", "sales", "person", "for", "store", "Area", "Bike", "Accessories", ".", "Which", "territory", "is", "he", "/", "she", "in", "?" ]
[ { "id": 2, "type": "value", "value": "Area Bike Accessories" }, { "id": 7, "type": "column", "value": "businessentityid" }, { "id": 1, "type": "table", "value": "salesterritory" }, { "id": 8, "type": "column", "value": "salespersonid" }, { "id": 4, "type": "column", "value": "territoryid" }, { "id": 6, "type": "table", "value": "salesperson" }, { "id": 3, "type": "table", "value": "person" }, { "id": 5, "type": "table", "value": "store" }, { "id": 0, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 0 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 6, 7, 8 ] }, { "entity_id": 3, "token_idxs": [ 3 ] }, { "entity_id": 4, "token_idxs": [ 11 ] }, { "entity_id": 5, "token_idxs": [ 5 ] }, { "entity_id": 6, "token_idxs": [ 2 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "B-COLUMN", "O", "B-TABLE", "B-TABLE", "O", "B-TABLE", "B-VALUE", "I-VALUE", "I-VALUE", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O" ]
2,422
retail_complains
bird:train.json:289
List by their ID number the 3 longest complaints.
SELECT `Complaint ID` FROM callcenterlogs ORDER BY ser_time DESC LIMIT 3
[ "List", "by", "their", "ID", "number", "the", "3", "longest", "complaints", "." ]
[ { "id": 0, "type": "table", "value": "callcenterlogs" }, { "id": 1, "type": "column", "value": "Complaint ID" }, { "id": 2, "type": "column", "value": "ser_time" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 8 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O" ]
2,423
news_report
spider:train_spider.json:2815
Show the names of journalists that have reported more than one event.
SELECT T3.Name FROM news_report AS T1 JOIN event AS T2 ON T1.Event_ID = T2.Event_ID JOIN journalist AS T3 ON T1.journalist_ID = T3.journalist_ID GROUP BY T3.Name HAVING COUNT(*) > 1
[ "Show", "the", "names", "of", "journalists", "that", "have", "reported", "more", "than", "one", "event", "." ]
[ { "id": 5, "type": "column", "value": "journalist_id" }, { "id": 3, "type": "table", "value": "news_report" }, { "id": 1, "type": "table", "value": "journalist" }, { "id": 6, "type": "column", "value": "event_id" }, { "id": 4, "type": "table", "value": "event" }, { "id": 0, "type": "column", "value": "name" }, { "id": 2, "type": "value", "value": "1" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 7 ] }, { "entity_id": 4, "token_idxs": [ 11 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "O", "B-TABLE", "O", "O", "B-TABLE", "O", "O", "O", "B-TABLE", "O" ]
2,424
superstore
bird:train.json:2375
How much is the total quantity of items from the East region shipped on 3/25/2015? Name the products.
SELECT SUM(T1.Quantity), T2.`Product Name` FROM east_superstore AS T1 INNER JOIN product AS T2 ON T1.`Product ID` = T2.`Product ID` WHERE T1.`Ship Date` = '2015-03-25' AND T2.Region = 'East'
[ "How", "much", "is", "the", "total", "quantity", "of", "items", "from", "the", "East", "region", "shipped", "on", "3/25/2015", "?", "Name", "the", "products", "." ]
[ { "id": 1, "type": "table", "value": "east_superstore" }, { "id": 0, "type": "column", "value": "Product Name" }, { "id": 4, "type": "column", "value": "Product ID" }, { "id": 6, "type": "value", "value": "2015-03-25" }, { "id": 5, "type": "column", "value": "Ship Date" }, { "id": 3, "type": "column", "value": "quantity" }, { "id": 2, "type": "table", "value": "product" }, { "id": 7, "type": "column", "value": "region" }, { "id": 8, "type": "value", "value": "East" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 18 ] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 12 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [ 11 ] }, { "entity_id": 8, "token_idxs": [ 10 ] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "B-VALUE", "B-COLUMN", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O" ]
2,425
product_catalog
spider:train_spider.json:339
How many products are there in the records?
SELECT count(*) FROM catalog_contents
[ "How", "many", "products", "are", "there", "in", "the", "records", "?" ]
[ { "id": 0, "type": "table", "value": "catalog_contents" } ]
[ { "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": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
2,427
book_1
bird:test.json:539
Show the book title corresponding to the book with the most number of orders.
SELECT T2.title FROM Books_Order AS T1 JOIN Book AS T2 ON T1.isbn = T2.isbn GROUP BY T1.isbn ORDER BY count(*) DESC LIMIT 1
[ "Show", "the", "book", "title", "corresponding", "to", "the", "book", "with", "the", "most", "number", "of", "orders", "." ]
[ { "id": 2, "type": "table", "value": "books_order" }, { "id": 1, "type": "column", "value": "title" }, { "id": 0, "type": "column", "value": "isbn" }, { "id": 3, "type": "table", "value": "book" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 12, 13 ] }, { "entity_id": 3, "token_idxs": [ 2 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "I-TABLE", "O" ]
2,428
university
bird:train.json:8045
What are the top three universities with the most international students?
SELECT DISTINCT T2.university_name FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id GROUP BY T2.university_name ORDER BY SUM(T1.num_students * T1.pct_international_students / 100) DESC LIMIT 3
[ "What", "are", "the", "top", "three", "universities", "with", "the", "most", "international", "students", "?" ]
[ { "id": 7, "type": "column", "value": "pct_international_students" }, { "id": 0, "type": "column", "value": "university_name" }, { "id": 1, "type": "table", "value": "university_year" }, { "id": 3, "type": "column", "value": "university_id" }, { "id": 6, "type": "column", "value": "num_students" }, { "id": 2, "type": "table", "value": "university" }, { "id": 5, "type": "value", "value": "100" }, { "id": 4, "type": "column", "value": "id" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [ 10 ] }, { "entity_id": 7, "token_idxs": [ 9 ] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "B-COLUMN", "O" ]
2,429
address
bird:train.json:5082
What is the total number of households in Arecibo county?
SELECT SUM(T1.households) FROM zip_data AS T1 INNER JOIN country AS T2 ON T1.zip_code = T2.zip_code WHERE T2.county = 'ARECIBO'
[ "What", "is", "the", "total", "number", "of", "households", "in", "Arecibo", "county", "?" ]
[ { "id": 4, "type": "column", "value": "households" }, { "id": 0, "type": "table", "value": "zip_data" }, { "id": 5, "type": "column", "value": "zip_code" }, { "id": 1, "type": "table", "value": "country" }, { "id": 3, "type": "value", "value": "ARECIBO" }, { "id": 2, "type": "column", "value": "county" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 9 ] }, { "entity_id": 3, "token_idxs": [ 8 ] }, { "entity_id": 4, "token_idxs": [ 6 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "B-VALUE", "B-COLUMN", "O" ]
2,430
book_1
bird:test.json:568
What are the titles of books that have a sale price equal to the lowest sale price across all books ?
select title from book order by saleprice asc limit 1
[ "What", "are", "the", "titles", "of", "books", "that", "have", "a", "sale", "price", "equal", "to", "the", "lowest", "sale", "price", "across", "all", "books", "?" ]
[ { "id": 2, "type": "column", "value": "saleprice" }, { "id": 1, "type": "column", "value": "title" }, { "id": 0, "type": "table", "value": "book" } ]
[ { "entity_id": 0, "token_idxs": [ 19 ] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 15, 16 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "O" ]
2,431
product_catalog
spider:train_spider.json:310
Which catalog publishers have substring "Murray" in their names?
SELECT distinct(catalog_publisher) FROM catalogs WHERE catalog_publisher LIKE "%Murray%"
[ "Which", "catalog", "publishers", "have", "substring", "\"", "Murray", "\"", "in", "their", "names", "?" ]
[ { "id": 1, "type": "column", "value": "catalog_publisher" }, { "id": 0, "type": "table", "value": "catalogs" }, { "id": 2, "type": "column", "value": "%Murray%" } ]
[ { "entity_id": 0, "token_idxs": [ 1 ] }, { "entity_id": 1, "token_idxs": [ 2 ] }, { "entity_id": 2, "token_idxs": [ 6 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O" ]
2,432
language_corpus
bird:train.json:5725
How many total occurrences are there in the three-letter words?
SELECT SUM(occurrences) FROM words WHERE LENGTH(word) = 3
[ "How", "many", "total", "occurrences", "are", "there", "in", "the", "three", "-", "letter", "words", "?" ]
[ { "id": 2, "type": "column", "value": "occurrences" }, { "id": 0, "type": "table", "value": "words" }, { "id": 3, "type": "column", "value": "word" }, { "id": 1, "type": "value", "value": "3" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 3 ] }, { "entity_id": 3, "token_idxs": [ 11 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O" ]
2,433
chicago_crime
bird:train.json:8769
Which district commander was responsible for more incidents in January, 2018, Robert A. Rubio or Glenn White?
SELECT T1.commander FROM District AS T1 INNER JOIN Crime AS T2 ON T1.district_no = T2.district_no WHERE T1.commander IN ('Robert A. Rubio', 'Glenn White') AND SUBSTR(T2.date, 1, 1) = '1' AND SUBSTR(T2.date, 5, 4) = '2018' GROUP BY T1.commander
[ "Which", "district", "commander", "was", "responsible", "for", "more", "incidents", "in", "January", ",", "2018", ",", "Robert", "A.", "Rubio", "or", "Glenn", "White", "?" ]
[ { "id": 4, "type": "value", "value": "Robert A. Rubio" }, { "id": 3, "type": "column", "value": "district_no" }, { "id": 5, "type": "value", "value": "Glenn White" }, { "id": 0, "type": "column", "value": "commander" }, { "id": 1, "type": "table", "value": "district" }, { "id": 2, "type": "table", "value": "crime" }, { "id": 7, "type": "value", "value": "2018" }, { "id": 8, "type": "column", "value": "date" }, { "id": 6, "type": "value", "value": "1" }, { "id": 9, "type": "value", "value": "5" }, { "id": 10, "type": "value", "value": "4" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [ 1 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 13, 14, 15 ] }, { "entity_id": 5, "token_idxs": [ 17, 18 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [ 11 ] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "B-TABLE", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O", "B-VALUE", "I-VALUE", "O" ]
2,434
bakery_1
bird:test.json:1515
What is the receipt number and date of the receipt in which the most expensive item was bought?
SELECT T1.ReceiptNumber , T1.Date FROM receipts AS T1 JOIN items AS T2 ON T1.ReceiptNumber = T2.receipt JOIN goods AS T3 ON T2.item = T3.id ORDER BY T3.price DESC LIMIT 1
[ "What", "is", "the", "receipt", "number", "and", "date", "of", "the", "receipt", "in", "which", "the", "most", "expensive", "item", "was", "bought", "?" ]
[ { "id": 0, "type": "column", "value": "receiptnumber" }, { "id": 4, "type": "table", "value": "receipts" }, { "id": 8, "type": "column", "value": "receipt" }, { "id": 2, "type": "table", "value": "goods" }, { "id": 3, "type": "column", "value": "price" }, { "id": 5, "type": "table", "value": "items" }, { "id": 1, "type": "column", "value": "date" }, { "id": 6, "type": "column", "value": "item" }, { "id": 7, "type": "column", "value": "id" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "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": [] }, { "entity_id": 6, "token_idxs": [ 15 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [ 3 ] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-COLUMN", "B-COLUMN", "O", "B-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O" ]
2,435
mondial_geo
bird:train.json:8393
In which country is the city of Grozny? Give the full name of the country.
SELECT T1.Name FROM country AS T1 INNER JOIN province AS T2 ON T1.Code = T2.Country INNER JOIN city AS T3 ON T3.Province = T2.Name WHERE T3.Name = 'Grozny'
[ "In", "which", "country", "is", "the", "city", "of", "Grozny", "?", "Give", "the", "full", "name", "of", "the", "country", "." ]
[ { "id": 4, "type": "table", "value": "province" }, { "id": 5, "type": "column", "value": "province" }, { "id": 3, "type": "table", "value": "country" }, { "id": 7, "type": "column", "value": "country" }, { "id": 2, "type": "value", "value": "Grozny" }, { "id": 0, "type": "column", "value": "name" }, { "id": 1, "type": "table", "value": "city" }, { "id": 6, "type": "column", "value": "code" } ]
[ { "entity_id": 0, "token_idxs": [ 12 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [ 2 ] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "B-VALUE", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O" ]
2,436
music_1
spider:train_spider.json:3616
What is the id of every song that has a resolution higher than that of a song with a rating below 8?
SELECT f_id FROM song WHERE resolution > (SELECT max(resolution) FROM song WHERE rating < 8)
[ "What", "is", "the", "i", "d", "of", "every", "song", "that", "has", "a", "resolution", "higher", "than", "that", "of", "a", "song", "with", "a", "rating", "below", "8", "?" ]
[ { "id": 2, "type": "column", "value": "resolution" }, { "id": 3, "type": "column", "value": "rating" }, { "id": 0, "type": "table", "value": "song" }, { "id": 1, "type": "column", "value": "f_id" }, { "id": 4, "type": "value", "value": "8" } ]
[ { "entity_id": 0, "token_idxs": [ 17 ] }, { "entity_id": 1, "token_idxs": [ 3, 4 ] }, { "entity_id": 2, "token_idxs": [ 11 ] }, { "entity_id": 3, "token_idxs": [ 20 ] }, { "entity_id": 4, "token_idxs": [ 22 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "B-COLUMN", "O", "B-VALUE", "O" ]
2,437
hockey
bird:train.json:7744
How many teams did the team with the most victories in 1915 play against? Indicate the name of the team who won the most games in 1915, as well as the names of the opposing team.
SELECT COUNT(DISTINCT oppID), T2.tmID, T2.oppID FROM Teams AS T1 INNER JOIN TeamVsTeam AS T2 ON T1.year = T2.year AND T1.tmID = T2.tmID WHERE T2.year = 1915 GROUP BY T2.tmID, T2.oppID ORDER BY SUM(T2.W) DESC LIMIT 1
[ "How", "many", "teams", "did", "the", "team", "with", "the", "most", "victories", "in", "1915", "play", "against", "?", "\n", "Indicate", "the", "name", "of", "the", "team", "who", "won", "the", "most", "games", "in", "1915", ",", "as", "well", "as", "the", "names", "of", "the", "opposing", "team", "." ]
[ { "id": 3, "type": "table", "value": "teamvsteam" }, { "id": 1, "type": "column", "value": "oppid" }, { "id": 2, "type": "table", "value": "teams" }, { "id": 0, "type": "column", "value": "tmid" }, { "id": 4, "type": "column", "value": "year" }, { "id": 5, "type": "value", "value": "1915" }, { "id": 6, "type": "column", "value": "w" } ]
[ { "entity_id": 0, "token_idxs": [ 2, 3 ] }, { "entity_id": 1, "token_idxs": [ 37 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 20, 21 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 11 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "O", "B-VALUE", "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "I-TABLE", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O" ]
2,438
retail_world
bird:train.json:6389
List the name, address, and phone number of companies that supply products for more than thirty dollars per unit.
SELECT T2.CompanyName, T2.Address, T2.Phone FROM Products AS T1 INNER JOIN Suppliers AS T2 ON T1.SupplierID = T2.SupplierID WHERE T1.UnitPrice > 30
[ "List", "the", "name", ",", "address", ",", "and", "phone", "number", "of", "companies", "that", "supply", "products", "for", "more", "than", "thirty", "dollars", "per", "unit", "." ]
[ { "id": 0, "type": "column", "value": "companyname" }, { "id": 7, "type": "column", "value": "supplierid" }, { "id": 4, "type": "table", "value": "suppliers" }, { "id": 5, "type": "column", "value": "unitprice" }, { "id": 3, "type": "table", "value": "products" }, { "id": 1, "type": "column", "value": "address" }, { "id": 2, "type": "column", "value": "phone" }, { "id": 6, "type": "value", "value": "30" } ]
[ { "entity_id": 0, "token_idxs": [ 10 ] }, { "entity_id": 1, "token_idxs": [ 4 ] }, { "entity_id": 2, "token_idxs": [ 7 ] }, { "entity_id": 3, "token_idxs": [ 13 ] }, { "entity_id": 4, "token_idxs": [ 12 ] }, { "entity_id": 5, "token_idxs": [ 20 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "O", "B-COLUMN", "O", "B-TABLE", "B-TABLE", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O" ]
2,439
book_1
bird:test.json:552
What are the names of all the clients, and the total amount of books ordered by each?
SELECT T2.name , sum(T3.amount) FROM Orders AS T1 JOIN Client AS T2 ON T1.idClient = T2.idClient JOIN Books_Order AS T3 ON T3.idOrder = T1.idOrder GROUP BY T1.idClient
[ "What", "are", "the", "names", "of", "all", "the", "clients", ",", "and", "the", "total", "amount", "of", "books", "ordered", "by", "each", "?" ]
[ { "id": 2, "type": "table", "value": "books_order" }, { "id": 0, "type": "column", "value": "idclient" }, { "id": 6, "type": "column", "value": "idorder" }, { "id": 3, "type": "column", "value": "amount" }, { "id": 4, "type": "table", "value": "orders" }, { "id": 5, "type": "table", "value": "client" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 3 ] }, { "entity_id": 2, "token_idxs": [ 14 ] }, { "entity_id": 3, "token_idxs": [ 12 ] }, { "entity_id": 4, "token_idxs": [ 15 ] }, { "entity_id": 5, "token_idxs": [ 7 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "B-COLUMN", "O", "B-TABLE", "B-TABLE", "O", "O", "O" ]
2,440
sales
bird:train.json:5386
Has Alex purchased product with id 498?
SELECT IIF(T1.ProductID = 498, 'YES', 'NO') FROM Sales AS T1 INNER JOIN Customers AS T2 ON T1.CustomerID = T2.CustomerID WHERE T2.FirstName = 'Alex'
[ "Has", "Alex", "purchased", "product", "with", "i", "d", "498", "?" ]
[ { "id": 6, "type": "column", "value": "customerid" }, { "id": 1, "type": "table", "value": "customers" }, { "id": 2, "type": "column", "value": "firstname" }, { "id": 7, "type": "column", "value": "productid" }, { "id": 0, "type": "table", "value": "sales" }, { "id": 3, "type": "value", "value": "Alex" }, { "id": 4, "type": "value", "value": "YES" }, { "id": 8, "type": "value", "value": "498" }, { "id": 5, "type": "value", "value": "NO" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 1 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [ 3 ] }, { "entity_id": 8, "token_idxs": [ 7 ] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "B-VALUE", "O", "B-COLUMN", "O", "O", "O", "B-VALUE", "O" ]
2,441
cre_Drama_Workshop_Groups
spider:train_spider.json:5103
What are the minimum, average, and maximum quantities ordered? Check all the invoices.
SELECT min(Order_Quantity) , avg(Order_Quantity) , max(Order_Quantity) FROM INVOICES
[ "What", "are", "the", "minimum", ",", "average", ",", "and", "maximum", "quantities", "ordered", "?", "Check", "all", "the", "invoices", "." ]
[ { "id": 1, "type": "column", "value": "order_quantity" }, { "id": 0, "type": "table", "value": "invoices" } ]
[ { "entity_id": 0, "token_idxs": [ 15 ] }, { "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": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "O", "O", "B-TABLE", "O" ]
2,443
student_loan
bird:train.json:4560
How many female students have enlisted for the Army?
SELECT SUM(IIF(T3.name IS NULL, 1, 0)) AS "result" FROM enlist AS T1 INNER JOIN person AS T2 ON T1.name = T2.name LEFT JOIN male AS T3 ON T2.name = T3.name WHERE T1.organ = 'army'
[ "How", "many", "female", "students", "have", "enlisted", "for", "the", "Army", "?" ]
[ { "id": 3, "type": "table", "value": "enlist" }, { "id": 4, "type": "table", "value": "person" }, { "id": 1, "type": "column", "value": "organ" }, { "id": 0, "type": "table", "value": "male" }, { "id": 2, "type": "value", "value": "army" }, { "id": 5, "type": "column", "value": "name" }, { "id": 6, "type": "value", "value": "1" }, { "id": 7, "type": "value", "value": "0" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 8 ] }, { "entity_id": 3, "token_idxs": [ 5 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-TABLE", "O", "O", "B-TABLE", "O", "O", "B-VALUE", "O" ]
2,444
insurance_and_eClaims
spider:train_spider.json:1531
Find the names of the customers who have an deputy policy.
SELECT DISTINCT t2.customer_details FROM policies AS t1 JOIN customers AS t2 ON t1.customer_id = t2.customer_id WHERE t1.policy_type_code = "Deputy"
[ "Find", "the", "names", "of", "the", "customers", "who", "have", "an", "deputy", "policy", "." ]
[ { "id": 0, "type": "column", "value": "customer_details" }, { "id": 3, "type": "column", "value": "policy_type_code" }, { "id": 5, "type": "column", "value": "customer_id" }, { "id": 2, "type": "table", "value": "customers" }, { "id": 1, "type": "table", "value": "policies" }, { "id": 4, "type": "column", "value": "Deputy" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 10 ] }, { "entity_id": 2, "token_idxs": [ 5 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 9 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "B-TABLE", "O", "O", "O", "B-COLUMN", "B-TABLE", "O" ]
2,445
works_cycles
bird:train.json:7276
Among the sales with a tax applied to retail transaction, how many of them are charged by multiple types of taxes?
SELECT COUNT(SalesTaxRateID) FROM SalesTaxRate WHERE Name LIKE '%+%'
[ "Among", "the", "sales", "with", "a", "tax", "applied", "to", "retail", "transaction", ",", "how", "many", "of", "them", "are", "charged", "by", "multiple", "types", "of", "taxes", "?" ]
[ { "id": 3, "type": "column", "value": "salestaxrateid" }, { "id": 0, "type": "table", "value": "salestaxrate" }, { "id": 1, "type": "column", "value": "name" }, { "id": 2, "type": "value", "value": "%+%" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 3, 4, 5, 6 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-TABLE", "B-COLUMN", "I-COLUMN", "I-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O" ]
2,446
image_and_language
bird:train.json:7484
Please list all the predicted relation classes of object sample no.14 in image no.1.
SELECT T1.PRED_CLASS FROM PRED_CLASSES AS T1 INNER JOIN IMG_REL AS T2 ON T1.PRED_CLASS_ID = T2.PRED_CLASS_ID WHERE T2.OBJ1_SAMPLE_ID = 14 AND T2.OBJ2_SAMPLE_ID = 14
[ "Please", "list", "all", "the", "predicted", "relation", "classes", "of", "object", "sample", "no.14", "in", "image", "no.1", "." ]
[ { "id": 4, "type": "column", "value": "obj1_sample_id" }, { "id": 6, "type": "column", "value": "obj2_sample_id" }, { "id": 3, "type": "column", "value": "pred_class_id" }, { "id": 1, "type": "table", "value": "pred_classes" }, { "id": 0, "type": "column", "value": "pred_class" }, { "id": 2, "type": "table", "value": "img_rel" }, { "id": 5, "type": "value", "value": "14" } ]
[ { "entity_id": 0, "token_idxs": [ 6 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 12 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [ 8, 9 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "B-COLUMN", "I-COLUMN", "O", "O", "B-TABLE", "O", "O" ]
2,447
customers_and_orders
bird:test.json:295
What is the customer id, name, phone, and email for the customer with most orders?
SELECT T1.customer_id , T2.customer_name , T2.customer_phone , T2.customer_email FROM Customer_orders AS T1 JOIN Customers AS T2 ON T1.customer_id = T2.customer_id GROUP BY T1.customer_id ORDER BY count(*) DESC LIMIT 1
[ "What", "is", "the", "customer", "i", "d", ",", "name", ",", "phone", ",", "and", "email", "for", "the", "customer", "with", "most", "orders", "?" ]
[ { "id": 4, "type": "table", "value": "customer_orders" }, { "id": 2, "type": "column", "value": "customer_phone" }, { "id": 3, "type": "column", "value": "customer_email" }, { "id": 1, "type": "column", "value": "customer_name" }, { "id": 0, "type": "column", "value": "customer_id" }, { "id": 5, "type": "table", "value": "customers" } ]
[ { "entity_id": 0, "token_idxs": [ 4, 5 ] }, { "entity_id": 1, "token_idxs": [ 6, 7 ] }, { "entity_id": 2, "token_idxs": [ 15 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 16, 17, 18 ] }, { "entity_id": 5, "token_idxs": [ 3 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-TABLE", "B-COLUMN", "I-COLUMN", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "B-TABLE", "I-TABLE", "I-TABLE", "O" ]
2,448
retails
bird:train.json:6688
Among all the customers, what is the percentage of the customer's nation being Germany?
SELECT CAST(SUM(IIF(T2.n_name = 'GERMANY', 1, 0)) AS REAL) * 100 / COUNT(T1.c_custkey) FROM customer AS T1 INNER JOIN nation AS T2 ON T1.c_nationkey = T2.n_nationkey
[ "Among", "all", "the", "customers", ",", "what", "is", "the", "percentage", "of", "the", "customer", "'s", "nation", "being", "Germany", "?" ]
[ { "id": 2, "type": "column", "value": "c_nationkey" }, { "id": 3, "type": "column", "value": "n_nationkey" }, { "id": 5, "type": "column", "value": "c_custkey" }, { "id": 0, "type": "table", "value": "customer" }, { "id": 9, "type": "value", "value": "GERMANY" }, { "id": 1, "type": "table", "value": "nation" }, { "id": 8, "type": "column", "value": "n_name" }, { "id": 4, "type": "value", "value": "100" }, { "id": 6, "type": "value", "value": "1" }, { "id": 7, "type": "value", "value": "0" } ]
[ { "entity_id": 0, "token_idxs": [ 11 ] }, { "entity_id": 1, "token_idxs": [ 13 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [ 15 ] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "O", "B-TABLE", "O", "B-VALUE", "O" ]
2,449
customers_card_transactions
spider:train_spider.json:674
Give the full name and phone of the customer who has the account name 162.
SELECT T2.customer_first_name , T2.customer_last_name , T2.customer_phone FROM Accounts AS T1 JOIN Customers AS T2 ON T1.customer_id = T2.customer_id WHERE T1.account_name = "162"
[ "Give", "the", "full", "name", "and", "phone", "of", "the", "customer", "who", "has", "the", "account", "name", "162", "." ]
[ { "id": 0, "type": "column", "value": "customer_first_name" }, { "id": 1, "type": "column", "value": "customer_last_name" }, { "id": 2, "type": "column", "value": "customer_phone" }, { "id": 5, "type": "column", "value": "account_name" }, { "id": 7, "type": "column", "value": "customer_id" }, { "id": 4, "type": "table", "value": "customers" }, { "id": 3, "type": "table", "value": "accounts" }, { "id": 6, "type": "column", "value": "162" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [ 10, 11 ] }, { "entity_id": 2, "token_idxs": [ 9 ] }, { "entity_id": 3, "token_idxs": [ 12 ] }, { "entity_id": 4, "token_idxs": [ 8 ] }, { "entity_id": 5, "token_idxs": [ 13 ] }, { "entity_id": 6, "token_idxs": [ 14 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "O", "O", "B-TABLE", "B-COLUMN", "B-COLUMN", "I-COLUMN", "B-TABLE", "B-COLUMN", "B-COLUMN", "O" ]
2,450
works_cycles
bird:train.json:7315
What is the job title of the oldest employee in the company? In which department is he in?
SELECT T2.JobTitle, T4.Name FROM Person AS T1 INNER JOIN Employee AS T2 ON T1.BusinessEntityID = T2.BusinessEntityID INNER JOIN EmployeeDepartmentHistory AS T3 ON T2.BusinessEntityID = T3.BusinessEntityID INNER JOIN Department AS T4 ON T3.DepartmentID = T4.DepartmentID ORDER BY T2.HireDate LIMIT 1
[ "What", "is", "the", "job", "title", "of", "the", "oldest", "employee", "in", "the", "company", "?", "In", "which", "department", "is", "he", "in", "?" ]
[ { "id": 4, "type": "table", "value": "employeedepartmenthistory" }, { "id": 8, "type": "column", "value": "businessentityid" }, { "id": 5, "type": "column", "value": "departmentid" }, { "id": 2, "type": "table", "value": "department" }, { "id": 0, "type": "column", "value": "jobtitle" }, { "id": 3, "type": "column", "value": "hiredate" }, { "id": 7, "type": "table", "value": "employee" }, { "id": 6, "type": "table", "value": "person" }, { "id": 1, "type": "column", "value": "name" } ]
[ { "entity_id": 0, "token_idxs": [ 3, 4 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 15 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 16 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [ 8 ] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "B-TABLE", "O", "O", "O", "O", "O", "O", "B-TABLE", "B-TABLE", "O", "O", "O" ]
2,451
superhero
bird:dev.json:798
What is the publisher for Hawkman, Karate Kid and Speedy?
SELECT T2.publisher_name FROM superhero AS T1 INNER JOIN publisher AS T2 ON T1.publisher_id = T2.id WHERE T1.superhero_name IN ('Hawkman', 'Karate Kid', 'Speedy')
[ "What", "is", "the", "publisher", "for", "Hawkman", ",", "Karate", "Kid", "and", "Speedy", "?" ]
[ { "id": 0, "type": "column", "value": "publisher_name" }, { "id": 3, "type": "column", "value": "superhero_name" }, { "id": 7, "type": "column", "value": "publisher_id" }, { "id": 5, "type": "value", "value": "Karate Kid" }, { "id": 1, "type": "table", "value": "superhero" }, { "id": 2, "type": "table", "value": "publisher" }, { "id": 4, "type": "value", "value": "Hawkman" }, { "id": 6, "type": "value", "value": "Speedy" }, { "id": 8, "type": "column", "value": "id" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 3 ] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 5 ] }, { "entity_id": 5, "token_idxs": [ 7 ] }, { "entity_id": 6, "token_idxs": [ 10 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [ 8 ] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "B-TABLE", "O", "B-VALUE", "O", "B-VALUE", "B-COLUMN", "O", "B-VALUE", "O" ]
2,452
retail_world
bird:train.json:6506
In 1996, how many orders were from customers in the UK?
SELECT COUNT(T1.CustomerID) FROM Customers AS T1 INNER JOIN Orders AS T2 ON T1.CustomerID = T2.CustomerID WHERE STRFTIME('%Y', T2.OrderDate) = '1996' AND T1.Country = 'UK'
[ "In", "1996", ",", "how", "many", "orders", "were", "from", "customers", "in", "the", "UK", "?" ]
[ { "id": 2, "type": "column", "value": "customerid" }, { "id": 0, "type": "table", "value": "customers" }, { "id": 7, "type": "column", "value": "orderdate" }, { "id": 4, "type": "column", "value": "country" }, { "id": 1, "type": "table", "value": "orders" }, { "id": 3, "type": "value", "value": "1996" }, { "id": 5, "type": "value", "value": "UK" }, { "id": 6, "type": "value", "value": "%Y" } ]
[ { "entity_id": 0, "token_idxs": [ 8 ] }, { "entity_id": 1, "token_idxs": [ 5 ] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 1 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 11 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "B-VALUE", "O", "O", "O", "B-TABLE", "O", "O", "B-TABLE", "O", "O", "B-VALUE", "O" ]
2,453
beer_factory
bird:train.json:5278
How many Henry Weinhard's were bought by Nicholas Sparks?
SELECT COUNT(T1.CustomerID) FROM customers AS T1 INNER JOIN `transaction` AS T2 ON T1.CustomerID = T2.CustomerID INNER JOIN rootbeer AS T3 ON T2.RootBeerID = T3.RootBeerID INNER JOIN rootbeerbrand AS T4 ON T3.BrandID = T4.BrandID WHERE T1.First = 'Nicholas' AND T1.Last = 'Sparks' AND T4.BrandName LIKE 'Henry Weinhard%s'
[ "How", "many", "Henry", "Weinhard", "'s", "were", "bought", "by", "Nicholas", "Sparks", "?" ]
[ { "id": 9, "type": "value", "value": "Henry Weinhard%s" }, { "id": 0, "type": "table", "value": "rootbeerbrand" }, { "id": 11, "type": "table", "value": "transaction" }, { "id": 1, "type": "column", "value": "customerid" }, { "id": 12, "type": "column", "value": "rootbeerid" }, { "id": 8, "type": "column", "value": "brandname" }, { "id": 10, "type": "table", "value": "customers" }, { "id": 2, "type": "table", "value": "rootbeer" }, { "id": 5, "type": "value", "value": "Nicholas" }, { "id": 3, "type": "column", "value": "brandid" }, { "id": 7, "type": "value", "value": "Sparks" }, { "id": 4, "type": "column", "value": "first" }, { "id": 6, "type": "column", "value": "last" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 8 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [ 9 ] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [ 2, 3, 4 ] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-VALUE", "I-VALUE", "I-VALUE", "O", "O", "O", "B-VALUE", "B-VALUE", "O" ]
2,454
products_gen_characteristics
spider:train_spider.json:5566
Find the number of characteristics that the product "flax" has.
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 = "flax"
[ "Find", "the", "number", "of", "characteristics", "that", "the", "product", "\"", "flax", "\"", "has", "." ]
[ { "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": 6, "type": "column", "value": "product_id" }, { "id": 3, "type": "table", "value": "products" }, { "id": 2, "type": "column", "value": "flax" } ]
[ { "entity_id": 0, "token_idxs": [ 4 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 9 ] }, { "entity_id": 3, "token_idxs": [ 7 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "B-TABLE", "O", "O", "B-TABLE", "O", "B-COLUMN", "O", "O", "O" ]
2,455
music_1
spider:train_spider.json:3615
What is ids of the songs whose resolution is higher than the resolution of any songs with rating lower than 8?
SELECT f_id FROM song WHERE resolution > (SELECT max(resolution) FROM song WHERE rating < 8)
[ "What", "is", "ids", "of", "the", "songs", "whose", "resolution", "is", "higher", "than", "the", "resolution", "of", "any", "songs", "with", "rating", "lower", "than", "8", "?" ]
[ { "id": 2, "type": "column", "value": "resolution" }, { "id": 3, "type": "column", "value": "rating" }, { "id": 0, "type": "table", "value": "song" }, { "id": 1, "type": "column", "value": "f_id" }, { "id": 4, "type": "value", "value": "8" } ]
[ { "entity_id": 0, "token_idxs": [ 15 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 12 ] }, { "entity_id": 3, "token_idxs": [ 17 ] }, { "entity_id": 4, "token_idxs": [ 20 ] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-TABLE", "O", "B-COLUMN", "O", "O", "B-VALUE", "O" ]
2,456
advertising_agencies
bird:test.json:2136
Return the number of distinct staff who have attended a meeting?
SELECT count(DISTINCT staff_id) FROM Staff_in_meetings
[ "Return", "the", "number", "of", "distinct", "staff", "who", "have", "attended", "a", "meeting", "?" ]
[ { "id": 0, "type": "table", "value": "staff_in_meetings" }, { "id": 1, "type": "column", "value": "staff_id" } ]
[ { "entity_id": 0, "token_idxs": [ 9, 10 ] }, { "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": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "O", "B-TABLE", "I-TABLE", "O" ]
2,457
address
bird:train.json:5133
How many states are in the central time zone? Write their full names.
SELECT SUM(CASE WHEN T1.time_zone = 'Central' THEN 1 ELSE 0 END) AS count FROM zip_data AS T1 INNER JOIN state AS T2 ON T2.abbreviation = T1.state WHERE T1.time_zone = 'Central'
[ "How", "many", "states", "are", "in", "the", "central", "time", "zone", "?", "Write", "their", "full", "names", "." ]
[ { "id": 4, "type": "column", "value": "abbreviation" }, { "id": 2, "type": "column", "value": "time_zone" }, { "id": 0, "type": "table", "value": "zip_data" }, { "id": 3, "type": "value", "value": "Central" }, { "id": 1, "type": "table", "value": "state" }, { "id": 5, "type": "column", "value": "state" }, { "id": 6, "type": "value", "value": "0" }, { "id": 7, "type": "value", "value": "1" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [ 7, 8 ] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [ 2 ] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "O", "O", "O", "B-VALUE", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O" ]
2,458
works_cycles
bird:train.json:7462
List the locations ids, compartments and containers for the Lock Ring
SELECT T2.LocationID, T2.Shelf, T2.Bin FROM Product AS T1 INNER JOIN ProductInventory AS T2 ON T1.ProductID = T2.ProductID WHERE T1.Name LIKE 'Lock Ring'
[ "List", "the", "locations", "ids", ",", "compartments", "and", "containers", "for", "the", "Lock", "Ring" ]
[ { "id": 4, "type": "table", "value": "productinventory" }, { "id": 0, "type": "column", "value": "locationid" }, { "id": 6, "type": "value", "value": "Lock Ring" }, { "id": 7, "type": "column", "value": "productid" }, { "id": 3, "type": "table", "value": "product" }, { "id": 1, "type": "column", "value": "shelf" }, { "id": 5, "type": "column", "value": "name" }, { "id": 2, "type": "column", "value": "bin" } ]
[ { "entity_id": 0, "token_idxs": [ 2, 3 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [ 10, 11 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-COLUMN", "I-COLUMN", "O", "O", "O", "O", "O", "O", "B-VALUE", "I-VALUE" ]
2,459
cars
bird:train.json:3108
How many of the cars from Japan weighed less than 3000?
SELECT COUNT(*) FROM price AS T1 INNER JOIN production AS T2 ON T1.ID = T2.ID INNER JOIN country AS T3 ON T3.origin = T2.country INNER JOIN data AS T4 ON T4.ID = T1.ID WHERE T3.country = 'Japan' AND T4.weight < 3000
[ "How", "many", "of", "the", "cars", "from", "Japan", "weighed", "less", "than", "3000", "?" ]
[ { "id": 8, "type": "table", "value": "production" }, { "id": 1, "type": "table", "value": "country" }, { "id": 3, "type": "column", "value": "country" }, { "id": 5, "type": "column", "value": "weight" }, { "id": 9, "type": "column", "value": "origin" }, { "id": 4, "type": "value", "value": "Japan" }, { "id": 7, "type": "table", "value": "price" }, { "id": 0, "type": "table", "value": "data" }, { "id": 6, "type": "value", "value": "3000" }, { "id": 2, "type": "column", "value": "id" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [ 6 ] }, { "entity_id": 5, "token_idxs": [ 7 ] }, { "entity_id": 6, "token_idxs": [ 10 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "O", "O", "O", "O", "B-VALUE", "B-COLUMN", "O", "O", "B-VALUE", "O" ]
2,460
protein_institute
spider:train_spider.json:1910
How many buildings are there?
SELECT count(*) FROM building
[ "How", "many", "buildings", "are", "there", "?" ]
[ { "id": 0, "type": "table", "value": "building" } ]
[ { "entity_id": 0, "token_idxs": [ 2 ] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [] }, { "entity_id": 4, "token_idxs": [] }, { "entity_id": 5, "token_idxs": [] }, { "entity_id": 6, "token_idxs": [] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-TABLE", "O", "O", "O" ]
2,461
cs_semester
bird:train.json:863
Among the students who got a B in the course Machine Learning Theory, how many of them have a gpa of over 3?
SELECT COUNT(student_id) FROM registration WHERE grade = 'B' AND student_id IN ( SELECT student_id FROM student WHERE gpa > 3 AND course_id IN ( SELECT course_id FROM course WHERE name = 'Machine Learning Theory' ) )
[ "Among", "the", "students", "who", "got", "a", "B", "in", "the", "course", "Machine", "Learning", "Theory", ",", "how", "many", "of", "them", "have", "a", "gpa", "of", "over", "3", "?" ]
[ { "id": 10, "type": "value", "value": "Machine Learning Theory" }, { "id": 0, "type": "table", "value": "registration" }, { "id": 1, "type": "column", "value": "student_id" }, { "id": 7, "type": "column", "value": "course_id" }, { "id": 4, "type": "table", "value": "student" }, { "id": 8, "type": "table", "value": "course" }, { "id": 2, "type": "column", "value": "grade" }, { "id": 9, "type": "column", "value": "name" }, { "id": 5, "type": "column", "value": "gpa" }, { "id": 3, "type": "value", "value": "B" }, { "id": 6, "type": "value", "value": "3" } ]
[ { "entity_id": 0, "token_idxs": [] }, { "entity_id": 1, "token_idxs": [] }, { "entity_id": 2, "token_idxs": [] }, { "entity_id": 3, "token_idxs": [ 6 ] }, { "entity_id": 4, "token_idxs": [ 2 ] }, { "entity_id": 5, "token_idxs": [ 20 ] }, { "entity_id": 6, "token_idxs": [ 23 ] }, { "entity_id": 7, "token_idxs": [] }, { "entity_id": 8, "token_idxs": [ 9 ] }, { "entity_id": 9, "token_idxs": [] }, { "entity_id": 10, "token_idxs": [ 10, 11, 12 ] }, { "entity_id": 11, "token_idxs": [] }, { "entity_id": 12, "token_idxs": [] }, { "entity_id": 13, "token_idxs": [] }, { "entity_id": 14, "token_idxs": [] }, { "entity_id": 15, "token_idxs": [] }, { "entity_id": 16, "token_idxs": [] }, { "entity_id": 17, "token_idxs": [] }, { "entity_id": 18, "token_idxs": [] }, { "entity_id": 19, "token_idxs": [] } ]
[ "O", "O", "B-TABLE", "O", "O", "O", "B-VALUE", "O", "O", "B-TABLE", "B-VALUE", "I-VALUE", "I-VALUE", "O", "O", "O", "O", "O", "O", "O", "B-COLUMN", "O", "O", "B-VALUE", "O" ]