Database: cookbook
Question: Among all recipes containing cheese, what is the percentage of recipes with calories greater than 200?
Evidence: cheese is a category; calories greater than 200 refers to calories > 200; calculation = MULTIPLY(DIVIDE(COUNT(calories > 200 THEN recipe_id), COUNT(recipe_id)), 100)
SQL: SELECT CAST(SUM(CASE WHEN T4.calories > 200 THEN 1 ELSE 0 END) AS REAL) * 100 / 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 INNER JOIN Nutrition AS T4 ON T4.recipe_id = T1.recipe_id WHERE T3.category = 'cheese'

Database: world_development_indicators
Question: Please write down the footnote descriptions of Albania in 1981.
Evidence: Albania is the name of country where Country = 'Albania'
SQL: SELECT DISTINCT T1.Description FROM FootNotes AS T1 INNER JOIN Country AS T2 ON T1.Countrycode = T2.CountryCode WHERE T1.Year = 'YR1981' AND T2.ShortName = 'Albania'

Database: shooting
Question: Did the number of cases with Vehicle as subject weapon increase or decrease from year 2007 to 2008. State the difference.
Evidence: number of cases refers to count(case_number); with Vehicle as subject weapon refers to subject_weapon = 'Vehicle'; year 2007 refers to date between '2007-01-01' and '2007-12-31'; year 2008 refers to date between '2008-01-01' and '2008-12-31'
SQL: SELECT SUM(IIF(STRFTIME('%Y', date) = '2007', 1, 0)) - SUM(IIF(STRFTIME('%Y', date) = '2008', 1, 0)) FROM incidents WHERE subject_weapon = 'Vehicle'

Database: public_review_platform
Question: How many Yelp_Business under the category of "Food" are good for kids?
Evidence: under the category of "Food" refers to category_name = 'Food'; are good for kids refers to attribute_name = 'Good for Kids' and attribute_value = 'true'
SQL: SELECT COUNT(T3.stars) FROM Categories AS T1 INNER JOIN Business_Categories AS T2 ON T1.category_id = T2.category_id INNER JOIN Business AS T3 ON T2.business_id = T3.business_id INNER JOIN Business_Attributes AS T4 ON T3.business_id = T4.business_id INNER JOIN Attributes AS T5 ON T4.attribute_id = T5.attribute_id WHERE T1.category_name LIKE 'Food' AND T5.attribute_name LIKE 'Good for Kids' AND T4.attribute_value LIKE 'TRUE'

Database: simpson_episodes
Question: What is the title of episode nominated for WGA Award (TV) with votes greater than 1000?
Evidence: nominated refers to result = 'Nominee'; WGA Award (TV) refers to award_category = 'WGA Award (TV)'; votes greater than 1000 refers to votes > 1000
SQL: SELECT DISTINCT T2.title FROM Award AS T1 INNER JOIN Episode AS T2 ON T1.episode_id = T2.episode_id WHERE T2.votes > 1000 AND T1.award_category = 'WGA Award (TV)' AND T1.result = 'Nominee';

Database: law_episode
Question: Who played the role of the "president of NBC West Coast" in the first episode?
Evidence: who refers to name; the role of the "president of NBC West Coast" refers to role = 'president of NBC West Coast'; the first episode refers to episode = 1
SQL: SELECT T2.name FROM Credit AS T1 INNER JOIN Person AS T2 ON T2.person_id = T1.person_id INNER JOIN Episode AS T3 ON T1.episode_id = T3.episode_id WHERE T3.episode = 1 AND T1.role = 'president of NBC West Coast'

Database: retails
Question: What is the lowest supply cost for the part "hot spring dodger dim light"?
Evidence: the lowest supply cost refers to min(ps_supplycost); part "hot spring dodger dim light" refers to p_name = 'hot spring dodger dim light'
SQL: SELECT MIN(T1.ps_supplycost) FROM partsupp AS T1 INNER JOIN part AS T2 ON T1.ps_partkey = T2.p_partkey WHERE T2.p_name = 'hot spring dodger dim light'

Database: retail_world
Question: Please list any three order numbers that have been shipped using Speedy Express.
Evidence: Speedy Express is the name of the shipping company; three order numbers refer to OrderID LIMIT 3;
SQL: SELECT T1.OrderID FROM Orders AS T1 INNER JOIN Shippers AS T2 ON T1.ShipVia = T2.ShipperID WHERE T2.CompanyName = 'Speedy Express' LIMIT 3

Database: image_and_language
Question: What is the bounding box of "spoon" in image id 1344?
Evidence: the bounding box refers to X, Y, W, H from IMG_OBJ; image id 1344 refers to IMG_ID = 1344; "spoon" refers to OBJ_CLASS = 'spoon';
SQL: SELECT T1.X, T1.Y, T1.W, T1.H FROM IMG_OBJ AS T1 INNER JOIN OBJ_CLASSES AS T2 ON T1.OBJ_CLASS_ID = T2.OBJ_CLASS_ID WHERE T1.IMG_ID = 1344 AND T2.OBJ_CLASS = 'spoon'

Database: movie_3
Question: How many films are there under the category of "Horror"?
Evidence: "Horror" is the name of category
SQL: SELECT COUNT(T1.film_id) FROM film_category AS T1 INNER JOIN category AS T2 ON T1.category_id = T2.category_id WHERE T2.name = 'Horror'

Database: simpson_episodes
Question: What percentage of votes are from the nominated episodes?
Evidence: nominated episodes refers to result = 'Nominee'; percentage of votes = DIVIDE(SUM(result = 'Nominee), SUM(Votes)) as percentage
SQL: SELECT CAST(SUM(CASE WHEN T1.result = 'Nominee' THEN T2.votes ELSE 0 END) AS REAL) * 100 / SUM(T2.votes) FROM Award AS T1 INNER JOIN Episode AS T2 ON T1.episode_id = T2.episode_id;

Database: music_platform_2
Question: What is the average rating of podcasts in comedy category?
Evidence: comedy category refers to category = 'comedy'; average rating = Divide (Sum(rating), Count(podcast_id))
SQL: SELECT AVG(T2.rating) FROM categories AS T1 INNER JOIN reviews AS T2 ON T2.podcast_id = T1.podcast_id WHERE T1.category = 'comedy'

Database: shipping
Question: Where was the destination city of shipment no.1701?
Evidence: shipment no. 1701 refers to ship_id = 1701; destination city refers to city_name
SQL: SELECT T2.city_name FROM shipment AS T1 INNER JOIN city AS T2 ON T1.city_id = T2.city_id WHERE T1.ship_id = '1701'

Database: soccer_2016
Question: List down the match ID of matches that the "man of the match" award was given to BB McCullum.
SQL: SELECT T1.Match_Id FROM Match AS T1 INNER JOIN Player AS T2 ON T2.Player_Id = T1.Man_of_the_Match WHERE T2.Player_Name = 'BB McCullum'

Database: movies_4
Question: What are the genres of Sky Captain and the World of Tomorrow?
Evidence: genres refers to genre_name; Sky Captain and the World of Tomorrow refers to title = 'Sky Captain and the World of Tomorrow'
SQL: SELECT T3.genre_name 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 T1.title = 'Sky Captain and the World of Tomorrow'

Database: donor
Question: What is the total price including optional support received by the teacher who posted the essay titled "Recording Rockin' Readers"?
SQL: SELECT SUM(T1.total_price_including_optional_support) FROM projects AS T1 INNER JOIN essays AS T2 ON T1.projectid = T2.projectid WHERE T2.title = 'Recording Rockin'' Readers'

Database: student_loan
Question: List all the organisations of students who filed for bankcrupcy.
Evidence: organization refers to organ; students who filed for bankrupcy refers to file_for_bankrupcy.name
SQL: SELECT T2.organ FROM filed_for_bankrupcy AS T1 INNER JOIN enlist AS T2 ON T1.name = T2.name

Database: public_review_platform
Question: Among all closed businesses in Avondale, AZ what percent have obtained a 'wonderful experience' rating of the business.
Evidence: closed business refers to active = 'false'; in Avondale refers to city = 'Avondale'; 'wonderful experience' rating refers to stars > 3; percentage = divide(count(business_id where stars > 3), count(business_id))*100%
SQL: SELECT CAST(SUM(CASE WHEN stars > 3 THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(stars) FROM Business WHERE city = 'Avondale' AND active = 'false'