Database: public_review_platform
Question: How many businesses are there in Scottsdale city under the category of "Beauty & Spas"?
Evidence: category refers to category_name;
SQL: SELECT COUNT(T2.business_id) 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 WHERE T3.city LIKE 'Scottsdale' AND T1.category_name LIKE 'Beauty & Spas'

Database: language_corpus
Question: How many total occurrences are there in the three-letter words?
Evidence: three-letter words are words composed of exactly three letters;
SQL: SELECT SUM(occurrences) FROM words WHERE LENGTH(word) = 3

Database: trains
Question: Please list the directions in which the trains with 4 short cars run.
Evidence: short refers to len = 'short'; 4 cars run refers to position = 4
SQL: SELECT T2.direction FROM cars AS T1 INNER JOIN trains AS T2 ON T1.train_id = T2.id WHERE T1.len = 'short' AND T1.position = 4

Database: image_and_language
Question: What is the bounding box of the object sample in image no.5 that has a self-relation?
Evidence: bounding box of the object sample refers to (x, y, W, H); image no.5 refers to IMG_ID = 5; has a self-relation refers to OBJ1_SAMPLE_ID = OBJ2_SAMPLE_ID
SQL: SELECT T2.X, T2.Y, T2.W, T2.H FROM IMG_REL AS T1 INNER JOIN IMG_OBJ AS T2 ON T1.IMG_ID = T2.IMG_ID WHERE T1.IMG_ID = 5 AND T1.OBJ1_SAMPLE_ID = T1.OBJ2_SAMPLE_ID

Database: cars
Question: Among the cars with 8 cylinders, what is the name of the one that's the most expensive?
Evidence: with 8 cylinders refers to cylinders = 8; name of the car refers to car_name; the most expensive refers to max(price)
SQL: SELECT T1.car_name FROM data AS T1 INNER JOIN price AS T2 ON T1.ID = T2.ID WHERE T1.cylinders = 8 ORDER BY T2.price DESC LIMIT 1

Database: retail_complains
Question: How many of the complaints are longer than 15 minutes?
Evidence: longer than 15 minutes refers to ser_time > '00:15:00'
SQL: SELECT COUNT(ser_time) FROM callcenterlogs WHERE strftime('%M', ser_time) > '15'

Database: student_loan
Question: List 10 students that have no due payments and are not males.
Evidence: no due payments refers to bool = 'neg'; not males refers to not in male table
SQL: SELECT T1.name FROM no_payment_due AS T1 INNER JOIN person AS T2 ON T1.`name` = T2.`name` WHERE T2.`name` NOT IN ( SELECT name FROM male ) AND T1.bool = 'neg'

Database: music_platform_2
Question: Which category does the podcast titled 'SciFi Tech Talk' belong to?
Evidence: podcast titled 'SciFi Tech Talk' refers to title = 'SciFi Tech Talk'
SQL: SELECT T1.category FROM categories AS T1 INNER JOIN podcasts AS T2 ON T2.podcast_id = T1.podcast_id WHERE T2.title = 'SciFi Tech Talk'

Database: address
Question: Please list the numbers of males in all the residential areas in Arecibo county.
Evidence: "ARECIBO" is the county; number of males refers to Sum(male_population)
SQL: SELECT SUM(T1.male_population) FROM zip_data AS T1 INNER JOIN country AS T2 ON T1.zip_code = T2.zip_code WHERE T2.county = 'ARECIBO'

Database: food_inspection_2
Question: Among the facilities that have undergone at least one inspection in 2010, how many of them are restaurants or cafeterias?
Evidence: in 2010 refers to inspection_date like '2010%'; restaurant or cafeteria refers to facility_type = 'Restaurant'
SQL: SELECT COUNT(DISTINCT T1.license_no) FROM inspection AS T1 INNER JOIN establishment AS T2 ON T1.license_no = T2.license_no WHERE strftime('%Y', T1.inspection_date) = '2010' AND T2.facility_type = 'Restaurant'

Database: airline
Question: How many flights were there on 2018/8/1?
Evidence: on 2018/8/1 refers to FL_DATE = '2018/8/1';
SQL: SELECT COUNT(*) FROM Airlines WHERE FL_DATE = '2018/8/1'

Database: donor
Question: How many total items were requested for the Onslow Co School District urban metro school projects?
Evidence: Onslow Co School District refers to school_district = 'Onslow Co School District';
SQL: SELECT SUM(T1.item_quantity) FROM resources AS T1 INNER JOIN projects AS T2 ON T1.projectid = T2.projectid WHERE T2.school_metro = 'urban' AND T2.school_district = 'Onslow Co School District'

Database: retail_world
Question: Provide the list of product IDs and names under the meat/poultry category.
Evidence: meat/poultry category refers to CategoryName = 'Meat/Poultry';
SQL: SELECT T2.ProductName, T1.CategoryName FROM Categories AS T1 INNER JOIN Products AS T2 ON T1.CategoryID = T2.CategoryID WHERE T2.ReorderLevel = ( SELECT MAX(ReorderLevel) FROM Products )

Database: food_inspection_2
Question: What is the employee's last name at 7211 S Hermitage Ave, Chicago, IL?
Evidence: 7211 S Hermitage Ave refers to address = '7211 S Hermitage Ave'; Chicago refers to city = 'Chicago'; IL refers to state = 'IL'
SQL: SELECT last_name FROM employee WHERE address = '7211 S Hermitage Ave' AND city = 'Chicago' AND state = 'IL'

Database: codebase_comments
Question: Please state the API calls for method number 10 and its intended course of action.
Evidence: method number refers to Method_100k.Id; Method_100k.Id = 10; intended course of action refers to Path;
SQL: SELECT T2.ApiCalls, T1.Path FROM Solution AS T1 INNER JOIN Method AS T2 ON T1.Id = T2.SolutionId WHERE T2.Id = 10

Database: software_company
Question: Among the female customers with an level of education of 3 and below, list their income.
Evidence: female customers with level of education of 3 and below refer to SEX = 'Female' where EDUCATIONNUM ≤ 3; income refers to INCOME_K;
SQL: SELECT INCOME_K FROM Demog WHERE GEOID IN ( SELECT GEOID FROM Customers WHERE EDUCATIONNUM < 3 AND SEX = 'Female' )

Database: superstore
Question: What is the total profit of "Memorex Froggy Flash Drive 8 GB in south superstore?
Evidence: "Memorix Froggy Flash Drive 8 GB" is the "Product Name"
SQL: SELECT SUM(T1.Profit) FROM south_superstore AS T1 INNER JOIN product AS T2 ON T1.`Product ID` = T2.`Product ID` GROUP BY T2.`Product Name` = 'Memorix Froggy Flash Drive 8 GB'

Database: public_review_platform
Question: Give the number of "4" stars Yelp businesses in "Mesa" city.
Evidence: "4" stars refers to stars = '4'; 'Mesa' is the name of city
SQL: SELECT COUNT(business_id) FROM Business WHERE stars = 4 AND city = 'Mesa'

Database: public_review_platform
Question: How many Yelp_Businesses are there in Arizona in total?
Evidence: Arizona refers to state = 'AZ';
SQL: SELECT COUNT(business_id) FROM Business WHERE state LIKE 'AZ'

Database: airline
Question: Tell the number of fights landed earlier on Miami Airport on 2018/8/12.
Evidence: landed on refers to DEST; landed earlier refers to ARR_DELAY < 0; Miami Airport refers to DEST = 'MIA'; on 2018/8/12 refers to FL_DATE = '2018/8/12';
SQL: SELECT COUNT(*) FROM Airports AS T1 INNER JOIN Airlines AS T2 ON T1.Code = T2.DEST WHERE T2.FL_DATE = '2018/8/12' AND T2.DEST = 'MIA' AND T2.ARR_DELAY < 0

Database: movies_4
Question: Which production company produced the movie that made the most money at the box office?
Evidence: Which production company refers to company_name; most money at the box office refers to max(revenue)
SQL: SELECT T1.company_name FROM production_company AS T1 INNER JOIN movie_company AS T2 ON T1.company_id = T2.company_id INNER JOIN movie AS T3 ON T2.movie_id = T3.movie_id GROUP BY T1.company_id ORDER BY SUM(T3.revenue) DESC LIMIT 1

Database: address
Question: Who are the congress representatives of the postal points in Garfield?
Evidence: Who are the congress representatives refer to first_name, last_name; Garfield is the city;
SQL: SELECT T3.first_name, T3.last_name FROM zip_data AS T1 INNER JOIN zip_congress AS T2 ON T1.zip_code = T2.zip_code INNER JOIN congress AS T3 ON T2.district = T3.cognress_rep_id WHERE T1.city = 'Garfield'