Database: european_football_1
Question: How many Scottish League One games took place on the day that "Pro Vercelli" and "Pescara"had a 5-2 game?
Evidence: Pro Vercelli and Pescara are names of teams; HomeTeam = 'Pro Vercelli'; AwayTeam = 'Pescara'; 5-2 is a score where FTHG = '5' and FTAG = '2'; Scottish League One is a name of division; games refer to Div;
SQL: SELECT COUNT(T1.Date) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'Scottish League One' AND T1.Date = ( SELECT Date FROM matchs WHERE FTHG = 5 AND FTAG = 2 AND HomeTeam = 'Pro Vercelli' AND AwayTeam = 'Pescara' )

Database: shipping
Question: Provide the brand of the truck and the name of the driver that transported goods in Klett & Sons Repair.
Evidence: "Klett & Sons Repair" is the cust_name; brand of truck refers to make; name of driver refers to first_name, last_name
SQL: SELECT T3.make, T4.first_name, T4.last_name FROM customer AS T1 INNER JOIN shipment AS T2 ON T1.cust_id = T2.cust_id INNER JOIN truck AS T3 ON T3.truck_id = T2.truck_id INNER JOIN driver AS T4 ON T4.driver_id = T2.driver_id WHERE T1.cust_name = 'Klett & Sons Repair'

Database: food_inspection
Question: In 2016, which city has the highest number of establishments with the highest health and safety hazards?
Evidence: the highest health and safety hazards refer to risk_category = 'High Risk'; year(date) = 2016; establishments has the same meaning as businesses;
SQL: SELECT T2.city FROM violations AS T1 INNER JOIN businesses AS T2 ON T1.business_id = T2.business_id WHERE STRFTIME('%Y', T1.`date`) = '2016' AND T1.risk_category = 'High Risk' GROUP BY T2.city ORDER BY COUNT(T2.city) DESC LIMIT 1

Database: software_company
Question: How many female customers have an education level of over 11?
Evidence: education level of 11 refers to EDUCATIONNUM = 11; SEX = 'Female';
SQL: SELECT COUNT(ID) FROM Customers WHERE EDUCATIONNUM > 11 AND SEX = 'Female'

Database: car_retails
Question: Which of the customers, whose Tokyo-based sales representative reports to the Vice President of Sales whose employee number is 1056, has paid the highest payment? List the customer's name, the contact person and calculate the total amount of that customer's total payments.
Evidence: Tokyo is a city; 'reportsTO' is the leader of the 'employeeNumber'; highest payment refers to MAX(amount); total amount of payments = SUM(amount);
SQL: SELECT T2.customerName, T2.contactFirstName, T2.contactLastName, SUM(T3.amount) FROM employees AS T1 INNER JOIN customers AS T2 ON T2.salesRepEmployeeNumber = T1.employeeNumber INNER JOIN payments AS T3 ON T2.customerNumber = T3.customerNumber INNER JOIN offices AS T4 ON T1.officeCode = T4.officeCode WHERE T4.city = 'Tokyo' AND T1.reportsTo = 1056 GROUP BY T2.customerName, T2.contactFirstName, T2.contactLastName ORDER BY amount DESC LIMIT 1

Database: soccer_2016
Question: Which country is umpire TH Wijewardene from?
Evidence: country refers to Country_Name
SQL: SELECT T2.Country_Name FROM Umpire AS T1 INNER JOIN country AS T2 ON T2.Country_Id = T1.Umpire_Country WHERE T1.Umpire_Name = 'TH Wijewardene'

Database: movies_4
Question: List the character names played by Catherine Deneuve.
SQL: SELECT T2.character_name FROM person AS T1 INNER JOIN movie_cast AS T2 ON T1.person_id = T2.person_id WHERE T1.person_name = 'Catherine Deneuve'

Database: retail_world
Question: What is the average value of the sales order?
Evidence: calculation = DIVIDE(SUM(UnitPrice * Quantity * SUBTRACT(1, Discount)), COUNT(OrderID))
SQL: SELECT SUM(UnitPrice * Quantity * (1 - Discount)) / COUNT(OrderID) FROM `Order Details`

Database: chicago_crime
Question: Provide at least 5 ward office addresses associated with the crimes that happened in the community of Montclare.
Evidence: "Montclare" is the community_area_name
SQL: SELECT T3.ward_office_address FROM Community_Area AS T1 INNER JOIN Crime AS T2 ON T1.community_area_no = T2.community_area_no INNER JOIN Ward AS T3 ON T2.ward_no = T3.ward_no WHERE T1.community_area_name = 'Montclare' GROUP BY T3.ward_office_address LIMIT 5

Database: simpson_episodes
Question: Please list all of the episodes that aired in 2008 that have the highest number of votes for the maximum star rating.
Evidence: aired in 2008 refers to air_date like '2008%'; highest number of votes refers to MAX(votes); maximum star rating refers to stars = 10
SQL: SELECT T1.episode_id FROM Episode AS T1 INNER JOIN Vote AS T2 ON T2.episode_id = T1.episode_id WHERE SUBSTR(T1.air_date, 1, 4) = '2008' ORDER BY T2.votes DESC LIMIT 1;

Database: codebase_comments
Question: Among the repository "3", how many methods whose comments is XML format?
Evidence: repository refers to RepoId; RepoId = 3; method refers to Name; method whose comment is XML format refers to CommentIsXml = 1;
SQL: SELECT COUNT(T2.SolutionId) FROM Solution AS T1 INNER JOIN Method AS T2 ON T1.Id = T2.SolutionId WHERE T1.RepoId = 3 AND T2.CommentIsXml = 1

Database: trains
Question: How many trains are there that run in the east direction?
Evidence: east is a direction
SQL: SELECT COUNT(id) FROM trains WHERE direction = 'east'

Database: retail_world
Question: What is the full name of the employees who report to the Sales Manager?
Evidence: full name refers to LastName, FirstName; the Sales Manager refers to Title = 'Sales Manager'; report to refers to ReportsTo is not NULL;
SQL: SELECT FirstName, LastName FROM Employees WHERE ReportsTo = ( SELECT EmployeeID FROM Employees WHERE Title = 'Sales Manager' )

Database: talkingdata
Question: How many categories in total do the app users who were not active when event no.2 happened belong to?
Evidence: not active refers to is_active = 0; event no. refers to event_id; event_id = 2;
SQL: SELECT COUNT(*) FROM ( SELECT COUNT(DISTINCT T1.category) AS result FROM label_categories AS T1 INNER JOIN app_labels AS T2 ON T1.label_id = T2.label_id INNER JOIN app_events AS T3 ON T2.app_id = T3.app_id WHERE T3.event_id = 2 AND T3.is_active = 0 GROUP BY T1.category ) T

Database: app_store
Question: For the Honkai Impact 3rd App, what is the highest sentiment polarity score and what genre does it belong to?
Evidence: highest sentiment polarity score refers to MAX(Sentiment_Polarity);
SQL: SELECT MAX(T2.Sentiment_Polarity), T1.Genres FROM playstore AS T1 INNER JOIN user_reviews AS T2 ON T1.App = T2.App WHERE T1.App = 'Honkai Impact 3rd' AND T2.Sentiment_Polarity > 0.5 GROUP BY T1.Genres

Database: soccer_2016
Question: How many matches were there in May, 2008?
Evidence: in May 2008 refers to SUBSTR(Match_Date, 1, 4) = '2008' AND SUBSTR(Match_Date, 7, 1) = '5'
SQL: SELECT COUNT(Match_Id) FROM `Match` WHERE SUBSTR(Match_Date, 1, 4) = '2008' AND SUBSTR(Match_Date, 7, 1) = '5'

Database: donor
Question: What is the total donation amount for the project 'Engaging Young Readers with a Leveled Classroom Library'?
Evidence: Engaging Young Readers with a Leveled Classroom Library' is the title; total donation amount = Add(donation_to_project, donation_optional_support)
SQL: SELECT SUM(T2.donation_to_project) + SUM(T2.donation_optional_support) FROM essays AS T1 INNER JOIN donations AS T2 ON T1.projectid = T2.projectid WHERE T1.title LIKE 'Engaging Young Readers with a Leveled Classroom Library '

Database: car_retails
Question: From 2003 to 2004, how many customers have paid more than three times?
Evidence: paymentdate BETWEEN '2003-01-01' AND '2004-12-31'; customers who have paid more than three times refers to (COUNT(customernumber)>3);
SQL: SELECT COUNT(customernumber) FROM ( SELECT customernumber FROM payments WHERE STRFTIME('%Y', paymentDate) >= '2003' AND STRFTIME('%Y', paymentDate) <= '2004' GROUP BY customernumber HAVING COUNT(customernumber) > 3 ) T