Database: olympics
Question: In the 2014 Winter game, what is the percentage of competitors who age 28 years old?
Evidence: DIVIDE(COUNT(age = 28), COUNT(id)) as percentage where games_name = '2014 Winter';
SQL: SELECT CAST(COUNT(CASE WHEN T2.age = 28 THEN 1 END) AS REAL) * 100 / COUNT(T2.person_id) FROM games AS T1 INNER JOIN games_competitor AS T2 ON T1.id = T2.games_id WHERE T1.games_name = '2014 Winter'

Database: simpson_episodes
Question: Which are the years that character Mr. Burns won an award?
SQL: SELECT DISTINCT T1.year FROM Award AS T1 INNER JOIN Character_Award AS T2 ON T1.award_id = T2.award_id WHERE T2.character = 'Mr. Burns';

Database: movie_3
Question: From 5/30/2005 at 3:43:54 AM to 7/31/2005 at 10:08:29 PM, how many times did Susan Wilson pay for film rentals?
Evidence: from 5/30/2005 at 3:43:54 AM to 7/31/2005 at 10:08:29 PM refers to payment_date between '2005-05-30 03:43:54' and '2005-07-31 10:08:29'
SQL: SELECT COUNT(T1.customer_id) FROM payment AS T1 INNER JOIN customer AS T2 ON T1.customer_id = T2.customer_id WHERE T1.payment_date BETWEEN '2005-05-30 03:43:54' AND '2005-07-31 10:08:29'

Database: simpson_episodes
Question: List out the title of episodes which have star score of 2.
Evidence: star score of 2 refers to stars = 2
SQL: SELECT T1.title FROM Episode AS T1 INNER JOIN Vote AS T2 ON T2.episode_id = T1.episode_id WHERE T2.stars = 2;

Database: retails
Question: Among the items shipped in 1994 via truck, how many items were returned?
Evidence: 1994 refers to year(l_shipdate) = 1994; via truck refers to l_shipmode = 'TRUCK'; returned refers to l_returnflag = 'R'
SQL: SELECT COUNT(l_orderkey) FROM lineitem WHERE STRFTIME('%Y', l_shipdate) = '1994' AND l_returnflag = 'R' AND l_shipmode = 'TRUCK'

Database: movie_platform
Question: Please give me the url of the movie "La Antena".
Evidence: movie La Antena refers to movie_title = 'La Antena'; url refers to movie_url;
SQL: SELECT movie_url FROM movies WHERE movie_title = 'La Antena'

Database: beer_factory
Question: What is the name of all the customers who have ever given a 5-star review?
Evidence: name of the customer = First, Last; 5-star review refers to StarRating = 5;
SQL: SELECT T1.First, T1.Last FROM customers AS T1 INNER JOIN rootbeerreview AS T2 ON T1.CustomerID = T2.CustomerID WHERE T2.StarRating = 5

Database: talkingdata
Question: Among the devices with an event occurring in 2016, how many of them are owned by a user in the M23-26 user group?
Evidence: in 2016 refers to year(timestamp) = 2016; M23-26 user group refers to `group` = 'M23-26';
SQL: SELECT COUNT(T1.device_id) FROM gender_age AS T1 INNER JOIN events AS T2 ON T1.device_id = T2.device_id WHERE STRFTIME('%Y', T2.timestamp) = '2016' AND T1.`group` = 'M23-26'

Database: soccer_2016
Question: How many matches are there in April, 2008?
Evidence: in April, 2008 refers to Match_date like '2008-04%'
SQL: SELECT COUNT(Match_Id) FROM Match WHERE Match_date LIKE '2008-04%'

Database: olympics
Question: Calculate the percentage of bronze medals won by men's basketball players.
Evidence: DIVIDE(COUNT(competitor_id where medal_name = 'Bronze'), COUNT(competitor_id)) as percentage where event_name = 'Basketball Men''s Basketball';
SQL: SELECT CAST(COUNT(CASE WHEN T4.medal_name = 'Bronze' THEN 1 ELSE NULL 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 INNER JOIN event AS T3 ON T1.event_id = T3.id INNER JOIN medal AS T4 ON T1.medal_id = T4.id WHERE T3.event_name LIKE 'Basketball Men%s Basketball'

Database: public_review_platform
Question: Among the elite users of 10 consecutive year from 2005 to 2014, list down the user ID and their number of compliment on photos.
Evidence: from 2005 to 2014 refers to year_id BETWEEN 2005 AND 2014; compliment_type = 'photos';
SQL: SELECT T2.user_id, T2.number_of_compliments FROM Compliments AS T1 INNER JOIN Users_Compliments AS T2 ON T1.compliment_id = T2.compliment_id INNER JOIN Elite AS T3 ON T2.user_id = T3.user_id WHERE T3.year_id BETWEEN 2005 AND 2014 AND T1.compliment_type = 'photos'

Database: world_development_indicators
Question: Please list the countries that got the footnote "Data are classified as official aid." on the series code DC.DAC.AUSL.CD in 2002.
Evidence: countries are the Countrycode; footnote refers to Description = 'Data are classified as official aid'
SQL: SELECT T1.SHORTNAME FROM Country AS T1 INNER JOIN FootNotes AS T2 ON T1.CountryCode = T2.Countrycode WHERE T2.Description = 'Data are classified as official aid.' AND T2.Seriescode = 'DC.DAC.AUSL.CD' AND T2.Year LIKE '%2002%'

Database: retail_complains
Question: List by name all customers who provided consent for the tag Older American.
Evidence: name refers to first; provided consent refers to "Consumer consent provided?" not in ('N/A', null, 'empty');
SQL: SELECT T1.first, T1.middle, T1.last FROM client AS T1 INNER JOIN events AS T2 ON T1.client_id = T2.Client_ID WHERE T2.Tags = 'Older American' AND T2.`Consumer consent provided?` != 'N/A' AND T2.`Consumer consent provided?` IS NOT NULL AND T2.`Consumer consent provided?` != ''

Database: mental_health_survey
Question: Please list all the questions in the mental health survey for 2014.
Evidence: mental health survey for 2014 refers to SurveyID = 2014
SQL: SELECT T2.questiontext FROM Answer AS T1 INNER JOIN Question AS T2 ON T1.QuestionID = T2.questionid INNER JOIN Survey AS T3 ON T1.SurveyID = T3.SurveyID WHERE T3.Description LIKE 'mental health survey for 2014' GROUP BY T2.questiontext

Database: olympics
Question: Calculate the bmi of the competitor id 147420.
Evidence: DIVIDE(weight), MULTIPLY(height, height) where id = 147420;
SQL: SELECT CAST(T1.weight AS REAL) / (T1.height * T1.height) FROM person AS T1 INNER JOIN games_competitor AS T2 ON T1.id = T2.person_id WHERE T2.id = 147420

Database: olympics
Question: What are the id of the games held in London?
Evidence: London refers to city_name = 'London';
SQL: SELECT T1.games_id FROM games_city AS T1 INNER JOIN city AS T2 ON T1.city_id = T2.id WHERE T2.city_name = 'London'

Database: soccer_2016
Question: List all the names of the winning team's players in the first match of season 1.
Evidence: names refers to Player_Name; winning team's refers to Match_Winner; first match of season 1 refers to Season_Id = 1 and min(Match_Date)
SQL: SELECT T3.Player_Name FROM `Match` AS T1 INNER JOIN Player_Match AS T2 ON T1.Match_Winner = T2.Team_Id INNER JOIN Player AS T3 ON T2.Player_Id = T3.Player_Id WHERE T1.Season_Id = 1 ORDER BY T1.Match_Date LIMIT 1

Database: address
Question: Provide the zip codes and the alias of Greeneville.
Evidence: Greeneville is the city;
SQL: SELECT T2.zip_code, T1.alias FROM alias AS T1 INNER JOIN zip_data AS T2 ON T1.zip_code = T2.zip_code WHERE T2.city = 'Greeneville'

Database: law_episode
Question: How many votes did the episode titled "Cherished" get in total?
Evidence: titled "Cherished" refers to title = 'Cherished'
SQL: SELECT SUM(T2.votes) FROM Episode AS T1 INNER JOIN Vote AS T2 ON T1.episode_id = T2.episode_id WHERE T1.title = 'Cherished'

Database: simpson_episodes
Question: Among the episodes aired in 2008 with votes ranges from 920 to 950, list their percent.
Evidence: aired in 2008 refers to air_date LIKE '2008%'; votes ranges from 920 to 950 refers to votes BETWEEN 920 AND 950
SQL: SELECT T2.percent FROM Episode AS T1 INNER JOIN Vote AS T2 ON T2.episode_id = T1.episode_id WHERE SUBSTR(T1.air_date, 1, 4) = '2008' AND T1.votes BETWEEN 950 AND 960;

Database: law_episode
Question: How many awards has Rene Balcer been nominated for?
SQL: SELECT COUNT(T2.award_id) FROM Person AS T1 INNER JOIN Award AS T2 ON T1.person_id = T2.person_id WHERE T1.name = 'Rene Balcer'