Question: How much space does page 1 of the menu "Zentral Theater Terrace" cover?

SELECT T2.full_height * T2.full_width FROM Menu AS T1 INNER JOIN MenuPage AS T2 ON T1.id = T2.menu_id WHERE T1.name = 'Zentral Theater Terrace' AND T2.page_number = 1

How much space does page 1 of the menu " Zentral Theater Terrace " cover ?

O O O O B-TABLE B-VALUE O O B-TABLE O B-VALUE I-VALUE I-VALUE O O O


Question: What is the venue and year with the most number of publications?

SELECT venue ,  YEAR FROM paper GROUP BY venue ,  YEAR ORDER BY count(*) DESC LIMIT 1

What is the venue and year with the most number of publications ?


Question: What is the contact title for the person who supplied a product that is 10 boxes x 12 pieces.

SELECT T2.ContactTitle FROM Products AS T1 INNER JOIN Suppliers AS T2 ON T1.SupplierID = T2.SupplierID WHERE T1.QuantityPerUnit = '10 boxes x 12 pieces'

What is the contact title for the person who supplied a product that is 10 boxes x 12 pieces .

O O O B-COLUMN I-COLUMN O O O O B-TABLE O B-TABLE O O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O


Question: What is the full name of the customer who owns the "aalleburtonkc@yellowbook.com" e-mail address?

SELECT first_name, last_name FROM customer WHERE email = 'aalleburtonkc@yellowbook.com'

What is the full name of the customer who owns the " aalleburtonkc@yellowbook.com " e - mail address ?

O O O O B-COLUMN O O B-TABLE O O O O B-VALUE O B-COLUMN I-COLUMN I-COLUMN O O


Question: How many patients who were examined between 1987/7/6 and 1996/1/31 had a GPT level greater than 30 and an ALB level less than 4? List them by their ID.

SELECT DISTINCT ID FROM Laboratory WHERE Date BETWEEN '1987-07-06' AND '1996-01-31' AND GPT > 30 AND ALB < 4

How many patients who were examined between 1987/7/6 and 1996/1/31 had a GPT level greater than 30 and an ALB level less than 4 ? List them by their ID .

O O O O O O O B-VALUE O B-VALUE O O B-COLUMN O O O B-VALUE O O B-COLUMN O O O B-VALUE O O O O O B-COLUMN O


Question: Which of Cooperativa de Quesos 'Las Cabras' products have a unit price greater than 20?

SELECT T1.ProductName FROM Products AS T1 INNER JOIN Suppliers AS T2 ON T1.SupplierID = T2.SupplierID WHERE T2.CompanyName LIKE 'Cooperativa de Quesos%' AND T1.UnitPrice > 20

Which of Cooperativa de Quesos ' Las Cabras ' products have a unit price greater than 20 ?

O O B-VALUE I-VALUE I-VALUE O O O O B-TABLE B-COLUMN O B-COLUMN I-COLUMN O O B-VALUE O


Question: How many document types are there?


Question: Write down any five film names under the documentary category.

SELECT T1.title FROM film AS T1 INNER JOIN film_category AS T2 ON T1.film_id = T2.film_id INNER JOIN category AS T3 ON T2.category_id = T3.category_id WHERE T3.name = 'Documentary' LIMIT 5

Write down any five film names under the documentary category .

B-COLUMN O O O B-TABLE B-COLUMN O O B-VALUE B-TABLE O


Question: How many online orders were shipped during the month of June 2018?

SELECT SUM(IIF(ShipDate LIKE '6/%/18' AND `Sales Channel` = 'Online', 1, 0)) FROM `Sales Orders`

How many online orders were shipped during the month of June 2018 ?

O O B-VALUE B-TABLE O B-COLUMN O O O O O O O


Question: Show all product colors.

SELECT DISTINCT product_color FROM Products


Question: Please list the titles of all the episodes in which Park Dietz was credited.

SELECT T1.title FROM Episode AS T1 INNER JOIN Credit AS T2 ON T1.episode_id = T2.episode_id INNER JOIN Person AS T3 ON T3.person_id = T2.person_id WHERE T2.credited = 'true' AND T3.name = 'Park Dietz'

Please list the titles of all the episodes in which Park Dietz was credited .

O O O B-COLUMN O O O B-TABLE O O B-VALUE I-VALUE O B-TABLE O


Question: Please list the names of customers who have total orders of over 3 in 2018.

SELECT DISTINCT IIF(COUNT(T2.CustomerID) > 3, T2.`Customer Names`, NULL) FROM `Sales Orders` AS T1 INNER JOIN Customers AS T2 ON T2.CustomerID = T1._CustomerID WHERE T1.OrderDate LIKE '%/%/18' GROUP BY T1._CustomerID HAVING COUNT(T2.CustomerID)

Please list the names of customers who have total orders of over 3 in 2018 .

O O O O O B-TABLE O O B-TABLE B-COLUMN O O B-VALUE O O O


Question: Calculate the total votes of episodes that Adam Kuhlman had involved.

SELECT SUM(T1.votes) FROM Episode AS T1 INNER JOIN Credit AS T2 ON T1.episode_id = T2.episode_id WHERE T2.person = 'Adam Kuhlman';

Calculate the total votes of episodes that Adam Kuhlman had involved .

O O O B-COLUMN O B-TABLE O B-VALUE I-VALUE O O O


Question: How many orders made by Rochester Ltd?

SELECT SUM(CASE WHEN T1.`Customer Names` = 'Rochester Ltd' THEN 1 ELSE 0 END) FROM Customers AS T1 INNER JOIN `Sales Orders` AS T2 ON T2._CustomerID = T1.CustomerID


Question: List out the number of disabled students who enlisted in marines.

SELECT COUNT(T1.name) FROM disabled AS T1 INNER JOIN enlist AS T2 ON T1.name = T2.name WHERE T2.organ = 'marines'

List out the number of disabled students who enlisted in marines .

O O O B-COLUMN O B-TABLE O O B-TABLE O B-VALUE O


Question: List out director names that received an award along with the episode number.

SELECT T3.name, T1.episode_id FROM Episode AS T1 INNER JOIN Award AS T2 ON T1.episode_id = T2.episode_id INNER JOIN Person AS T3 ON T2.person_id = T3.person_id WHERE T2.role = 'director' AND T2.result = 'Winner'

List out director names that received an award along with the episode number .

O O B-VALUE B-COLUMN O O O B-TABLE O O O B-TABLE O O


Question: Who is the director that made the most movies? Give the director's id.

SELECT director_id FROM movies GROUP BY director_id ORDER BY COUNT(movie_id) DESC LIMIT 1

Who is the director that made the most movies ? Give the director 's i d.

O O O O O O O O B-TABLE O O O B-COLUMN O O O


Question: Provide the zip codes and their affiliated organization for the postal point under Kingsport-Bristol, TN-VA.

SELECT T2.zip_code, T2.organization FROM CBSA AS T1 INNER JOIN zip_data AS T2 ON T1.CBSA = T2.CBSA WHERE T1.CBSA_name = 'Kingsport-Bristol, TN-VA'

Provide the zip codes and their affiliated organization for the postal point under Kingsport - Bristol , TN - VA .

O O B-COLUMN I-COLUMN O O O B-COLUMN O O O O O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O


Question: Identify the total number of orders processed by Northwind employee named Andrew Fuller. What percent of those orders was shipped to Austria?

SELECT CAST(COUNT(CASE WHEN T2.ShipCountry = 'Austria' THEN 1 ELSE NULL END) AS REAL) * 100 / COUNT(T2.OrderID) FROM Employees AS T1 INNER JOIN Orders AS T2 ON T1.EmployeeID = T2.EmployeeID WHERE T1.FirstName = 'Andrew' AND T1.LastName = 'Fuller'

Identify the total number of orders processed by Northwind employee named Andrew Fuller . What percent of those orders was shipped to Austria ?

O O O O O B-COLUMN O O O B-TABLE B-COLUMN B-VALUE B-VALUE O O O O O B-TABLE O O O B-VALUE O


Question: Show the short names of the buildings managed by "Emma".

SELECT building_short_name FROM Apartment_Buildings WHERE building_manager	 =  "Emma"

Show the short names of the buildings managed by " Emma " .

O O O O O B-TABLE B-COLUMN I-COLUMN O O B-COLUMN O O


Question: When do all the researcher role staff start to work, and when do they stop working?

SELECT date_from ,  date_to FROM Project_Staff WHERE role_code  =  'researcher'

When do all the researcher role staff start to work , and when do they stop working ?

O O O O B-VALUE B-COLUMN B-TABLE O O O O O O O O O O O


Question: Who is the oldest among all the casts and crews?

SELECT name FROM Person ORDER BY birthdate ASC LIMIT 1;

Who is the oldest among all the casts and crews ?


Question: What are all the instruments used by the musician with the last name "Heilo"?

SELECT instrument FROM instruments AS T1 JOIN Band AS T2 ON T1.bandmateid  =  T2.id WHERE T2.lastname  =  "Heilo"

What are all the instruments used by the musician with the last name " Heilo " ?

O O O O B-COLUMN O O O O O O B-COLUMN I-COLUMN O B-COLUMN O O


Question: What is the name of the entrepreneur with the greatest weight?

SELECT T2.Name FROM entrepreneur AS T1 JOIN people AS T2 ON T1.People_ID  =  T2.People_ID ORDER BY T2.Weight DESC LIMIT 1

What is the name of the entrepreneur with the greatest weight ?

O O O B-COLUMN O O B-TABLE O O O B-COLUMN O


Question: What is the id of the reviewer whose name has substring “Mike”?

SELECT rID FROM Reviewer WHERE name LIKE "%Mike%"

What is the i d of the reviewer whose name has substring “ Mike ” ?

O O O B-COLUMN I-COLUMN O O B-TABLE O B-COLUMN O O O B-COLUMN O O


Question: What are all the locations with a cinema?

What are all the locations with a cinema ?


Question: Which nation has the greatest infant mortality rate among those that attained independence in 1960?

SELECT T1.Country FROM politics AS T1 INNER JOIN population AS T2 ON T1.Country = T2.Country WHERE STRFTIME('%Y', T1.Independence) = '1960' ORDER BY T2.Infant_Mortality DESC LIMIT 1

Which nation has the greatest infant mortality rate among those that attained independence in 1960 ?

O B-TABLE O O O B-COLUMN I-COLUMN O O O O O B-COLUMN O B-VALUE O


Question: Find the number of rooms located on each block floor.

SELECT count(*) ,  T1.blockfloor FROM BLOCK AS T1 JOIN room AS T2 ON T1.blockfloor  =  T2.blockfloor AND T1.blockcode  =  T2.blockcode GROUP BY T1.blockfloor

Find the number of rooms located on each block floor .

O O O O B-TABLE O O O B-TABLE B-COLUMN O


Question: What is the average age of clients in South Atlantic?

SELECT AVG(T1.age) FROM client AS T1 INNER JOIN district AS T2 ON T1.district_id = T2.district_id WHERE T2.division = 'South Atlantic'

What is the average age of clients in South Atlantic ?

O O O O B-COLUMN O B-TABLE O B-VALUE I-VALUE O


Question: Find the papers which have "Olin Shivers" as an author.

SELECT t3.title FROM authors AS t1 JOIN authorship AS t2 ON t1.authid  =  t2.authid JOIN papers AS t3 ON t2.paperid  =  t3.paperid WHERE t1.fname  =  "Olin" AND t1.lname  =  "Shivers"

Find the papers which have " Olin Shivers " as an author .

O O B-TABLE O O O B-COLUMN B-COLUMN O O O B-COLUMN O


Question: Which contact channel has been used by the customer with name "Tillman Ernser"?

SELECT DISTINCT channel_code FROM customers AS t1 JOIN customer_contact_channels AS t2 ON t1.customer_id  =  t2.customer_id WHERE t1.customer_name  =  "Tillman Ernser"

Which contact channel has been used by the customer with name " Tillman Ernser " ?

O B-TABLE B-COLUMN O O O O O B-TABLE B-COLUMN I-COLUMN O B-COLUMN I-COLUMN O O


Question: Report all majors that have less than 3 students.

SELECT Major FROM STUDENT GROUP BY Major HAVING COUNT(*)  <  3

Report all majors that have less than 3 students .


Question: How many faculty members does each building have? List the result with the name of the building.

SELECT building ,  count(*) FROM Faculty GROUP BY building

How many faculty members does each building have ? List the result with the name of the building .

O O B-TABLE O O O O O O O O O O O O O O B-COLUMN O


Question: What is the name of the bank branch with the greatest number of customers?

SELECT bname FROM bank ORDER BY no_of_customers DESC LIMIT 1

What is the name of the bank branch with the greatest number of customers ?

O O O B-COLUMN O O B-TABLE O O O O O B-COLUMN I-COLUMN O


Question: What is the percentage of users gave "5" to the movie "Go Go Tales"?

SELECT CAST(SUM(CASE WHEN T1.rating_score = 5 THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(T1.user_id) FROM ratings AS T1 INNER JOIN movies AS T2 ON T1.movie_id = T2.movie_id WHERE T2.movie_title = 'Go Go Tales'

What is the percentage of users gave " 5 " to the movie " Go Go Tales " ?

O O O O O B-COLUMN O O B-VALUE O O O B-TABLE O B-VALUE I-VALUE I-VALUE O O


Question: How many actors played a role in the 2006 film whose rental duration is 7 days, rental rate is 4.99 and is 98 minutes duration?

SELECT COUNT(T1.actor_id) FROM film_actor AS T1 INNER JOIN film AS T2 ON T1.film_id = T2.film_id WHERE T2.release_year = 2006 AND T2.rental_duration = 7 AND T2.rental_duration = 4.99 AND T2.length = 98

How many actors played a role in the 2006 film whose rental duration is 7 days , rental rate is 4.99 and is 98 minutes duration ?

O O B-COLUMN O O B-COLUMN I-COLUMN I-COLUMN B-VALUE B-TABLE O B-COLUMN I-COLUMN O B-VALUE O O O O O B-VALUE O O B-VALUE O O O


Question: What is the id of the trip that has the shortest duration?

SELECT id FROM trip ORDER BY duration LIMIT 1

What is the i d of the trip that has the shortest duration ?

O O O B-COLUMN I-COLUMN O O B-TABLE O O O O B-COLUMN O


Question: Find the first name of student who is taking classes from accounting and Computer Info. Systems departments

SELECT T1.stu_fname FROM student AS T1 JOIN enroll AS T2 ON T1.stu_num  =  T2.stu_num JOIN CLASS AS T3 ON T2.class_code  =  T3.class_code JOIN course AS T4 ON T3.crs_code  =  T4.crs_code JOIN department AS T5 ON T5.dept_code  =  T4.dept_code WHERE T5.dept_name  =  'Accounting' INTERSECT SELECT T1.stu_fname FROM student AS T1 JOIN enroll AS T2 ON T1.stu_num  =  T2.stu_num JOIN CLASS AS T3 ON T2.class_code  =  T3.class_code JOIN course AS T4 ON T3.crs_code  =  T4.crs_code JOIN department AS T5 ON T5.dept_code  =  T4.dept_code WHERE T5.dept_name  =  'Computer Info. Systems'

Find the first name of student who is taking classes from accounting and Computer Info . Systems departments

O O B-COLUMN B-COLUMN O B-TABLE O O O B-TABLE O B-VALUE O B-VALUE I-VALUE I-VALUE I-VALUE B-TABLE


Question: Show the name of track and the number of races in each track.

SELECT T2.name ,  count(*) FROM race AS T1 JOIN track AS T2 ON T1.track_id  =  T2.track_id GROUP BY T1.track_id

Show the name of track and the number of races in each track .

O O B-COLUMN O B-COLUMN O O O O B-TABLE O O B-TABLE O


Question: Find the component amounts and names of all furnitures that have more than 10 components.

SELECT Num_of_Component ,  name FROM furniture WHERE Num_of_Component  >  10

Find the component amounts and names of all furnitures that have more than 10 components .

O O B-COLUMN O O B-COLUMN O O B-TABLE O O O O B-VALUE O O


Question: What is the address for the customer with id 10?

SELECT T1.address_details FROM addresses AS T1 JOIN customer_addresses AS T2 ON T1.address_id  =  T2.address_id WHERE T2.customer_id  =  10

What is the address for the customer with i d 10 ?

O O O B-TABLE O O B-COLUMN O O O B-VALUE O


Question: How many suppliers does Northwind have in USA?

SELECT COUNT(SupplierID) FROM Suppliers WHERE Country = 'USA'

How many suppliers does Northwind have in USA ?


Question: From 1980 to 2000, which artist had the most disco releases?

SELECT T1.artist FROM torrents AS T1 INNER JOIN tags AS T2 ON T1.id = T2.id WHERE T1.groupYear BETWEEN 1980 AND 2000 AND T2.tag LIKE 'disco' GROUP BY T1.artist ORDER BY COUNT(T2.tag) DESC LIMIT 1

From 1980 to 2000 , which artist had the most disco releases ?

O B-VALUE O B-VALUE O O B-COLUMN O O O B-VALUE O O


Question: What is the number of cards are there in the set of "Rinascita di Alara"?

SELECT T1.baseSetSize FROM sets AS T1 INNER JOIN set_translations AS T2 ON T2.setCode = T1.code WHERE T2.translation = 'Rinascita di Alara'

What is the number of cards are there in the set of " Rinascita di Alara " ?

O O O O O O O O O O B-TABLE B-COLUMN O B-VALUE I-VALUE I-VALUE O O


Question: What proportion of work order is in Subassembly?

SELECT 100.0 * SUM(CASE WHEN T1.Name = 'Subassembly' THEN 1 ELSE 0 END) / COUNT(T2.WorkOrderID) FROM Location AS T1 INNER JOIN WorkOrderRouting AS T2 ON T1.LocationID = T2.LocationID

What proportion of work order is in Subassembly ?

O O O B-COLUMN I-COLUMN B-TABLE I-TABLE B-VALUE O


Question: List the heroes' names whose eyes and hair colours are both black.

SELECT T1.superhero_name FROM superhero AS T1 INNER JOIN colour AS T2 ON T1.eye_colour_id = T2.id AND T1.hair_colour_id = T2.id WHERE T2.colour = 'Black'

List the heroes ' names whose eyes and hair colours are both black .

O O B-COLUMN I-COLUMN I-COLUMN O O O B-COLUMN B-COLUMN O O B-VALUE O


Question: State the locations of all Pet Services business.

SELECT T1.city FROM Business AS T1 INNER JOIN Business_Categories AS T2 ON T1.business_id = T2.business_id INNER JOIN Categories AS T3 ON T2.category_id = T3.category_id WHERE T3.category_name = 'Pet Services'

State the locations of all Pet Services business .


Question: What is the score of university ID 68 in 2015?

SELECT score FROM university_ranking_year WHERE year = 2015 AND university_id = 68

What is the score of university ID 68 in 2015 ?

O O O B-COLUMN O B-COLUMN I-COLUMN B-VALUE O B-VALUE O


Question: Based on the population in 2020, calculate the percentage for the population of Asian in the zip code where the CBSA was Atmore, AL.

SELECT CAST(T2.asian_population AS REAL) * 100 / T2.population_2010 FROM CBSA AS T1 INNER JOIN zip_data AS T2 ON T1.CBSA = T2.CBSA WHERE T1.CBSA_name = 'Atmore, AL'

Based on the population in 2020 , calculate the percentage for the population of Asian in the zip code where the CBSA was Atmore , AL .

O O O B-COLUMN O O O O O O O O O O O O O O O O O B-COLUMN O B-VALUE I-VALUE I-VALUE O


Question: Please list the full names of all the customers who live in Italy.

SELECT T4.first_name, T4.last_name FROM address AS T1 INNER JOIN city AS T2 ON T1.city_id = T2.city_id INNER JOIN country AS T3 ON T2.country_id = T3.country_id INNER JOIN customer AS T4 ON T1.address_id = T4.address_id WHERE T3.country = 'Italy'

Please list the full names of all the customers who live in Italy .


Question: What are the names, locations, and years of opening for tracks with seating higher than average?

SELECT name ,  LOCATION ,  year_opened FROM track WHERE seating  >  (SELECT avg(seating) FROM track)

What are the names , locations , and years of opening for tracks with seating higher than average ?

O O O B-COLUMN O B-COLUMN O O B-COLUMN I-COLUMN I-COLUMN O B-TABLE O B-COLUMN O O O O


Question: What is the total sum of the donations paid with an optional support in projects that reach more than 300 students?

SELECT SUM(T2.dollar_amount) FROM projects AS T1 INNER JOIN donations AS T2 ON T1.projectid = T2.projectid WHERE T1.students_reached > 300 AND t2.donation_included_optional_support = 't'

What is the total sum of the donations paid with an optional support in projects that reach more than 300 students ?

O O O O O O O B-TABLE O O B-COLUMN I-COLUMN I-COLUMN O B-TABLE O O O O B-VALUE B-COLUMN O


Question: Tell me the title of the film in which Sandra Kilmer is one of the actors.

SELECT T3.title FROM film_actor AS T1 INNER JOIN actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T1.film_id = T3.film_id WHERE T2.first_name = 'SANDRA' AND T2.last_name = 'KILMER'

Tell me the title of the film in which Sandra Kilmer is one of the actors .

O O O B-COLUMN O O B-TABLE O O B-VALUE B-VALUE O O O O B-TABLE O


Question: Show the total number of keywords of the movie "I Hope They Serve Beer in Hell".

SELECT COUNT(T2.keyword_id) FROM movie AS T1 INNER JOIN movie_keywords AS T2 ON T1.movie_id = T2.movie_id WHERE T1.title = 'I Hope They Serve Beer in Hell'

Show the total number of keywords of the movie " I Hope They Serve Beer in Hell " .

O O B-COLUMN O O B-COLUMN O O B-TABLE O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O O


Question: what is the total package weight for each planet, list its name ?

select t3.name ,  sum(t1.weight) from package as t1 join shipment as t2 on t1.shipment = t2.shipmentid join planet as t3 on t2.planet = t3.planetid group by t2.planet;

what is the total package weight for each planet , list its name ?

O O O O B-TABLE B-COLUMN O O B-TABLE O O O B-COLUMN O


Question: What is the detail of document subset with name 'Best for 2000'?

SELECT Document_Subset_Details FROM Document_Subsets WHERE Document_Subset_Name = "Best for 2000";

What is the detail of document subset with name ' Best for 2000 ' ?

O O O O O B-TABLE I-TABLE B-COLUMN I-COLUMN O B-COLUMN I-COLUMN I-COLUMN O O


Question: What is the precise location of the place where Tommy Kono made a purchase in 2014?

SELECT DISTINCT T1.Latitude, T1.Longitude FROM geolocation AS T1 INNER JOIN `transaction` AS T2 ON T2.LocationID = T1.LocationID INNER JOIN customers AS T3 ON T3.CustomerID = T2.CustomerID WHERE T3.First = 'Tommy' AND T3.Last = 'Kono' AND T2.TransactionDate LIKE '2014%'

What is the precise location of the place where Tommy Kono made a purchase in 2014 ?

O O O O B-COLUMN O O O O B-VALUE B-VALUE O O O O B-VALUE O


Question: For the patient who got the laboratory test of uric acid level as 8.4 on 1991-10-21, how old was he/she at that time?

SELECT STRFTIME('%Y', T2.Date) - STRFTIME('%Y', T1.Birthday) FROM Patient AS T1 INNER JOIN Laboratory AS T2 ON T1.ID = T2.ID WHERE T2.UA = 8.4 AND T2.Date = '1991-10-21'

For the patient who got the laboratory test of uric acid level as 8.4 on 1991 - 10 - 21 , how old was he / she at that time ?

O O B-TABLE O O O B-TABLE O O O B-COLUMN O O B-VALUE O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O O O O O O O B-COLUMN O O O


Question: Among the films starred by Nick Wahlberg, what is the percentage of the films with G rating?

SELECT CAST(SUM(IIF(T3.rating = 'G', 1, 0)) AS REAL) / COUNT(T3.film_id) FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id WHERE T1.first_name = 'Elvis' AND T1.last_name = 'Marx'

Among the films starred by Nick Wahlberg , what is the percentage of the films with G rating ?

O O B-COLUMN O O O O O O O O O O O B-TABLE O B-VALUE B-COLUMN O


Question: What is the project detail for the project with document "King Book"?

SELECT T1.project_details FROM Projects AS T1 JOIN Documents AS T2 ON T1.project_id  =  T2.project_id WHERE T2.document_name  =  "King Book"

What is the project detail for the project with document " King Book " ?

O O O B-COLUMN I-COLUMN O O B-TABLE O B-TABLE O B-COLUMN I-COLUMN O O


Question: Return the investors who have invested in two or more entrepreneurs.

SELECT Investor FROM entrepreneur GROUP BY Investor HAVING COUNT(*)  >=  2

Return the investors who have invested in two or more entrepreneurs .


Question: For each student, find the student id, student biographical data, and the number of courses he or she takes.

SELECT T1.student_id ,  T1.bio_data ,  count(*) FROM Students AS T1 JOIN Classes AS T2 ON T1.student_id  =  T2.student_id GROUP BY T1.student_id

For each student , find the student i d , student biographical data , and the number of courses he or she takes .

O O O O O O B-COLUMN I-COLUMN I-COLUMN O B-TABLE O B-COLUMN O O O O O O O O O O O


Question: What is the order status code that is most common?

SELECT order_status_code FROM Customer_orders GROUP BY order_status_code ORDER BY count(*) DESC LIMIT 1

What is the order status code that is most common ?

O B-TABLE I-TABLE I-TABLE B-COLUMN I-COLUMN O O O O O


Question: How many products does each gender buy?

SELECT T1.gender_code ,  count(*) FROM Customers AS T1 JOIN Orders AS T2 ON T1.customer_id  =  T2.customer_id JOIN Order_items AS T3 ON T2.order_id  =  T3.order_id GROUP BY T1.gender_code

How many products does each gender buy ?


Question: What was the price of Bitcoin when it closed at the end of the day on 2013/4/29?

SELECT T2.close FROM coins AS T1 INNER JOIN historical AS T2 ON T1.id = T2.coin_id WHERE T2.date = '2013-04-29' AND T1.name = 'Bitcoin'

What was the price of Bitcoin when it closed at the end of the day on 2013/4/29 ?

O O O O O B-TABLE O O B-COLUMN B-COLUMN O O O O O O B-VALUE O


Question: Which part has a bigger size, "pink powder drab lawn cyan" or "cornflower sky burlywood green beige"?

SELECT T.p_name FROM ( SELECT p_name, p_size FROM part WHERE p_name IN ('pink powder drab lawn cyan', 'cornflower sky burlywood green beige') ) AS T ORDER BY p_size DESC LIMIT 1

Which part has a bigger size , " pink powder drab lawn cyan " or " cornflower sky burlywood green beige " ?

O B-TABLE O O O B-COLUMN O O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O O O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O O


Question: What was the number of goals did player Id "dyeba01" make in the 1921 Stanley Cup finals?

SELECT G FROM ScoringSC WHERE playerID = 'dyeba01' AND year = 1921

What was the number of goals did player I d " dyeba01 " make in the 1921 Stanley Cup finals ?

O O O O O O O B-COLUMN B-COLUMN I-COLUMN O B-VALUE O O O O B-VALUE O O O O


Question: Among the schools' projects whose donation didn't use account credits redemption,how many schools are public magnet schools?

SELECT COUNT(T1.schoolid) FROM projects AS T1 INNER JOIN donations AS T2 ON T1.projectid = T2.projectid WHERE T1.school_magnet = 't' AND T2.payment_included_acct_credit = 'f'

Among the schools ' projects whose donation did n't use account credits redemption , how many schools are public magnet schools ?

O O O O B-TABLE O B-TABLE O O O O O O O O O B-COLUMN I-COLUMN O O B-COLUMN O


Question: Provide the score of the most populated university in 2011.

SELECT T2.score FROM university_year AS T1 INNER JOIN university_ranking_year AS T2 ON T1.university_id = T2.university_id WHERE T1.year = 2011 ORDER BY T1.num_students DESC LIMIT 1

Provide the score of the most populated university in 2011 .

O O B-COLUMN O O O O B-COLUMN B-TABLE B-VALUE O


Question: Which team has the highest number of losses of all time?

SELECT T1.Team_Name FROM Team AS T1 INNER JOIN ( SELECT COUNT(Team_1) AS a, Team_1 FROM Match WHERE Team_1 <> Match_Winner GROUP BY Team_1 UNION SELECT COUNT(Team_2) AS a, Team_2 FROM Match WHERE Team_2 <> Match_Winner GROUP BY Team_2 ORDER BY a DESC LIMIT 1 ) AS T2 ON T1.Team_Id = T2.Team_1

Which team has the highest number of losses of all time ?


Question: How many papers were published in 2005. Calculate the difference between the number of paper published in 2005 and the number of paper published in the previous year.

SELECT SUM(CASE WHEN Year = 2005 THEN 1 ELSE 0 END) , SUM(CASE WHEN year = 2005 THEN 1 ELSE 0 END) - SUM(CASE WHEN year = 2004 THEN 1 ELSE 0 END) AS diff FROM Paper

How many papers were published in 2005 . Calculate the difference between the number of paper published in 2005 and the number of paper published in the previous year .

O O O O O O B-VALUE O O O O O O O O B-TABLE O O B-VALUE O O O O O O O O O B-COLUMN O


Question: Which planet has most shipments? List the planet name.

SELECT T2.Name FROM Shipment AS T1 JOIN Planet AS T2 ON T1.Planet = T2.PlanetID GROUP BY T1.Planet ORDER BY count(*) DESC LIMIT 1;

Which planet has most shipments ? List the planet name .

O O O O B-TABLE O O O B-TABLE B-COLUMN O


Question: On which date was the part "burnished seashell gainsboro navajo chocolate" in order no.1 shipped?

SELECT T1.l_shipdate FROM lineitem AS T1 INNER JOIN part AS T2 ON T1.l_partkey = T2.p_partkey WHERE T1.l_orderkey = 1 AND T2.p_name = 'burnished seashell gainsboro navajo chocolate'

On which date was the part " burnished seashell gainsboro navajo chocolate " in order no.1 shipped ?

O B-COLUMN I-COLUMN O O B-TABLE O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O O B-COLUMN O O O


Question: Show the most common nationality of customers.

SELECT Nationality FROM customer GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1

Show the most common nationality of customers .


Question: List the organisation id with the maximum outcome count, and the count.

SELECT T1.organisation_id ,  count(*) FROM Projects AS T1 JOIN Project_outcomes AS T2 ON T1.project_id  =  T2.project_id GROUP BY T1.organisation_id ORDER BY count(*) DESC LIMIT 1

List the organisation i d with the maximum outcome count , and the count .

O O B-COLUMN I-COLUMN I-COLUMN O O O B-TABLE O O O O O O


Question: What are the atom IDs of the bond TR000_2_5?

SELECT T.atom_id FROM connected AS T WHERE T.bond_id = 'TR000_2_5'

What are the atom IDs of the bond TR000_2_5 ?

O O O B-COLUMN I-COLUMN O O B-COLUMN B-VALUE O


Question: Show the names of donors who donated to both school "Glenn" and "Triton."

SELECT T1.donator_name FROM endowment AS T1 JOIN school AS T2 ON T1.school_id  =  T2.school_id WHERE T2.school_name  =  'Glenn' INTERSECT SELECT T1.donator_name FROM endowment AS T1 JOIN school AS T2 ON T1.school_id  =  T2.school_id WHERE T2.school_name  =  'Triton'

Show the names of donors who donated to both school " Glenn " and " Triton . "

O O O O O O B-COLUMN O O B-TABLE O B-VALUE O O O B-VALUE O O


Question: Please list the Nicknames of the players who got in the Hall of Fame in 2007.

SELECT DISTINCT T1.nameNick FROM Master AS T1 INNER JOIN HOF AS T2 ON T1.hofID = T2.hofID WHERE T2.year = 2007

Please list the Nicknames of the players who got in the Hall of Fame in 2007 .

O O O O O O O O O O O O B-TABLE O O B-VALUE O


Question: How many camera lenses have a focal length longer than 15 mm?

SELECT count(*) FROM camera_lens WHERE focal_length_mm  >  15

How many camera lenses have a focal length longer than 15 mm ?

O O B-TABLE I-TABLE O O B-COLUMN I-COLUMN O O B-VALUE O O


Question: What are largest height and width dimensions for paintings in each year?

SELECT max(height_mm) ,  max(width_mm) ,  YEAR FROM paintings GROUP BY YEAR ORDER BY YEAR

What are largest height and width dimensions for paintings in each year ?

O O O B-COLUMN O B-COLUMN O O B-TABLE O O B-COLUMN O


Question: What the percentage of the english methods among the methods whose comments is XML format?

SELECT CAST(SUM(CASE WHEN Lang = 'en' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(Name) FROM Method WHERE CommentIsXml = 1

What the percentage of the english methods among the methods whose comments is XML format ?

O O O O O O O B-COLUMN O B-TABLE O B-COLUMN I-COLUMN I-COLUMN O O


Question: How many units of item no.5 were sold in store no.3 on the day the temperature range was the biggest?

SELECT t2.units FROM relation AS T1 INNER JOIN sales_in_weather AS T2 ON T1.store_nbr = T2.store_nbr INNER JOIN weather AS T3 ON T1.station_nbr = T3.station_nbr WHERE T2.store_nbr = 3 AND T2.item_nbr = 5 ORDER BY t3.tmax - t3.tmin DESC LIMIT 1

How many units of item no.5 were sold in store no.3 on the day the temperature range was the biggest ?

O O B-COLUMN O B-COLUMN O O O B-COLUMN B-COLUMN O O O O O O O B-TABLE I-TABLE O O


Question: Give the year where a university had the lowest number of students.

SELECT year FROM university_year ORDER BY num_students ASC LIMIT 1

Give the year where a university had the lowest number of students .

O O B-COLUMN O O B-TABLE O O O O O B-COLUMN O


Question: Is the donor of the project 'Calculate, Financial Security For Tomorrow Starts Today! ' a teacher?

SELECT T2.is_teacher_acct FROM essays AS T1 INNER JOIN donations AS T2 ON T1.projectid = T2.projectid WHERE T1.title LIKE 'Calculate, Financial Security For Tomorrow Starts Today! '

Is the donor of the project ' Calculate , Financial Security For Tomorrow Starts Today ! ' a teacher ?

O O O O O B-COLUMN O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O B-COLUMN O


Question: Give the name of the student in the History department with the most credits.

SELECT name FROM student WHERE dept_name  =  'History' ORDER BY tot_cred DESC LIMIT 1

Give the name of the student in the History department with the most credits .

O O B-COLUMN O O B-TABLE O O B-VALUE B-COLUMN O O B-COLUMN I-COLUMN O


Question: Among the products with an order quantity of no less than 5 that was shipped in the month of May 2019, what is the name of the product with the lowest net profit?

SELECT T2.`Product Name` FROM `Sales Orders` AS T1 INNER JOIN Products AS T2 ON T2.ProductID = T1._ProductID WHERE T1.`Order Quantity` > 5 AND ShipDate LIKE '5/%/19' ORDER BY REPLACE(T1.`Unit Price`, ',', '') - REPLACE(T1.`Unit Cost`, ',', '') ASC LIMIT 1

Among the products with an order quantity of no less than 5 that was shipped in the month of May 2019 , what is the name of the product with the lowest net profit ?

O O B-TABLE O B-TABLE I-TABLE B-COLUMN I-COLUMN O O O B-VALUE O O B-COLUMN O O O O O O B-VALUE O O O O O O B-COLUMN O O O B-COLUMN I-COLUMN O


Question: List at least 3 categories with the lowest number of users.

SELECT T1.category FROM label_categories AS T1 INNER JOIN app_labels AS T2 ON T1.label_id = T2.label_id ORDER BY T2.label_id LIMIT 3

List at least 3 categories with the lowest number of users .


Question: How many performances are there?


Question: What are the names of musicals who have no actors?

SELECT Name FROM musical WHERE Musical_ID NOT IN (SELECT Musical_ID FROM actor)

What are the names of musicals who have no actors ?

O O O B-COLUMN O B-TABLE O O O B-TABLE O


Question: List the full names and phone numbers of clients that were from the Pacific.

SELECT T1.first, T1.middle, T1.last, T1.phone FROM client AS T1 INNER JOIN district AS T2 ON T1.district_id = T2.district_id WHERE T2.division = 'Pacific'

List the full names and phone numbers of clients that were from the Pacific .

B-COLUMN O O O O B-COLUMN O O B-TABLE O O O O B-VALUE O


Question: What is the description of the footnote on the series code AG.LND.FRST.K2 in 1990 for Aruba?

SELECT T2.Description FROM Country AS T1 INNER JOIN FootNotes AS T2 ON T1.CountryCode = T2.Countrycode WHERE T1.ShortName = 'Aruba' AND T2.Seriescode = 'AG.LND.FRST.K2' AND T2.Year = 'YR1990'

What is the description of the footnote on the series code AG.LND.FRST.K2 in 1990 for Aruba ?

O O O B-COLUMN O O B-TABLE O O B-COLUMN I-COLUMN B-VALUE O B-VALUE O B-VALUE O


Question: Show the minimum, maximum, average price for all products.

SELECT min(product_price) ,  max(product_price) ,  avg(product_price) FROM products

Show the minimum , maximum , average price for all products .


Question: How many shipments in 2017 were done by Sue Newell?

SELECT COUNT(*) FROM shipment AS T1 INNER JOIN driver AS T2 ON T1.driver_id = T2.driver_id WHERE STRFTIME('%Y', T1.ship_date) = '2017' AND T2.first_name = 'Sue' AND T2.last_name = 'Newell'

How many shipments in 2017 were done by Sue Newell ?

O O B-TABLE O B-VALUE O O O B-VALUE B-VALUE O


Question: Who is the tallest camera operator?

SELECT T2.name FROM Credit AS T1 INNER JOIN Person AS T2 ON T2.person_id = T1.person_id WHERE T1.role = 'camera operator' ORDER BY T2.height_meters DESC LIMIT 1


Question: What are the names of perpetrators in country "China" or "Japan"?

SELECT T1.Name FROM people AS T1 JOIN perpetrator AS T2 ON T1.People_ID  =  T2.People_ID WHERE T2.Country  =  "China" OR T2.Country  =  "Japan"

What are the names of perpetrators in country " China " or " Japan " ?

O O O B-COLUMN O B-TABLE O B-COLUMN O B-COLUMN O O O B-COLUMN O O


Question: What is the average height of people from USA?

SELECT AVG(height_meters) FROM Person WHERE birth_country = 'USA';

What is the average height of people from USA ?


Question: How many card border with black color ? List out the card id.

SELECT id FROM cards WHERE borderColor = 'black' GROUP BY id

How many card border with black color ? List out the card i d.

O O O B-COLUMN O B-VALUE O O O O O B-TABLE B-COLUMN I-COLUMN


Question: For the client who applied 98832 USD loan in 1996/1/3, when was his/her birthday?

SELECT T4.birth_date FROM loan AS T1 INNER JOIN account AS T2 ON T1.account_id = T2.account_id INNER JOIN disp AS T3 ON T2.account_id = T3.account_id INNER JOIN client AS T4 ON T3.client_id = T4.client_id WHERE T1.date = '1996-01-03' AND T1.amount = 98832

For the client who applied 98832 USD loan in 1996/1/3 , when was his / her birthday ?

O O B-TABLE O O B-VALUE O B-TABLE O B-VALUE O O O O O O B-COLUMN O


Question: What is the minimum of International migrant stock, total of heavily indebted poor countries?

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'

What is the minimum of International migrant stock , total of heavily indebted poor countries ?

O O O O O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O O O O B-TABLE O


Question: show all train numbers and names ordered by their time from early to late.

SELECT train_number ,  name FROM train ORDER BY TIME

show all train numbers and names ordered by their time from early to late .

O O B-TABLE B-COLUMN O B-COLUMN O O O B-COLUMN O O O O O


Question: What are the code and description of the least frequent detention type ?

SELECT T1.detention_type_code ,  T2.detention_type_description FROM Detention AS T1 JOIN Ref_Detention_Type AS T2 ON T1.detention_type_code  =  T2.detention_type_code GROUP BY T1.detention_type_code ORDER BY count(*) ASC LIMIT 1


Question: Find the names of the top 10 airlines that operate the most number of routes.

SELECT T1.name ,  T2.alid FROM airlines AS T1 JOIN routes AS T2 ON T1.alid  =  T2.alid GROUP BY T2.alid ORDER BY count(*) DESC LIMIT 10

Find the names of the top 10 airlines that operate the most number of routes .

O O B-COLUMN O O O O B-TABLE O O O O O O B-TABLE O


Question: Show ids for all the male faculty.

SELECT FacID FROM Faculty WHERE Sex  =  'M'


Question: List the tax code and inspection type of the business named "Rue Lepic".

SELECT DISTINCT T3.tax_code, T2.type FROM violations AS T1 INNER JOIN inspections AS T2 ON T1.business_id = T2.business_id INNER JOIN businesses AS T3 ON T2.business_id = T3.business_id WHERE T3.name = 'Rue Lepic'

List the tax code and inspection type of the business named " Rue Lepic " .

O O B-COLUMN I-COLUMN O B-TABLE B-COLUMN O O B-TABLE B-COLUMN O B-VALUE I-VALUE O O


Question: Please list the unit measure code of the component that is of the greatest need in quantity to create the assembly.

SELECT UnitMeasureCode FROM BillOfMaterials ORDER BY PerAssemblyQty DESC LIMIT 1

Please list the unit measure code of the component that is of the greatest need in quantity to create the assembly .

O O O B-COLUMN I-COLUMN I-COLUMN O O O O O O O O O O O O O O B-COLUMN O


Question: What is the major of Garrett Gerke and which department does it belong to?

SELECT T2.major_name, T2.department FROM member AS T1 INNER JOIN major AS T2 ON T2.major_id = T1.link_to_major WHERE T1.first_name = 'Garrett' AND T1.last_name = 'Gerke'

What is the major of Garrett Gerke and which department does it belong to ?

O O O B-TABLE O B-VALUE B-VALUE O O B-COLUMN O O O O O


Question: What is the most common type of ships?

SELECT TYPE FROM ship GROUP BY TYPE ORDER BY COUNT(*) DESC LIMIT 1


Question: What are the names of companies whose headquarters are not "USA"?

SELECT name FROM Companies WHERE Headquarters != 'USA'

What are the names of companies whose headquarters are not " USA " ?

O O O B-COLUMN O B-TABLE O B-COLUMN O O O B-VALUE O O


Question: Please list the full names of all the students who took the course Machine Learning Theory.

SELECT T1.f_name, T1.l_name FROM student AS T1 INNER JOIN registration AS T2 ON T1.student_id = T2.student_id INNER JOIN course AS T3 ON T2.course_id = T3.course_id WHERE T3.name = 'Machine Learning Theory'

Please list the full names of all the students who took the course Machine Learning Theory .

O O O O B-COLUMN O O O B-TABLE O O O B-TABLE B-VALUE I-VALUE I-VALUE O


Question: How many songs listed are not performed?

SELECT count(*) FROM songs WHERE id NOT IN ( SELECT songs_id FROM performance_score );

How many songs listed are not performed ?


Question: What are the titles of books that are not "Poet"?

SELECT Title FROM book WHERE TYPE != "Poet"

What are the titles of books that are not " Poet " ?

O O O B-COLUMN O B-TABLE O O O O B-COLUMN O O


Question: Who is the publisher of Sauron?

SELECT T2.publisher_name FROM superhero AS T1 INNER JOIN publisher AS T2 ON T1.publisher_id = T2.id WHERE T1.superhero_name = 'Sauron'


Question: Find the first name and age of students who are living in the dorms that do not have amenity TV Lounge.

SELECT T1.fname ,  T1.age FROM student AS T1 JOIN lives_in AS T2 ON T1.stuid  =  T2.stuid WHERE T2.dormid NOT IN (SELECT T3.dormid FROM has_amenity AS T3 JOIN dorm_amenity AS T4 ON T3.amenid  =  T4.amenid WHERE T4.amenity_name  =  'TV Lounge')

Find the first name and age of students who are living in the dorms that do not have amenity TV Lounge .

O O O B-COLUMN O B-COLUMN O B-COLUMN O O B-TABLE O O B-COLUMN O O O O B-COLUMN B-VALUE I-VALUE O


Question: List every city in San Mateo County.

SELECT city FROM geographic WHERE county = 'san mateo county'

O O B-COLUMN O B-VALUE I-VALUE B-COLUMN O


Question: Who sent most number of packages? List client name and number of packages sent by that client.

SELECT T2.Name ,  count(*) FROM PACKAGE AS T1 JOIN Client AS T2 ON T1.Sender  =  T2.AccountNumber GROUP BY T1.Sender ORDER BY count(*) DESC LIMIT 1;

Who sent most number of packages ? List client name and number of packages sent by that client .

O B-COLUMN O O O B-TABLE O O O B-COLUMN B-COLUMN I-COLUMN O O O O O B-TABLE O


Question: What is the name of the product with the highest price?

SELECT Product_Name FROM Products ORDER BY Product_Price DESC LIMIT 1

What is the name of the product with the highest price ?


Question: For patients with severe degree of thrombosis, list their ID, sex and disease the patient is diagnosed with.

SELECT DISTINCT T1.ID, T1.SEX, T1.Diagnosis FROM Patient AS T1 INNER JOIN Examination AS T2 ON T1.ID = T2.ID WHERE T2.Thrombosis = 2

For patients with severe degree of thrombosis , list their ID , sex and disease the patient is diagnosed with .

O O O O O O B-COLUMN O O O B-COLUMN O B-COLUMN O O O B-TABLE O B-COLUMN O O


Question: What is the owner of document with the Description 'Braeden Collection'?

SELECT OWNER FROM Document_Objects WHERE Description  =  'Braeden Collection'

What is the owner of document with the Description ' Braeden Collection ' ?

O O O B-COLUMN O B-TABLE O O B-COLUMN O B-VALUE I-VALUE O O


Question: Find the name of all the services which either have been used by customer "Hardy Kutch" or have been rated as "good" in one of the customer interactions.

SELECT DISTINCT t3.service_details FROM customers AS t1 JOIN customers_and_services AS t2 ON t1.customer_id  =  t2.customer_id JOIN services AS t3 ON t2.service_id  =  t3.service_id JOIN customer_interactions AS t4 ON t3.service_id  =  t4.service_id WHERE t1.customer_details  =  "Hardy Kutch" OR t4.services_and_channels_details  =  "good"

Find the name of all the services which either have been used by customer " Hardy Kutch " or have been rated as " good " in one of the customer interactions .

O O O O O O B-TABLE O O O O O O B-COLUMN O B-COLUMN I-COLUMN O O O O O O O B-COLUMN O O O O O B-TABLE B-TABLE O


Question: List all the solutions ids of the repository with "636430969128176000" processed time

SELECT T2.Id FROM Repo AS T1 INNER JOIN Solution AS T2 ON T1.Id = T2.RepoId WHERE T1.ProcessedTime = 636430969128176000

List all the solutions ids of the repository with " 636430969128176000 " processed time

O O O B-TABLE B-COLUMN O O B-COLUMN O O B-VALUE O B-COLUMN I-COLUMN


Question: Which song names have the substring "Is"?

SELECT name FROM songs WHERE name LIKE "%Is%"

Which song names have the substring " Is " ?


Question: Among the active businesses located at Goodyear, AZ, list the category and atrributes of business with a high review count.

SELECT T3.category_name, T5.attribute_name FROM Business AS T1 INNER JOIN Business_Categories AS T2 ON T1.business_id = T2.business_id INNER JOIN Categories AS T3 ON T2.category_id = T3.category_id INNER JOIN Business_Attributes AS T4 ON T1.business_id = T4.business_id INNER JOIN Attributes AS T5 ON T4.attribute_id = T5.attribute_id WHERE T1.review_count = 'High' AND T1.city = 'Goodyear' AND T1.state = 'AZ' AND T1.active = 'true'

Among the active businesses located at Goodyear , AZ , list the category and atrributes of business with a high review count .

O O B-COLUMN B-TABLE O O B-VALUE O B-VALUE O B-COLUMN I-COLUMN B-TABLE O B-TABLE O B-TABLE O O B-VALUE B-COLUMN I-COLUMN O


Question: How many English language codes whose comments for the method are in the XML format?

SELECT COUNT(Lang) FROM Method WHERE Lang = 'en' AND CommentIsXml = 1

How many English language codes whose comments for the method are in the XML format ?

O O O B-COLUMN O O B-COLUMN O O B-TABLE O O O O O O


Question: What are the names and headquarters of all manufacturers, ordered by revenue descending?

SELECT name ,  headquarter FROM manufacturers ORDER BY revenue DESC

What are the names and headquarters of all manufacturers , ordered by revenue descending ?

O O O B-COLUMN O B-COLUMN O O B-TABLE O O O B-COLUMN O O


Question: What are the names of products with price at most 200?

SELECT name FROM products WHERE price  <=  200

What are the names of products with price at most 200 ?

O O O B-COLUMN O B-TABLE O B-COLUMN O O B-VALUE O


Question: How many votes did the episode titled Juvenile get?

SELECT SUM(T2.votes) FROM Episode AS T1 INNER JOIN Vote AS T2 ON T1.episode_id = T2.episode_id WHERE T1.title = 'Juvenile'

How many votes did the episode titled Juvenile get ?

O O B-TABLE O O B-TABLE B-COLUMN B-VALUE O O


Question: How many customers are there in Canada?

SELECT COUNT(T2.CustomerID) FROM SalesTerritory AS T1 INNER JOIN Customer AS T2 ON T1.TerritoryID = T2.TerritoryID WHERE T1.Name = 'Canada'

How many customers are there in Canada ?


Question: Which country has the tallest person in the crew?

SELECT birth_country FROM Person ORDER BY height_meters DESC LIMIT 1;

Which country has the tallest person in the crew ?


Question: List the violation type ID of business with business ID from 30 to 50 and located at 747 IRVING St, San Francisco.

SELECT DISTINCT T1.violation_type_id FROM violations AS T1 INNER JOIN businesses AS T2 ON T1.business_id = T2.business_id WHERE T2.business_id BETWEEN 30 AND 50 AND T2.address = '747 IRVING St' AND T2.city = 'San Francisco'

List the violation type ID of business with business ID from 30 to 50 and located at 747 IRVING St , San Francisco .

O O B-TABLE B-COLUMN I-COLUMN O B-TABLE O B-COLUMN I-COLUMN O B-VALUE O B-VALUE O O O B-VALUE I-VALUE I-VALUE O B-VALUE I-VALUE O


Question: How many students are 18 years old?

SELECT count(*) FROM Student WHERE age  =  18


Question: Give the phone number of the customer who placed the order id 10264.

SELECT T1.Phone FROM Customers AS T1 INNER JOIN Orders AS T2 ON T1.CustomerID = T2.CustomerID WHERE T2.OrderID = 10264

Give the phone number of the customer who placed the order i d 10264 .

O O B-COLUMN O O O B-TABLE O O O B-TABLE B-COLUMN I-COLUMN B-VALUE O


Question: Please provide the address of the customer whose first name is SUSAN with the postal code 77948.

SELECT T1.address FROM address AS T1 INNER JOIN customer AS T2 ON T1.address_id = T2.address_id WHERE T2.first_name = 'SUSAN' AND T1.postal_code = 77948

Please provide the address of the customer whose first name is SUSAN with the postal code 77948 .

O O O B-TABLE O O B-TABLE O B-COLUMN I-COLUMN O B-VALUE O O B-COLUMN I-COLUMN B-VALUE O


Question: What is the average loan amount by male borrowers?

SELECT AVG(T4.amount) FROM client AS T1 INNER JOIN disp AS T2 ON T1.client_id = T2.client_id INNER JOIN account AS T3 ON T2.account_id = T3.account_id INNER JOIN loan AS T4 ON T3.account_id = T4.account_id WHERE T1.gender = 'M'

What is the average loan amount by male borrowers ?


Question: What are the ids of all reviewers who have not given 4 stars at least once?

What are the ids of all reviewers who have not given 4 stars at least once ?

O O O B-COLUMN O O O O O O O B-VALUE B-COLUMN O O O O


Question: Who has friends that are older than the average age? Print their friends and their ages as well

SELECT DISTINCT T2.name ,  T2.friend ,  T1.age FROM Person AS T1 JOIN PersonFriend AS T2 ON T1.name  =  T2.friend WHERE T1.age  >  (SELECT avg(age) FROM person)

Who has friends that are older than the average age ? Print their friends and their ages as well

O O O O O O O O O B-COLUMN O O B-TABLE B-COLUMN O O O O O


Question: Please list the names of the players who use the right hand as their batting hand and are from Australia.

SELECT T2.Player_Name FROM Country AS T1 INNER JOIN Player AS T2 ON T2.Country_Name = T1.Country_id INNER JOIN Batting_Style AS T3 ON T2.Batting_hand = T3.Batting_Id WHERE T1.Country_Name = 'Australia' AND T3.Batting_Hand = 'Right-hand bat'

Please list the names of the players who use the right hand as their batting hand and are from Australia .

O O O O O O B-TABLE O O O B-VALUE I-VALUE I-VALUE O B-COLUMN B-COLUMN O O O B-VALUE O


Question: How many units of item 7 have been sold by store 7 when the snow is less than 5 inches?

SELECT SUM(units) FROM weather AS T1 INNER JOIN relation AS T2 ON T1.station_nbr = T2.station_nbr INNER JOIN sales_in_weather AS T3 ON T2.store_nbr = T3.store_nbr WHERE T2.store_nbr = 7 AND T3.item_nbr = 7 AND T1.snowfall < 5

How many units of item 7 have been sold by store 7 when the snow is less than 5 inches ?

O O B-COLUMN O B-COLUMN O O O O O B-COLUMN B-VALUE B-TABLE I-TABLE B-COLUMN O O O B-VALUE O O


Question: Among the cities with a population between 140000 and 150000, list the country that has life expectancy greater than 80% life expectancy of all countries.

SELECT T2.Name FROM City AS T1 INNER JOIN Country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Population BETWEEN 140000 AND 150000 GROUP BY T2.Name, LifeExpectancy HAVING LifeExpectancy < ( SELECT AVG(LifeExpectancy) FROM Country ) * 0.8

Among the cities with a population between 140000 and 150000 , list the country that has life expectancy greater than 80 % life expectancy of all countries .

O O B-TABLE O O B-COLUMN O B-VALUE O B-VALUE O O O B-TABLE O O B-COLUMN I-COLUMN O O O O O O O O O O


Question: What is the average unit price of a Cookware product?

SELECT AVG(REPLACE(T1.`Unit Price`, ',', '')) FROM `Sales Orders` AS T1 INNER JOIN Products AS T2 ON T2.ProductID = T1._ProductID WHERE T2.`Product Name` = 'Cookware'

What is the average unit price of a Cookware product ?

O O O O B-COLUMN I-COLUMN O O B-VALUE B-TABLE O


Question: Among all the current legislators whose religion is Roman Catholic, what is the percentage of the ones without an instagram account?

SELECT CAST(SUM(CASE WHEN T1.instagram IS NULL THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(*) FROM `social-media` AS T1 INNER JOIN current AS T2 ON T1.bioguide = T2.bioguide_id WHERE T2.religion_bio = 'Roman Catholic'

Among all the current legislators whose religion is Roman Catholic , what is the percentage of the ones without an instagram account ?

O O O B-TABLE O O B-COLUMN O B-VALUE I-VALUE O O O O O O O O O O B-COLUMN O O


Question: List out all post ID with score more than 60 and list out all the user ID that created these post.

SELECT PostId, UserId FROM postHistory WHERE PostId IN ( SELECT Id FROM posts WHERE Score > 60 )

List out all post ID with score more than 60 and list out all the user ID that created these post .

O O O B-COLUMN B-COLUMN O B-COLUMN O O B-VALUE O O O O O B-COLUMN I-COLUMN O O O B-TABLE O


Question: What is the status code, phone number, and email address of the customer whose last name is Kohler or whose first name is Marina?

SELECT customer_status_code ,  cell_mobile_phone_number ,  email_address FROM Customers WHERE first_name = "Marina" OR last_name  =  "Kohler"

What is the status code , phone number , and email address of the customer whose last name is Kohler or whose first name is Marina ?

O O B-COLUMN I-COLUMN I-COLUMN B-COLUMN I-COLUMN I-COLUMN O O B-COLUMN I-COLUMN O O B-TABLE O B-COLUMN I-COLUMN O B-COLUMN O O B-COLUMN I-COLUMN O B-COLUMN O


Question: Show the ids of the faculty who don't participate in any activity.

SELECT FacID FROM Faculty EXCEPT SELECT FacID FROM Faculty_participates_in

Show the ids of the faculty who do n't participate in any activity .

O O O O O B-TABLE O O O B-TABLE I-TABLE O O O


Question: Show the names and other details for all authors.

SELECT author_name ,  other_details FROM Authors

Show the names and other details for all authors .


Question: How many clients are there?


Question: Please list the titles of all the books in British English.

SELECT T1.title FROM book AS T1 INNER JOIN book_language AS T2 ON T1.language_id = T2.language_id WHERE T2.language_name = 'British English'

Please list the titles of all the books in British English .

O O O B-COLUMN O O O B-TABLE O B-VALUE I-VALUE O


Question: Find the response status to customer whose geographic ID of 134.

SELECT T2.RESPONSE FROM Customers AS T1 INNER JOIN mailings3 AS T2 ON T1.ID = T2.REFID WHERE T1.GEOID = 134

Find the response status to customer whose geographic ID of 134 .

B-COLUMN O B-COLUMN O O B-TABLE O O B-COLUMN O B-VALUE O


Question: What does the person with the phone number "809-555-3360" major in?

SELECT T2.major_name FROM member AS T1 INNER JOIN major AS T2 ON T1.link_to_major = T2.major_id WHERE T1.phone = '809-555-3360'

What does the person with the phone number " 809 - 555 - 3360 " major in ?

O O O O O O B-COLUMN B-TABLE O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O B-TABLE O O


Question: List the names and scores of all wines.

List the names and scores of all wines .


Question: What were the ids, dates, and status codes for orders made by Jeromy?

SELECT order_id ,  order_date ,  order_status_code FROM Customer_orders AS T1 JOIN Customers AS T2 ON T1.customer_id  =  T2.customer_id WHERE T2.customer_name  =  "Jeromy"

What were the ids , dates , and status codes for orders made by Jeromy ?

O O O O O O O O B-COLUMN B-TABLE I-TABLE B-COLUMN B-COLUMN O B-COLUMN O


Question: On what dates did the student whose personal name is "Karson" enroll in and complete the courses?

SELECT T1.date_of_enrolment ,  T1.date_of_completion FROM Student_Course_Enrolment AS T1 JOIN Students AS T2 ON T1.student_id  =  T2.student_id WHERE T2.personal_name  =  "Karson"

On what dates did the student whose personal name is " Karson " enroll in and complete the courses ?

O O O O O B-TABLE B-TABLE B-COLUMN I-COLUMN O O B-COLUMN O O O O O O O O


Question: List all the comments on the lowest rated Mature 17+ app.

SELECT T2.Translated_Review FROM playstore AS T1 INNER JOIN user_reviews AS T2 ON T1.App = T2.App WHERE T1."Content Rating" = 'Mature 17+' ORDER BY T1.Rating LIMIT 1

List all the comments on the lowest rated Mature 17 + app .

O O O O O O O O B-VALUE I-VALUE I-VALUE B-COLUMN O


Question: Among the businesses in Chandler, list the attribute of the business with a low review count.

SELECT DISTINCT T3.attribute_id, T3.attribute_name FROM Business AS T1 INNER JOIN Business_Attributes AS T2 ON T1.business_id = T2.attribute_id INNER JOIN Attributes AS T3 ON T2.attribute_id = T3.attribute_id WHERE T1.review_count = 'Low' AND T1.city = 'Chandler'

Among the businesses in Chandler , list the attribute of the business with a low review count .

O O O O B-VALUE O O O B-TABLE O O B-TABLE O O B-VALUE B-COLUMN I-COLUMN O


Question: What are the comments of the inspector during the inspection of Taqueria La Fiesta on 1/25/2010?

SELECT T3.inspector_comment FROM establishment AS T1 INNER JOIN inspection AS T2 ON T1.license_no = T2.license_no INNER JOIN violation AS T3 ON T2.inspection_id = T3.inspection_id WHERE T2.inspection_date = '2010-01-25' AND T1.dba_name = 'TAQUERIA LA FIESTA'

What are the comments of the inspector during the inspection of Taqueria La Fiesta on 1/25/2010 ?

O O O O O O B-COLUMN O O B-TABLE O B-VALUE I-VALUE I-VALUE O O O


Question: What is the difference of female and male audiences in number who viewed horror movies?

SELECT SUM(IIF(T2.u_gender = 'F', 1, 0)) - SUM(IIF(T2.u_gender = 'M', 1, 0)) FROM u2base AS T1 INNER JOIN users AS T2 ON T1.userid = T2.userid INNER JOIN movies2directors AS T3 ON T3.movieid = T1.movieid WHERE T3.genre = 'horror'

What is the difference of female and male audiences in number who viewed horror movies ?

O O O O B-VALUE O O O O O O O O B-VALUE B-COLUMN O


Question: Which nation, with a population ranging from 60,000,000 to 99,000,000, has the greatest gross domestic product?

SELECT T1.Name, T2.GDP FROM country AS T1 INNER JOIN economy AS T2 ON T1.Code = T2.Country WHERE T1.Population BETWEEN 60000000 AND 90000000 ORDER BY T2.GDP DESC LIMIT 1

Which nation , with a population ranging from 60,000,000 to 99,000,000 , has the greatest gross domestic product ?

O O O O O B-COLUMN O O B-VALUE O B-VALUE O O O O O O O O


Question: What are the full names and hire dates for employees in the same department as someone with the first name Clara?

SELECT first_name ,  last_name ,  hire_date FROM employees WHERE department_id  =  (SELECT department_id FROM employees WHERE first_name  =  "Clara")

What are the full names and hire dates for employees in the same department as someone with the first name Clara ?

O O O O O O B-COLUMN I-COLUMN O B-TABLE O O O B-COLUMN O O O O B-COLUMN I-COLUMN B-COLUMN O


Question: Among the movie in which Dariusz Wolski works as the director of photography, what is the percentage of those movie whose vote average is over 5.0?

SELECT CAST(COUNT(CASE WHEN T1.vote_average > 5 THEN 1 ELSE NULL END) AS REAL) * 100 / COUNT(T1.vote_average) FROM movie AS T1 INNER JOIN movie_crew AS T2 ON T1.movie_id = T2.movie_id INNER JOIN person AS T3 ON T2.person_id = T3.person_id WHERE T3.person_name = 'Dariusz Wolski' AND T2.job = 'Director of Photography'

Among the movie in which Dariusz Wolski works as the director of photography , what is the percentage of those movie whose vote average is over 5.0 ?

O O B-TABLE O O B-VALUE I-VALUE O O O B-VALUE I-VALUE I-VALUE O O O O O O O B-TABLE O B-COLUMN I-COLUMN O O O O


Question: Calculate the average number of complaints received from New Bedford each year which are closed with explanation.

SELECT STRFTIME('%Y', T3.`Date received`) , CAST(SUM(CASE WHEN T3.`Company response to consumer` = 'Closed with explanation' THEN 1 ELSE 0 END) AS REAL) / COUNT(T3.`Complaint ID`) AS average FROM callcenterlogs AS T1 INNER JOIN client AS T2 ON T1.`rand client` = T2.client_id INNER JOIN events AS T3 ON T1.`Complaint ID` = T3.`Complaint ID` WHERE T2.city = 'New Bedford' GROUP BY strftime('%Y', T3.`Date received`)

Calculate the average number of complaints received from New Bedford each year which are closed with explanation .

O O O O O B-TABLE B-COLUMN O B-VALUE I-VALUE O O O O B-VALUE I-VALUE I-VALUE O


Question: Please list the IDs of the top 3 professors that teaches the most courses.

SELECT T1.p_id FROM taughtBy AS T1 INNER JOIN person AS T2 ON T1.p_id = T2.p_id WHERE T2.professor = 1 GROUP BY T1.p_id ORDER BY COUNT(*) DESC LIMIT 3

Please list the IDs of the top 3 professors that teaches the most courses .


Question: How many schools in urban area requested for books resources?

SELECT COUNT(T2.schoolid) FROM resources AS T1 INNER JOIN projects AS T2 ON T1.projectid = T2.projectid WHERE T2.resource_type = 'Books' AND T2.school_metro = 'urban'

How many schools in urban area requested for books resources ?

O O B-COLUMN O B-VALUE O O O B-VALUE B-TABLE O


Question: How many claim processing stages are there in total?

SELECT count(*) FROM claims_processing_stages

How many claim processing stages are there in total ?


Question: List any five parts name in Medium Plated Brass.

SELECT p_name FROM part WHERE p_type = 'MEDIUM PLATED BRASS' LIMIT 5

List any five parts name in Medium Plated Brass .

O O O B-TABLE B-COLUMN O B-VALUE I-VALUE I-VALUE O


Question: Please list the first names of the coaches who have taught the Montreal Canadiens.

SELECT DISTINCT T3.firstName FROM Coaches AS T1 INNER JOIN Teams AS T2 ON T1.year = T2.year AND T1.tmID = T2.tmID INNER JOIN Master AS T3 ON T1.coachID = T3.coachID WHERE T2.name = 'Montreal Canadiens'

Please list the first names of the coaches who have taught the Montreal Canadiens .

O O O B-COLUMN B-COLUMN O O B-COLUMN O O O O B-VALUE I-VALUE O


Question: How many businesses are there in Scottsdale city under the category of "Beauty & Spas"?

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'

How many businesses are there in Scottsdale city under the category of " Beauty & Spas " ?

O O B-TABLE O O O B-VALUE B-COLUMN O O B-TABLE O O B-VALUE I-VALUE I-VALUE O O


Question: Show all information for all discounts.

Show all information for all discounts .


Question: For the all donations to the project 'Bringing Drama to Life', what is the percentage of the donation is paid by credit card?

SELECT CAST(SUM(CASE WHEN T2.payment_method LIKE 'creditcard' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(donationid) FROM essays AS T1 INNER JOIN donations AS T2 ON T1.projectid = T2.projectid WHERE T1.title LIKE 'Bringing Drama to Life'

For the all donations to the project ' Bringing Drama to Life ' , what is the percentage of the donation is paid by credit card ?

O O O B-TABLE O O B-COLUMN O B-VALUE I-VALUE I-VALUE I-VALUE O O O O O O O O B-COLUMN O O O B-VALUE I-VALUE O


Question: What is the number of votes for 10-star for the episode that has the keyword "reference to the fantastic four"?

SELECT T2.votes FROM Keyword AS T1 INNER JOIN Vote AS T2 ON T1.episode_id = T2.episode_id WHERE T2.stars = 10 AND T1.keyword = 'reference to the fantastic four';

What is the number of votes for 10 - star for the episode that has the keyword " reference to the fantastic four " ?

O O O O O B-TABLE O B-VALUE O B-COLUMN O O B-COLUMN O O O B-COLUMN O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O O


Question: What are the ids and names of customers with addressed that contain WY and who do not use a credit card for payment?

SELECT customer_id ,  customer_name FROM customers WHERE customer_address LIKE "%WY%" AND payment_method_code != "Credit Card"

What are the ids and names of customers with addressed that contain WY and who do not use a credit card for payment ?

O O O O O O O B-TABLE B-COLUMN I-COLUMN O O B-COLUMN O O O O O O B-COLUMN I-COLUMN O O O


Question: Return the distinct descriptions of all the detentions that have happened.

SELECT distinct(T1.detention_type_description) FROM Ref_Detention_Type AS T1 JOIN Detention AS T2 ON T1.detention_type_code  =  T2.detention_type_code

Return the distinct descriptions of all the detentions that have happened .

O O B-COLUMN I-COLUMN O O O B-TABLE O O O O


Question: Show the name of aircrafts with top three lowest distances.

SELECT name FROM Aircraft ORDER BY distance LIMIT 3

Show the name of aircrafts with top three lowest distances .

O O B-COLUMN O B-TABLE O O O O B-COLUMN O


Question: What are the countries for each market ordered by decreasing number of cities?

SELECT Country FROM market ORDER BY Number_cities DESC

What are the countries for each market ordered by decreasing number of cities ?

O O O B-COLUMN O O B-TABLE O O O B-COLUMN I-COLUMN I-COLUMN O


Question: Find the year which offers the largest number of courses.

SELECT YEAR FROM SECTION GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1

Find the year which offers the largest number of courses .


Question: Tell the special features of the film Uprising Uptown.

SELECT special_features FROM film WHERE title = 'UPRISING UPTOWN'

Tell the special features of the film Uprising Uptown .

O O B-COLUMN I-COLUMN O O B-TABLE B-VALUE I-VALUE O


Question: How many films with the rental rate of $2.99 have the special feature of "Deleted Scenes"?

SELECT COUNT(film_id) FROM film WHERE rental_rate = 2.99 AND special_features = 'Deleted Scenes'

How many films with the rental rate of $ 2.99 have the special feature of " Deleted Scenes " ?

O O B-TABLE O O B-COLUMN I-COLUMN O O B-VALUE O O B-COLUMN I-COLUMN O O B-VALUE I-VALUE O O


Question: List all program origins in the alphabetical order.

SELECT origin FROM program ORDER BY origin

List all program origins in the alphabetical order .


Question: What are the top 5 most popular movies of the 21st century? Indicate how many users gave it a rating score of 5.

SELECT DISTINCT T2.movie_id, SUM(T1.rating_score = 5) FROM ratings AS T1 INNER JOIN movies AS T2 ON T1.movie_id = T2.movie_id ORDER BY T2.movie_popularity DESC LIMIT 5

What are the top 5 most popular movies of the 21st century ? Indicate how many users gave it a rating score of 5 .

O O O O B-VALUE B-COLUMN I-COLUMN B-TABLE O O O O O O O O O O O O B-TABLE B-COLUMN O O O


Question: Find the title of books which are ordered by client Peter Doe but not client James Smith.

SELECT T4.title FROM Orders AS T1 JOIN Books_Order AS T2 ON T1.idOrder  =  T2.idOrder JOIN Client AS T3 ON T1.idClient  =  T3.idClient JOIN book AS T4 ON T2.ISBN  =  T4.isbn WHERE T3.name  =  "Peter Doe" EXCEPT SELECT T4.title FROM Orders AS T1 JOIN Books_Order AS T2 ON T1.idOrder  =  T2.idOrder JOIN Client AS T3 ON T1.idClient  =  T3.idClient JOIN book AS T4 ON T2.ISBN  =  T4.isbn WHERE T3.name  =  "James Smith"

Find the title of books which are ordered by client Peter Doe but not client James Smith .

O O B-COLUMN O B-TABLE O O B-TABLE O B-TABLE B-COLUMN I-COLUMN O O O B-COLUMN B-COLUMN O


Question: Between 1/1/2012 to 12/31/2014, which date recorded the hottest temperature in weather station 1?

SELECT `date` FROM weather WHERE station_nbr = 1 AND CAST(SUBSTR(`date`, 1, 4) AS int) BETWEEN 2012 AND 2014 ORDER BY tmax DESC LIMIT 1

Between 1/1/2012 to 12/31/2014 , which date recorded the hottest temperature in weather station 1 ?

O B-VALUE O O O O B-COLUMN O O O O O B-TABLE B-COLUMN B-VALUE O


Question: What is the github address of the solution path "joeyrobert_bloomfilter\DataTypes.BloomFilter.sln"?

SELECT T1.Url FROM Repo AS T1 INNER JOIN Solution AS T2 ON T1.Id = T2.RepoId WHERE T2.Path = 'joeyrobert_bloomfilterDataTypes.BloomFilter.sln'

What is the github address of the solution path " joeyrobert_bloomfilter\DataTypes . BloomFilter.sln " ?

O O O O O O O B-TABLE B-COLUMN O B-VALUE I-VALUE I-VALUE O O


Question: Among the establishments with a postal code of 94102, how many establishments have a score of 90 or more in 2015?

SELECT COUNT(DISTINCT T2.business_id) FROM violations AS T1 INNER JOIN businesses AS T2 ON T1.business_id = T2.business_id INNER JOIN inspections AS T3 ON T2.business_id = T3.business_id WHERE STRFTIME('%Y', T1.`date`) = '2015' AND T2.postal_code = '94102' AND T3.score > 90

Among the establishments with a postal code of 94102 , how many establishments have a score of 90 or more in 2015 ?

O O O O O B-COLUMN I-COLUMN O B-VALUE O O O O O O B-COLUMN O B-VALUE O O O B-VALUE O


Question: For all the set of cards that has Brazil Portuguese translation, what is the percentage of them are only available online?

SELECT CAST(SUM(CASE WHEN isOnlineOnly = 1 THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(id) FROM sets WHERE code IN ( SELECT setCode FROM set_translations WHERE language = 'Portuguese (Brazil)' )

For all the set of cards that has Brazil Portuguese translation , what is the percentage of them are only available online ?

O O O B-TABLE B-COLUMN O O O O B-VALUE B-TABLE O O O O O O O O O O B-COLUMN O


Question: List all movies rated by user 39115684. State the title, rating date and rating score.

SELECT T2.movie_title, T1.rating_timestamp_utc, T1.rating_score FROM ratings AS T1 INNER JOIN movies AS T2 ON T1.movie_id = T2.movie_id WHERE T1.user_id = 39115684

List all movies rated by user 39115684 . State the title , rating date and rating score .

O O B-TABLE O O B-COLUMN B-VALUE O O O B-COLUMN O O O O B-TABLE B-COLUMN O


Question: How many headphones are stored in the Woodman store?

SELECT sum(t2.quantity) FROM store AS t1 JOIN stock AS t2 ON t1.store_id  =  t2.store_id WHERE t1.name  =  'Woodman'

How many headphones are stored in the Woodman store ?


Question: Find the names of all the product characteristics.

SELECT DISTINCT characteristic_name FROM CHARACTERISTICS

Find the names of all the product characteristics .


Question: What percentage of games are sports?

SELECT CAST(COUNT(CASE WHEN T1.genre_name = 'Sports' THEN T2.id ELSE NULL END) AS REAL) * 100 / COUNT(T2.id) FROM genre AS T1 INNER JOIN game AS T2 ON T1.id = T2.genre_id


Question: What is the content of the earliest review for the "Stuff You Should Know" podcast?

SELECT T2.content FROM podcasts AS T1 INNER JOIN reviews AS T2 ON T2.podcast_id = T1.podcast_id WHERE T1.title = 'Stuff You Should Know' ORDER BY T2.created_at ASC LIMIT 1

What is the content of the earliest review for the " Stuff You Should Know " podcast ?

O O O B-COLUMN O O O B-TABLE O O O B-VALUE I-VALUE I-VALUE I-VALUE O B-TABLE O


Question: List all countries with 'Category III' membership in 'IFAD' organization. Please also provide the capital of the country.

SELECT Name, Capital FROM country WHERE Code IN ( SELECT Country FROM isMember WHERE type = 'Category III' AND Organization = 'IFAD' )

List all countries with ' Category III ' membership in ' IFAD ' organization . Please also provide the capital of the country .

O O O O O B-VALUE I-VALUE O B-TABLE O O B-VALUE O B-COLUMN O O O O O B-COLUMN O O B-COLUMN O


Question: What are the nicknames of schools whose division is not 1?

SELECT Nickname FROM school_details WHERE Division != "Division 1"

What are the nicknames of schools whose division is not 1 ?

O O O B-COLUMN O B-TABLE O B-COLUMN O O O O


Question: Among all the customers of store no.1, how many of them are active?

SELECT COUNT(customer_id) FROM customer WHERE active = 1 AND store_id = 1

Among all the customers of store no.1 , how many of them are active ?

O O O B-TABLE O B-COLUMN O O O O O O O B-COLUMN O


Question: Give the total amount of rent for the movie Clockwork Paradice.

SELECT SUM(T1.amount) FROM payment AS T1 INNER JOIN rental AS T2 ON T1.rental_id = T2.rental_id INNER JOIN inventory AS T3 ON T2.inventory_id = T3.inventory_id INNER JOIN film AS T4 ON T3.film_id = T4.film_id WHERE T4.title = 'CLOCKWORK PARADICE'

Give the total amount of rent for the movie Clockwork Paradice .

O O B-COLUMN B-COLUMN O B-TABLE B-TABLE O O B-VALUE I-VALUE O


Question: For each constructor id, how many races are there?

SELECT count(*) ,  constructorid FROM constructorStandings GROUP BY constructorid

For each constructor i d , how many races are there ?

O O B-COLUMN I-COLUMN I-COLUMN O O O O O O O


Question: What is the maximum weight being transported to New York during a single shipment?

SELECT MAX(T1.weight) FROM shipment AS T1 INNER JOIN city AS T2 ON T1.city_id = T2.city_id WHERE T2.city_name = 'New York'

What is the maximum weight being transported to New York during a single shipment ?

O O O O B-COLUMN O O O B-VALUE I-VALUE O O O B-TABLE O


Question: What is the name of the coin that creates the most total value in the past 24 hours?

SELECT T1.name FROM coins AS T1 INNER JOIN historical AS T2 ON T1.id = T2.coin_id WHERE T2.volume_24h = ( SELECT MAX(volume_24h) FROM historical )

What is the name of the coin that creates the most total value in the past 24 hours ?

O O O B-COLUMN O O B-TABLE O O O O O O O O O O O O


Question: Among students with 1 month of absenses, how many of them are enlisted in the air force department?

SELECT COUNT(T1.name) FROM longest_absense_from_school AS T1 INNER JOIN enlist AS T2 ON T1.name = T2.name WHERE T1.month = 1 AND T2.organ = 'air_force'

Among students with 1 month of absenses , how many of them are enlisted in the air force department ?

O O O B-VALUE B-COLUMN O O O O O O O O B-TABLE O O B-VALUE I-VALUE O O


Question: Compute the total salary that the player with first name Len and last name Barker received between 1985 to 1990.

SELECT sum(T1.salary) FROM salary AS T1 JOIN player AS T2 ON T1.player_id = T2.player_id WHERE T2.name_first  =  'Len' AND T2.name_last = 'Barker' AND T1.year BETWEEN 1985 AND 1990;

Compute the total salary that the player with first name Len and last name Barker received between 1985 to 1990 .

O O O B-COLUMN O O B-COLUMN O B-COLUMN O B-VALUE O B-COLUMN O B-VALUE O O B-VALUE O B-VALUE O


Question: What is the average heights of crew members from Animation Department?

SELECT AVG(T1.height_meters) FROM Person AS T1 INNER JOIN Credit AS T2 ON T1.name = T2.person WHERE T2.category = 'Animation Department';

What is the average heights of crew members from Animation Department ?

O O O O B-COLUMN O B-TABLE O O B-VALUE I-VALUE O


Question: What is the difference in order number from "WARE-MKL1006" and "WARE-NBV1002"?

SELECT SUM(IIF(WarehouseCode = 'WARE-MKL1006', 1, 0)) - SUM(IIF(WarehouseCode = 'WARE-NBV1002', 1, 0)) AS difference FROM `Sales Orders`

What is the difference in order number from " WARE - MKL1006 " and " WARE - NBV1002 " ?

O O O O B-TABLE I-TABLE O O O B-VALUE I-VALUE I-VALUE O O O B-VALUE I-VALUE I-VALUE O O


Question: Which country does customer with first name as Carole and last name as Bernhard lived in?

SELECT T2.country FROM Customers AS T1 JOIN Addresses AS T2 ON T1.customer_address_id = T2.address_id WHERE T1.first_name = "Carole" AND T1.last_name = "Bernhard"

Which country does customer with first name as Carole and last name as Bernhard lived in ?

O B-COLUMN O B-TABLE O B-COLUMN I-COLUMN O B-COLUMN O B-COLUMN I-COLUMN O B-COLUMN O O O


Question: What is the job title of the newest employee in department 12?

SELECT T1.JobTitle FROM Employee AS T1 INNER JOIN EmployeeDepartmentHistory AS T2 ON T1.BusinessEntityID = T2.BusinessEntityID WHERE T2.DepartmentID = 12 ORDER BY T2.StartDate DESC LIMIT 1

What is the job title of the newest employee in department 12 ?

O O O B-COLUMN I-COLUMN O O O B-TABLE B-TABLE B-COLUMN B-VALUE O


Question: Find the branch name of the bank that has the most number of customers.

SELECT bname FROM bank ORDER BY no_of_customers DESC LIMIT 1

Find the branch name of the bank that has the most number of customers .

O O O B-COLUMN O O B-TABLE O O O O O B-COLUMN I-COLUMN O


Question: User No."63469" has got "1" like for a tip to the Yelp business, which city is that business located in?

SELECT T1.city FROM Business AS T1 INNER JOIN Tips AS T2 ON T1.business_id = T2.business_id WHERE T2.likes = 1 AND T2.user_id = 63469

User No . "63469 " has got " 1 " like for a tip to the Yelp business , which city is that business located in ?

B-COLUMN O O B-VALUE O O O O B-VALUE O B-COLUMN O O B-TABLE O O O B-TABLE O O B-COLUMN O O O O O O


Question: How many people, who were born in Canada, won an award in 1999?

SELECT COUNT(T1.person_id) FROM Person AS T1 INNER JOIN Award AS T2 ON T1.person_id = T2.person_id WHERE T2.year = 1999 AND T1.birth_country = 'Canada'

How many people , who were born in Canada , won an award in 1999 ?

O O O O O O O O B-VALUE O O O B-TABLE O B-VALUE O


Question: State the coordinate of X and Y for the object with the attribute of 'sparse' in image 1.

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 = 1 AND T1.ATT_CLASS = 'sparse'

State the coordinate of X and Y for the object with the attribute of ' sparse ' in image 1 .

O O O O B-COLUMN O B-COLUMN O O O O O O O O B-VALUE O O O B-VALUE O


Question: Please list the names of the universities with a score in teaching of over 90 in 2011.

SELECT T3.university_name FROM ranking_criteria AS T1 INNER JOIN university_ranking_year AS T2 ON T1.id = T2.ranking_criteria_id INNER JOIN university AS T3 ON T3.id = T2.university_id WHERE T1.criteria_name = 'Teaching' AND T2.year = 2011 AND T2.score > 90

Please list the names of the universities with a score in teaching of over 90 in 2011 .

O O O O O O B-TABLE O O B-COLUMN O B-VALUE O O B-VALUE O B-VALUE O


Question: Names the Sales Representative with the highest year to date sales.

SELECT T2.FirstName, T2.MiddleName, T2.LastName FROM SalesPerson AS T1 INNER JOIN Person AS T2 ON T1.BusinessEntityID = T2.BusinessEntityID ORDER BY T1.SalesYTD DESC LIMIT 1

Names the Sales Representative with the highest year to date sales .


Question: Who was the earliest user created a list but didn't get any followers? Give the user ID.

SELECT user_id FROM lists_users WHERE user_subscriber = 0 ORDER BY list_creation_date_utc LIMIT 1

Who was the earliest user created a list but did n't get any followers ? Give the user ID .

O O O B-TABLE I-TABLE O O O O O O O O O O O O B-COLUMN I-COLUMN O


Question: Give the distinct famous release dates for all artists.

SELECT distinct(Famous_Release_date) FROM artist

Give the distinct famous release dates for all artists .

O O O B-COLUMN I-COLUMN I-COLUMN O O B-TABLE O


Question: What is the largest and smallest customer codes?

SELECT max(customer_code) ,  min(customer_code) FROM Customers

What is the largest and smallest customer codes ?


Question: How many customers in KAM had a consumption of less than 30,000 for the year 2012?

SELECT COUNT(*) FROM ( SELECT T2.CustomerID FROM customers AS T1 INNER JOIN yearmonth AS T2 ON T1.CustomerID = T2.CustomerID WHERE T1.Segment = 'KAM' AND SUBSTRING(T2.Date, 1, 4) = '2012' GROUP BY T2.CustomerID HAVING SUM(T2.Consumption) < 30000 ) AS t1

How many customers in KAM had a consumption of less than 30,000 for the year 2012 ?

O O B-TABLE O B-VALUE O O B-COLUMN O O O B-VALUE O O B-TABLE B-VALUE O


Question: Find the titles of albums that contain tracks of both the Reggae and Rock genres.

SELECT T1.Title FROM Album AS T1 JOIN Track AS T2 ON T1.AlbumId  =  T2.AlbumId JOIN Genre AS T3 ON T2.GenreID  =  T3.GenreID WHERE T3.Name  =  'Reggae' INTERSECT SELECT T1.Title FROM Album AS T1 JOIN Track AS T2 ON T1.AlbumId  =  T2.AlbumId JOIN Genre AS T3 ON T2.GenreID  =  T3.GenreID WHERE T3.Name  =  'Rock'

Find the titles of albums that contain tracks of both the Reggae and Rock genres .

O O B-COLUMN O B-TABLE O O B-TABLE O O O B-VALUE O B-VALUE B-TABLE O


Question: What is the brand of the youngest user's device?

SELECT device_model FROM phone_brand_device_model2 WHERE device_id IN ( SELECT device_id FROM gender_age WHERE age = ( SELECT MIN(age) FROM gender_age ) )

What is the brand of the youngest user 's device ?


Question: Identify the number of posts that offer a bounty amount over 30.

SELECT COUNT(id) FROM votes WHERE BountyAmount >= 30

Identify the number of posts that offer a bounty amount over 30 .

O O O O B-TABLE O O O B-COLUMN I-COLUMN O B-VALUE O


Question: What are the cities for country called "Â´Uman" in local name.

SELECT T1.Name FROM City AS T1 INNER JOIN Country AS T2 ON T1.CountryCode = T2.Code WHERE T2.LocalName = 'Â´Uman'

What are the cities for country called " Â´Uman " in local name .

O O O B-TABLE O B-TABLE O O B-VALUE O O B-COLUMN B-COLUMN O


Question: What is the maximum training hours for the students whose training hours is greater than 1000 in different positions?

SELECT max(T1.HS) ,  pPos FROM player AS T1 JOIN tryout AS T2 ON T1.pID  =  T2.pID WHERE T1.HS  >  1000 GROUP BY T2.pPos

What is the maximum training hours for the students whose training hours is greater than 1000 in different positions ?

O O O O O O O O O O O O O O O B-VALUE O O O O


Question: What is the average access count of documents?

What is the average access count of documents ?


Question: Find the name and city of the airport which is the destination of the most number of routes.

SELECT T1.name ,  T1.city ,  T2.dst_apid FROM airports AS T1 JOIN routes AS T2 ON T1.apid  =  T2.dst_apid GROUP BY T2.dst_apid ORDER BY count(*) DESC LIMIT 1

Find the name and city of the airport which is the destination of the most number of routes .

O O B-COLUMN O B-COLUMN O O B-TABLE O O O O O O O O O B-TABLE O


Question: What are the different ways the name of the author, Randall Davis, is written on their papers?

SELECT DISTINCT T1.Name FROM PaperAuthor AS T1 INNER JOIN Author AS T2 ON T1.AuthorId = T2.Id WHERE T2.Name = 'Randall Davis' AND T1.Name != 'Randall Davis'

What are the different ways the name of the author , Randall Davis , is written on their papers ?

O O O O O O B-COLUMN O O B-TABLE O B-VALUE I-VALUE O O O O O O O


Question: List all the IDs of images that have objects with the attributes of 'wired'.

SELECT DISTINCT T2.IMG_ID FROM ATT_CLASSES AS T1 INNER JOIN IMG_OBJ_ATT AS T2 ON T1.ATT_CLASS_ID = T2.ATT_CLASS_ID WHERE T1.ATT_CLASS = 'wired'

List all the IDs of images that have objects with the attributes of ' wired ' .


Question: For how many times was Park Dietz credited?

SELECT COUNT(T3.person_id) FROM Episode AS T1 INNER JOIN Credit AS T2 ON T1.episode_id = T2.episode_id INNER JOIN Person AS T3 ON T3.person_id = T2.person_id WHERE T2.credited = 'true' AND T3.name = 'Park Dietz'

For how many times was Park Dietz credited ?


Question: What is the number of female graduates between 2011 to 2013 from the state where 'Gateway Community College' is located?

SELECT COUNT(T2.grad_cohort) FROM institution_details AS T1 INNER JOIN state_sector_grads AS T2 ON T1.state = T2.state WHERE T2.year BETWEEN 2011 AND 2013 AND T1.chronname = 'Gateway Community College' AND T2.gender = 'F'

What is the number of female graduates between 2011 to 2013 from the state where ' Gateway Community College ' is located ?

O O O O B-VALUE O O O B-VALUE O B-VALUE O O B-COLUMN O O B-VALUE I-VALUE I-VALUE O O O O


Question: List out the type of events which have remaining budget more than 30 USD.

SELECT T1.type FROM event AS T1 INNER JOIN budget AS T2 ON T1.event_id = T2.link_to_event WHERE T2.remaining > 30

List out the type of events which have remaining budget more than 30 USD .

O O O B-COLUMN O B-TABLE O O B-COLUMN B-TABLE O O B-VALUE O O


Question: List the names of countries whose language is not "German".

SELECT Name FROM country WHERE Languages != "German"

List the names of countries whose language is not " German " .

O O B-COLUMN O B-TABLE O B-COLUMN O O O B-COLUMN O O


Question: What are the planes owned by pilot Smith with age 41?

SELECT plane_name FROM pilotskills WHERE pilot_name  =  'Smith' AND age  =  41

What are the planes owned by pilot Smith with age 41 ?

O O O B-COLUMN I-COLUMN O B-COLUMN B-VALUE O B-COLUMN B-VALUE O


Question: What is the name of the institution the author "Katsuhiro Ueno" belongs to?

SELECT DISTINCT t3.name FROM authors AS t1 JOIN authorship AS t2 ON t1.authid  =  t2.authid JOIN inst AS t3 ON t2.instid  =  t3.instid WHERE t1.fname  =  "Katsuhiro" AND t1.lname  =  "Ueno"

What is the name of the institution the author " Katsuhiro Ueno " belongs to ?

O B-TABLE O B-COLUMN O O B-COLUMN O B-COLUMN O B-COLUMN B-COLUMN O O O O


Question: How many people were injured between 2006 and 2014 as a result of a handgun?

SELECT COUNT(location) FROM incidents WHERE subject_weapon = 'Handgun' AND subject_statuses = 'Injured' AND date BETWEEN '2006-01-01' AND '2013-12-31'

How many people were injured between 2006 and 2014 as a result of a handgun ?

O O O O B-VALUE O O O O O O O O O B-VALUE O


Question: Find the title, author name, and publisher name for the top 3 best sales books.

SELECT t1.name ,  t2.title ,  t3.name FROM author AS t1 JOIN book AS t2 ON t1.author_id  =  t2.author_id JOIN press AS t3 ON t2.press_id  =  t3.press_id ORDER BY t2.sale_amount DESC LIMIT 3

Find the title , author name , and publisher name for the top 3 best sales books .

O O B-COLUMN O B-TABLE B-COLUMN O O O O O O O O O O B-TABLE O


Question: What is the GNP growth rate by the country of Shanghai?

SELECT CAST((T1.GNP - T1.GNPOld) AS REAL) / T1.GNPOld FROM Country AS T1 INNER JOIN City AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = 'Shanghai'

What is the GNP growth rate by the country of Shanghai ?

O O O B-COLUMN O O O O B-TABLE O B-VALUE O


Question: Please list the reference names of the drivers who are eliminated in the first period in race number 20.

SELECT T2.driverRef FROM qualifying AS T1 INNER JOIN drivers AS T2 ON T2.driverId = T1.driverId WHERE T1.raceId = 20 ORDER BY T1.q1 DESC LIMIT 5

Please list the reference names of the drivers who are eliminated in the first period in race number 20 .

O O O O O O O B-TABLE O O O O O O O O B-COLUMN O B-VALUE O


Question: Count the number of wines produced at Robert Biale winery.

SELECT count(*) FROM WINE WHERE Winery  =  "Robert Biale"

Count the number of wines produced at Robert Biale winery .

O O O O B-TABLE O O B-COLUMN I-COLUMN B-COLUMN O


Question: Write down the tweet text posted from Rawang, Selangor, Malaysia.

SELECT T1.text FROM twitter AS T1 INNER JOIN location AS T2 ON T1.LocationID = T2.LocationID WHERE T2.City = 'Rawang' AND T2.State = 'Selangor' AND T2.Country = 'Malaysia'

Write down the tweet text posted from Rawang , Selangor , Malaysia .

B-TABLE O O O B-COLUMN O O B-VALUE O B-VALUE O B-VALUE O


Question: What is the average selling price of different vendors of the product Hex Nut 5?

SELECT SUM(T1.StandardPrice) / COUNT(T1.BusinessEntityID) FROM ProductVendor AS T1 INNER JOIN Product AS T2 ON T1.ProductID = T2.ProductID WHERE T2.Name = 'Hex Nut 5'

What is the average selling price of different vendors of the product Hex Nut 5 ?

O O O O O O O O O O O B-TABLE B-VALUE I-VALUE I-VALUE O


Question: To whom does the employee have to inform that is the sales representative of the French customer?

SELECT T1.reportsTo FROM employees AS T1 INNER JOIN customers AS T2 ON T1.employeeNumber = T2.salesRepEmployeeNumber WHERE T2.country = 'France'

To whom does the employee have to inform that is the sales representative of the French customer ?

O O O O B-TABLE O O O O O O O O O O B-VALUE B-TABLE O


Question: Which authors have never published under the "Accor" press? Give me their names.

SELECT name FROM author EXCEPT SELECT t1.name FROM author AS t1 JOIN book AS t2 ON t1.author_id  =  t2.author_id JOIN press AS t3 ON t2.press_id  =  t3.press_id WHERE t3.name  =  'Accor'

Which authors have never published under the " Accor " press ? Give me their names .

O B-TABLE O O O O O O B-VALUE O B-TABLE O O O O B-COLUMN O


Question: What is the chapter description where the paragraph "What, wilt thou hear some music, my sweet love?" belongs?

SELECT T1.id, T1.Description FROM chapters AS T1 INNER JOIN paragraphs AS T2 ON T1.id = T2.chapter_id WHERE T2.PlainText = 'What, wilt thou hear some music, my sweet love?'

What is the chapter description where the paragraph " What , wilt thou hear some music , my sweet love ? " belongs ?

O O O B-TABLE B-COLUMN O O B-TABLE O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O O O


Question: How many rooms are located for each block code?

SELECT count(*) ,  T1.blockcode FROM BLOCK AS T1 JOIN room AS T2 ON T1.blockfloor  =  T2.blockfloor AND T1.blockcode  =  T2.blockcode GROUP BY T1.blockcode

How many rooms are located for each block code ?


Question: For the deal happened at 2012/8/24 12:42:00, which country was it?

SELECT T2.Country FROM transactions_1k AS T1 INNER JOIN gasstations AS T2 ON T1.GasStationID = T2.GasStationID WHERE T1.Date = '2012-08-24' AND T1.Time = '12:42:00'

For the deal happened at 2012/8/24 12:42:00 , which country was it ?

O O O O B-COLUMN B-VALUE B-VALUE O O B-COLUMN O O O


Question: Return the average age of pilots for each plane name.

SELECT avg(age) ,  plane_name FROM pilotskills GROUP BY plane_name

Return the average age of pilots for each plane name .

O O O B-COLUMN O B-TABLE O O B-COLUMN I-COLUMN O


Question: What is the disposition id of the client who made 5100 USD transaction in 1998/9/2?

SELECT T1.disp_id FROM disp AS T1 INNER JOIN account AS T2 ON T1.account_id = T2.account_id INNER JOIN trans AS T3 ON T2.account_id = T3.account_id WHERE T3.date='1997-08-20' AND T3.amount = 5100

What is the disposition i d of the client who made 5100 USD transaction in 1998/9/2 ?

O B-TABLE O O O O O O O O O B-VALUE O B-TABLE O O O


Question: List the station names of city channels whose affiliation is not "ABC".

SELECT Station_name FROM city_channel WHERE Affiliation != "ABC"

List the station names of city channels whose affiliation is not " ABC " .

O O B-COLUMN I-COLUMN O B-TABLE I-TABLE O B-COLUMN O O O B-COLUMN O O


Question: What are the first and last names of all customers with more than 2 payments?

SELECT T2.first_name ,  T2.last_name FROM Customer_Payments AS T1 JOIN Customers AS T2 ON T1.customer_id = T2.customer_id GROUP BY T1.customer_id HAVING count(*)  >  2;

What are the first and last names of all customers with more than 2 payments ?

O O O B-COLUMN O B-COLUMN I-COLUMN O O B-TABLE O O O B-VALUE O O


Question: Which player has the strongest overall strength?

SELECT t1.player_name FROM Player AS t1 INNER JOIN Player_Attributes AS t2 ON t1.player_api_id = t2.player_api_id ORDER BY t2.overall_rating DESC LIMIT 1

Which player has the strongest overall strength ?

O B-TABLE B-TABLE I-TABLE I-TABLE B-COLUMN O O


Question: Provide eateries' IDs, risk categories and descriptions with violation ID of 103101.

SELECT business_id, risk_category, description FROM violations WHERE violation_type_id = '103101'

Provide eateries ' IDs , risk categories and descriptions with violation ID of 103101 .

O O O O O B-COLUMN I-COLUMN O B-COLUMN O B-TABLE B-COLUMN O B-VALUE O


Question: What is the minimum snatch score?


Question: What are the managers and captains of clubs?

What are the managers and captains of clubs ?


Question: Which staff have contacted which engineers? List the staff name and the engineer first name and last name.

SELECT T1.staff_name ,  T3.first_name ,  T3.last_name FROM Staff AS T1 JOIN Engineer_Visits AS T2 ON T1.staff_id  =  T2.contact_staff_id JOIN Maintenance_Engineers AS T3 ON T2.engineer_id  =  T3.engineer_id

Which staff have contacted which engineers ? List the staff name and the engineer first name and last name .

O B-TABLE O B-COLUMN O O O O O B-COLUMN B-COLUMN B-TABLE I-TABLE B-COLUMN B-COLUMN I-COLUMN O B-COLUMN I-COLUMN O


Question: Find the distinct details of invoices which are created before 1989-09-03 or after 2007-12-25.

SELECT DISTINCT invoice_details FROM invoices WHERE invoice_date < "1989-09-03" OR invoice_date > "2007-12-25"

Find the distinct details of invoices which are created before 1989 - 09 - 03 or after 2007 - 12 - 25 .

O O O O O B-TABLE O O O O B-COLUMN I-COLUMN I-COLUMN I-COLUMN I-COLUMN O O B-COLUMN I-COLUMN I-COLUMN I-COLUMN I-COLUMN O


Question: How many games were not won by runs?

SELECT SUM(CASE WHEN T2.Win_Type != 'runs' THEN 1 ELSE 0 END) FROM `Match` AS T1 INNER JOIN Win_By AS T2 ON T1.Win_Type = T2.Win_Id


Question: List the name of actors in ascending alphabetical order.

SELECT Name FROM actor ORDER BY Name ASC

List the name of actors in ascending alphabetical order .


Question: What was the average monthly consumption of customers in SME for the year 2013?

SELECT AVG(T2.Consumption) / 12 FROM customers AS T1 INNER JOIN yearmonth AS T2 ON T1.CustomerID = T2.CustomerID WHERE SUBSTR(T2.Date, 1, 4) = '2013' AND T1.Segment = 'SME'

What was the average monthly consumption of customers in SME for the year 2013 ?

O O O O B-TABLE B-COLUMN O B-TABLE O B-VALUE O O O B-VALUE O


Question: What are the names of all cinemas not showing any movies?

SELECT DISTINCT name FROM MovieTheaters WHERE Movie  =  'null'

What are the names of all cinemas not showing any movies ?


Question: How many students live in HKG or CHI?

SELECT count(*) FROM Student WHERE city_code  =  "HKG" OR city_code  =  "CHI"


Question: Are there more in-patient or outpatient who were male? What is the deviation in percentage?

SELECT CAST(SUM(CASE WHEN Admission = '+' THEN 1 ELSE 0 END) AS REAL) * 100 / SUM(CASE WHEN Admission = '-' THEN 1 ELSE 0 END) FROM Patient WHERE SEX = 'M'

Are there more in - patient or outpatient who were male ? What is the deviation in percentage ?

O O O O B-VALUE B-TABLE O O O O O O O O O O O O O


Question: What are the names of captains that have either the rank Midshipman or Lieutenant?

SELECT name FROM captain WHERE rank  =  'Midshipman' OR rank  =  'Lieutenant'

What are the names of captains that have either the rank Midshipman or Lieutenant ?

O O O B-COLUMN O B-TABLE O O O O B-COLUMN B-VALUE O B-VALUE O


Question: Find id of the candidate who most recently accessed the course?

SELECT candidate_id FROM candidate_assessments ORDER BY assessment_date DESC LIMIT 1

Find i d of the candidate who most recently accessed the course ?

O O O O O B-COLUMN O O O B-COLUMN I-COLUMN O O


Question: How many Yelp_Businesses do not provide alcohol?

SELECT COUNT(T1.attribute_id) FROM Attributes AS T1 INNER JOIN Business_Attributes AS T2 ON T1.attribute_id = T2.attribute_id WHERE T1.attribute_name LIKE 'Alcohol' AND T2.attribute_value LIKE 'none'

How many Yelp_Businesses do not provide alcohol ?


Question: What city does the business have a business hour from 10 am to 12 pm on Sunday?

SELECT T1.city FROM Business AS T1 INNER JOIN Business_Hours AS T2 ON T1.business_id = T2.business_id INNER JOIN Days AS T3 ON T2.day_id = T3.day_id WHERE T2.opening_time LIKE '10AM' AND T2.closing_time LIKE '12PM' AND T3.day_of_week LIKE 'Sunday'

What city does the business have a business hour from 10 am to 12 pm on Sunday ?

O B-COLUMN O O O O O B-TABLE B-TABLE O B-VALUE I-VALUE O B-VALUE I-VALUE O B-TABLE O


Question: What are the date and detail of each transcript?

SELECT date_of_transcript ,  transcript_details FROM Transcripts

What are the date and detail of each transcript ?


Question: How many users answered the question "Overall, how much importance does your employer place on physical health?"?

SELECT COUNT(T1.UserID) FROM Answer AS T1 INNER JOIN Question AS T2 ON T1.QuestionID = T2.questionid WHERE T2.questiontext LIKE 'Overall, how much importance does your employer place on physical health?'

How many users answered the question " Overall , how much importance does your employer place on physical health ? " ?

O O B-COLUMN B-TABLE O B-TABLE O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O O


Question: What are the types of every competition and in which countries are they located?

SELECT Competition_type ,  Country FROM competition

What are the types of every competition and in which countries are they located ?

O O O O O O B-TABLE O O O B-COLUMN O O O O


Question: What is minimum age for different job title?

SELECT min(age) ,  job FROM Person GROUP BY job

What is minimum age for different job title ?


Question: What is the name of the patient who made the most recent appointment?

SELECT T1.name FROM patient AS T1 JOIN appointment AS T2 ON T1.ssn = T2.patient ORDER BY T2.start DESC LIMIT 1

What is the name of the patient who made the most recent appointment ?

O O O B-COLUMN O O B-COLUMN O O O O O B-TABLE O


Question: What are full names and salaries of employees working in the city of London?

SELECT first_name ,  last_name ,  salary FROM employees AS T1 JOIN departments AS T2 ON T1.department_id  =  T2.department_id JOIN  locations AS T3 ON T2.location_id  =  T3.location_id WHERE  T3.city  =  'London'

What are full names and salaries of employees working in the city of London ?

O O O O O B-COLUMN O B-TABLE O O O B-COLUMN O B-VALUE O


Question: Among the menu pages of "Ritz Carlton", how many of them have a width of over 1000?

SELECT SUM(CASE WHEN T1.name = 'Ritz Carlton' THEN 1 ELSE 0 END) FROM Menu AS T1 INNER JOIN MenuPage AS T2 ON T1.id = T2.menu_id WHERE T2.full_width > 1000

Among the menu pages of " Ritz Carlton " , how many of them have a width of over 1000 ?

O O B-TABLE B-TABLE O O B-VALUE I-VALUE O O O O O O O O B-COLUMN O O B-VALUE O


Question: How many authors is affiliated to the organization "Otterbein University"?

SELECT COUNT(Name) FROM Author WHERE Affiliation = 'Otterbein University'

How many authors is affiliated to the organization " Otterbein University " ?

O O B-TABLE O B-COLUMN O O O O B-VALUE I-VALUE O O


Question: What is the id, first name, and last name of the driver who was in the first position for laptime at least twice?

SELECT T1.driverid ,  T1.forename ,  T1.surname FROM drivers AS T1 JOIN laptimes AS T2 ON T1.driverid = T2.driverid WHERE POSITION  =  '1' GROUP BY T1.driverid HAVING count(*)  >=  2

What is the i d , first name , and last name of the driver who was in the first position for laptime at least twice ?

O O O O O O O B-COLUMN O O O B-COLUMN O O B-TABLE O O O O O B-COLUMN O B-TABLE O O O O


Question: Write down the organization, year, award, and award category in which Rene Balcer is the winner.

SELECT T2.organization, T2.year, T2.award, T2.award_category FROM Person AS T1 INNER JOIN Award AS T2 ON T1.person_id = T2.person_id WHERE T1.name = 'Rene Balcer' AND T2.result = 'Winner'

Write down the organization , year , award , and award category in which Rene Balcer is the winner .

O O O B-COLUMN O B-COLUMN O B-TABLE O O B-COLUMN I-COLUMN O O B-VALUE I-VALUE O O B-VALUE O


Question: How many proteins are associated with an institution founded after 1880 or an institution with type "Private"?

SELECT count(*) FROM institution AS T1 JOIN protein AS T2 ON T1.institution_id  =  T2.institution_id WHERE T1.founded  >  1880 OR T1.type  =  'Private'

How many proteins are associated with an institution founded after 1880 or an institution with type " Private " ?

O O B-TABLE O O O O B-TABLE B-COLUMN O B-VALUE O O O O B-COLUMN O B-VALUE O O


Question: What are the last names and ids of all drivers who had 11 pit stops and participated in more than 5 races?

SELECT T1.surname ,  T1.driverid FROM drivers AS T1 JOIN pitstops AS T2 ON T1.driverid  =  T2.driverid GROUP BY T1.driverid HAVING count(*)  =  11 INTERSECT SELECT T1.surname ,  T1.driverid FROM drivers AS T1 JOIN results AS T2 ON T1.driverid  =  T2.driverid GROUP BY T1.driverid HAVING count(*)  >  5

What are the last names and ids of all drivers who had 11 pit stops and participated in more than 5 races ?

O O O O B-COLUMN O O O O B-TABLE O O B-VALUE B-TABLE I-TABLE O O O O O B-VALUE O O


Question: Return all players sorted by college in ascending alphabetical order.

SELECT player FROM match_season ORDER BY College ASC

Return all players sorted by college in ascending alphabetical order .


Question: Which two countries have the border in length of 803 km? Give the full names of the countries.

SELECT T1.Name, T3.Name FROM country AS T1 INNER JOIN borders AS T2 ON T1.Code = T2.Country1 INNER JOIN country AS T3 ON T3.Code = T2.Country2 WHERE T2.Length = 803

Which two countries have the border in length of 803 km ? Give the full names of the countries .

O O B-TABLE O O B-COLUMN O B-COLUMN O B-VALUE O O O O O B-COLUMN O O O O


Question: How many suppliers are from Japan?

SELECT COUNT(T1.c_custkey) FROM customer AS T1 INNER JOIN nation AS T2 ON T1.c_nationkey = T2.n_nationkey WHERE T2.n_name = 'JAPAN'


Question: Among the cities with alias Ponce, what is the percentage of cities with a country level FIPS code of less than 20?

SELECT CAST(COUNT(CASE WHEN T2.county_fips < 20 THEN T2.zip_code ELSE NULL END) AS REAL) * 100 / COUNT(T2.zip_code) FROM alias AS T1 INNER JOIN zip_data AS T2 ON T1.zip_code = T2.zip_code WHERE T1.alias = 'Ponce'

Among the cities with alias Ponce , what is the percentage of cities with a country level FIPS code of less than 20 ?

O O O O B-COLUMN B-VALUE O O O O O O O O O B-COLUMN I-COLUMN B-COLUMN I-COLUMN O O O B-VALUE O


Question: Where is the history department?

SELECT dept_address FROM department WHERE dept_name  =  'History'