Database: cs_semester
Question: Please give the name of the course in which most numbers of the students got an A. Also, list the full name of the students who got an A in this course.
Evidence: most number of students got an A refers MAX(COUNT(student_id WHERE grade = 'A')); full name = f_name, l_name; got an A refers to grade = 'A';
SQL: SELECT T3.name, T2.f_name, T2.l_name FROM registration AS T1 INNER JOIN student AS T2 ON T1.student_id = T2.student_id INNER JOIN course AS T3 ON T1.course_id = T3.course_id WHERE T1.grade = 'A' GROUP BY T3.name ORDER BY COUNT(T1.student_id) DESC LIMIT 1

Database: simpson_episodes
Question: Which episode has the largest number of votes?
Evidence: largest number of votes refers to MAX(votes)
SQL: SELECT episode FROM Episode WHERE votes = ( SELECT MAX(votes) FROM Episode );

Database: restaurant
Question: What is the full address of the most popular restaurant among the diners?
Evidence: full address refers to street_num, street_name, city; the most popular refers to max(review)
SQL: SELECT T2.street_name, T2.street_num, T2.city FROM generalinfo AS T1 INNER JOIN location AS T2 ON T1.id_restaurant = T2.id_restaurant ORDER BY T1.review DESC LIMIT 1

Database: image_and_language
Question: What is the caption for the prediction class id 12?
Evidence: caption for the prediction class id 12 refers to PRED_CLASS where PRED_CLASS_ID = 12;
SQL: SELECT PRED_CLASS FROM PRED_CLASSES WHERE PRED_CLASS_ID = 12

Database: legislator
Question: How many Jewish legislators do not have facebook?
Evidence: Jewish legislators refers to religion_bio = 'Jewish'; do not have facebook refers to facebook is null;
SQL: SELECT COUNT(T3.bioguide_id) FROM ( SELECT T1.bioguide_id FROM current AS T1 INNER JOIN `social-media` AS T2 ON T1.bioguide_id = T2.bioguide WHERE T2.facebook IS NULL GROUP BY T1.bioguide_id ) T3

Database: professional_basketball
Question: From 1950 to 1970, what is the maximum point of players whose teams were ranked 1?
Evidence: from 1950 to 1970 refers to year between 1950 and 1970; team with rank 1 refers to rank = 1; maximum point refers to Max(points)
SQL: SELECT MAX(T2.points) FROM teams AS T1 INNER JOIN players_teams AS T2 ON T1.tmID = T2.tmID AND T1.year = T2.year WHERE T1.year BETWEEN 1950 AND 1970 AND T1.rank = 1

Database: movie_platform
Question: How many movie lists were still updated 10 years after it was created?
Evidence: updated 10 years after it was created refers to list_update_timestamp_utc > (list_creation_timestamp_utc+10);
SQL: SELECT COUNT(*) FROM lists WHERE SUBSTR(list_update_timestamp_utc, 1, 4) - SUBSTR(list_creation_timestamp_utc, 1, 4) > 10

Database: legislator
Question: List the full names of 10 legislators who only have a Facebook account.
Evidence: full names refers to official_full_name; only have a Facebook account refers to youtube is NULL or youtube = '', instagram is NULL or instagram = '', twitter is NULL or twitter = '', facebook is not NULL and facebook = ''
SQL: SELECT T2.official_full_name FROM `social-media` AS T1 INNER JOIN current AS T2 ON T1.bioguide = T2.bioguide_id WHERE (T1.youtube IS NULL OR T1.youtube = '') AND (T1.instagram IS NULL OR T1.instagram = '') AND (T1.twitter IS NULL OR T1.twitter = '') AND T1.facebook IS NOT NULL AND T1.facebook != ''

Database: image_and_language
Question: Give the X and Y coordinates of the sample object of image ID 23 that has the 'cast' attribute class.
Evidence: X and Y refer to coordinates of the bounding box; image ID 23 refers to IMG_ID = 23; 'cast' attribute class refers to ATT_CLASS = 'cast';
SQL: SELECT T3.OBJ_SAMPLE_ID, T3.X, T3.Y FROM ATT_CLASSES AS T1 INNER JOIN IMG_OBJ_ATT AS T2 ON T1.ATT_CLASS_ID = T2.ATT_CLASS_ID INNER JOIN IMG_OBJ AS T3 ON T2.IMG_ID = T3.IMG_ID WHERE T3.IMG_ID = 23 AND T1.ATT_CLASS = 'cast'

Database: shipping
Question: How many of the shipments bound for New York City were shipped to Harry's Hot Rod Auto and Truck Accessories?
Evidence: "New York" is the city_name; 'Harry's Hot Rod Auto & Truck Accessories' is the cust_name
SQL: SELECT COUNT(*) FROM customer AS T1 INNER JOIN shipment AS T2 ON T1.cust_id = T2.cust_id INNER JOIN city AS T3 ON T3.city_id = T2.city_id WHERE T3.city_name = 'New York' AND T1.cust_name = 'Harry''s Hot Rod Auto & Truck Accessories'

Database: computer_student
Question: List all the course IDs for professional or master/graduate courses.
Evidence: professional or master/graduate courses refers to courseLevel = 'Level_500'
SQL: SELECT course_id FROM course WHERE courseLevel = 'Level_500'

Database: coinmarketcap
Question: What was the number of Bitcoins verifiably burned until 2013/4/28?
Evidence: the number of Bitcoins verifiably burned = max_supply - total_supply; 2013/4/28 refers to date = '2013-04-28'
SQL: SELECT T2.max_supply - T2.total_supply FROM coins AS T1 INNER JOIN historical AS T2 ON T1.id = T2.coin_id WHERE T2.date = '2013-04-28' AND T1.name = 'Bitcoin'

Database: donor
Question: How many Rock Hill City School projects have teacher donors?
Evidence: Rock Hill City School refers to school_city = 'Rock Hill'; teacher donors refers to is_teacher_acct = 't'
SQL: SELECT COUNT(DISTINCT T1.teacher_acctid) FROM projects AS T1 INNER JOIN donations AS T2 ON T1.projectid = T2.projectid WHERE T1.school_city = 'Rock Hill' AND is_teacher_acct = 't'

Database: professional_basketball
Question: What is the percentage of coaches in 1969 who were awarded "NBA Coach of the Year"?
Evidence: in 1969 refers to year = 1969; awarded "NBA Coach of the Year" refers to award = 'NBA Coach of the Year'; percentage = divide(count(coachID where year = 1969 and award = 'NBA Coach of the Year'), count(coachID)) * 100%
SQL: SELECT CAST(SUM(CASE WHEN award = 'NBA Coach of the Year' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(*) FROM awards_coaches WHERE year = 1969

Database: soccer_2016
Question: How many times has Sunrisers Hyderabad been the toss winner of a game?
Evidence: Sunrisers Hyderabad refers to Team_Name = 'Sunrisers Hyderabad'; time of toss winner refers to count(Toss_Winner)
SQL: SELECT SUM(CASE WHEN Toss_Winner = ( SELECT Team_Id FROM Team WHERE Team_Name = 'Sunrisers Hyderabad' ) THEN 1 ELSE 0 END) FROM `Match`

Database: airline
Question: Among the flights with air carrier described as Asap Air Inc.: ASP, what is the tail number of the flight with the longest departure delay?
Evidence: Asap Air Inc.: ASP refers to Description = 'Asap Air Inc.: ASP'; tail number refers to TAIL_NUM; longest departure delay refers to MAX(DEP_DELAY);
SQL: SELECT T2.TAIL_NUM FROM `Air Carriers` AS T1 INNER JOIN Airlines AS T2 ON T1.Code = T2.OP_CARRIER_AIRLINE_ID WHERE T1.Description = 'Asap Air Inc.: ASP' ORDER BY T2.DEP_DELAY DESC LIMIT 1

Database: retail_world
Question: What territories is the Inside Sales Coordinator in charge of?
Evidence: territories refer to TerritoryDescription; Title = 'Inside Sales Coordinator';
SQL: SELECT T3.TerritoryDescription 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 T1.Title = 'Inside Sales Coordinator'

Database: ice_hockey_draft
Question: What is the weight in kg of Tony Martensson?
Evidence: FALSE;
SQL: SELECT T2.weight_in_kg FROM PlayerInfo AS T1 INNER JOIN weight_info AS T2 ON T1.weight = T2.weight_id WHERE T1.PlayerName = 'Tony Martensson'

Database: olympics
Question: Which city was the 1992 Summer Olympic held?
Evidence: city refers to city_name; 1992 Summer Olympic refers to games_name = '1992 Summer';
SQL: SELECT T2.city_name FROM games_city AS T1 INNER JOIN city AS T2 ON T1.city_id = T2.id INNER JOIN games AS T3 ON T1.games_id = T3.id WHERE T3.games_name = '1992 Summer'