Question: Calculate the percentage of Black students in all private for profit institutions.

SELECT CAST(SUM(CASE WHEN T2.race = 'B' THEN 1 ELSE 0 END) AS REAL) * 100 / SUM(T2.grad_cohort) FROM institution_details AS T1 INNER JOIN institution_grads AS T2 ON T1.unitid = T2.unitid WHERE T2.race = 'B' AND T1.control = 'Private for-profit'

Calculate the percentage of Black students in all private for profit institutions .

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


Question: Find the payment method that is used most frequently.

SELECT payment_method FROM Customers GROUP BY payment_method ORDER BY count(*) DESC LIMIT 1

Find the payment method that is used most frequently .


Question: Please provide the id of the respository that the most people like.

SELECT Id FROM Repo WHERE Stars = ( SELECT MAX(Stars) FROM Repo )

Please provide the i d of the respository that the most people like .

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


Question: What is the total amount of grants given by each organisations? Also list the organisation id.

SELECT sum(grant_amount) ,  organisation_id FROM Grants GROUP BY organisation_id

What is the total amount of grants given by each organisations ? Also list the organisation i d.

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


Question: How many sets are available just in Japanese and not in Magic: The Gathering Online?

SELECT COUNT(T1.id) FROM sets AS T1 INNER JOIN set_translations AS T2 ON T2.setCode = T1.code WHERE T2.language = 'Japanese'  AND (T1.mtgoCode IS NULL OR T1.mtgoCode = '')

How many sets are available just in Japanese and not in Magic : The Gathering Online ?

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


Question: What are the sales made by the games in Japan region?

SELECT SUM(CASE WHEN T2.region_name = 'Japan' THEN T1.num_sales ELSE 0 END) AS nums FROM region_sales AS T1 INNER JOIN region AS T2 ON T1.region_id = T2.id

What are the sales made by the games in Japan region ?

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


Question: Show the capital of the region that has the most buildings.

SELECT T2.capital FROM building AS T1 JOIN region AS T2 ON T1.Region_ID  =  T2.Region_ID GROUP BY T1.Region_ID ORDER BY COUNT(*) DESC LIMIT 1

Show the capital of the region that has the most buildings .

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


Question: Find the name of the campuses opened before 1800.

SELECT campus FROM campuses WHERE YEAR  <  1800

Find the name of the campuses opened before 1800 .


Question: What is the title of the newest movie?

SELECT title FROM Movie WHERE YEAR  =  (SELECT max(YEAR) FROM Movie)


Question: What are the names of languages that contain the word "ish"?

SELECT name FROM languages WHERE name LIKE "%ish%"

What are the names of languages that contain the word " ish " ?

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


Question: What are the city codes of the cities with the maximum distance?

SELECT city1_code ,  city2_code FROM Direct_distance ORDER BY distance DESC LIMIT 1

What are the city codes of the cities with the maximum distance ?

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


Question: How many businesses with the category named Stadiums & Arenas are rated highest?

SELECT COUNT(T1.business_id) FROM Business_Categories AS T1 INNER JOIN Categories AS T2 ON T1.category_id = T2.category_id INNER JOIN Business AS T3 ON T1.business_id = T3.business_id WHERE T2.category_name = 'Stadiums & Arenas' AND T3.stars = ( SELECT MAX(stars) FROM Business )

How many businesses with the category named Stadiums & Arenas are rated highest ?

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


Question: Which legislator has the YouTube channel 'RoskamIL06?' Write the official full name.

SELECT T1.official_full_name FROM current AS T1 INNER JOIN `social-media` AS T2 ON T2.bioguide = T1.bioguide_id WHERE T2.youtube = 'RoskamIL06'

Which legislator has the YouTube channel ' RoskamIL06 ? ' Write the official full name .

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


Question: How many players got out in the first inning of match ID "548335"?

SELECT SUM(CASE WHEN Match_Id = 548335 THEN 1 ELSE 0 END) FROM Wicket_Taken WHERE Innings_No = 1

How many players got out in the first inning of match ID " 548335 " ?

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


Question: List the id and type of each thing, and the details of the organization that owns it.

SELECT T1.thing_id ,  T1.type_of_Thing_Code ,  T2.organization_details FROM Things AS T1 JOIN Organizations AS T2 ON T1.organization_id  =  T2.organization_id

List the i d and type of each thing , and the details of the organization that owns it .

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


Question: What is the salary range for sales representative in Northwind?

SELECT ( SELECT MIN(Salary) FROM Employees WHERE Title = 'Sales Representative' ) AS MIN , ( SELECT MAX(Salary) FROM Employees WHERE Title = 'Sales Representative' ) AS MAX

What is the salary range for sales representative in Northwind ?

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


Question: Provide the language used in the country ruled by Pierre Buyoya.

SELECT T1.Language FROM CountryLanguage AS T1 INNER JOIN Country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = 'Pierre Buyoya'

Provide the language used in the country ruled by Pierre Buyoya .

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


Question: Which product's detail contains the word "Latte" or "Americano"? Return the full detail.

SELECT product_details FROM products WHERE product_details LIKE "%Latte%" OR product_details LIKE "%Americano%"

Which product 's detail contains the word " Latte " or " Americano " ? Return the full detail .

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


Question: What is the awarded category that the awarded character Lenny won?

SELECT DISTINCT T1.award_category FROM Award AS T1 INNER JOIN Character_Award AS T2 ON T1.award_id = T2.award_id WHERE T2.character = 'Lenny';

What is the awarded category that the awarded character Lenny won ?

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


Question: Give the name of the most widely used ingredient.

SELECT T1.name FROM Ingredient AS T1 INNER JOIN Quantity AS T2 ON T1.ingredient_id = T2.ingredient_id GROUP BY T1.name ORDER BY COUNT(T1.name) DESC LIMIT 1

Give the name of the most widely used ingredient .


Question: What is the maximum, average, and minimum enrollment for universities?

SELECT max(enrollment) ,  avg(enrollment) ,  min(enrollment) FROM University

What is the maximum , average , and minimum enrollment for universities ?


Question: Please list the Italian names of the cards in the set Coldsnap with the highest converted mana cost.

SELECT T2.name FROM foreign_data AS T1 INNER JOIN cards AS T2 ON T2.uuid = T1.uuid INNER JOIN sets AS T3 ON T3.code = T2.setCode WHERE T3.name = 'Coldsnap' AND T1.language = 'Italian' ORDER BY T2.convertedManaCost DESC

Please list the Italian names of the cards in the set Coldsnap with the highest converted mana cost .

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


Question: What is the genre ID of the game named 25 to Life?

SELECT T.genre_id FROM game AS T WHERE T.game_name = '25 to Life'

What is the genre ID of the game named 25 to Life ?

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


Question: What is the iso code of "Kyrgyz Republic"?

SELECT COUNTry_iso_code FROM COUNTry WHERE COUNTry_name = 'Kyrgyz Republic'

What is the iso code of " Kyrgyz Republic " ?

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


Question: Calculate the percentage of businesses who located in Mesa. What is attribute value of these businesses.

SELECT CAST(COUNT(T1.city) AS REAL) * 100 / ( SELECT COUNT(business_id) FROM Business ), T2.attribute_value FROM Business AS T1 INNER JOIN Business_Attributes AS T2 ON T1.business_id = T2.business_id WHERE T1.city = 'Mesa'

Calculate the percentage of businesses who located in Mesa . What is attribute value of these businesses .

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


Question: What are the minimum and maximum prices of food goods, ordered by food?

SELECT min(price) ,  max(price) ,  food FROM goods GROUP BY food ORDER BY food

What are the minimum and maximum prices of food goods , ordered by food ?

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


Question: What are the average price and score of wines grouped by appelation?

SELECT avg(Price) ,  avg(Score) ,  Appelation FROM WINE GROUP BY Appelation

What are the average price and score of wines grouped by appelation ?

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


Question: Give the flavors of Cakes that are not available for Tart.

SELECT DISTINCT flavor FROM goods WHERE food  =  "Cake" EXCEPT SELECT DISTINCT flavor FROM goods WHERE food  =  "Tart"

Give the flavors of Cakes that are not available for Tart .

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


Question: How many cards are there in the base set of "Hauptset Zehnte Edition"?

SELECT T1.baseSetSize FROM sets AS T1 INNER JOIN set_translations AS T2 ON T2.setCode = T1.code WHERE T2.translation = 'Hauptset Zehnte Edition'

How many cards are there in the base set of " Hauptset Zehnte Edition " ?

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


Question: What is the total amount due of all the purchases made by the company to the vendor that has the lowest selling price amount of a single product? Indicate the name of the vendor to which the purchases was made.

SELECT T1.UnitPrice, T3.Name FROM PurchaseOrderDetail AS T1 INNER JOIN PurchaseOrderHeader AS T2 ON T1.PurchaseOrderID = T2.PurchaseOrderID INNER JOIN Vendor AS T3 ON T2.VendorID = T3.BusinessEntityID ORDER BY T1.UnitPrice LIMIT 1

What is the total amount due of all the purchases made by the company to the vendor that has the lowest selling price amount of a single product ? Indicate the name of the vendor to which the purchases was made .

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


Question: What are the names of drivers, ordered descending alphabetically?

SELECT Driver_Name FROM driver ORDER BY Driver_Name DESC

What are the names of drivers , ordered descending alphabetically ?


Question: Show the names of the drivers without a school bus.

SELECT name FROM driver WHERE driver_id NOT IN (SELECT driver_id FROM school_bus)

Show the names of the drivers without a school bus .

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


Question: Who are the actors of film titled "BIRD INDEPENDENCE"?

SELECT T3.first_name, T3.last_name FROM film AS T1 INNER JOIN film_actor AS T2 ON T1.film_id = T2.film_id INNER JOIN actor AS T3 ON T2.actor_id = T3.actor_id WHERE T1.title = 'BIRD INDEPENDENCE'

Who are the actors of film titled " BIRD INDEPENDENCE " ?

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


Question: In Abadia, what is the word id of the of the Catalan language that appeared the highest amount of times? Indicate the how many times did they said word id appeared.

SELECT T2.wid, T2.occurrences FROM pages AS T1 INNER JOIN pages_words AS T2 ON T1.pid = T2.pid WHERE T1.title = 'Abadia' ORDER BY T2.occurrences DESC LIMIT 1

In Abadia , what is the word i d of the of the Catalan language that appeared the highest amount of times ? Indicate the how many times did they said word i d appeared .

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


Question: List the names of people that are not entrepreneurs.

SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM entrepreneur)

List the names of people that are not entrepreneurs .


Question: What are the bond IDs that have the same atom ID 2 of TR000_2?

SELECT T.bond_id FROM connected AS T WHERE T.atom_id2 = 'TR000_2'

What are the bond IDs that have the same atom ID 2 of TR000_2 ?

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


Question: What are the names of all students who tried out in alphabetical order?

SELECT T1.pName FROM player AS T1 JOIN tryout AS T2 ON T1.pID  =  T2.pID ORDER BY T1.pName

What are the names of all students who tried out in alphabetical order ?

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


Question: What is the price and quantity of the product named Seat Tube?

SELECT DISTINCT T2.Price, T1.Quantity FROM Sales AS T1 INNER JOIN Products AS T2 ON T1.ProductID = T2.ProductID WHERE T2.Name = 'Seat Tube'

What is the price and quantity of the product named Seat Tube ?

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


Question: To which current legislator does twitter ID234128524 belong? Please give his or her full official name.

SELECT T1.official_full_name FROM current AS T1 INNER JOIN `social-media` AS T2 ON T2.bioguide = T1.bioguide_id WHERE T2.twitter_id = 234128524

To which current legislator does twitter ID234128524 belong ? Please give his or her full official name .

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


Question: What were the locations of the events on 8th May, 2016?

SELECT longitude, latitude FROM `events` WHERE SUBSTR(`timestamp`, 1, 10) = '2016-05-08'

What were the locations of the events on 8th May , 2016 ?


Question: Return the names of planes owned by the pilot whose name is Smith and is 41 years old.

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

Return the names of planes owned by the pilot whose name is Smith and is 41 years old .

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


Question: What is the ID of the item that sold the best on 2012/1/1 in store no.1?

SELECT item_nbr FROM sales_in_weather WHERE `date` = '2012-01-01' AND store_nbr = 1 ORDER BY units DESC LIMIT 1

What is the ID of the item that sold the best on 2012/1/1 in store no.1 ?

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


Question: For each city, what is the highest latitude for its stations?

SELECT city ,  max(lat) FROM station GROUP BY city

For each city , what is the highest latitude for its stations ?


Question: List the names and locations of all stations ordered by their yearly entry exit and interchange amounts.

SELECT name ,  LOCATION FROM station ORDER BY Annual_entry_exit ,  Annual_interchanges

List the names and locations of all stations ordered by their yearly entry exit and interchange amounts .

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


Question: What is the gender and name of the artist who sang the song with the smallest resolution?

SELECT T1.gender ,  T1.artist_name FROM artist AS T1 JOIN song AS T2 ON T1.artist_name  =  T2.artist_name ORDER BY T2.resolution LIMIT 1

What is the gender and name of the artist who sang the song with the smallest resolution ?

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


Question: How many courses do students take at most? Also find the id of the student who takes the most courses.

SELECT count(*) ,  student_id FROM Classes GROUP BY student_id ORDER BY count(*) DESC LIMIT 1

How many courses do students take at most ? Also find the i d of the student who takes the most courses .

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


Question: Return the founder of Sony.

SELECT founder FROM manufacturers WHERE name  =  'Sony'


Question: What is the count of the songs that last approximately 4 minutes?

SELECT count(*) FROM files WHERE duration LIKE "4:%"

What is the count of the songs that last approximately 4 minutes ?


Question: Identify the operating hours of businesses in Black Canyon City with review count greater than average.

SELECT T2.opening_time, T2.closing_time 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 T1.city = 'Black Canyon City' GROUP BY t2.business_id HAVING T1.review_count > AVG(T1.review_count)

Identify the operating hours of businesses in Black Canyon City with review count greater than average .

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


Question: How many students of the Student_Club have attended the event "Women's Soccer"?

SELECT COUNT(T1.event_id) FROM event AS T1 INNER JOIN attendance AS T2 ON T1.event_id = T2.link_to_event WHERE T1.event_name = 'Women''s Soccer'

How many students of the Student_Club have attended the event " Women 's Soccer " ?

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


Question: Name the title of the episode that received the highest star score and the highest number of votes.

SELECT T1.title FROM Episode AS T1 INNER JOIN Vote AS T2 ON T2.episode_id = T1.episode_id ORDER BY T2.stars DESC, T2.votes DESC LIMIT 1;

Name the title of the episode that received the highest star score and the highest number of votes .

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


Question: Find the names of all instructors whose name includes the substring “dar”.

SELECT name FROM instructor WHERE name LIKE '%dar%'

Find the names of all instructors whose name includes the substring “ dar ” .

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


Question: How many complaints were served in 5 minutes or less by DORIT and responded to the customer with an explanation, were made by phone?

SELECT COUNT(T1.`Complaint ID`) FROM callcenterlogs AS T1 INNER JOIN events AS T2 ON T1.`Complaint ID` = T2.`Complaint ID` WHERE T1.ser_time < '00:05:00' AND T1.server = 'DORIT' AND T2.`Submitted via` = 'Phone' AND T2.`Company response to consumer` = 'Closed with explanation'

How many complaints were served in 5 minutes or less by DORIT and responded to the customer with an explanation , were made by phone ?

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


Question: Show student ids who don't have any sports.

SELECT StuID FROM Student EXCEPT SELECT StuID FROM Sportsinfo

Show student ids who do n't have any sports .


Question: Provide the name of game produced by 505 Games in 2006.

SELECT T3.game_name FROM game_platform AS T1 INNER JOIN game_publisher AS T2 ON T1.game_publisher_id = T2.id INNER JOIN game AS T3 ON T2.game_id = T3.id INNER JOIN publisher AS T4 ON T2.publisher_id = T4.id WHERE T4.publisher_name = '505 Games' AND T1.release_year = 2006

Provide the name of game produced by 505 Games in 2006 .

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


Question: What are the codes, names, and descriptions of the different document types?

SELECT document_type_code ,  document_type_name ,  document_type_description FROM Ref_document_types

What are the codes , names , and descriptions of the different document types ?

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


Question: Which CBSAs have more than 10 zip codes?

SELECT T1.CBSA_name FROM CBSA AS T1 INNER JOIN zip_data AS T2 ON T1.CBSA = T2.CBSA GROUP BY T1.CBSA HAVING COUNT(T2.zip_code) > 10

Which CBSAs have more than 10 zip codes ?

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


Question: What are the dates that have an average sea level pressure between 30.3 and 31?

SELECT date FROM weather WHERE mean_sea_level_pressure_inches BETWEEN 30.3 AND 31

What are the dates that have an average sea level pressure between 30.3 and 31 ?

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


Question: Find the name of scientists who are assigned to some project.

SELECT T2.name FROM assignedto AS T1 JOIN scientists AS T2 ON T1.scientist  =  T2.ssn

Find the name of scientists who are assigned to some project .

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


Question: Among the schools with an SAT excellence rate of over 0.3, what is the highest eligible free rate for students aged 5-17?

SELECT MAX(CAST(T1.`Free Meal Count (Ages 5-17)` AS REAL) / T1.`Enrollment (Ages 5-17)`) FROM frpm AS T1 INNER JOIN satscores AS T2 ON T1.CDSCode = T2.cds WHERE CAST(T2.NumGE1500 AS REAL) / T2.NumTstTakr > 0.3

Among the schools with an SAT excellence rate of over 0.3 , what is the highest eligible free rate for students aged 5 - 17 ?

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


Question: What is the name of the CBSA of the city with the highest average house value?

SELECT DISTINCT T1.CBSA_name FROM CBSA AS T1 INNER JOIN zip_data AS T2 ON T1.CBSA = T2.CBSA WHERE T2.avg_house_value = ( SELECT MAX(avg_house_value) FROM zip_data ) LIMIT 1

What is the name of the CBSA of the city with the highest average house value ?

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


Question: How many different products correspond to each order id?

SELECT order_id ,  count(DISTINCT product_id) FROM Order_items GROUP BY order_id

How many different products correspond to each order i d ?

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


Question: In which venue did Kochi Tuskers Kerala play most of their matches?

SELECT T1.Venue_Name FROM Venue AS T1 INNER JOIN Match AS T2 ON T1.Venue_Id = T2.Venue_Id INNER JOIN Team AS T3 ON T2.Team_1 = T3.Team_Id WHERE T3.Team_Name = 'Kochi Tuskers Kerala' GROUP BY T1.Venue_Name

In which venue did Kochi Tuskers Kerala play most of their matches ?

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


Question: What is the percentage of horror film titles in English film titles?

SELECT CAST(SUM(IIF(T3.name = 'Horror', 1, 0)) AS REAL) * 100 / COUNT(T1.film_id) FROM film_category AS T1 INNER JOIN film AS T2 ON T1.film_id = T2.film_id INNER JOIN category AS T3 ON T1.category_id = T3.category_id INNER JOIN language AS T4 ON T2.language_id = T4.language_id WHERE T4.name = 'English'

What is the percentage of horror film titles in English film titles ?

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


Question: Which kind of credit card does client number 9 possess?

SELECT T3.type FROM client AS T1 INNER JOIN disp AS T2 ON T1.client_id = T2.client_id INNER JOIN card AS T3 ON T2.disp_id = T3.disp_id WHERE T1.client_id = 9

Which kind of credit card does client number 9 possess ?


Question: Give me the average prices of wines that are produced by appelations in Sonoma County.

SELECT AVG(T2.Price) FROM APPELLATIONS AS T1 JOIN WINE AS T2 ON T1.Appelation  =  T2.Appelation WHERE T1.County  =  "Sonoma"

Give me the average prices of wines that are produced by appelations in Sonoma County .

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


Question: Return the description of the budget type that has the code ORG.

SELECT budget_type_description FROM Ref_budget_codes WHERE budget_type_code  =  "ORG"

Return the description of the budget type that has the code ORG .

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


Question: Which establishments did Joshua Rosa inspect?

SELECT DISTINCT T3.dba_name FROM employee AS T1 INNER JOIN inspection AS T2 ON T1.employee_id = T2.employee_id INNER JOIN establishment AS T3 ON T2.license_no = T3.license_no WHERE T1.first_name = 'Joshua' AND T1.last_name = 'Rosa'

Which establishments did Joshua Rosa inspect ?


Question: Which episode has the highest total number of viewer votes?

SELECT T1.title FROM Episode AS T1 INNER JOIN Vote AS T2 ON T1.episode_id = T2.episode_id GROUP BY T1.title ORDER BY SUM(T1.votes) DESC LIMIT 1

Which episode has the highest total number of viewer votes ?

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


Question: How films are produced by each studio?

SELECT Studio ,  COUNT(*) FROM film GROUP BY Studio


Question: What are the times of elimination for wrestlers with over 50 days held?

SELECT T1.Time FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID  =  T2.Wrestler_ID WHERE T2.Days_held  >  50

What are the times of elimination for wrestlers with over 50 days held ?

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


Question: What are the employee ids and job ids for employees who make less than the lowest earning employee with title MK_MAN?

SELECT employee_id ,  job_id FROM employees WHERE salary  <  ( SELECT min(salary) FROM employees WHERE job_id  =  'MK_MAN' )

What are the employee ids and job ids for employees who make less than the lowest earning employee with title MK_MAN ?

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


Question: Give at least five alias of cities with a postal point of post office.

SELECT T1.alias FROM alias AS T1 INNER JOIN zip_data AS T2 ON T1.zip_code = T2.zip_code WHERE T2.type = 'Post Office' LIMIT 5

Give at least five alias of cities with a postal point of post office .

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


Question: How many faculty lines are there in "San Francisco State University" in year 2004?

SELECT faculty FROM faculty AS T1 JOIN campuses AS T2 ON T1.campus  =  T2.id WHERE T1.year  =  2004 AND T2.campus  =  "San Francisco State University"

How many faculty lines are there in " San Francisco State University " in year 2004 ?

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


Question: Which student is more satisfied with the course Machine Learning Theory, Willie Rechert or Laughton Antonio?

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 (T1.f_name = 'Laughton' OR T1.f_name = 'Willie') AND (T1.l_name = 'Antonio' OR T1.l_name = 'Rechert') AND T3.name = 'Machine Learning Theory' ORDER BY T2.sat DESC LIMIT 1

Which student is more satisfied with the course Machine Learning Theory , Willie Rechert or Laughton Antonio ?

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


Question: List the names of wrestlers that have not been eliminated.

SELECT Name FROM wrestler WHERE Wrestler_ID NOT IN (SELECT Wrestler_ID FROM elimination)

List the names of wrestlers that have not been eliminated .

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


Question: What is the genre of the Advent Rising game?

SELECT T2.genre_name FROM game AS T1 INNER JOIN genre AS T2 ON T1.genre_id = T2.id WHERE T1.game_name = 'Advent Rising'

What is the genre of the Advent Rising game ?

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


Question: How many rivers finally flows to the sea of 459m in depth?

SELECT COUNT(*) FROM river WHERE Sea IN ( SELECT Name FROM sea WHERE Depth = 459 )

How many rivers finally flows to the sea of 459 m in depth ?

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


Question: What percentage of votes are from the nominated episodes?

SELECT CAST(SUM(CASE WHEN T1.result = 'Nominee' THEN T2.votes ELSE 0 END) AS REAL) * 100 / SUM(T2.votes) FROM Award AS T1 INNER JOIN Episode AS T2 ON T1.episode_id = T2.episode_id;

What percentage of votes are from the nominated episodes ?


Question: What percentage of cards without power are in French?

SELECT CAST(SUM(CASE WHEN T2.language = 'French' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(T1.id) FROM cards AS T1 INNER JOIN foreign_data AS T2 ON T1.uuid = T2.uuid WHERE T1.power IS NULL OR T1.power = '*'

What percentage of cards without power are in French ?


Question: List the authors and journal short name of the papers with "chemiluminescence" in its title and has a journal ID from 245 to 250.

SELECT T2.Name, T3.ShortName FROM Paper AS T1 INNER JOIN PaperAuthor AS T2 ON T1.Id = T2.PaperId INNER JOIN Journal AS T3 ON T1.JournalId = T3.Id WHERE T1.JournalId BETWEEN 245 AND 250 AND T1.Title LIKE '%chemiluminescence%'

List the authors and journal short name of the papers with " chemiluminescence " in its title and has a journal ID from 245 to 250 .

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


Question: What is the order ID of the security-Tint Envelopes product ordered on June 3, 2013, in the Central region?

SELECT DISTINCT T1.`Order ID` FROM central_superstore AS T1 INNER JOIN product AS T2 ON T1.`Product ID` = T2.`Product ID` WHERE T2.`Product Name` = 'Security-Tint Envelopes' AND T1.`Order Date` = '2013-06-03'

What is the order ID of the security - Tint Envelopes product ordered on June 3 , 2013 , in the Central region ?

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


Question: List all deceased goalies by last name. List the season where he had the most time played.

SELECT T1.playerID, T2.year, Min FROM Master AS T1 INNER JOIN Goalies AS T2 ON T2.playerID = T1.playerID WHERE T1.deathYear IS NOT NULL ORDER BY T2.Min DESC LIMIT 1

List all deceased goalies by last name . List the season where he had the most time played .

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


Question: How many customers do we have?


Question: State the gender of users who use the device "-9222956879900150000".

SELECT gender FROM gender_age WHERE device_id = -9222956879900150000

State the gender of users who use the device " -9222956879900150000 " .

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


Question: Which current legislator has served for more terms, Sherrod Brown or Maria Cantwell?

SELECT CASE WHEN SUM(CASE WHEN T1.official_full_name = 'Maria Cantwell' THEN 1 ELSE 0 END) > SUM(CASE WHEN T1.official_full_name = 'Sherrod Brown' THEN 1 ELSE 0 END) THEN 'Maria Cantwell' ELSE 'Sherrod Brown' END FROM current AS T1 INNER JOIN `current-terms` AS T2 ON T1.bioguide_id = T2.bioguide

Which current legislator has served for more terms , Sherrod Brown or Maria Cantwell ?

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


Question: Which city is post code 255 located in?

SELECT city FROM addresses WHERE zip_postcode  =  255

Which city is post code 255 located in ?

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


Question: How many female actors acted in the movies of year 4?

SELECT COUNT(T2.actorid) FROM movies AS T1 INNER JOIN movies2actors AS T2 ON T1.movieid = T2.movieid INNER JOIN actors AS T3 ON T2.actorid = T3.actorid WHERE T3.a_gender = 'F' AND T1.year = 4

How many female actors acted in the movies of year 4 ?

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


Question: Which detailed product did Mr Lennox Oliver Drake complain about?

SELECT DISTINCT T2.`Sub-product` FROM client AS T1 INNER JOIN events AS T2 ON T1.client_id = T2.Client_ID WHERE T1.first = 'Lennox' AND T1.middle = 'Oliver' AND T1.last = 'Drake' AND T1.sex = 'Male'

Which detailed product did Mr Lennox Oliver Drake complain about ?

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


Question: What is the total number of rooms available in this inn?

What is the total number of rooms available in this inn ?


Question: In which Country is the second highest volcanic mountain located in? Give the code of the country.

SELECT T3.Country FROM mountain AS T1 INNER JOIN geo_mountain AS T2 ON T1.Name = T2.Mountain INNER JOIN province AS T3 ON T3.Name = T2.Province ORDER BY T1.Height DESC LIMIT 1, 1

In which Country is the second highest volcanic mountain located in ? Give the code of the country .

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


Question: Find the full name of the customer with the email "luisg@embraer.com.br".

SELECT FirstName ,  LastName FROM CUSTOMER WHERE Email  =  "luisg@embraer.com.br"

Find the full name of the customer with the email " luisg@embraer.com.br " .

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


Question: What is the correlation between the review starts and business stars?

SELECT CAST(SUM(T2.review_stars) AS REAL) / COUNT(T1.business_id) FROM Business AS T1 INNER JOIN Reviews AS T2 ON T1.business_id = T2.business_id

What is the correlation between the review starts and business stars ?

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


Question: What are the names of scientists who have not been assigned a project?

SELECT Name FROM scientists WHERE ssn NOT IN (SELECT scientist FROM AssignedTo)

What are the names of scientists who have not been assigned a project ?

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


Question: Among the devices with event no.2 happening, how many of them are vivo devices?

SELECT COUNT(T1.device_id) FROM phone_brand_device_model2 AS T1 INNER JOIN events AS T2 ON T2.device_id = T1.device_id WHERE T1.phone_brand = 'vivo' AND T2.event_id = 2

Among the devices with event no.2 happening , how many of them are vivo devices ?

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


Question: Find the number of professors with a Ph.D. degree in each department.

SELECT count(*) ,  dept_code FROM professor WHERE prof_high_degree  =  'Ph.D.' GROUP BY dept_code

Find the number of professors with a Ph.D. degree in each department .


Question: Among the players whose total NHL games played in their first 7 years of NHL career is no less than 500, what is the name of the player who committed the most rule violations?

SELECT T1.PlayerName FROM PlayerInfo AS T1 INNER JOIN SeasonStatus AS T2 ON T1.ELITEID = T2.ELITEID WHERE T1.sum_7yr_GP > 500 ORDER BY T2.PIM DESC LIMIT 1

Among the players whose total NHL games played in their first 7 years of NHL career is no less than 500 , what is the name of the player who committed the most rule violations ?

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


Question: How many movies did Wolfgang Reitherman direct?

SELECT COUNT(name) FROM director WHERE director = 'Wolfgang Reitherman'

How many movies did Wolfgang Reitherman direct ?


Question: What was the deposit interest rate in the Commonwealth of Australia in 1979 in percentage?

SELECT T1.Value FROM Indicators AS T1 INNER JOIN Country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.LongName = 'Commonwealth of Australia' AND T1.IndicatorName = 'Deposit interest rate (%)' AND T1.Year = 1979

What was the deposit interest rate in the Commonwealth of Australia in 1979 in percentage ?

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


Question: Show the total number of rooms of all apartments with facility code "Gym".

SELECT sum(T2.room_count) FROM Apartment_Facilities AS T1 JOIN Apartments AS T2 ON T1.apt_id  =  T2.apt_id WHERE T1.facility_code  =  "Gym"

Show the total number of rooms of all apartments with facility code " Gym " .

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


Question: List all the event names by year from the most recent to the oldest.

SELECT name FROM event ORDER BY YEAR DESC

List all the event names by year from the most recent to the oldest .

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


Question: What's Emma H Harris's Business Entity ID number?

SELECT BusinessEntityID FROM Person WHERE FirstName = 'Emma' AND LastName = 'Harris'

What 's Emma H Harris 's Business Entity ID number ?

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


Question: Calculate the average number of male users who posted tweets in a week.

SELECT COUNT(DISTINCT T1.TweetID) / COUNT(DISTINCT T1.UserID) / 7 AS avg FROM twitter AS T1 INNER JOIN user AS T2 ON T1.UserID = T2.UserID WHERE T2.Gender = 'Male' AND T1.Day BETWEEN 1 AND 31

Calculate the average number of male users who posted tweets in a week .

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


Question: How many accounts are there for each customer id?

SELECT customer_id ,  count(*) FROM Accounts GROUP BY customer_id

How many accounts are there for each customer i d ?

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


Question: List the most common type of Status across cities.

SELECT Status FROM city GROUP BY Status ORDER BY COUNT(*) DESC LIMIT 1

List the most common type of Status across cities .


Question: What are the names of all tryout participants who are from the largest college?

SELECT T2.pName FROM  tryout AS T1 JOIN player AS T2 ON T1.pID  =  T2.pID WHERE T1.cName  =  (SELECT cName FROM college ORDER BY enr DESC LIMIT 1)

What are the names of all tryout participants who are from the largest college ?

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


Question: How many books are there?


Question: What is the ratio of outpatient to inpatient followed up treatment among all the 'SLE' diagnosed patient?

SELECT SUM(CASE WHEN Admission = '+' THEN 1.0 ELSE 0 END) / SUM(CASE WHEN Admission = '-' THEN 1 ELSE 0 END) FROM Patient WHERE Diagnosis = 'SLE'

What is the ratio of outpatient to inpatient followed up treatment among all the ' SLE ' diagnosed patient ?

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


Question: Find the names of users who have more than one tweet.

SELECT T1.name FROM user_profiles AS T1 JOIN tweets AS T2 ON T1.uid  =  T2.uid GROUP BY T2.uid HAVING count(*)  >  1

Find the names of users who have more than one tweet .


Question: How many students does Ogdon Zywicki advise?

SELECT COUNT(T1.student_id) FROM RA AS T1 INNER JOIN prof AS T2 ON T1.prof_id = T2.prof_id WHERE T2.first_name = 'Ogdon' AND T2.last_name = 'Zywicki'

How many students does Ogdon Zywicki advise ?


Question: What are the ids of the movies that are not reviewed by Brittany Harris.

SELECT mID FROM Rating EXCEPT SELECT T1.mID FROM Rating AS T1 JOIN Reviewer AS T2 ON T1.rID  =  T2.rID WHERE T2.name  =  "Brittany Harris"

What are the ids of the movies that are not reviewed by Brittany Harris .

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


Question: How many transactions were paid through MasterCard in 2014?

SELECT COUNT(TransactionID) FROM `transaction` WHERE CreditCardType = 'MasterCard' AND TransactionDate LIKE '2014%'

How many transactions were paid through MasterCard in 2014 ?


Question: List the film with the highest budget in each genre.

SELECT T3.genre_name, MAX(T1.budget) FROM movie AS T1 INNER JOIN movie_genres AS T2 ON T1.movie_id = T2.movie_id INNER JOIN genre AS T3 ON T2.genre_id = T3.genre_id GROUP BY T3.genre_name

List the film with the highest budget in each genre .


Question: Among the orders in Central superstore, which art product were ordered the most?

SELECT T2.`Product Name` FROM central_superstore AS T1 INNER JOIN product AS T2 ON T1.`Product ID` = T2.`Product ID` WHERE T2.`Sub-Category` = 'Art' GROUP BY T2.`Product Name` ORDER BY COUNT(T2.`Product ID`) DESC LIMIT 1

Among the orders in Central superstore , which art product were ordered the most ?

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


Question: display job ID for those jobs that were done by two or more for more than 300 days.

SELECT job_id FROM job_history WHERE end_date - start_date  > 300 GROUP BY job_id HAVING COUNT(*) >= 2

display job ID for those jobs that were done by two or more for more than 300 days .

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


Question: What are the total grosses for the movies with Jim Cummings as the voice actor?

SELECT T2.movie_title FROM `voice-actors` AS T1 INNER JOIN movies_total_gross AS T2 ON T2.movie_title = T1.movie WHERE T1.`voice-actor` = 'Jim Cummings' ORDER BY CAST(REPLACE(trim(T2.total_gross, '$'), ',', '') AS REAL) DESC LIMIT 1

What are the total grosses for the movies with Jim Cummings as the voice actor ?

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


Question: Player from which team has the highest point per minute in NBA from 1991 to 2000?

SELECT tmID FROM players_teams WHERE year BETWEEN 1991 AND 2000 ORDER BY CAST(points AS REAL) / minutes DESC LIMIT 1

Player from which team has the highest point per minute in NBA from 1991 to 2000 ?

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


Question: How many players born in USA are right-handed batters? That is, have the batter value 'R'.

SELECT count(*) FROM player WHERE birth_country = 'USA' AND bats  =  'R';

How many players born in USA are right - handed batters ? That is , have the batter value ' R ' .

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


Question: List the genres of the movies which actor id 851 is the star.

SELECT T2.genre FROM movies2actors AS T1 INNER JOIN movies2directors AS T2 ON T1.movieid = T2.movieid INNER JOIN actors AS T3 ON T1.actorid = T3.actorid WHERE T3.actorid = 851

List the genres of the movies which actor i d 851 is the star .

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


Question: Among the buildings not completed in 1980, what is the maximum number of stories?

SELECT max(Number_of_Stories) FROM building WHERE Completed_Year != "1980"

Among the buildings not completed in 1980 , what is the maximum number of stories ?

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


Question: What are the game IDs of the games published by Bethesda Softworks?

SELECT T1.game_id FROM game_publisher AS T1 INNER JOIN publisher AS T2 ON T1.publisher_id = T2.id WHERE T2.publisher_name = 'Bethesda Softworks'

What are the game IDs of the games published by Bethesda Softworks ?

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


Question: On average how many carcinogenic molecules are single bonded?

SELECT AVG(single_bond_count) FROM (SELECT T3.molecule_id, COUNT(T1.bond_type) AS single_bond_count FROM bond AS T1  INNER JOIN atom AS T2 ON T1.molecule_id = T2.molecule_id INNER JOIN molecule AS T3 ON T3.molecule_id = T2.molecule_id WHERE T1.bond_type = '-' AND T3.label = '+' GROUP BY T3.molecule_id) AS subquery

On average how many carcinogenic molecules are single bonded ?


Question: What is the hero's full name with the highest attribute in strength?

SELECT T1.full_name FROM superhero AS T1 INNER JOIN hero_attribute AS T2 ON T1.id = T2.hero_id INNER JOIN attribute AS T3 ON T2.attribute_id = T3.id WHERE T3.attribute_name = 'Strength' ORDER BY T2.attribute_value DESC LIMIT 1

What is the hero 's full name with the highest attribute in strength ?

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


Question: List total amount of  invoice from Chicago, IL.

SELECT sum(total) FROM invoices WHERE billing_city  =  "Chicago" AND billing_state  =  "IL";

List total amount of invoice from Chicago , IL .

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


Question: How many companies are in either "Banking" industry or "Conglomerate" industry?

SELECT count(*) FROM Companies WHERE Industry  =  "Banking" OR Industry  =  "Conglomerate"

How many companies are in either " Banking " industry or " Conglomerate " industry ?

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


Question: What is the name of the least popular Indian restaurant on Shattuck Avenue in Berkeley?

SELECT T1.id_restaurant FROM generalinfo AS T1 INNER JOIN location AS T2 ON T1.id_restaurant = T2.id_restaurant WHERE T1.city = 'berkeley' AND T2.street_name = 'shattuck ave' AND T1.food_type = 'Indian restaurant' ORDER BY T1.review LIMIT 1

What is the name of the least popular Indian restaurant on Shattuck Avenue in Berkeley ?

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


Question: Among the patients whose total cholesterol is within the normal range, how many of them have a P pattern observed in the sheet of ANA examination?

SELECT COUNT(T1.ID) FROM Patient AS T1 INNER JOIN Laboratory AS T2 ON T1.ID = T2.ID INNER JOIN Examination AS T3 ON T1.ID = T3.ID WHERE T3.`ANA Pattern` = 'P' AND T2.`T-CHO` < 250

Among the patients whose total cholesterol is within the normal range , how many of them have a P pattern observed in the sheet of ANA examination ?

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


Question: How many times does the biwords "que gregorio" appear in the language?

SELECT occurrences FROM biwords WHERE w1st = ( SELECT wid FROM words WHERE word = 'que' ) AND w2nd = ( SELECT wid FROM words WHERE word = 'gregorio' )

How many times does the biwords " que gregorio " appear in the language ?

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


Question: What is the title of episode that has a keyword of 'riot' and 'cake'?

SELECT DISTINCT T1.title FROM Episode AS T1 INNER JOIN Keyword AS T2 ON T1.episode_id = T2.episode_id WHERE T2.keyword IN ('riot', 'cake');

What is the title of episode that has a keyword of ' riot ' and ' cake ' ?

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


Question: List the customer's name from the South region with a standard class ship mode and sales greater than the 88% of the average sales of all orders.

SELECT DISTINCT T2.`Customer Name` FROM south_superstore AS T1 INNER JOIN people AS T2 ON T1.`Customer ID` = T2.`Customer ID` WHERE T2.Region = 'South' AND T1.`Ship Mode` = 'Standard Class' AND 100 * T1.Sales / ( SELECT AVG(Sales) FROM south_superstore ) > 88

List the customer 's name from the South region with a standard class ship mode and sales greater than the 88 % of the average sales of all orders .

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


Question: On average how many caffeinated root beers are sold a day?

SELECT CAST(COUNT(T2.RootBeerID) AS REAL) / COUNT(DISTINCT T2.PurchaseDate) FROM rootbeerbrand AS T1 INNER JOIN rootbeer AS T2 ON T1.BrandID = T2.BrandID INNER JOIN `transaction` AS T3 ON T2.RootBeerID = T3.RootBeerID WHERE T1.Caffeinated = 'TRUE'

On average how many caffeinated root beers are sold a day ?

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


Question: How many different clerks have served the customer with the address uFTe2u518et8Q8UC?

SELECT COUNT(T1.o_clerk) FROM orders AS T1 INNER JOIN customer AS T2 ON T1.o_custkey = T2.c_custkey WHERE T2.c_address = 'uFTe2u518et8Q8UC'

How many different clerks have served the customer with the address uFTe2u518et8Q8UC ?

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


Question: What is the minimum, mean, and maximum age across all students?

SELECT min(age) ,  avg(age) ,  max(age) FROM Student

What is the minimum , mean , and maximum age across all students ?

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


Question: Provide the most used keyword in the movies.

SELECT T1.keyword_name FROM keyword AS T1 INNER JOIN movie_keywords AS T2 ON T1.keyword_id = T2.keyword_id GROUP BY T1.keyword_name ORDER BY COUNT(T1.keyword_name) DESC LIMIT 1

Provide the most used keyword in the movies .


Question: What is the average number of characters in all the works of Shakespeare?

SELECT SUM(DISTINCT T4.id) / COUNT(T1.id) FROM works AS T1 INNER JOIN chapters AS T2 ON T1.id = T2.work_id INNER JOIN paragraphs AS T3 ON T2.id = T3.chapter_id INNER JOIN characters AS T4 ON T3.character_id = T4.id

What is the average number of characters in all the works of Shakespeare ?

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


Question: Count the number of vehicles.


Question: Enumerate the footnote narratives of The Bahamas under the series code SH.DTH.IMRT in the year 1984.

SELECT DISTINCT T1.Description FROM FootNotes AS T1 INNER JOIN Country AS T2 ON T1.Countrycode = T2.CountryCode WHERE T1.Year = 'YR1984' AND T2.ShortName = 'The Bahamas' AND T1.Seriescode = 'SH.DTH.IMRT'

Enumerate the footnote narratives of The Bahamas under the series code SH.DTH.IMRT in the year 1984 .

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


Question: Return the rank for which there are the fewest captains.

SELECT rank FROM captain GROUP BY rank ORDER BY count(*) DESC LIMIT 1

Return the rank for which there are the fewest captains .


Question: How many male customers who were born between 1974 and 1976 have made a payment on their home in excess of $4000?

SELECT COUNT(T1.account_id) FROM trans AS T1 INNER JOIN account AS T2 ON T1.account_id = T2.account_id INNER JOIN disp AS T4 ON T2.account_id = T4.account_id INNER JOIN client AS T3 ON T4.client_id = T3.client_id WHERE STRFTIME('%Y', T3.birth_date) BETWEEN '1974' AND '1976' AND T3.gender = 'M' AND T1.amount > 4000 AND T1.k_symbol = 'SIPO'

How many male customers who were born between 1974 and 1976 have made a payment on their home in excess of $ 4000 ?

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


Question: What are the names of the technicians by ascending order of age?

SELECT Name FROM technician ORDER BY Age ASC

What are the names of the technicians by ascending order of age ?

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


Question: Which top 20 driver created the shortest lap time ever record in a Formula_1 race? Please give them full names.

WITH lap_times_in_seconds AS (SELECT driverId, (CASE WHEN SUBSTR(time, 1, INSTR(time, ':') - 1) <> '' THEN CAST(SUBSTR(time, 1, INSTR(time, ':') - 1) AS REAL) * 60 ELSE 0 END + CASE WHEN SUBSTR(time, INSTR(time, ':') + 1, INSTR(time, '.') - INSTR(time, ':') - 1) <> '' THEN CAST(SUBSTR(time, INSTR(time, ':') + 1, INSTR(time, '.') - INSTR(time, ':') - 1) AS REAL) ELSE 0 END + CASE WHEN SUBSTR(time, INSTR(time, '.') + 1) <> '' THEN CAST(SUBSTR(time, INSTR(time, '.') + 1) AS REAL) / 1000 ELSE 0 END) AS time_in_seconds FROM lapTimes) SELECT T2.forename, T2.surname, T1.driverId FROM (SELECT driverId, MIN(time_in_seconds) AS min_time_in_seconds FROM lap_times_in_seconds GROUP BY driverId) AS T1 INNER JOIN drivers AS T2 ON T1.driverId = T2.driverId ORDER BY T1.min_time_in_seconds ASC LIMIT 20

Which top 20 driver created the shortest lap time ever record in a Formula_1 race ? Please give them full names .

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


Question: Find the code and content of all boxes whose value is higher than the value of all boxes with Scissors as content.

SELECT code ,  CONTENTS FROM boxes WHERE value  >  (SELECT max(value) FROM boxes WHERE CONTENTS  =  'Scissors')

Find the code and content of all boxes whose value is higher than the value of all boxes with Scissors as content .

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


Question: What is the percentage of female patient had total protein not within the normal range?

SELECT CAST(SUM(CASE WHEN T1.SEX = 'F' AND (T2.TP < 6.0 OR T2.TP > 8.5) THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(*) FROM Patient AS T1 INNER JOIN Laboratory AS T2 ON T1.ID = T2.ID WHERE T1.SEX = 'F'

What is the percentage of female patient had total protein not within the normal range ?

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


Question: Count the number of tracks that are part of the rock genre.

SELECT COUNT(*) FROM GENRE AS T1 JOIN TRACK AS T2 ON T1.GenreId  =  T2.GenreId WHERE T1.Name  =  "Rock"

Count the number of tracks that are part of the rock genre .

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


Question: How many sales does game platform id 3871 make in Europe?

SELECT T2.num_sales * 100000 FROM region AS T1 INNER JOIN region_sales AS T2 ON T1.id = T2.region_id WHERE T1.region_name = 'Europe' AND T2.game_platform_id = 3871

How many sales does game platform i d 3871 make in Europe ?

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


Question: Indicate the attribute value of superhero Abomination.

SELECT T2.attribute_value FROM superhero AS T1 INNER JOIN hero_attribute AS T2 ON T1.id = T2.hero_id WHERE T1.superhero_name = 'Abomination'

Indicate the attribute value of superhero Abomination .

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


Question: What are the names of all students who took a class and the corresponding course descriptions?

SELECT T1.stu_fname ,  T1.stu_lname ,  T4.crs_description 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

What are the names of all students who took a class and the corresponding course descriptions ?

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


Question: Which earpads never use plastic construction?

SELECT earpads FROM headphone EXCEPT SELECT earpads FROM headphone WHERE construction  =  'Plastic'

Which earpads never use plastic construction ?


Question: What are the names of all colleges that have two or more players?

SELECT College FROM match_season GROUP BY College HAVING count(*)  >=  2

What are the names of all colleges that have two or more players ?


Question: What are the the total number of territory in each region?

SELECT COUNT(TerritoryDescription) FROM Territories WHERE RegionID IN (1, 2, 3, 4) GROUP BY RegionID

What are the the total number of territory in each region ?

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


Question: What is the description of the airline code 19049?

SELECT Description FROM `Air Carriers` WHERE Code = 19049

What is the description of the airline code 19049 ?


Question: What are the maximum points of British constructors?

SELECT MAX(T1.points) FROM constructorStandings AS T1 INNER JOIN constructors AS T2 on T1.constructorId = T2.constructorId WHERE T2.nationality = 'British'

What are the maximum points of British constructors ?


Question: How many video games do you have?


Question: Calculate the average score of university ID 79 between year 2013 to 2015.

SELECT AVG(score) FROM university_ranking_year WHERE year BETWEEN 2013 AND 2015 AND university_id = 79

Calculate the average score of university ID 79 between year 2013 to 2015 .

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


Question: In 2012, how many Asian female graduates were seeking another type of degree or certificate at the 4-year institution at University of Alaska at Anchorage?

SELECT COUNT(*) FROM institution_details AS T1 INNER JOIN institution_grads AS T2 ON T1.unitid = T2.unitid WHERE T2.gender = 'F' AND T2.race = 'A' AND T1.chronname = 'University of Alaska at Anchorage' AND T2.cohort = '4y other'

In 2012 , how many Asian female graduates were seeking another type of degree or certificate at the 4 - year institution at University of Alaska at Anchorage ?

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


Question: Find the address and staff number of the shops that do not have any happy hour.

SELECT address ,  num_of_staff FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM happy_hour)

Find the address and staff number of the shops that do not have any happy hour .

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


Question: How many word that has number of different words equal to 3?

SELECT COUNT(T2.wid) FROM pages AS T1 INNER JOIN pages_words AS T2 ON T1.pid = T2.pid WHERE T1.words = 3

How many word that has number of different words equal to 3 ?


Question: How many incidents have the general description of "ASSAULT" in the IUCR classification?

SELECT COUNT(*) FROM IUCR WHERE primary_description = 'ASSAULT'

How many incidents have the general description of " ASSAULT " in the IUCR classification ?

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


Question: Name all disabled students that are enrolled in SMC.

SELECT T2.name FROM enrolled AS T1 INNER JOIN disabled AS T2 ON T1.`name` = T2.`name` WHERE T1.school = 'smc'

Name all disabled students that are enrolled in SMC .

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


Question: Did license number 1222441 pass the inspection and what is the zip code number of it?

SELECT DISTINCT T2.results, T1.zip FROM establishment AS T1 INNER JOIN inspection AS T2 ON T1.license_no = T2.license_no WHERE T1.license_no = 1222441

Did license number 1222441 pass the inspection and what is the zip code number of it ?

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


Question: Which winning team in the 1947 playoff quarterfinals managed to score 3,513 defensive points that same year?

SELECT T2.tmID FROM series_post AS T1 INNER JOIN teams AS T2 ON T1.tmIDWinner = T2.tmID WHERE T1.year = 1947 AND T1.round = 'QF' AND T2.d_pts = 3513

Which winning team in the 1947 playoff quarterfinals managed to score 3,513 defensive points that same year ?

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


Question: Name the player who is born on July 7, 1981.

SELECT Player_name FROM Player WHERE DOB = '1981-07-07'

Name the player who is born on July 7 , 1981 .


Question: Which customer uses the most policies? Give me the customer name.

SELECT t1.customer_name FROM customers AS t1 JOIN customers_policies AS t2 ON t1.customer_id  =  t2.customer_id GROUP BY t1.customer_name ORDER BY count(*) DESC LIMIT 1

Which customer uses the most policies ? Give me the customer name .

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


Question: What is the average population growth rate of countries where more than 3 languages are used?

SELECT SUM(T3.Population_Growth) / COUNT(T3.Country) FROM country AS T1 INNER JOIN language AS T2 ON T1.Code = T2.Country INNER JOIN population AS T3 ON T3.Country = T2.Country WHERE T2.Country IN ( SELECT Country FROM language GROUP BY Country HAVING COUNT(Country) > 3 ) GROUP BY T3.Country

What is the average population growth rate of countries where more than 3 languages are used ?

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


Question: For all products sold more than 3 times, what are their ids and descriptions?

SELECT T1.product_id ,  T1.product_description FROM Products AS T1 JOIN Order_items AS T2 ON T1.product_id  =  T2.product_id GROUP BY T1.product_id HAVING count(*)  >  3

For all products sold more than 3 times , what are their ids and descriptions ?

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


Question: For all the female patient age 50 and above, who has abnormal red blood cell count. State if they were admitted to hospital.

SELECT DISTINCT T1.ID, T1.Admission FROM Patient AS T1 INNER JOIN Laboratory AS T2 ON T1.ID = T2.ID WHERE T1.SEX = 'F' AND (T2.RBC <= 3.5 OR T2.RBC >= 6.0) AND STRFTIME('%Y', CURRENT_TIMESTAMP) - STRFTIME('%Y', T1.Birthday) >= 50

For all the female patient age 50 and above , who has abnormal red blood cell count . State if they were admitted to hospital .

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


Question: Among all the customers in Brazil, how many of them have an account balance of less than 1000?

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 = 'BRAZIL' AND T1.c_acctbal < 1000

Among all the customers in Brazil , how many of them have an account balance of less than 1000 ?

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


Question: How many credits does the department offer?

SELECT sum(crs_credit) ,  dept_code FROM course GROUP BY dept_code

How many credits does the department offer ?


Question: What are the names of all employees who are not certified to fly Boeing 737-800s?

SELECT name FROM Employee EXCEPT SELECT T1.name FROM Employee AS T1 JOIN Certificate AS T2 ON T1.eid  =  T2.eid JOIN Aircraft AS T3 ON T3.aid  =  T2.aid WHERE T3.name  =  "Boeing 737-800"

What are the names of all employees who are not certified to fly Boeing 737 - 800s ?

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


Question: Identify the total number of orders placed by the customer 'Laughing Bacchus Wine Cellars' and it's average value.

SELECT COUNT(T2.OrderID) , SUM(T3.UnitPrice * T3.Quantity * (1 - T3.Discount)) / COUNT(T2.OrderID) FROM Customers AS T1 INNER JOIN Orders AS T2 ON T1.CustomerID = T2.CustomerID INNER JOIN `Order Details` AS T3 ON T2.OrderID = T3.OrderID WHERE T1.CompanyName = 'Laughing Bacchus Wine Cellars'

Identify the total number of orders placed by the customer ' Laughing Bacchus Wine Cellars ' and it 's average value .

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


Question: Show the names of club leaders of clubs with overall ranking higher than 100.

SELECT T3.Name ,  T2.Club_Name FROM club_leader AS T1 JOIN club AS T2 ON T1.Club_ID  =  T2.Club_ID JOIN member AS T3 ON T1.Member_ID  =  T3.Member_ID WHERE T2.Overall_Ranking  <  100

Show the names of club leaders of clubs with overall ranking higher than 100 .

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


Question: For the method which got the tokenized name as 't jadwal entity get single mpic', what is the path time for its solution?

SELECT DISTINCT T1.ProcessedTime FROM Solution AS T1 INNER JOIN Method AS T2 ON T1.Id = T2.SolutionId WHERE T2.NameTokenized = 't jadwal entity get single mpic'

For the method which got the tokenized name as ' t jadwal entity get single mpic ' , what is the path time for its solution ?

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


Question: When was the product with the highest unit price shipped?

SELECT t1.shippedDate FROM orders AS t1 INNER JOIN orderdetails AS t2 ON t1.orderNumber = t2.orderNumber ORDER BY t2.priceEach DESC LIMIT 1

When was the product with the highest unit price shipped ?


Question: Which product has the highest net profit in 2019?

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

Which product has the highest net profit in 2019 ?

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


Question: Give me the detail and opening hour for each museum.

SELECT T1.Museum_Details ,  T2.Opening_Hours FROM MUSEUMS AS T1 JOIN TOURIST_ATTRACTIONS AS T2 ON T1.Museum_ID  =  T2.Tourist_Attraction_ID

Give me the detail and opening hour for each museum .

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


Question: Please calculate the number of orders from customers by country in 1996.

SELECT COUNT(T2.CustomerID) FROM Customers AS T1 INNER JOIN Orders AS T2 ON T1.CustomerID = T2.CustomerID WHERE STRFTIME('%Y', T2.OrderDate) = '1996' GROUP BY T1.Country

Please calculate the number of orders from customers by country in 1996 .

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


Question: What are the details of the student who registered for the most number of courses?

SELECT T1.student_details FROM students AS T1 JOIN student_course_registrations AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1

What are the details of the student who registered for the most number of courses ?

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


Question: Among the accounts who have loan validity more than 24 months, list out the accounts that have the lowest approved amount and have account opening date before 1997.

SELECT T1.account_id FROM loan AS T1 INNER JOIN account AS T2 ON T1.account_id = T2.account_id WHERE T1.duration > 24 AND STRFTIME('%Y', T2.date) < '1997' ORDER BY T1.amount ASC LIMIT 1

Among the accounts who have loan validity more than 24 months , list out the accounts that have the lowest approved amount and have account opening date before 1997 .

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


Question: Show the most common location of performances.

SELECT LOCATION FROM performance GROUP BY LOCATION ORDER BY COUNT(*) DESC LIMIT 1

Show the most common location of performances .


Question: How many units of item no.5 were sold in store no.3 in total on days with a total precipitation of over 0.05?

SELECT SUM(CASE WHEN T3.preciptotal > 0.05 THEN units ELSE 0 END) AS sum FROM sales_in_weather AS T1 INNER JOIN relation AS T2 ON T1.store_nbr = T2.store_nbr INNER JOIN weather AS T3 ON T2.station_nbr = T3.station_nbr WHERE T2.store_nbr = 3 AND T1.item_nbr = 5

How many units of item no.5 were sold in store no.3 in total on days with a total precipitation of over 0.05 ?

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


Question: In how many counties is there a street called Appian Way?

SELECT COUNT(DISTINCT T2.county) FROM location AS T1 INNER JOIN geographic AS T2 ON T1.city = T2.city WHERE T1.street_name = 'appian way'

In how many counties is there a street called Appian Way ?

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


Question: List down the business ID with a star range from 2 to 3, located at Mesa.

SELECT business_id FROM Business WHERE city LIKE 'Mesa' AND stars BETWEEN 2 AND 3

List down the business ID with a star range from 2 to 3 , located at Mesa .

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


Question: List the full name and phone number of male customers from Fair Oaks who are subscribed to the email list.

SELECT First, Last, PhoneNumber FROM customers WHERE Gender = 'M' AND City = 'Fair Oaks' AND SubscribedToEmailList = 'TRUE'

List the full name and phone number of male customers from Fair Oaks who are subscribed to the email list .

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


Question: What is the category of the inspection of the establishment named "J & J FOOD"?

SELECT DISTINCT T4.category 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 INNER JOIN inspection_point AS T4 ON T3.point_id = T4.point_id WHERE T1.dba_name = 'J & J FOOD'

What is the category of the inspection of the establishment named " J & J FOOD " ?

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


Question: What are the x and y coordinates of all the images with a prediction relationship class id of 98?

SELECT T2.X, T2.Y FROM IMG_REL AS T1 INNER JOIN IMG_OBJ AS T2 ON T1.IMG_ID = T2.IMG_ID WHERE T1.PRED_CLASS_ID = 98

What are the x and y coordinates of all the images with a prediction relationship class i d of 98 ?

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


Question: Return the last name of the staff member who handled the complaint with the earliest date raised.

SELECT t1.last_name FROM staff AS t1 JOIN complaints AS t2 ON t1.staff_id  =  t2.staff_id ORDER BY t2.date_complaint_raised LIMIT 1

Return the last name of the staff member who handled the complaint with the earliest date raised .

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


Question: Return the hometown that is most common among gymnasts.

SELECT T2.Hometown FROM gymnast AS T1 JOIN people AS T2 ON T1.Gymnast_ID  =  T2.People_ID GROUP BY T2.Hometown ORDER BY COUNT(*) DESC LIMIT 1

Return the hometown that is most common among gymnasts .


Question: List the award name and persons who won the award in 2009.

SELECT award, person FROM Award WHERE result = 'Winner' AND SUBSTR(year, 1, 4) = '2009';

List the award name and persons who won the award in 2009 .

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


Question: What are the names of the wrestlers, ordered descending by days held?

SELECT Name FROM wrestler ORDER BY Days_held DESC

What are the names of the wrestlers , ordered descending by days held ?

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


Question: Which county do the delegates on "Appropriations" committee belong to? Give me the county names.

SELECT T1.County_name FROM county AS T1 JOIN election AS T2 ON T1.County_id  =  T2.District WHERE T2.Committee  =  "Appropriations"

Which county do the delegates on " Appropriations " committee belong to ? Give me the county names .

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


Question: Which paper is published in an institution in "USA" and have "Turon" as its second 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 JOIN inst AS t4 ON t2.instid  =  t4.instid WHERE t4.country  =  "USA" AND t2.authorder  =  2 AND t1.lname  =  "Turon"

Which paper is published in an institution in " USA " and have " Turon " as its second author ?

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


Question: What are the categories of music festivals for which there have been more than 1 music festival?

SELECT Category FROM music_festival GROUP BY Category HAVING COUNT(*)  >  1

What are the categories of music festivals for which there have been more than 1 music festival ?

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


Question: List the first names of the people with more than 65 sick leave hours.

SELECT T2.FirstName FROM Employee AS T1 INNER JOIN Person AS T2 ON T1.BusinessEntityID = T2.BusinessEntityID WHERE T1.SickLeaveHours > 65

List the first names of the people with more than 65 sick leave hours .

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


Question: Which chicken restaurant has the highest review?

SELECT label FROM generalinfo WHERE food_type = 'chicken' ORDER BY review DESC LIMIT 1

Which chicken restaurant has the highest review ?


Question: How many times does the Catalan word "nombre" repeat itself?

SELECT T1.occurrences FROM langs_words AS T1 INNER JOIN words AS T2 ON T1.wid = T2.wid WHERE T2.word = 'nombre'

How many times does the Catalan word " nombre " repeat itself ?

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


Question: Give the publisher's name of the books authored by Alan Lee.

SELECT T4.publisher_name FROM book AS T1 INNER JOIN book_author AS T2 ON T1.book_id = T2.book_id INNER JOIN author AS T3 ON T3.author_id = T2.author_id INNER JOIN publisher AS T4 ON T4.publisher_id = T1.publisher_id WHERE T3.author_name = 'Alan Lee' GROUP BY T4.publisher_name

Give the publisher 's name of the books authored by Alan Lee .

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


Question: Which station sold the highest quantity of item number 5 overall?

SELECT T2.station_nbr FROM sales_in_weather AS T1 INNER JOIN relation AS T2 ON T1.store_nbr = T2.store_nbr WHERE T1.item_nbr = 5 GROUP BY T2.station_nbr ORDER BY SUM(T1.units) DESC LIMIT 1

Which station sold the highest quantity of item number 5 overall ?

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


Question: What are the method, date and amount of each payment? Sort the list in ascending order of date.

SELECT Payment_Method_Code ,  Date_Payment_Made ,  Amount_Payment FROM Payments ORDER BY Date_Payment_Made ASC

What are the method , date and amount of each payment ? Sort the list in ascending order of date .

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


Question: List the name of all products in the west superstore that customers chose for same-day shipment in the year 2013.

SELECT T2.`Product Name` FROM west_superstore AS T1 INNER JOIN product AS T2 ON T1.`Product ID` = T2.`Product ID` WHERE T1.`Ship Mode` = 'Same Day' AND T1.`Ship Date` LIKE '2013%'

List the name of all products in the west superstore that customers chose for same - day shipment in the year 2013 .

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


Question: List down the platform IDs of the games released in 2007.

SELECT DISTINCT T.platform_id FROM game_platform AS T WHERE T.release_year = 2007

List down the platform IDs of the games released in 2007 .

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


Question: List the names of counties that do not have any cities.

SELECT Name FROM county_public_safety WHERE County_ID NOT IN (SELECT County_ID FROM city)

List the names of counties that do not have any cities .

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


Question: Show all book isbns which were ordered by both client Peter Doe and client James Smith.

SELECT T2.isbn FROM Orders AS T1 JOIN Books_Order AS T2 ON T1.idOrder  =  T2.idOrder JOIN Client AS T3 ON T1.idClient  =  T3.idClient WHERE T3.name  =  "Peter Doe" INTERSECT SELECT T2.isbn FROM Orders AS T1 JOIN Books_Order AS T2 ON T1.idOrder  =  T2.idOrder JOIN Client AS T3 ON T1.idClient  =  T3.idClient WHERE T3.name  =  "James Smith"

Show all book isbns which were ordered by both client Peter Doe and client James Smith .

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


Question: How many elections are there?


Question: What are the years when countries have indicator name of "Air transport, passengers carried"? List the table name of these countries.

SELECT DISTINCT T2.Year, T1.TableName FROM Country AS T1 INNER JOIN Indicators AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IndicatorName = 'Air transport, passengers carried'

What are the years when countries have indicator name of " Air transport , passengers carried " ? List the table name of these countries .

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


Question: What is the song with the most vocals?

SELECT title FROM vocals AS T1 JOIN songs AS T2 ON T1.songid  =  T2.songid GROUP BY T1.songid ORDER BY count(*) DESC LIMIT 1


Question: Among the languages used in Baltic Countries, provide the languages which are used by over 80%.

SELECT T2.Language FROM Country AS T1 INNER JOIN CountryLanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Region = 'Baltic Countries' AND T2.Percentage > 80

Among the languages used in Baltic Countries , provide the languages which are used by over 80 % .

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


Question: What is the average number of papers published in the World Computer Congress each year?

SELECT CAST(SUM(CASE WHEN T2.FullName = 'International Congress Series' THEN 1 ELSE 0 END) AS REAL) / COUNT(T1.Id) AS Div1, T1.Year FROM Paper AS T1 INNER JOIN Journal AS T2 ON T1.JournalId = T2.Id GROUP BY T1.YEAR HAVING Div1 != 0

What is the average number of papers published in the World Computer Congress each year ?

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


Question: Which students only got the most common result for his or her all behaviour monitoring details? List the students' biographical information.

SELECT T1.bio_data FROM Students AS T1 JOIN Behaviour_Monitoring AS T2 ON T1.student_id  =  T2.student_id WHERE T2.behaviour_monitoring_details IN ( SELECT behaviour_monitoring_details FROM Behaviour_Monitoring GROUP BY behaviour_monitoring_details ORDER BY count(*) DESC LIMIT 1 ) EXCEPT SELECT T1.bio_data FROM Students AS T1 JOIN Behaviour_Monitoring AS T2 ON T1.student_id  =  T2.student_id WHERE T2.behaviour_monitoring_details NOT IN ( SELECT behaviour_monitoring_details FROM Behaviour_Monitoring GROUP BY behaviour_monitoring_details ORDER BY count(*) DESC LIMIT 1 )

Which students only got the most common result for his or her all behaviour monitoring details ? List the students ' biographical information .

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


Question: What is the name of the production company that made the most movies?

SELECT T1.company_name FROM production_company AS T1 INNER JOIN movie_company AS T2 ON T1.company_id = T2.company_id GROUP BY T1.company_id ORDER BY COUNT(T2.movie_id) DESC LIMIT 1

What is the name of the production company that made the most movies ?

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


Question: What is the maximum sweep volume of a car that costs less than $30000?

SELECT MAX(T1.displacement / T1.cylinders) FROM data AS T1 INNER JOIN price AS T2 ON T1.ID = T2.ID WHERE T2.price < 30000

What is the maximum sweep volume of a car that costs less than $ 30000 ?


Question: What are the allergies and their types?

SELECT allergy ,  allergytype FROM Allergy_type

What are the allergies and their types ?


Question: What is the last date of the staff leaving the projects?

SELECT date_to FROM Project_Staff ORDER BY date_to DESC LIMIT 1

What is the last date of the staff leaving the projects ?


Question: How many shooter games are there?

SELECT COUNT(T1.id) FROM game AS T1 INNER JOIN genre AS T2 ON T1.genre_id = T2.id WHERE T2.genre_name = 'Shooter'


Question: Among the single bond molecule id, which molecules are not carcinogenic?

SELECT DISTINCT T1.molecule_id FROM bond AS T1 INNER JOIN molecule AS T2 ON T1.molecule_id = T2.molecule_id WHERE T2.label = '-' AND T1.bond_type = '-'

Among the single bond molecule i d , which molecules are not carcinogenic ?

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


Question: How many female users reshared their tweets?

SELECT COUNT(T1.UserID) FROM twitter AS T1 INNER JOIN user AS T2 ON T1.UserID = T2.UserID WHERE T2.Gender = 'Female' AND T1.IsReshare = 'TRUE'

How many female users reshared their tweets ?


Question: How many cars on a train that runs in the east direction have a flat roof?

SELECT SUM(CASE WHEN T1.roof = 'flat' THEN 1 ELSE 0 END)as count FROM cars AS T1 INNER JOIN trains AS T2 ON T1.train_id = T2.id WHERE T2.direction = 'east'

How many cars on a train that runs in the east direction have a flat roof ?

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


Question: List the duration, file size and format of songs whose genre is pop, ordered by title?

SELECT T1.duration ,  T1.file_size ,  T1.formats FROM files AS T1 JOIN song AS T2 ON T1.f_id  =  T2.f_id WHERE T2.genre_is  =  "pop" ORDER BY T2.song_name

List the duration , file size and format of songs whose genre is pop , ordered by title ?

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


Question: What are the names of staff who have been assigned multiple jobs?

SELECT T1.staff_name FROM staff AS T1 JOIN staff_department_assignments AS T2 ON T1.staff_id  =  T2.staff_id GROUP BY T2.staff_id HAVING COUNT (*)  >  1

What are the names of staff who have been assigned multiple jobs ?


Question: Among all the users with the average ratings of at least 4 and above of all reviews, calculate the percent that have no fans or followers.

SELECT CAST(SUM(CASE WHEN user_fans = 'None' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(user_id) FROM Users WHERE user_average_stars >= 4

Among all the users with the average ratings of at least 4 and above of all reviews , calculate the percent that have no fans or followers .

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


Question: How many online sales were made in May 2018 where products were shipped from Norman?

SELECT SUM(CASE WHEN T1.OrderDate LIKE '5/%/18' AND T1.`Sales Channel` = 'Online' AND T2.`City Name` = 'Norman' THEN 1 ELSE 0 END) FROM `Sales Orders` AS T1 INNER JOIN `Store Locations` AS T2 ON T2.StoreID = T1._StoreID

How many online sales were made in May 2018 where products were shipped from Norman ?

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


Question: What is the highest price of the dish "Clear green turtle" on a menu page?

SELECT T2.price FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id WHERE T1.name = 'Clear green turtle' ORDER BY T2.price DESC LIMIT 1

What is the highest price of the dish " Clear green turtle " on a menu page ?

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


Question: Where was the first Olympic game held?

SELECT T2.city_name FROM games_city AS T1 INNER JOIN city AS T2 ON T1.city_id = T2.id INNER JOIN games AS T3 ON T1.games_id = T3.id ORDER BY T3.games_year LIMIT 1


Question: Show different parties of people along with the number of people in each party.

SELECT Party ,  COUNT(*) FROM people GROUP BY Party

Show different parties of people along with the number of people in each party .

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


Question: What is the most common interaction type between enzymes and medicine? And how many are there?

SELECT interaction_type ,  count(*) FROM medicine_enzyme_interaction GROUP BY interaction_type ORDER BY count(*) DESC LIMIT 1

What is the most common interaction type between enzymes and medicine ? And how many are there ?

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


Question: Return the ids of the two department store chains with the most department stores.

SELECT dept_store_chain_id FROM department_stores GROUP BY dept_store_chain_id ORDER BY count(*) DESC LIMIT 2

Return the ids of the two department store chains with the most department stores .

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


Question: List down the long name for slow speed class team.

SELECT DISTINCT t1.team_long_name FROM Team AS t1 INNER JOIN Team_Attributes AS t2 ON t1.team_api_id = t2.team_api_id WHERE t2.buildUpPlaySpeedClass = 'Slow'

List down the long name for slow speed class team .

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


Question: What is the number of air carriers in the database?

What is the number of air carriers in the database ?


Question: List all the product names with the color description "white".

SELECT t1.product_name FROM products AS t1 JOIN ref_colors AS t2 ON t1.color_code  =  t2.color_code WHERE t2.color_description  =  "white"

List all the product names with the color description " white " .

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


Question: What are the voice sound quality scores received for the song named ' The Balkan Girls ' in English language ?

SELECT T1.voice_sound_quality FROM performance_score AS T1 JOIN songs AS T2 ON T1.songs_id  =  T2.id WHERE T2.name  =  ' The Balkan Girls ' AND T2.language  =  'English'

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


Question: List all the attribute classes of image ID 22.

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

List all the attribute classes of image ID 22 .

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


Question: What was the temperature range of station no.1 on 2012/1/1?

SELECT tmax - tmin AS temrange FROM weather WHERE station_nbr = 1 AND `date` = '2012-01-01'

What was the temperature range of station no.1 on 2012/1/1 ?

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


Question: Please list the disparate time of the transactions taken place in the gas stations from chain no. 11.

SELECT DISTINCT T1.Time FROM transactions_1k AS T1 INNER JOIN gasstations AS T2 ON T1.GasStationID = T2.GasStationID WHERE T2.ChainID = 11

Please list the disparate time of the transactions taken place in the gas stations from chain no . 11 .

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


Question: What is the passing class of CLB team?

SELECT DISTINCT t2.buildUpPlayPassingClass FROM Team AS t1 INNER JOIN Team_Attributes AS t2 ON t1.team_api_id = t2.team_api_id WHERE t1.team_short_name = 'CLB'

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


Question: Which publisher has published the game 'Pachi-Slot Kanzen Kouryaku 3: Universal Koushiki Gaido Volume 3'?

SELECT T1.publisher_name FROM publisher AS T1 INNER JOIN game_publisher AS T2 ON T1.id = T2.publisher_id INNER JOIN game AS T3 ON T2.game_id = T3.id WHERE T3.game_name = 'Pachi-Slot Kanzen Kouryaku 3: Universal Koushiki Gaido Volume 3'

Which publisher has published the game ' Pachi - Slot Kanzen Kouryaku 3 : Universal Koushiki Gaido Volume 3 ' ?

O B-TABLE O B-COLUMN 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


Question: Among the books published in 2004, list the name of the publisher of books with number of pages greater than 70% of the average number of pages of all books.

SELECT T1.title, T2.publisher_name FROM book AS T1 INNER JOIN publisher AS T2 ON T1.publisher_id = T2.publisher_id WHERE STRFTIME('%Y', T1.publication_date) = '2004' AND T1.num_pages * 100 > ( SELECT AVG(num_pages) FROM book ) * 70

Among the books published in 2004 , list the name of the publisher of books with number of pages greater than 70 % of the average number of pages of all books .

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


Question: Return all information about employees with salaries between 8000 and 12000 for which commission is not null or where their department id is not 40.

SELECT * FROM employees WHERE salary BETWEEN 8000 AND 12000 AND commission_pct != "null" OR  department_id != 40

Return all information about employees with salaries between 8000 and 12000 for which commission is not null or where their department i d is not 40 .

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


Question: Rank heroes published by Marvel Comics by their height in descending order.

SELECT superhero_name, height_cm, RANK() OVER (ORDER BY height_cm DESC) AS HeightRank FROM superhero INNER JOIN publisher ON superhero.publisher_id = publisher.id WHERE publisher.publisher_name = 'Marvel Comics'

Rank heroes published by Marvel Comics by their height in descending order .

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


Question: Which business was the first one to get a low risk violation because of "Permit license or inspection report not posted"? Give the name of the business.

SELECT T2.name FROM violations AS T1 INNER JOIN businesses AS T2 ON T1.business_id = T2.business_id WHERE T1.`date` = ( SELECT MIN(`date`) FROM violations WHERE risk_category = 'Low Risk' AND description = 'Permit license or inspection report not posted' ) AND T1.risk_category = 'Low Risk' AND T1.description = 'Permit license or inspection report not posted'

Which business was the first one to get a low risk violation because of " Permit license or inspection report not posted " ? Give the name of the business .

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


Question: Among the publishers in the USA, how many of them have published books that are over $15?

SELECT COUNT(DISTINCT T1.pub_id) FROM titles AS T1 INNER JOIN publishers AS T2 ON T1.pub_id = T2.pub_id WHERE T2.country = 'USA' AND T1.price > 15

Among the publishers in the USA , how many of them have published books that are over $ 15 ?

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


Question: What is the total average movie directed by the directors who's quality and revenue is 4?

SELECT CAST(SUM(CASE WHEN T1.d_quality = 4 AND T1.avg_revenue = 4 THEN 1 ELSE 0 END) AS REAL) / COUNT(T2.movieid) FROM directors AS T1 INNER JOIN movies2directors AS T2 ON T1.directorid = T2.directorid

What is the total average movie directed by the directors who 's quality and revenue is 4 ?

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


Question: Among the Independent senators that started their term in 2011 and onwards, what are the official full names of the senators that caucused with the Democrat?

SELECT T1.official_full_name FROM current AS T1 INNER JOIN `current-terms` AS T2 ON T1.bioguide_id = T2.bioguide WHERE T2.party = 'Independent' AND strftime('%Y', T2.start) >= '2011' AND T2.type = 'sen' AND T2.caucus = 'Democrat'

Among the Independent senators that started their term in 2011 and onwards , what are the official full names of the senators that caucused with the Democrat ?

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


Question: How much US dollars does a Ford Torino cost?

SELECT T2.price FROM data AS T1 INNER JOIN price AS T2 ON T1.ID = T2.ID WHERE T1.car_name = 'ford torino'

How much US dollars does a Ford Torino cost ?


Question: What are the names of the states where at least 3 heads were born?

SELECT born_state FROM head GROUP BY born_state HAVING count(*)  >=  3

What are the names of the states where at least 3 heads were born ?

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


Question: What is the first and last name of the student who played the most sports?

SELECT T2.Fname ,  T2.Lname FROM Sportsinfo AS T1 JOIN Student AS T2 ON T1.StuID  =  T2.StuID GROUP BY T1.StuID ORDER BY count(*) DESC LIMIT 1

What is the first and last name of the student who played the most sports ?

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


Question: What are the first names of student who only took one course?

SELECT T1.stu_fname FROM student AS T1 JOIN enroll AS T2 ON T1.stu_num  =  T2.stu_num GROUP BY T2.stu_num HAVING count(*)  =  1

What are the first names of student who only took one course ?

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


Question: What was the maximum weight of the shipment carried to Boston? Name the customer of that shipment.

SELECT T1.weight, T2.cust_name FROM shipment AS T1 INNER JOIN customer AS T2 ON T1.cust_id = T2.cust_id INNER JOIN city AS T3 ON T3.city_id = T1.city_id WHERE T3.city_name = 'Boston' ORDER BY T1.weight DESC LIMIT 1

What was the maximum weight of the shipment carried to Boston ? Name the customer of that shipment .

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


Question: Among the legislators who started a term on 2nd December 1793, how many of them were males?

SELECT COUNT(T1.bioguide_id) FROM historical AS T1 INNER JOIN `historical-terms` AS T2 ON T1.bioguide_id = T2.bioguide WHERE T1.gender_bio = 'M' AND T2.start = '1793-12-02'

Among the legislators who started a term on 2nd December 1793 , how many of them were males ?

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


Question: How many business have been reviewed by user ID 3 and how long have this user been with Yelp?

SELECT COUNT(T1.business_id) , strftime('%Y', 'now') - T2.user_yelping_since_year FROM Reviews AS T1 INNER JOIN Users AS T2 ON T1.user_id = T2.user_id WHERE T1.user_id = 3

How many business have been reviewed by user ID 3 and how long have this user been with Yelp ?

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


Question: Show the product type and name for the products with price higher than 1000 or lower than 500.

SELECT product_type_code ,  product_name FROM products WHERE product_price  >  1000 OR product_price  <  500

Show the product type and name for the products with price higher than 1000 or lower than 500 .

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


Question: Define the onion's bounding box on image no. 285930.

SELECT T1.X, T1.Y, T1.W, T1.H FROM IMG_OBJ AS T1 INNER JOIN OBJ_CLASSES AS T2 ON T1.OBJ_CLASS_ID = T2.OBJ_CLASS_ID WHERE T1.IMG_ID = 285930 AND T2.OBJ_CLASS = 'onion'

Define the onion 's bounding box on image no . 285930 .


Question: List the biographical data and student id for the students who take 2 or more classes and the students who have less than 2 detentions.

SELECT T1.bio_data ,  T1.student_id FROM Students AS T1 JOIN Classes AS T2 ON T1.student_id  =  T2.student_id GROUP BY T1.student_id HAVING count(*)  >=  2 UNION SELECT T1.bio_data ,  T1.student_id FROM Students AS T1 JOIN Detention AS T2 ON T1.student_id  =  T2.student_id GROUP BY T1.student_id HAVING count(*)  <  2

List the biographical data and student i d for the students who take 2 or more classes and the students who have less than 2 detentions .

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


Question: Find the number of stores in each city.

SELECT t3.headquartered_city ,  count(*) FROM store AS t1 JOIN store_district AS t2 ON t1.store_id  =  t2.store_id JOIN district AS t3 ON t2.district_id  =  t3.district_id GROUP BY t3.headquartered_city

Find the number of stores in each city .


Question: How many employees who are IT staff are from each city?

SELECT count(*) ,  city FROM employees WHERE title  =  'IT Staff' GROUP BY city

How many employees who are IT staff are from each city ?

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


Question: Please list the shapes of all the head cars on the trains that run in the east direction.

SELECT T1.shape FROM cars AS T1 INNER JOIN trains AS T2 ON T1.train_id = T2.id WHERE T2.direction = 'east' AND T1.position = 1 GROUP BY T1.shape

Please list the shapes of all the head cars on the trains that run in the east direction .

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


Question: What is the average salary of all employees with a 2 year degree position?

SELECT AVG(CAST(REPLACE(SUBSTR(T1.salary, 4), ',', '') AS REAL)) FROM employee AS T1  INNER JOIN position AS T2  ON T1.positionID = T2.positionID WHERE T2.educationrequired = '2 year degree'

What is the average salary of all employees with a 2 year degree position ?

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


Question: Compare the numbers of postal points under Smith Adrian and Heck Joe.

SELECT CASE WHEN COUNT(CASE WHEN T1.first_name = 'Smith' AND T1.last_name = 'Adrian' THEN T2.zip_code ELSE NULL END) > COUNT(CASE WHEN T1.first_name = 'Heck' AND T1.last_name = 'Joe' THEN T2.zip_code ELSE NULL END) THEN 'Smith Adrian>Heck Joe' ELSE 'Smith Adrian<=Heck Joe' END AS COMPARE FROM congress AS T1 INNER JOIN zip_congress AS T2 ON T1.cognress_rep_id = T2.district

Compare the numbers of postal points under Smith Adrian and Heck Joe .

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


Question: Give me the match ID and date of the matches that were held in Kingsmead for three consecutive days.

SELECT T1.Match_Id, T1.Match_Date FROM `Match` AS T1 INNER JOIN Venue AS T2 ON T1.Venue_Id = T2.Venue_Id WHERE T2.Venue_Name = 'Kingsmead'

Give me the match ID and date of the matches that were held in Kingsmead for three consecutive days .

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


Question: What is the name of all sailors whose rating is higher than any sailor named Luis?

SELECT name FROM Sailors WHERE rating  >  (SELECT min(rating) FROM Sailors WHERE name  =  'Luis')

What is the name of all sailors whose rating is higher than any sailor named Luis ?

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


Question: What is the number of professors for different school?

SELECT count(*) ,  T1.school_code FROM department AS T1 JOIN professor AS T2 ON T1.dept_code  =  T2.dept_code GROUP BY T1.school_code

What is the number of professors for different school ?


Question: Describe the voice actors and villains in Cinderella.

SELECT T1.`voice-actor`, T2.villian FROM `voice-actors` AS T1 INNER JOIN characters AS T2 ON T1.movie = T2.movie_title WHERE T2.movie_title = 'Cinderella'

Describe the voice actors and villains in Cinderella .

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


Question: Among the postal points in the District of Columbia, how many of them have an area with above 20000 black population?

SELECT COUNT(T1.zip_code) FROM country AS T1 INNER JOIN zip_data AS T2 ON T1.zip_code = T2.zip_code WHERE T1.county = 'DISTRICT OF COLUMBIA' AND T2.black_population > 20000

Among the postal points in the District of Columbia , how many of them have an area with above 20000 black population ?

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


Question: Please give the link of the website that shows more information about the circuits the Spanish Grand Prix used in 2009.

SELECT T1.url FROM circuits AS T1 INNER JOIN races AS T2 ON T2.circuitID = T1.circuitId WHERE T2.year = 2009 AND T2.name = 'Spanish Grand Prix'

Please give the link of the website that shows more information about the circuits the Spanish Grand Prix used in 2009 .

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


Question: What dishes made their first and last appearances in 1855 and 1900, respectively?

SELECT name FROM Dish WHERE first_appeared = 1855 AND last_appeared = 1900

What dishes made their first and last appearances in 1855 and 1900 , respectively ?

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


Question: Excluding all P only ANA Pattern patients, how many of the remainder are women born between 1980 and 1989?

SELECT COUNT(DISTINCT T1.ID) FROM Patient AS T1 INNER JOIN Examination AS T2 ON T1.ID = T2.ID WHERE T2.`ANA Pattern` != 'P' AND STRFTIME('%Y', T1.Birthday) BETWEEN '1980' AND '1989' AND T1.SEX = 'F'

Excluding all P only ANA Pattern patients , how many of the remainder are women born between 1980 and 1989 ?

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


Question: How many institutions with over 50,000 students in 2011 had a percentage of oversea students of more than 10%?

SELECT COUNT(*) FROM university_year WHERE year = 2011 AND num_students > 50000 AND pct_international_students > 10

How many institutions with over 50,000 students in 2011 had a percentage of oversea students of more than 10 % ?

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


Question: List the race class with at least two races.

SELECT CLASS FROM race GROUP BY CLASS HAVING count(*)  >=  2

List the race class with at least two races .


Question: List all the coaches with more game lost than won from year 2000-2010. List the coach ID, team name and year.

SELECT DISTINCT T1.coachID, T2.tmID, T1.year FROM coaches AS T1 INNER JOIN teams AS T2 ON T1.tmID = T2.tmID AND T1.year = T2.year WHERE T1.year BETWEEN 2000 AND 2010 AND T2.lost > T2.won

List all the coaches with more game lost than won from year 2000 - 2010 . List the coach ID , team name and year .

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


Question: List the forename and surname of all distinct drivers who once had laptime less than 93000 milliseconds?

SELECT DISTINCT T1.forename ,  T1.surname FROM drivers AS T1 JOIN laptimes AS T2 ON T1.driverid = T2.driverid WHERE T2.milliseconds < 93000

List the forename and surname of all distinct drivers who once had laptime less than 93000 milliseconds ?

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


Question: How many sales channels does the sales team have in the Midwest?

SELECT COUNT(T1.`Sales Channel`) FROM `Sales Orders` AS T1 INNER JOIN `Sales Team` AS T2 ON T2.SalesTeamID = T1._SalesTeamID WHERE T2.Region = 'Midwest'

How many sales channels does the sales team have in the Midwest ?

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


Question: return all columns of the albums created in the year of 2012.

SELECT * FROM Albums WHERE YEAR  =  2012

return all columns of the albums created in the year of 2012 .

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


Question: Find the file format that is used by the most files.

SELECT formats FROM files GROUP BY formats ORDER BY COUNT (*) DESC LIMIT 1

Find the file format that is used by the most files .


Question: Give the names of the female cast in Movie No. 1865.

SELECT T2.person_name FROM movie_cast AS T1 INNER JOIN person AS T2 ON T1.person_id = T2.person_id INNER JOIN gender AS T3 ON T1.gender_id = T3.gender_id WHERE T1.movie_id = 1865 AND T3.gender = 'Female'

Give the names of the female cast in Movie No . 1865 .

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