Database: software_company
Question: In male customers with an occupation handlers or cleaners, what is the percentage of customers with a true response?
Evidence: DIVIDE(COUNT(OCCUPATION = 'Handlers-cleaners', SEX = 'Male' and RESPONSE = 'true'), COUNT(OCCUPATION = 'Handlers-cleaners' and SEX = 'Male')) as percentage;
SQL: SELECT CAST(SUM(CASE WHEN T2.RESPONSE = 'true' THEN 1.0 ELSE 0 END) AS REAL) * 100 / COUNT(T2.REFID) FROM Customers AS T1 INNER JOIN Mailings1_2 AS T2 ON T1.ID = T2.REFID WHERE T1.OCCUPATION = 'Handlers-cleaners' AND T1.SEX = 'Male'

Database: synthea
Question: What is/are the ids of the tallest patient/s?
Evidence: id of the tallest patient/s refers to PATIENT from observations where MAX(DESCRIPTION = 'Body Height');
SQL: SELECT PATIENT FROM observations WHERE DESCRIPTION = 'Body Height' AND UNITS = 'cm' ORDER BY VALUE DESC LIMIT 1

Database: soccer_2016
Question: How many players got out by being stumped in the second innings of all matches?
Evidence: got out by being stumped refers to Out_Name = 'stumped'; the second innings refers to Innings_No = 2
SQL: SELECT SUM(CASE WHEN T1.Innings_No = 2 THEN 1 ELSE 0 END) FROM Wicket_Taken AS T1 INNER JOIN Out_Type AS T2 ON T2.Out_Id = T1.Kind_Out WHERE T2.Out_Name = 'stumped'

Database: talkingdata
Question: Among HTC Butterfly phone users, list any five devices' IDs used by females.
Evidence: HTC Butterfly refers to phone_brand = 'HTC' AND device_model = 'Butterfly'; females refers to gender = 'F';
SQL: SELECT T2.device_id FROM phone_brand_device_model2 AS T1 INNER JOIN gender_age AS T2 ON T2.device_id = T1.device_id WHERE T1.device_model = 'Butterfly' AND T2.gender = 'F' AND T1.phone_brand = 'HTC' LIMIT 5

Database: soccer_2016
Question: How many times did Yuvraj Singh receive the Man of the Match award?
Evidence: Yuvraj Singh refers to Player_Name = 'Yuvraj Singh'; receive the Man of the Match award refers to Player_Id = Man_of_the_Match
SQL: SELECT SUM(CASE WHEN T2.Player_Name = 'Yuvraj Singh' THEN 1 ELSE 0 END) FROM Match AS T1 INNER JOIN Player AS T2 ON T2.Player_Id = T1.Man_of_the_Match

Database: movies_4
Question: Provide the ID and ISO code of Belgium.
Evidence: ID refers to country_id; ISO code refers to country_iso_code; Belgium refers to country_name = 'Belgium'
SQL: SELECT COUNTry_id, COUNTry_iso_code FROM COUNTry WHERE COUNTry_name = 'Belgium'

Database: public_review_platform
Question: List the names of business in AZ with a rating of 5.
Evidence: AZ refers to state = 'AZ'; rating refers to stars;
SQL: SELECT business_id FROM Business WHERE state LIKE 'AZ' AND stars = 5

Database: movie_3
Question: Please give the full name of the customer who had made the biggest amount of payment in one single film rental.
Evidence: full name refers to first_name, last_name; the biggest amount refers to max(amount)
SQL: SELECT T2.first_name, T2.last_name FROM payment AS T1 INNER JOIN customer AS T2 ON T1.customer_id = T2.customer_id ORDER BY T1.amount DESC LIMIT 1

Database: cars
Question: Among the cars produced in year 1973, how many of the cars have horsepower less than 100?
Evidence: produced in year 1973 refers to model_year = 1973; have horsepower less than 100 refers to horsepower < 100
SQL: SELECT COUNT(*) FROM data AS T1 INNER JOIN production AS T2 ON T1.ID = T2.ID WHERE T2.model_year = 1973 AND T1.horsepower < 100

Database: authors
Question: How many journals don’t have a short name?
Evidence: don’t have a short name means ShortName is null
SQL: SELECT COUNT(ShortName) FROM Journal WHERE ShortName = ''

Database: restaurant
Question: What is the county and region of Davis City?
SQL: SELECT county, region FROM geographic WHERE city = 'Davis'

Database: video_games
Question: What is the genre of the game ID 119?
Evidence: genre of the game refers to genre_name; game ID 119 refers to game.id = 119;
SQL: SELECT T2.genre_name FROM game AS T1 INNER JOIN genre AS T2 ON T1.genre_id = T2.id WHERE T1.id = 119

Database: mental_health_survey
Question: According to 2016's survey, what is the number of users with a mental health disorder in the past?
Evidence: users with a mental health disorder in the past refers to AnswerText(QuestionID(32)) = 'Yes'
SQL: SELECT COUNT(T2.UserID) FROM Question AS T1 INNER JOIN Answer AS T2 ON T1.questionid = T2.QuestionID WHERE T2.SurveyID = 2016 AND T1.questiontext LIKE 'Have you had a mental health disorder in the past?' AND T2.AnswerText = 'Yes'

Database: beer_factory
Question: What is the percentage of 5 star ratings River City brand root beer get?
Evidence: percentage = MULTIPLY(DIVIDE(SUM(BrandID WHERE StarRating = 5), COUNT(BrandID) WHERE BrandName = 'River City'), 1.0); 5 star ratings refers to StarRating = 5; River City refers to BrandName = 'River City';
SQL: SELECT CAST(COUNT(CASE WHEN T2.StarRating = 5 THEN 1 ELSE NULL END) AS REAL) * 100 / COUNT(T2.StarRating) FROM rootbeerbrand AS T1 INNER JOIN rootbeerreview AS T2 ON T1.BrandID = T2.BrandID WHERE T1.BrandName = 'River City'

Database: soccer_2016
Question: What is the role of W Jaffer in season year 2012?
Evidence: W Jaffer refers to Player_name = 'W Jaffer'; in season year 2012 refers to Season_Year = 2012; role refers to Role_Desc
SQL: SELECT T4.Role_Desc FROM Player AS T1 INNER JOIN Player_Match AS T2 ON T1.Player_Id = T2.Player_Id INNER JOIN Match AS T3 ON T2.Match_Id = T3.Match_Id INNER JOIN Rolee AS T4 ON T2.Role_Id = T4.Role_Id INNER JOIN Season AS T5 ON T3.Season_Id = T5.Season_Id WHERE T1.Player_name = 'W Jaffer' AND T5.Season_Year = 2012

Database: regional_sales
Question: Indicate the procured dates for the customer whose ID is 11.
Evidence: ID is 11 refers to _CustomerID = 11;
SQL: SELECT DISTINCT T FROM ( SELECT IIF(_CustomerID = 11, ProcuredDate, NULL) AS T FROM `Sales Orders` ) WHERE T IS NOT NULL

Database: soccer_2016
Question: How many victory matches were there in 2008?
Evidence: in 2008 refers to Match_Date like '2008%'
SQL: SELECT COUNT(Match_Id) FROM Match WHERE Match_Date LIKE '2008%' AND Match_Winner IS NOT NULL

Database: shipping
Question: Give the annual revenue of the customer of ship ID 1047.
SQL: SELECT T2.annual_revenue FROM shipment AS T1 INNER JOIN customer AS T2 ON T1.cust_id = T2.cust_id WHERE T1.ship_id = '1047'

Database: world_development_indicators
Question: What is the minimum of International migrant stock, total of heavily indebted poor countries?
Evidence: IndicatorName = 'International migrant stock, total'; heavily indebted poor countries referred to by its abbreviated 'HIPC' = OtherGroups; MIN(Value);
SQL: SELECT MIN(T2.Value) FROM Country AS T1 INNER JOIN Indicators AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.OtherGroups = 'HIPC' AND T2.IndicatorName = 'International migrant stock, total'

Database: college_completion
Question: Give the web site address for "Swarthmore College".
Evidence: website address refers to site; Swarthmore College refers to chronname = 'Swarthmore College';
SQL: SELECT T FROM ( SELECT DISTINCT CASE WHEN chronname = 'Swarthmore College' THEN site ELSE NULL END AS T FROM institution_details ) WHERE T IS NOT NULL

Database: image_and_language
Question: List all the object classes in image 10.
Evidence: object classes refer to OBJ_CLASS; image 10 refers to IMG_ID = 10;
SQL: SELECT DISTINCT T2.OBJ_CLASS FROM IMG_OBJ AS T1 INNER JOIN OBJ_CLASSES AS T2 ON T1.OBJ_CLASS_ID = T2.OBJ_CLASS_ID WHERE T1.IMG_ID = 10

Database: retail_world
Question: Which employee is in charge of the sales in Hollis? Please give the employee's full name.
Evidence: Hollis refers to TerritoryDescription = 'Hollis'; full name = FirstName, LastName;
SQL: SELECT T1.FirstName, T1.LastName FROM Employees AS T1 INNER JOIN EmployeeTerritories AS T2 ON T1.EmployeeID = T2.EmployeeID INNER JOIN Territories AS T3 ON T2.TerritoryID = T3.TerritoryID WHERE T3.TerritoryDescription = 'Hollis'