Question: SELECT count(*) FROM Properties WHERE parking_lots  =  1 OR garage_yn  =  1;

SELECT count ( * ) FROM Properties WHERE parking_lots = 1 OR garage_yn = 1 ;

select count ( * ) from properties where parking_lots = value or garage_yn = value

Question: How many properties have 1 parking lot or 1 garage?

How many properties have 1 parking lot or 1 garage ?


Question: SELECT avg(value) ,  sum(value) FROM boxes

SELECT avg ( value ) , sum ( value ) FROM boxes

select avg ( value ) , sum ( value ) from boxes

Question: Find the average and total values of all boxes.

Find the average and total values of all boxes .


Question: SELECT T2.Name FROM building AS T1 JOIN region AS T2 ON T1.Region_ID  =  T2.Region_ID GROUP BY T1.Region_ID HAVING COUNT(*)  >  1

SELECT T2.Name FROM building AS T1 JOIN region AS T2 ON T1.Region_ID = T2.Region_ID GROUP BY T1.Region_ID HAVING COUNT ( * ) > 1

select t2 . name from building as t1 join region as t2 on t1 . region_id = t2 . region_id group by t1 . region_id having count ( * ) > value

Question: Show the names of regions that have more than one building.

Show the names of regions that have more than one building .


Question: SELECT DISTINCT T4.Collection_Name FROM Collection_Subset_Members AS T1 JOIN Collection_Subset_Members AS T2 ON T1.Related_Collection_ID = T2.Collection_ID JOIN Collections AS T3 ON T1.Collection_ID = T3.Collection_ID JOIN Collections AS T4 ON T2.Collection_ID = T4.Collection_ID WHERE T3.Collection_Name = "Best";

Question: What are the names of the collections that are related to the collection named Best?

What are the names of the collections that are related to the collection named Best ?


Question: SELECT Team FROM team WHERE Team_ID NOT IN (SELECT Team_ID FROM team_driver)

SELECT Team FROM team WHERE Team_ID NOT IN ( SELECT Team_ID FROM team_driver )

select team from team where team_id not in ( select team_id from team_driver )

Question: List the names of teams that do not have any drivers.

List the names of teams that do not have any drivers .


Question: SELECT id ,  flavor FROM goods WHERE food  =  "Cake" ORDER BY flavor

SELECT id , flavor FROM goods WHERE food = `` Cake '' ORDER BY flavor

select id , flavor from goods where food = value order by flavor

Question: Return a list of the id and flavor for Cakes ordered by flavor.

Return a list of the id and flavor for Cakes ordered by flavor .


Question: SELECT count(*) ,  plane_name FROM pilotskills GROUP BY plane_name HAVING avg(age)  <  35

SELECT count ( * ) , plane_name FROM pilotskills GROUP BY plane_name HAVING avg ( age ) < 35

select count ( * ) , plane_name from pilotskills group by plane_name having avg ( age ) < value

Question: Find the number of pilots for the plane types with average pilot age below 35.

Find the number of pilots for the plane types with average pilot age below 35 .


Question: SELECT DISTINCT T1.PackageNumber FROM PACKAGE AS T1 JOIN Client AS T2 ON T1.Sender  =  T2.AccountNumber OR T1.Recipient  =  T2.AccountNumber WHERE T2.Name = "Leo Wong"

SELECT DISTINCT T1.PackageNumber FROM PACKAGE AS T1 JOIN Client AS T2 ON T1.Sender = T2.AccountNumber OR T1.Recipient = T2.AccountNumber WHERE T2.Name = `` Leo Wong ''

select distinct t1 . packagenumber from package as t1 join client as t2 on t1 . sender = t2 . accountnumber or t1 . recipient = t2 . accountnumber where t2 . name = value

Question: List all package sent or received by Leo Wong.

List all package sent or received by Leo Wong .


Question: SELECT title FROM paintings WHERE width_mm  <  600 OR height_mm  >  800

select title from paintings where width_mm < value or height_mm > value

Question: What are the titles of paintings that have a width less than 600 or a height taller taller than 800?

What are the titles of paintings that have a width less than 600 or a height taller taller than 800 ?


Question: SELECT name FROM Author

Question: What are the names of all the authors?


Question: SELECT max(voice_sound_quality) ,  min(voice_sound_quality) FROM performance_score

SELECT max ( voice_sound_quality ) , min ( voice_sound_quality ) FROM performance_score

select max ( voice_sound_quality ) , min ( voice_sound_quality ) from performance_score

Question: What are the maximum and minimum voice sound quality score of the performances?

What are the maximum and minimum voice sound quality score of the performances ?


Question: SELECT room_size ,  count(*) FROM Rooms GROUP BY room_size

SELECT room_size , count ( * ) FROM Rooms GROUP BY room_size

select room_size , count ( * ) from rooms group by room_size

Question: Return the number of rooms with each different room size.

Return the number of rooms with each different room size .


Question: SELECT count(*) FROM City AS T1 JOIN Student AS T2 ON T1.city_code  =  T2.city_code WHERE T1.country  =  "CHINA"

SELECT count ( * ) FROM City AS T1 JOIN Student AS T2 ON T1.city_code = T2.city_code WHERE T1.country = `` CHINA ''

select count ( * ) from city as t1 join student as t2 on t1 . city_code = t2 . city_code where t1 . country = value

Question: Count the number of students living in China.

Count the number of students living in China .


Question: SELECT DISTINCT CONTENTS FROM boxes WHERE value  >  (SELECT avg(value) FROM boxes)

SELECT DISTINCT CONTENTS FROM boxes WHERE value > ( SELECT avg ( value ) FROM boxes )

select distinct contents from boxes where value > ( select avg ( value ) from boxes )

Question: What are the different contents of boxes for which the value is higher than the average value across all boxes?

What are the different contents of boxes for which the value is higher than the average value across all boxes ?


Question: SELECT count(DISTINCT LOCATION) FROM hangar

SELECT count ( DISTINCT LOCATION ) FROM hangar

select count ( distinct location ) from hangar

Question: How many different places have some plane?

How many different places have some plane ?


Question: SELECT T1.ShipmentID FROM Shipment AS T1 JOIN Employee AS T2 ON T1.Manager = T2.EmployeeID WHERE T2.Name = "Phillip J. Fry";

SELECT T1.ShipmentID FROM Shipment AS T1 JOIN Employee AS T2 ON T1.Manager = T2.EmployeeID WHERE T2.Name = `` Phillip J. Fry '' ;

select t1 . shipmentid from shipment as t1 join employee as t2 on t1 . manager = t2 . employeeid where t2 . name = value

Question: List all shipment id under Phillip J. Fry's management.

List all shipment id under Phillip J. Fry 's management .


Question: SELECT count(*) FROM Properties GROUP BY property_id HAVING count(*)  >= 2;

SELECT count ( * ) FROM Properties GROUP BY property_id HAVING count ( * ) > = 2 ;

select count ( * ) from properties group by property_id having count ( * ) > = value

Question: Count the number of properties with at least two features.

Count the number of properties with at least two features .


Question: SELECT T2.Document_Object_ID FROM Document_Objects AS T1 JOIN Document_Objects AS T2 ON T1.Parent_Document_Object_ID = T2.Document_Object_ID GROUP BY T2.Document_Object_ID HAVING count(*)  >  1;

Question: What are the ids of the documents that have more than one child?

What are the ids of the documents that have more than one child ?


Question: SELECT deathYear - birthYear FROM artists ORDER BY deathYear - birthYear LIMIT 1

select deathyear - birthyear from artists order by deathyear - birthyear limit value

Question: What is the age of the artist who had the shortest life?

What is the age of the artist who had the shortest life ?


Question: SELECT T1.feature_name ,  T1.feature_description FROM Features AS T1 JOIN Property_Features AS T2 ON T1.feature_id  =  T2.feature_id GROUP BY T1.feature_name ORDER BY count(*) DESC LIMIT 1;

SELECT T1.feature_name , T1.feature_description FROM Features AS T1 JOIN Property_Features AS T2 ON T1.feature_id = T2.feature_id GROUP BY T1.feature_name ORDER BY count ( * ) DESC LIMIT 1 ;

Question: Give the feature name and description for the most common feature across all properties.

Give the feature name and description for the most common feature across all properties .


Question: SELECT AVG(rating) ,  MAX(age) FROM Sailors

SELECT AVG ( rating ) , MAX ( age ) FROM Sailors

select avg ( rating ) , max ( age ) from sailors

Question: Find the average rating and largest age for the sailors


Question: SELECT customer_id FROM Customers EXCEPT SELECT customer_id FROM Customer_orders

select customer_id from customers except select customer_id from customer_orders

Question: What are the ids of customers who have not made an order?

What are the ids of customers who have not made an order ?


Question: SELECT T1.bio_data ,  T1.student_details FROM Students AS T1 JOIN Student_Loans AS T2 ON T1.student_id  =  T2.student_id WHERE T2.amount_of_loan  >  ( SELECT avg(amount_of_loan) FROM Student_Loans )

Question: Find the biographical data and details for students whose student loan is above the average amount.

Find the biographical data and details for students whose student loan is above the average amount .


Question: SELECT name FROM countries ORDER BY overall_score DESC

select name from countries order by overall_score desc

Question: Show the names of countries in descending order of overall scores.

Show the names of countries in descending order of overall scores .


Question: SELECT invoice_status_code FROM Invoices WHERE invoice_number NOT IN ( SELECT invoice_number FROM Shipments )

select invoice_status_code from invoices where invoice_number not in ( select invoice_number from shipments )

Question: What are the invoice statuses for all orderes that have not been shipped out yet?

What are the invoice statuses for all orderes that have not been shipped out yet ?


Question: SELECT name FROM countries ORDER BY politics_score DESC LIMIT 1

select name from countries order by politics_score desc limit value

Question: List the name of the country with the biggest score in politics.

List the name of the country with the biggest score in politics .


Question: SELECT count(*) ,  racing_series FROM driver GROUP BY racing_series

SELECT count ( * ) , racing_series FROM driver GROUP BY racing_series

select count ( * ) , racing_series from driver group by racing_series

Question: Count the number of drivers that have raced in each series.

Count the number of drivers that have raced in each series .


Question: SELECT T1.teacher_details ,  T1.teacher_id FROM Teachers AS T1 JOIN Classes AS T2 ON T1.teacher_id  =  T2.teacher_id GROUP BY T1.teacher_id ORDER BY count(*) DESC LIMIT 1

SELECT T1.teacher_details , T1.teacher_id FROM Teachers AS T1 JOIN Classes AS T2 ON T1.teacher_id = T2.teacher_id GROUP BY T1.teacher_id ORDER BY count ( * ) DESC LIMIT 1

select t1 . teacher_details , t1 . teacher_id from teachers as t1 join classes as t2 on t1 . teacher_id = t2 . teacher_id group by t1 . teacher_id order by count ( * ) desc limit value

Question: List the detail and id of the teacher who teaches the most courses.

List the detail and id of the teacher who teaches the most courses .


Question: SELECT paintingID FROM paintings WHERE height_mm  >  500 AND height_mm  <  2000

select paintingid from paintings where height_mm > value and height_mm < value

Question: What are the ids of paintings that are taller than 500 and shorter than 2000?

What are the ids of paintings that are taller than 500 and shorter than 2000 ?


Question: select t1.document_subset_id ,  t2.document_subset_name , count(distinct t1.document_object_id) from document_subset_members as t1 join document_subsets as t2 on t1.document_subset_id =  t2.document_subset_id group by t1.document_subset_id order by count(*) desc limit 1;

select t1.document_subset_id , t2.document_subset_name , count ( distinct t1.document_object_id ) from document_subset_members as t1 join document_subsets as t2 on t1.document_subset_id = t2.document_subset_id group by t1.document_subset_id order by count ( * ) desc limit 1 ;

Question: Which document subset has most of number of distinct documents ? List subset id , name and number of documents .


Question: select distinct subject_code from exams order by subject_code asc

Question: List the distinct subject code of exams in ascending alphabetical order .


Question: SELECT count(*) ,  gender FROM author WHERE age  >  30 GROUP BY gender

SELECT count ( * ) , gender FROM author WHERE age > 30 GROUP BY gender

select count ( * ) , gender from author where age > value group by gender

Question: How many authors are of age above 30 for each gender?

How many authors are of age above 30 for each gender ?


Question: SELECT T1.Driver_Name ,  COUNT(*) FROM driver AS T1 JOIN race AS T2 ON T1.Driver_ID  =  T2.Driver_ID GROUP BY T1.Driver_ID

SELECT T1.Driver_Name , COUNT ( * ) FROM driver AS T1 JOIN race AS T2 ON T1.Driver_ID = T2.Driver_ID GROUP BY T1.Driver_ID

select t1 . driver_name , count ( * ) from driver as t1 join race as t2 on t1 . driver_id = t2 . driver_id group by t1 . driver_id

Question: Please show the names of drivers and the number of races they participate in.

Please show the names of drivers and the number of races they participate in .


Question: SELECT T2.Document_Object_ID ,  count(*) FROM Document_Objects AS T1 JOIN Document_Objects AS T2 ON T1.Parent_Document_Object_ID = T2.Document_Object_ID GROUP BY T2.Document_Object_ID;

Question: How many child documents does each parent document has? List the document id and the number.

How many child documents does each parent document has ? List the document id and the number .


Question: SELECT CONTENTS FROM boxes ORDER BY value DESC LIMIT 1

select contents from boxes order by value desc limit value

Question: Find the content that has the highest total values in all boxes.

Find the content that has the highest total values in all boxes .


Question: SELECT T3.Name FROM Has_Clearance AS T1 JOIN Employee AS T2 ON T1.Employee = T2.EmployeeID JOIN Planet AS T3 ON T1.Planet = T3.PlanetID GROUP BY T1.Planet HAVING count(*)  =  1;

SELECT T3.Name FROM Has_Clearance AS T1 JOIN Employee AS T2 ON T1.Employee = T2.EmployeeID JOIN Planet AS T3 ON T1.Planet = T3.PlanetID GROUP BY T1.Planet HAVING count ( * ) = 1 ;

select t3 . name from has_clearance as t1 join employee as t2 on t1 . employee = t2 . employeeid join planet as t3 on t1 . planet = t3 . planetid group by t1 . planet having count ( * ) = value

Question: Which planets that have exact one employee has clearance? List planets' name.

Which planets that have exact one employee has clearance ? List planets ' name .


Question: SELECT count(*) FROM Customers WHERE customer_id NOT IN ( SELECT customer_id FROM Customer_Payment_Methods )

SELECT count ( * ) FROM Customers WHERE customer_id NOT IN ( SELECT customer_id FROM Customer_Payment_Methods )

select count ( * ) from customers where customer_id not in ( select customer_id from customer_payment_methods )

Question: How many customers do not have any payment method?

How many customers do not have any payment method ?


Question: SELECT T1.title FROM movies AS T1 JOIN movietheaters AS T2 ON T1.code  =  T2.movie WHERE T2.name  =  'Odeon' INTERSECT SELECT T1.title FROM movies AS T1 JOIN movietheaters AS T2 ON T1.code  =  T2.movie WHERE T2.name  =  'Imperial'

SELECT T1.title FROM movies AS T1 JOIN movietheaters AS T2 ON T1.code = T2.movie WHERE T2.name = 'Odeon ' INTERSECT SELECT T1.title FROM movies AS T1 JOIN movietheaters AS T2 ON T1.code = T2.movie WHERE T2.name = 'Imperial '

select t1 . title from movies as t1 join movietheaters as t2 on t1 . code = t2 . movie where t2 . name = value intersect select t1 . title from movies as t1 join movietheaters as t2 on t1 . code = t2 . movie where t2 . name = value

Question: What movie is playing at both the Odeon and Imperial theater?

What movie is playing at both the Odeon and Imperial theater ?


Question: SELECT document_name ,  document_description FROM Documents

select document_name , document_description from documents

Question: Show the names and descriptions for all documents.

Show the names and descriptions for all documents .


Question: SELECT avg(age) ,  gender FROM author GROUP BY gender

SELECT avg ( age ) , gender FROM author GROUP BY gender

select avg ( age ) , gender from author group by gender

Question: find the average age of authors for each gender.

find the average age of authors for each gender .


Question: select name from member where nationality != "england"

select name from member where nationality ! = value

Question: List the names of members whose nationality is not `` England '' .


Question: SELECT name FROM languages WHERE id NOT IN (SELECT language_id FROM official_languages)

SELECT name FROM languages WHERE id NOT IN ( SELECT language_id FROM official_languages )

select name from languages where id not in ( select language_id from official_languages )

Question: What are the names of languages that are not the official language of any country?

What are the names of languages that are not the official language of any country ?


Question: SELECT T1.deathYear FROM artists AS T1 JOIN sculptures AS T2 ON T1.artistID  =  T2.sculptorID GROUP BY T2.sculptorID ORDER BY count(*) LIMIT 1

SELECT T1.deathYear FROM artists AS T1 JOIN sculptures AS T2 ON T1.artistID = T2.sculptorID GROUP BY T2.sculptorID ORDER BY count ( * ) LIMIT 1

select t1 . deathyear from artists as t1 join sculptures as t2 on t1 . artistid = t2 . sculptorid group by t2 . sculptorid order by count ( * ) limit value

Question: When did the artist who made the fewest sculptures die?

When did the artist who made the fewest sculptures die ?


Question: SELECT count(DISTINCT room_size) FROM Rooms;

SELECT count ( DISTINCT room_size ) FROM Rooms ;

select count ( distinct room_size ) from rooms

Question: How many kinds of room sizes are listed?

How many kinds of room sizes are listed ?


Question: SELECT DISTINCT T1.Document_Object_ID FROM Document_Subset_Members AS T1 JOIN Document_Subsets AS T2 ON T1.Document_Subset_ID =  T2.Document_Subset_ID WHERE T2.Document_Subset_Name = "Best for 2000";

Question: For document subset named 'Best for 2000', List all document id that in this subset.

For document subset named 'Best for 2000 ' , List all document id that in this subset .


Question: SELECT T2.age_category_code FROM Ref_User_Categories AS T1 JOIN Users AS T2 ON T1.user_category_code  =  T2.user_category_code WHERE T1.User_category_description LIKE "%Mother";

SELECT T2.age_category_code FROM Ref_User_Categories AS T1 JOIN Users AS T2 ON T1.user_category_code = T2.user_category_code WHERE T1.User_category_description LIKE `` % Mother '' ;

Question: What are the age categories for users whose description contains the string Mother?

What are the age categories for users whose description contains the string Mother ?


Question: SELECT count(*) FROM performance_score WHERE stage_presence  <  7 OR stage_presence  >  9

SELECT count ( * ) FROM performance_score WHERE stage_presence < 7 OR stage_presence > 9

select count ( * ) from performance_score where stage_presence < value or stage_presence > value

Question: How many performances have a stage presence score less than 7 or higher than 9?

How many performances have a stage presence score less than 7 or higher than 9 ?


Question: SELECT Completed_Year FROM building ORDER BY Number_of_Stories DESC

select completed_year from building order by number_of_stories desc

Question: Show the completed years of buildings in descending order of the number of stories.

Show the completed years of buildings in descending order of the number of stories .


Question: SELECT Warehouse ,  count(*) FROM boxes GROUP BY warehouse

SELECT Warehouse , count ( * ) FROM boxes GROUP BY warehouse

select warehouse , count ( * ) from boxes group by warehouse

Question: Select the warehouse codes along with the number of boxes in each warehouse.

Select the warehouse codes along with the number of boxes in each warehouse .


Question: SELECT T1.Country FROM country AS T1 JOIN driver AS T2 ON T1.Country_ID  =  T2.Country WHERE T2.Points  >  150

select t1 . country from country as t1 join driver as t2 on t1 . country_id = t2 . country where t2 . points > value

Question: Find all the countries where some drivers have points above 150.

Find all the countries where some drivers have points above 150 .


Question: SELECT T2.name ,  T2.Type_of_powertrain FROM renting_history AS T1 JOIN vehicles AS T2 ON T1.vehicles_id  =  T2.id GROUP BY T1.vehicles_id HAVING sum(T1.total_hours)  >  30

Question: Find the name and powertrain type of the cars that rented for more than 30 total hours.

Find the name and powertrain type of the cars that rented for more than 30 total hours .


Question: select distinct t1.venue ,  t1.year from paper as t1 join author_list as t2 on t1.paper_id  =  t2.paper_id join affiliation as t3 on t2.affiliation_id  =  t3.affiliation_id where t3.name = "columbia university"

Question: What are the venues and years where Columbia University had papers ?


Question: SELECT title ,  LOCATION ,  YEAR FROM paintings ORDER BY YEAR LIMIT 1

select title , location , year from paintings order by year limit value

Question: What is the name of the oldest painting and where is it located?

What is the name of the oldest painting and where is it located ?


Question: SELECT count(*) FROM Products

Question: How many products do we have?


Question: SELECT meeting_type ,  count(*) FROM Meetings GROUP BY meeting_type

SELECT meeting_type , count ( * ) FROM Meetings GROUP BY meeting_type

select meeting_type , count ( * ) from meetings group by meeting_type

Question: Show the meeting type codes and the number of meeting for each client.

Show the meeting type codes and the number of meeting for each client .


Question: SELECT pilot_name FROM pilotskills WHERE plane_name  =  'Piper Cub' INTERSECT SELECT pilot_name FROM pilotskills WHERE plane_name  =  'B-52 Bomber'

SELECT pilot_name FROM pilotskills WHERE plane_name = 'Piper Cub ' INTERSECT SELECT pilot_name FROM pilotskills WHERE plane_name = 'B-52 Bomber '

select pilot_name from pilotskills where plane_name = value intersect select pilot_name from pilotskills where plane_name = value

Question: Find pilots who own planes Piper Cub and B-52 Bomber.

Find pilots who own planes Piper Cub and B-52 Bomber .


Question: SELECT DISTINCT T2.sid ,  T3.name FROM Boats AS T1 JOIN Reserves AS T2 ON  T1.bid  =  T2.bid JOIN Sailors AS T3 ON T2.sid  =  T3.sid WHERE T1.color  =  'red' INTERSECT SELECT DISTINCT T2.sid ,  T3.name FROM Boats AS T1 JOIN Reserves AS T2 ON  T1.bid  =  T2.bid JOIN Sailors AS T3 ON T2.sid  =  T3.sid WHERE T1.color  =  "blue"

SELECT DISTINCT T2.sid , T3.name FROM Boats AS T1 JOIN Reserves AS T2 ON T1.bid = T2.bid JOIN Sailors AS T3 ON T2.sid = T3.sid WHERE T1.color = 'red ' INTERSECT SELECT DISTINCT T2.sid , T3.name FROM Boats AS T1 JOIN Reserves AS T2 ON T1.bid = T2.bid JOIN Sailors AS T3 ON T2.sid = T3.sid WHERE T1.color = `` blue ''

select distinct t2 . sid , t3 . name from boats as t1 join reserves as t2 on t1 . bid = t2 . bid join sailors as t3 on t2 . sid = t3 . sid where t1 . color = value intersect select distinct t2 . sid , t3 . name from boats as t1 join reserves as t2 on t1 . bid = t2 . bid join sailors as t3 on t2 . sid = t3 . sid where t1 . color = value

Question: Find the name and id of Sailors (sid) that reserved red and blue boat.

Find the name and id of Sailors ( sid ) that reserved red and blue boat .


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

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

select t2 . name , count ( * ) from package as t1 join client as t2 on t1 . sender = t2 . accountnumber group by t1 . sender order by count ( * ) desc limit value

Question: What is the name of the client who sent the most packages and how many were there?

What is the name of the client who sent the most packages and how many were there ?


Question: SELECT Player_name ,  College FROM player ORDER BY Rank_of_the_year DESC

select player_name , college from player order by rank_of_the_year desc

Question: What are the names and colleges of all players, ordered by rank of year descending?

What are the names and colleges of all players , ordered by rank of year descending ?


Question: SELECT POSITION FROM Employee WHERE Name  =  "Amy Wong";

SELECT POSITION FROM Employee WHERE Name = `` Amy Wong '' ;

select position from employee where name = value

Question: What position does Amy Wong have?


Question: SELECT city_name FROM City WHERE state  =  "PA"

SELECT city_name FROM City WHERE state = `` PA ''

select city_name from city where state = value

Question: What are the names of all cities in PA?

What are the names of all cities in PA ?


Question: select t2.name ,  count(*) from package as t1 join client as t2 on t1.recipient  =  t2.accountnumber group by t1.recipient order by count(*) limit 1;

select t2.name , count ( * ) from package as t1 join client as t2 on t1.recipient = t2.accountnumber group by t1.recipient order by count ( * ) limit 1 ;

select t2 . name , count ( * ) from package as t1 join client as t2 on t1 . recipient = t2 . accountnumber group by t1 . recipient order by count ( * ) limit value

Question: Who received least number of packages ? List client name and number of packages received by that client .


Question: SELECT min(product_price) ,  avg(product_price) ,  max(product_price) FROM Products

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

select min ( product_price ) , avg ( product_price ) , max ( product_price ) from products

Question: What are the minimum, average, and maximum prices across all products?

What are the minimum , average , and maximum prices across all products ?


Question: select t1.order_id ,  sum(t2.product_price) from order_items as t1 join products as t2 on t1.product_id  =  t2.product_id group by t1.order_id order by sum(t2.product_price) asc limit 1

select t1.order_id , sum ( t2.product_price ) from order_items as t1 join products as t2 on t1.product_id = t2.product_id group by t1.order_id order by sum ( t2.product_price ) asc limit 1

Question: What is the order that total cost the least , and how much is the total cost ?


Question: SELECT amount_of_loan ,  date_of_loan FROM Student_Loans WHERE student_id IN ( SELECT student_id FROM Achievements GROUP BY student_id HAVING count(*)  >=  2 )

SELECT amount_of_loan , date_of_loan FROM Student_Loans WHERE student_id IN ( SELECT student_id FROM Achievements GROUP BY student_id HAVING count ( * ) > = 2 )

select amount_of_loan , date_of_loan from student_loans where student_id in ( select student_id from achievements group by student_id having count ( * ) > = value )

Question: What are the loan amounts and loan dates of the students who have at least 2 achievements?

What are the loan amounts and loan dates of the students who have at least 2 achievements ?


Question: SELECT t1.name ,  t1.internet FROM channel AS t1 JOIN director_admin AS t2 ON t1.channel_id  =  t2.channel_id GROUP BY t1.channel_id ORDER BY count(*) DESC LIMIT 1

SELECT t1.name , t1.internet FROM channel AS t1 JOIN director_admin AS t2 ON t1.channel_id = t2.channel_id GROUP BY t1.channel_id ORDER BY count ( * ) DESC LIMIT 1

select t1 . name , t1 . internet from channel as t1 join director_admin as t2 on t1 . channel_id = t2 . channel_id group by t1 . channel_id order by count ( * ) desc limit value

Question: Find the name and internet web of the channel that is directed by the most directors.

Find the name and internet web of the channel that is directed by the most directors .


Question: SELECT name ,  age FROM author WHERE author_id NOT IN (SELECT author_id FROM book)

SELECT name , age FROM author WHERE author_id NOT IN ( SELECT author_id FROM book )

select name , age from author where author_id not in ( select author_id from book )

Question: Find the name and age of the authors who do not have any book in the record.

Find the name and age of the authors who do not have any book in the record .


Question: SELECT T2.university_name FROM Major_Ranking AS T1 JOIN University AS T2 ON T1.university_id  =  T2.university_id WHERE T1.rank  =  1 GROUP BY T2.university_name ORDER BY count(*) DESC LIMIT 1

SELECT T2.university_name FROM Major_Ranking AS T1 JOIN University AS T2 ON T1.university_id = T2.university_id WHERE T1.rank = 1 GROUP BY T2.university_name ORDER BY count ( * ) DESC LIMIT 1

select t2 . university_name from major_ranking as t1 join university as t2 on t1 . university_id = t2 . university_id where t1 . rank = value group by t2 . university_name order by count ( * ) desc limit value

Question: What is the name of the university that has most number of majors with rank 1?

What is the name of the university that has most number of majors with rank 1 ?


Question: SELECT DISTINCT sid FROM Sailors WHERE age  >  (SELECT min(age) FROM Sailors);

SELECT DISTINCT sid FROM Sailors WHERE age > ( SELECT min ( age ) FROM Sailors ) ;

select distinct sid from sailors where age > ( select min ( age ) from sailors )

Question: return the unique ids of sailors who are older than any sailors.

return the unique ids of sailors who are older than any sailors .


Question: SELECT title ,  LOCATION ,  YEAR FROM paintings WHERE height_mm  >  1000 ORDER BY title

select title , location , year from paintings where height_mm > value order by title

Question: List the year, location and title of paintings whose height is longer than 1000 ordered by title.

List the year , location and title of paintings whose height is longer than 1000 ordered by title .


Question: SELECT count(*) FROM Properties GROUP BY property_id HAVING count(*)  >= 2;

SELECT count ( * ) FROM Properties GROUP BY property_id HAVING count ( * ) > = 2 ;

select count ( * ) from properties group by property_id having count ( * ) > = value

Question: How many properties are there with at least 2 features?

How many properties are there with at least 2 features ?


Question: SELECT DISTINCT T1.product_name ,  T1.product_price ,  T1.product_description FROM Products AS T1 JOIN Order_items AS T2 ON T1.product_id  =  T2.product_id JOIN Orders AS T3 ON T2.order_id  =  T3.order_id JOIN Customers AS T4 ON T3.customer_id  =  T4.customer_id WHERE T4.gender_code  =  'Female'

Question: What are the different names, prices, and descriptions for all products bought by female customers?

What are the different names , prices , and descriptions for all products bought by female customers ?


Question: select distinct t3.document_subset_name ,  t1.document_object_id from document_subset_members as t1 join document_subset_members  as t2 on t1.related_document_object_id = t2.document_object_id join document_subsets as t3 on t2.document_subset_id =  t3.document_subset_id

Question: What are the different subsets of documents related to each document id , list the name of the document subset and id of the actual document ?


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

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

select t2 . name from shipment as t1 join planet as t2 on t1 . planet = t2 . planetid group by t1 . planet order by count ( * ) desc limit value

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

Which planet has most shipments ? List the planet name .


Question: SELECT Collection_Subset_Name FROM Collection_Subsets;

Question: List all collections' subset. List the subsets' names.

List all collections ' subset . List the subsets ' names .


Question: SELECT Name FROM region ORDER BY Name ASC

select name from region order by name asc

Question: List the names of regions in alphabetical order.

List the names of regions in alphabetical order .


Question: SELECT institution_name FROM institution WHERE institution_id NOT IN (SELECT institution_id FROM staff)

SELECT institution_name FROM institution WHERE institution_id NOT IN ( SELECT institution_id FROM staff )

select institution_name from institution where institution_id not in ( select institution_id from staff )

Question: What is the name of the institution with no staff in the records?

What is the name of the institution with no staff in the records ?


Question: SELECT Affiliation FROM institution WHERE City != "Vancouver"

SELECT Affiliation FROM institution WHERE City ! = `` Vancouver ''

select affiliation from institution where city ! = value

Question: Return the affiliations of instituions that are not in the city of Vancouver.

Return the affiliations of instituions that are not in the city of Vancouver .


Question: SELECT Name FROM player ORDER BY Earnings DESC LIMIT 1

select name from player order by earnings desc limit value

Question: What is the name of the player with the highest earnings?

What is the name of the player with the highest earnings ?


Question: SELECT T2.name FROM Orders AS T1 JOIN Client AS T2 ON T1.idClient  =  T2.idClient JOIN Books_Order AS T3 ON T3.idOrder  =  T1.idOrder GROUP BY T1.idClient ORDER BY sum(T3.amount) DESC LIMIT 1

select t2 . name from orders as t1 join client as t2 on t1 . idclient = t2 . idclient join books_order as t3 on t3 . idorder = t1 . idorder group by t1 . idclient order by sum ( t3 . amount ) desc limit value

Question: Show the client name who has the most total amount of books ordered.

Show the client name who has the most total amount of books ordered .


Question: SELECT Name FROM customer ORDER BY Level_of_Membership ASC

select name from customer order by level_of_membership asc

Question: List the names of customers in ascending order of level of membership.

List the names of customers in ascending order of level of membership .


Question: SELECT Platform_name ,  Market_district FROM platform

select platform_name , market_district from platform

Question: What are the names and market districts of all platforms?

What are the names and market districts of all platforms ?


Question: SELECT max(saleprice) ,  min(saleprice) FROM Book

SELECT max ( saleprice ) , min ( saleprice ) FROM Book

select max ( saleprice ) , min ( saleprice ) from book

Question: Give the maximum and minimum sale price of books.

Give the maximum and minimum sale price of books .


Question: SELECT count(*) FROM Shipment_Items

Question: How many items are shipped?


Question: SELECT count(*) FROM integration_platform WHERE integration_platform_details  =  "Success"

SELECT count ( * ) FROM integration_platform WHERE integration_platform_details = `` Success ''

select count ( * ) from integration_platform where integration_platform_details = value

Question: Count the number of integration platforms that have "Success" in the details.

Count the number of integration platforms that have `` Success '' in the details .


Question: SELECT country FROM country WHERE country_id NOT IN (SELECT country FROM driver)

SELECT country FROM country WHERE country_id NOT IN ( SELECT country FROM driver )

select country from country where country_id not in ( select country from driver )

Question: Which countries do not have any drivers?

Which countries do not have any drivers ?


Question: SELECT DISTINCT t1.service_details FROM services AS t1 JOIN customers_and_services AS t2 ON t1.service_id  =  t2.service_id WHERE t2.customers_and_services_details  =  "Unsatisfied"

SELECT DISTINCT t1.service_details FROM services AS t1 JOIN customers_and_services AS t2 ON t1.service_id = t2.service_id WHERE t2.customers_and_services_details = `` Unsatisfied ''

Question: Which services have been rated as "unsatisfied" in customers and services details? Give me the service_details.

Which services have been rated as `` unsatisfied '' in customers and services details ? Give me the service_details .


Question: SELECT Platform_name ,  Market_district FROM platform

select platform_name , market_district from platform

Question: Return all platform names and corresponding market districts.

Return all platform names and corresponding market districts .


Question: SELECT paintingID FROM paintings WHERE height_mm  >   (SELECT max(height_mm) FROM paintings WHERE YEAR  >  1900)

SELECT paintingID FROM paintings WHERE height_mm > ( SELECT max ( height_mm ) FROM paintings WHERE YEAR > 1900 )

select paintingid from paintings where height_mm > ( select max ( height_mm ) from paintings where year > value )

Question: List the ids of all paintings that are taller than the longest painting created after 1900.

List the ids of all paintings that are taller than the longest painting created after 1900 .


Question: SELECT DISTINCT LOCATION FROM paintings WHERE YEAR  < 1885 OR YEAR  >  1930

select distinct location from paintings where year < value or year > value

Question: What locations have works painted before 1885 or after 1930?

What locations have works painted before 1885 or after 1930 ?


Question: SELECT DISTINCT warehouse FROM boxes WHERE CONTENTS  =  'Rocks' OR CONTENTS  =  'Scissors'

SELECT DISTINCT warehouse FROM boxes WHERE CONTENTS = 'Rocks ' OR CONTENTS = 'Scissors '

select distinct warehouse from boxes where contents = value or contents = value

Question: What are the distinct warehouses that have boxes with Rocks or Scissors as contents?

What are the distinct warehouses that have boxes with Rocks or Scissors as contents ?


Question: SELECT Affiliation FROM city_channel GROUP BY Affiliation ORDER BY COUNT(*) DESC LIMIT 1

SELECT Affiliation FROM city_channel GROUP BY Affiliation ORDER BY COUNT ( * ) DESC LIMIT 1

select affiliation from city_channel group by affiliation order by count ( * ) desc limit value

Question: Please show the most common affiliation for city channels.

Please show the most common affiliation for city channels .


Question: SELECT avg(Salary) FROM Employee WHERE POSITION  =  "Intern";

SELECT avg ( Salary ) FROM Employee WHERE POSITION = `` Intern '' ;

select avg ( salary ) from employee where position = value

Question: What is the average salary of all intern jobs?

What is the average salary of all intern jobs ?


Question: SELECT T3.name FROM Book AS T1 JOIN Author_book AS T2 ON T1.isbn  =  T2.isbn JOIN Author AS T3 ON T2.Author  =  T3.idAuthor WHERE T1.title  =  "Pride and Prejudice"

SELECT T3.name FROM Book AS T1 JOIN Author_book AS T2 ON T1.isbn = T2.isbn JOIN Author AS T3 ON T2.Author = T3.idAuthor WHERE T1.title = `` Pride and Prejudice ''

select t3 . name from book as t1 join author_book as t2 on t1 . isbn = t2 . isbn join author as t3 on t2 . author = t3 . idauthor where t1 . title = value

Question: Give the name of the author who wrote the book titled Pride and Prejudice.

Give the name of the author who wrote the book titled Pride and Prejudice .


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

select t4 . title from orders as t1 join books_order as t2 on t1 . idorder = t2 . idorder join client as t3 on t1 . idclient = t3 . idclient join book as t4 on t2 . isbn = t4 . isbn where t3 . name = value except select t4 . title from orders as t1 join books_order as t2 on t1 . idorder = t2 . idorder join client as t3 on t1 . idclient = t3 . idclient join book as t4 on t2 . isbn = t4 . isbn where t3 . name = value

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

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


Question: SELECT count(*) ,  venue ,  YEAR FROM Paper GROUP BY venue ,  YEAR

SELECT count ( * ) , venue , YEAR FROM Paper GROUP BY venue , YEAR

select count ( * ) , venue , year from paper group by venue , year

Question: Find the number of papers published in different conferences each year.

Find the number of papers published in different conferences each year .


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

SELECT name FROM languages WHERE name LIKE `` % ish % ''

select name from languages where name like value

Question: Return the names of langauges that contain the substring "ish".

Return the names of langauges that contain the substring `` ish '' .


Question: SELECT DISTINCT T1.Document_Object_ID FROM Document_Subset_Members AS T1 JOIN Document_Subsets AS T2 ON T1.Document_Subset_ID =  T2.Document_Subset_ID JOIN Documents_in_Collections AS T3 ON T1.Document_Object_ID  =  T3.Document_Object_ID JOIN Collections AS T4 ON T3.Collection_ID  =  T4.Collection_ID WHERE T2.Document_Subset_Name = "Best for 2000" AND T4.Collection_Name = "Best";

Question: What are the different document object ids in the subset named 'Best for 2000' and in the collection named 'Best'?

What are the different document object ids in the subset named 'Best for 2000 ' and in the collection named 'Best ' ?


Question: SELECT title FROM movies WHERE rating  =  'G' OR rating  =  'PG'

SELECT title FROM movies WHERE rating = 'G ' OR rating = 'PG '

select title from movies where rating = value or rating = value

Question: Find the name of the cinemas that are playing movies with either rating ‘G’ or rating ‘PG’.

Find the name of the cinemas that are playing movies with either rating ‘G’ or rating ‘PG’ .


Question: SELECT Document_Object_ID FROM Document_Objects;

Question: List document id of all documents.


Question: SELECT Date FROM Shipment;

Question: List the dates of all shipments.


Question: SELECT Manufacturer FROM club GROUP BY Manufacturer HAVING COUNT(*)  >  1

SELECT Manufacturer FROM club GROUP BY Manufacturer HAVING COUNT ( * ) > 1

select manufacturer from club group by manufacturer having count ( * ) > value

Question: List the manufacturers that are associated with more than one club.

List the manufacturers that are associated with more than one club .


Question: SELECT T1.order_id ,  T1.date_order_placed FROM Orders AS T1 JOIN Order_items AS T2 ON T1.order_id  =  T2.order_id GROUP BY T1.order_id HAVING count(*)  >=  2

SELECT T1.order_id , T1.date_order_placed FROM Orders AS T1 JOIN Order_items AS T2 ON T1.order_id = T2.order_id GROUP BY T1.order_id HAVING count ( * ) > = 2

Question: What are the ids and dates of the orders with at least two products?

What are the ids and dates of the orders with at least two products ?


Question: SELECT process_id ,  count(*) FROM Documents_processes GROUP BY process_id

SELECT process_id , count ( * ) FROM Documents_processes GROUP BY process_id

select process_id , count ( * ) from documents_processes group by process_id

Question: Show all process ids and the number of documents in each process.

Show all process ids and the number of documents in each process .


Question: SELECT institution_name ,  LOCATION ,  founded FROM institution

select institution_name , location , founded from institution

Question: What are the names, locations, and founding years for all institutions?

What are the names , locations , and founding years for all institutions ?


Question: SELECT Nationality FROM member WHERE Age  >  22 INTERSECT SELECT Nationality FROM member WHERE Age  <  19

select nationality from member where age > value intersect select nationality from member where age < value

Question: Show the nations that have both members older than 22 and members younger than 19.

Show the nations that have both members older than 22 and members younger than 19 .


Question: SELECT venue FROM paper GROUP BY venue ORDER BY count(*) LIMIT 1

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

select venue from paper group by venue order by count ( * ) limit value

Question: Which venue has the fewest publications?

Which venue has the fewest publications ?


Question: SELECT T1.food ,  count(DISTINCT T3.CustomerId) FROM goods AS T1 JOIN items AS T2 ON T1.Id  =  T2.Item JOIN receipts AS T3 ON T2.Receipt  =  T3.ReceiptNumber GROUP BY T1.food

SELECT T1.food , count ( DISTINCT T3.CustomerId ) FROM goods AS T1 JOIN items AS T2 ON T1.Id = T2.Item JOIN receipts AS T3 ON T2.Receipt = T3.ReceiptNumber GROUP BY T1.food

select t1 . food , count ( distinct t3 . customerid ) from goods as t1 join items as t2 on t1 . id = t2 . item join receipts as t3 on t2 . receipt = t3 . receiptnumber group by t1 . food

Question: For each type of food, tell me how many customers have ever bought it.

For each type of food , tell me how many customers have ever bought it .


Question: SELECT Country FROM player WHERE Earnings  >  1400000 INTERSECT SELECT Country FROM player WHERE Earnings  <  1100000

select country from player where earnings > value intersect select country from player where earnings < value

Question: Show the country of players with earnings more than 1400000 and players with earnings less than 1100000.

Show the country of players with earnings more than 1400000 and players with earnings less than 1100000 .


Question: SELECT T1.University_Name ,  T2.Citation_point FROM University AS T1 JOIN Overall_ranking AS T2 ON T1.university_id  =  T2.university_id ORDER BY T2.Reputation_point DESC LIMIT 3

Question: What is the name and citation point of the unversities with the top 3 reputation points?

What is the name and citation point of the unversities with the top 3 reputation points ?


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

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

select max ( number_of_stories ) from building where completed_year ! = value

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

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


Question: SELECT T1.Driver_Name ,  T1.Age FROM driver AS T1 JOIN race AS T2 ON T1.Driver_ID  =  T2.Driver_ID GROUP BY T1.Driver_ID HAVING COUNT(*)  >=  2

SELECT T1.Driver_Name , T1.Age FROM driver AS T1 JOIN race AS T2 ON T1.Driver_ID = T2.Driver_ID GROUP BY T1.Driver_ID HAVING COUNT ( * ) > = 2

select t1 . driver_name , t1 . age from driver as t1 join race as t2 on t1 . driver_id = t2 . driver_id group by t1 . driver_id having count ( * ) > = value

Question: What are the names and ages of drivers who raced in two or more races?

What are the names and ages of drivers who raced in two or more races ?


Question: SELECT T1.title ,  T1.paper_id FROM Paper AS T1 JOIN Author_list AS T2 ON T1.paper_id  =  T2.paper_id JOIN Author AS T3 ON T2.author_id  =  T3.author_id WHERE T3.name LIKE "%Mckeown%" EXCEPT SELECT T1.title ,  T1.paper_id FROM Paper AS T1 JOIN Author_list AS T2 ON T1.paper_id  =  T2.paper_id JOIN Author AS T3 ON T2.author_id  =  T3.author_id WHERE T3.name LIKE "%Rambow%"

Question: What are the titles and paper ids which have Mckeown as an author, but not Rambow?

What are the titles and paper ids which have Mckeown as an author , but not Rambow ?


Question: SELECT T1.title ,  T1.paper_id FROM Paper AS T1 JOIN Author_list AS T2 ON T1.paper_id  =  T2.paper_id JOIN Author AS T3 ON T2.author_id  =  T3.author_id WHERE T3.name LIKE "%Mckeown ,  Kathleen%" INTERSECT SELECT T1.title ,  T1.paper_id FROM Paper AS T1 JOIN Author_list AS T2 ON T1.paper_id  =  T2.paper_id JOIN Author AS T3 ON T2.author_id  =  T3.author_id WHERE T3.name LIKE "%Rambow ,  Owen%"

SELECT T1.title , T1.paper_id FROM Paper AS T1 JOIN Author_list AS T2 ON T1.paper_id = T2.paper_id JOIN Author AS T3 ON T2.author_id = T3.author_id WHERE T3.name LIKE `` % Mckeown , Kathleen % '' INTERSECT SELECT T1.title , T1.paper_id FROM Paper AS T1 JOIN Author_list AS T2 ON T1.paper_id = T2.paper_id JOIN Author AS T3 ON T2.author_id = T3.author_id WHERE T3.name LIKE `` % Rambow , Owen % ''

Question: Find all papers with titles and paper IDs co-authored by Mckeown, Kathleen and Rambow, Owen.

Find all papers with titles and paper IDs co-authored by Mckeown , Kathleen and Rambow , Owen .


Question: SELECT T1.title FROM movies AS T1 JOIN movietheaters AS T2 ON T1.code  =  T2.movie WHERE T2.name  =  'Odeon' INTERSECT SELECT T1.title FROM movies AS T1 JOIN movietheaters AS T2 ON T1.code  =  T2.movie WHERE T2.name  =  'Imperial'

SELECT T1.title FROM movies AS T1 JOIN movietheaters AS T2 ON T1.code = T2.movie WHERE T2.name = 'Odeon ' INTERSECT SELECT T1.title FROM movies AS T1 JOIN movietheaters AS T2 ON T1.code = T2.movie WHERE T2.name = 'Imperial '

select t1 . title from movies as t1 join movietheaters as t2 on t1 . code = t2 . movie where t2 . name = value intersect select t1 . title from movies as t1 join movietheaters as t2 on t1 . code = t2 . movie where t2 . name = value

Question: Find the name of the movie that is on in both Odeon and Imperial theaters.

Find the name of the movie that is on in both Odeon and Imperial theaters .


Question: SELECT name ,  model_year FROM vehicles WHERE city_fuel_economy_rate  <=  highway_fuel_economy_rate

SELECT name , model_year FROM vehicles WHERE city_fuel_economy_rate < = highway_fuel_economy_rate

select name , model_year from vehicles where city_fuel_economy_rate < = highway_fuel_economy_rate

Question: Show name and model year for vehicles with city fuel economy rate less than or equal to highway fuel economy rate.

Show name and model year for vehicles with city fuel economy rate less than or equal to highway fuel economy rate .


Question: SELECT T2.agency_details FROM Clients AS T1 JOIN Agencies AS T2 ON T1.agency_id  =  T2.agency_id WHERE T1.client_details  =  'Mac'

SELECT T2.agency_details FROM Clients AS T1 JOIN Agencies AS T2 ON T1.agency_id = T2.agency_id WHERE T1.client_details = 'Mac '

Question: What are the agency details for clients with the detail Mac?

What are the agency details for clients with the detail Mac ?


Question: SELECT count(*) FROM club

Question: Count the number of clubs.


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

select t1 . name , t2 . title , t3 . name from author as t1 join book as t2 on t1 . author_id = t2 . author_id join press as t3 on t2 . press_id = t3 . press_id order by t2 . sale_amount desc limit value

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

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


Question: SELECT avg(purchaseprice) ,  avg(saleprice) FROM Book

SELECT avg ( purchaseprice ) , avg ( saleprice ) FROM Book

select avg ( purchaseprice ) , avg ( saleprice ) from book

Question: Give the average purchase price and average sale price for books.

Give the average purchase price and average sale price for books .


Question: SELECT count(*) FROM author WHERE age  <  30

SELECT count ( * ) FROM author WHERE age < 30

select count ( * ) from author where age < value

Question: how many authors are under age 30?


Question: SELECT DISTINCT name FROM Sailors WHERE age  >  (SELECT min(age) FROM Sailors WHERE rating  >  7);

SELECT DISTINCT name FROM Sailors WHERE age > ( SELECT min ( age ) FROM Sailors WHERE rating > 7 ) ;

select distinct name from sailors where age > ( select min ( age ) from sailors where rating > value )

Question: What are the different names of sailors who are older than some other sailor with a rating larger than 7?

What are the different names of sailors who are older than some other sailor with a rating larger than 7 ?


Question: SELECT DISTINCT T1.Developers FROM game AS T1 JOIN game_player AS T2 ON T1.Game_ID  =  T2.Game_ID JOIN player AS T3 ON T2.Player_ID  =  T3.Player_ID WHERE T3.College  =  "Auburn"

Question: Show the distinct developer of games played by players that go to college "Auburn".

Show the distinct developer of games played by players that go to college `` Auburn '' .


Question: SELECT T2.Fname ,  T2.Lname FROM City AS T1 JOIN Student AS T2 ON T1.city_code  =  T2.city_code WHERE T1.state  =  "MD"

SELECT T2.Fname , T2.Lname FROM City AS T1 JOIN Student AS T2 ON T1.city_code = T2.city_code WHERE T1.state = `` MD ''

select t2 . fname , t2 . lname from city as t1 join student as t2 on t1 . city_code = t2 . city_code where t1 . state = value

Question: Show the first name and the last name for students living in state MD.

Show the first name and the last name for students living in state MD .


Question: SELECT meeting_id ,  count(*) FROM Staff_in_meetings GROUP BY meeting_id

SELECT meeting_id , count ( * ) FROM Staff_in_meetings GROUP BY meeting_id

select meeting_id , count ( * ) from staff_in_meetings group by meeting_id

Question: Show the meeting ids and the number of staff in each meeting.

Show the meeting ids and the number of staff in each meeting .


Question: SELECT T1.idOrder ,  T2.name FROM Orders AS T1 JOIN Client AS T2 ON T1.idClient  =  T2.idClient

select t1 . idorder , t2 . name from orders as t1 join client as t2 on t1 . idclient = t2 . idclient

Question: Show all order ids and their client names.

Show all order ids and their client names .


Question: SELECT count(*) FROM City AS T1 JOIN Student AS T2 ON T1.city_code  =  T2.city_code WHERE T1.country  =  "CHINA"

SELECT count ( * ) FROM City AS T1 JOIN Student AS T2 ON T1.city_code = T2.city_code WHERE T1.country = `` CHINA ''

select count ( * ) from city as t1 join student as t2 on t1 . city_code = t2 . city_code where t1 . country = value

Question: How many students live in China?


Question: SELECT count(DISTINCT T1.driver_id) FROM vehicle_driver AS T1 JOIN vehicle AS T2 ON T1.vehicle_id  =  T2.vehicle_id WHERE T2.build_year  =  2012

Question: How many drivers have driven vehicles built in 2012?

How many drivers have driven vehicles built in 2012 ?


Question: SELECT T1.PackageNumber ,  max(T1.Weight) FROM PACKAGE AS T1 JOIN Client AS T2 ON T1.Sender  =  T2.AccountNumber WHERE T2.Name LIKE "John";

SELECT T1.PackageNumber , max ( T1.Weight ) FROM PACKAGE AS T1 JOIN Client AS T2 ON T1.Sender = T2.AccountNumber WHERE T2.Name LIKE `` John '' ;

select t1 . packagenumber , max ( t1 . weight ) from package as t1 join client as t2 on t1 . sender = t2 . accountnumber where t2 . name like value

Question: What is the heaviest package sent by the clients which 'John' is part of their name? List package number and weight.

What is the heaviest package sent by the clients which 'John ' is part of their name ? List package number and weight .


Question: SELECT count(DISTINCT staff_id) FROM Staff_in_meetings

SELECT count ( DISTINCT staff_id ) FROM Staff_in_meetings

select count ( distinct staff_id ) from staff_in_meetings

Question: Return the number of distinct staff who have attended a meeting?

Return the number of distinct staff who have attended a meeting ?


Question: SELECT sum(enrollment) FROM University AS T1 JOIN Overall_ranking AS T2 ON T1.university_id  =  T2.university_id WHERE T2.rank  >=  5

SELECT sum ( enrollment ) FROM University AS T1 JOIN Overall_ranking AS T2 ON T1.university_id = T2.university_id WHERE T2.rank > = 5

select sum ( enrollment ) from university as t1 join overall_ranking as t2 on t1 . university_id = t2 . university_id where t2 . rank > = value

Question: What is the total number of students enrolled in an university with a rank of 5 or below?

What is the total number of students enrolled in an university with a rank of 5 or below ?


Question: SELECT avg(points) ,  avg(age) FROM spokesman WHERE rank_position  =  1

SELECT avg ( points ) , avg ( age ) FROM spokesman WHERE rank_position = 1

select avg ( points ) , avg ( age ) from spokesman where rank_position = value

Question: Find the average points and average ages of all spokesmen whose rank position is 1.

Find the average points and average ages of all spokesmen whose rank position is 1 .


Question: SELECT T2.university_name ,  T2.city ,  T2.state FROM Major_Ranking AS T1 JOIN University AS T2 JOIN Major AS T3 ON T1.university_id  =  T2.university_id AND T1.major_id  =  T3.major_id WHERE T1.rank  =  1 AND T3.major_name  =  'Accounting'

Question: What is the name, city, state of the university with a rank 1 on Accounting major?

What is the name , city , state of the university with a rank 1 on Accounting major ?


Question: SELECT t1.manager ,  t1.car_owner FROM team AS t1 JOIN team_driver AS t2 ON t1.team_id  =  t2.team_id GROUP BY t2.team_id HAVING count(*)  >=  2

SELECT t1.manager , t1.car_owner FROM team AS t1 JOIN team_driver AS t2 ON t1.team_id = t2.team_id GROUP BY t2.team_id HAVING count ( * ) > = 2

select t1 . manager , t1 . car_owner from team as t1 join team_driver as t2 on t1 . team_id = t2 . team_id group by t2 . team_id having count ( * ) > = value

Question: Find the team with two or more drivers and return the the manager and car owner of the team.

Find the team with two or more drivers and return the the manager and car owner of the team .


Question: SELECT T1.ShipmentID FROM Shipment AS T1 JOIN Planet AS T2 ON T1.Planet = T2.PlanetID JOIN Employee AS T3 ON T3.EmployeeID = T1.Manager WHERE T2.Name = "Mars" AND T3.Name = "Turanga Leela";

SELECT T1.ShipmentID FROM Shipment AS T1 JOIN Planet AS T2 ON T1.Planet = T2.PlanetID JOIN Employee AS T3 ON T3.EmployeeID = T1.Manager WHERE T2.Name = `` Mars '' AND T3.Name = `` Turanga Leela '' ;

select t1 . shipmentid from shipment as t1 join planet as t2 on t1 . planet = t2 . planetid join employee as t3 on t3 . employeeid = t1 . manager where t2 . name = value and t3 . name = value

Question: List all shipment ids for the planet Mars and under the management of Turanga Leela.

List all shipment ids for the planet Mars and under the management of Turanga Leela .


Question: SELECT bid ,  count(*) FROM Reserves GROUP BY bid HAVING bid  >  50

SELECT bid , count ( * ) FROM Reserves GROUP BY bid HAVING bid > 50

select bid , count ( * ) from reserves group by bid having bid > value

Question: Find the number of reservations for each boat with id greater than 50.

Find the number of reservations for each boat with id greater than 50 .


Question: SELECT T2.Collection_Subset_ID ,  T1.Collection_Subset_Name ,  count(*) FROM Collection_Subsets AS T1 JOIN Collection_Subset_Members AS T2 ON T1.Collection_Subset_ID =  T2.Collection_Subset_ID GROUP BY T2.Collection_Subset_ID;

Question: What are the collection subset ids, names, and number of collections for each subset?

What are the collection subset ids , names , and number of collections for each subset ?


Question: SELECT first_name ,  middle_name ,  last_name ,  login_name FROM Users WHERE is_seller  =  1;

Question: What are the first, middle, last, and login names for all users who are sellers?

What are the first , middle , last , and login names for all users who are sellers ?


Question: SELECT T1.code ,  T2.location FROM boxes AS T1 JOIN warehouses AS T2 ON T1.Warehouse  =  T2.Code

select t1 . code , t2 . location from boxes as t1 join warehouses as t2 on t1 . warehouse = t2 . code

Question: What are the codes of all boxes, as well as the locations of the warehouses they are in?

What are the codes of all boxes , as well as the locations of the warehouses they are in ?


Question: SELECT T1.client_details ,  T2.agency_details FROM Clients AS T1 JOIN Agencies AS T2 ON T1.agency_id  =  T2.agency_id

Question: Show details for all clients and the details of their corresponding agents.

Show details for all clients and the details of their corresponding agents .


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

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

select min ( price ) , max ( price ) , food from goods group by food order by food

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

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


Question: SELECT avg(T1.product_price) FROM Products AS T1 JOIN Order_items AS T2 ON T1.product_id  =  T2.product_id

Question: What is the average price of the products being ordered?

What is the average price of the products being ordered ?


Question: SELECT DISTINCT model FROM headphone ORDER BY model

select distinct model from headphone order by model

Question: List all different headphone models in the alphabetical order.

List all different headphone models in the alphabetical order .


Question: SELECT count(DISTINCT Province) FROM institution

SELECT count ( DISTINCT Province ) FROM institution

select count ( distinct province ) from institution

Question: How many distinct provinces are the institutions in?

How many distinct provinces are the institutions in ?


Question: SELECT T2.name ,  COUNT(*) FROM official_languages AS T1 JOIN languages AS T2 ON T1.language_id  =  T2.id GROUP BY T2.name

SELECT T2.name , COUNT ( * ) FROM official_languages AS T1 JOIN languages AS T2 ON T1.language_id = T2.id GROUP BY T2.name

select t2 . name , count ( * ) from official_languages as t1 join languages as t2 on t1 . language_id = t2 . id group by t2 . name

Question: Show the official languages and the number of countries speaking each language.

Show the official languages and the number of countries speaking each language .


Question: SELECT count(plane_name) FROM pilotskills WHERE age  >  40

SELECT count ( plane_name ) FROM pilotskills WHERE age > 40

select count ( plane_name ) from pilotskills where age > value

Question: Count the number of planes flown by pilots older than 40.

Count the number of planes flown by pilots older than 40 .


Question: SELECT author_name FROM Documents WHERE document_id  =  4

select author_name from documents where document_id = value

Question: Who is the author of the document with id 4?

Who is the author of the document with id 4 ?


Question: SELECT payment_method_code ,  customer_number FROM Customers WHERE customer_name  =  "Jeromy"

SELECT payment_method_code , customer_number FROM Customers WHERE customer_name = `` Jeromy ''

select payment_method_code , customer_number from customers where customer_name = value

Question: What is the payment method and customer number for customer named Jeromy?

What is the payment method and customer number for customer named Jeromy ?


Question: SELECT T3.name FROM Paper AS T1 JOIN Author_list AS T2 ON T1.paper_id  =  T2.paper_id JOIN Author AS T3 ON T3.author_id  =  T2.author_id WHERE T1.year  =  2009 GROUP BY T2.author_id ORDER BY count(*) DESC LIMIT 1

select t3 . name from paper as t1 join author_list as t2 on t1 . paper_id = t2 . paper_id join author as t3 on t3 . author_id = t2 . author_id where t1 . year = value group by t2 . author_id order by count ( * ) desc limit value

Question: What is the name of the author with the most papers in 2009?

What is the name of the author with the most papers in 2009 ?


Question: SELECT product_type_code FROM Products GROUP BY product_type_code HAVING count(*)  >=  2

SELECT product_type_code FROM Products GROUP BY product_type_code HAVING count ( * ) > = 2

select product_type_code from products group by product_type_code having count ( * ) > = value

Question: Give the product type codes of product types that have two or more products.

Give the product type codes of product types that have two or more products .


Question: SELECT team_name FROM University WHERE enrollment  >  (SELECT avg(enrollment) FROM University)

SELECT team_name FROM University WHERE enrollment > ( SELECT avg ( enrollment ) FROM University )

select team_name from university where enrollment > ( select avg ( enrollment ) from university )

Question: List team name for all universities with enrollments above the average.

List team name for all universities with enrollments above the average .


Question: SELECT T1.Driver_Name FROM driver AS T1 JOIN race AS T2 ON T1.Driver_ID  =  T2.Driver_ID WHERE Pole_Position  =  "Carl Skerlong" INTERSECT SELECT T1.Driver_Name FROM driver AS T1 JOIN race AS T2 ON T1.Driver_ID  =  T2.Driver_ID WHERE Pole_Position  =  "James Hinchcliffe"

SELECT T1.Driver_Name FROM driver AS T1 JOIN race AS T2 ON T1.Driver_ID = T2.Driver_ID WHERE Pole_Position = `` Carl Skerlong '' INTERSECT SELECT T1.Driver_Name FROM driver AS T1 JOIN race AS T2 ON T1.Driver_ID = T2.Driver_ID WHERE Pole_Position = `` James Hinchcliffe ''

Question: Find the names of drivers who were in both "James Hinchcliffe" and "Carl Skerlong" pole positions before.

Find the names of drivers who were in both `` James Hinchcliffe '' and `` Carl Skerlong '' pole positions before .


Question: SELECT T1.PackageNumber FROM PACKAGE AS T1 JOIN Client AS T2 ON T1.Recipient  =  T2.AccountNumber WHERE T2.Name = "Leo Wong";

SELECT T1.PackageNumber FROM PACKAGE AS T1 JOIN Client AS T2 ON T1.Recipient = T2.AccountNumber WHERE T2.Name = `` Leo Wong '' ;

select t1 . packagenumber from package as t1 join client as t2 on t1 . recipient = t2 . accountnumber where t2 . name = value

Question: What are all of the package numbers received by Leo Wong?

What are all of the package numbers received by Leo Wong ?


Question: SELECT count(*) FROM Products

Question: Count the number of products.


Question: SELECT order_status_code ,  date_order_placed FROM Orders

select order_status_code , date_order_placed from orders

Question: What are all the order status and all the dates of orders?

What are all the order status and all the dates of orders ?


Question: SELECT T1.customer_first_name ,  T1.customer_middle_initial ,  T1.customer_last_name ,  T2.Payment_method_code FROM Customers AS T1 JOIN Customer_Payment_Methods AS T2 ON T1.customer_id  =  T2.customer_id

Question: What are the first names, middle initials, last names, and payment methods of all customers?

What are the first names , middle initials , last names , and payment methods of all customers ?


Question: SELECT DISTINCT T2.sid ,  T3.name FROM Boats AS T1 JOIN Reserves AS T2 ON  T1.bid  =  T2.bid JOIN Sailors AS T3 ON T2.sid  =  T3.sid WHERE T1.color  =  'red' INTERSECT SELECT DISTINCT T2.sid ,  T3.name FROM Boats AS T1 JOIN Reserves AS T2 ON  T1.bid  =  T2.bid JOIN Sailors AS T3 ON T2.sid  =  T3.sid WHERE T1.color  =  "blue"

SELECT DISTINCT T2.sid , T3.name FROM Boats AS T1 JOIN Reserves AS T2 ON T1.bid = T2.bid JOIN Sailors AS T3 ON T2.sid = T3.sid WHERE T1.color = 'red ' INTERSECT SELECT DISTINCT T2.sid , T3.name FROM Boats AS T1 JOIN Reserves AS T2 ON T1.bid = T2.bid JOIN Sailors AS T3 ON T2.sid = T3.sid WHERE T1.color = `` blue ''

select distinct t2 . sid , t3 . name from boats as t1 join reserves as t2 on t1 . bid = t2 . bid join sailors as t3 on t2 . sid = t3 . sid where t1 . color = value intersect select distinct t2 . sid , t3 . name from boats as t1 join reserves as t2 on t1 . bid = t2 . bid join sailors as t3 on t2 . sid = t3 . sid where t1 . color = value

Question: What are the names and ids of sailors who reserved red and blue boats?

What are the names and ids of sailors who reserved red and blue boats ?


Question: SELECT Collection_Name FROM Collections EXCEPT SELECT T2.Collection_Name FROM Collections AS T1 JOIN Collections AS T2 ON T1.Parent_Collection_ID = T2.Collection_ID;

SELECT Collection_Name FROM Collections EXCEPT SELECT T2.Collection_Name FROM Collections AS T1 JOIN Collections AS T2 ON T1.Parent_Collection_ID = T2.Collection_ID ;

Question: What are the names of the collections that are not the parent of the other collections?

What are the names of the collections that are not the parent of the other collections ?


Question: SELECT T1.client_id ,  T1.client_details FROM Clients AS T1 JOIN meetings AS T2 ON T1.client_id  =  T2.client_id UNION SELECT T1.client_id ,  T1.client_details FROM Clients AS T1 JOIN invoices AS T2 ON T1.client_id  =  T2.client_id

Question: Return the ids and details of clients who have attended a meeting or had an invoice.

Return the ids and details of clients who have attended a meeting or had an invoice .


Question: select distinct t1.service_details from services as t1 join customer_interactions as t2 on t1.service_id  =  t2.service_id join channels as t3 on t2.channel_id  =  t3.channel_id where t3.channel_details  =  "15 ij"

Question: Find details of all the services that have interacted with `` 15 ij '' for the the channel details.


Question: SELECT T1.achievement_details ,  T2.achievement_type_description FROM Achievements AS T1 JOIN Ref_Achievement_Type AS T2 ON T1.achievement_type_code  =  T2.achievement_type_code

Question: How are all the achievements described? List the achievement detail and the type description.

How are all the achievements described ? List the achievement detail and the type description .


Question: select customer_details from customers where customer_id not in (select customer_id from customers_and_services)

select customer_details from customers where customer_id not in ( select customer_id from customers_and_services )

Question: Which customers never used any services ? Give me the customer details .


Question: SELECT ReceiptNumber ,  date FROM receipts WHERE date  =  (SELECT date FROM receipts ORDER BY date DESC LIMIT 1)

SELECT ReceiptNumber , date FROM receipts WHERE date = ( SELECT date FROM receipts ORDER BY date DESC LIMIT 1 )

select receiptnumber , date from receipts where date = ( select date from receipts order by date desc limit value )

Question: What is the receipt number with the latest date, and what is that date?

What is the receipt number with the latest date , and what is that date ?


Question: SELECT Collection_Subset_Name FROM Collection_Subsets;

Question: What are the collection susbset names?


Question: SELECT id FROM goods WHERE food  =  "Cake" AND price  >=  (SELECT avg(price) FROM goods WHERE food  =  "Tart")

SELECT id FROM goods WHERE food = `` Cake '' AND price > = ( SELECT avg ( price ) FROM goods WHERE food = `` Tart '' )

select id from goods where food = value and price > = ( select avg ( price ) from goods where food = value )

Question: What are the ids of cakes that are at least as expensive as the average Tart?

What are the ids of cakes that are at least as expensive as the average Tart ?


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

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

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


Question: select count(*) from artists as t1 join paintings as t2 on t1.artistid  =  t2.painterid group by t2.painterid order by t1.deathyear - t1.birthyear desc limit 1

select count ( * ) from artists as t1 join paintings as t2 on t1.artistid = t2.painterid group by t2.painterid order by t1.deathyear - t1.birthyear desc limit 1

select count ( * ) from artists as t1 join paintings as t2 on t1 . artistid = t2 . painterid group by t2 . painterid order by t1 . deathyear - t1 . birthyear desc limit value

Question: How many paintings did the artist with the longest life make ?


Question: SELECT t1.name ,  sum(t2.quantity) FROM store AS t1 JOIN stock AS t2 ON t1.store_id  =  t2.store_id GROUP BY t2.store_id ORDER BY sum(t2.quantity) DESC LIMIT 1

SELECT t1.name , sum ( t2.quantity ) FROM store AS t1 JOIN stock AS t2 ON t1.store_id = t2.store_id GROUP BY t2.store_id ORDER BY sum ( t2.quantity ) DESC LIMIT 1

select t1 . name , sum ( t2 . quantity ) from store as t1 join stock as t2 on t1 . store_id = t2 . store_id group by t2 . store_id order by sum ( t2 . quantity ) desc limit value

Question: Which store has the headphones in stock? Give me the store name and the total quantity.

Which store has the headphones in stock ? Give me the store name and the total quantity .


Question: SELECT invoice_id ,  invoice_status FROM Invoices EXCEPT SELECT T1.invoice_id ,  T1.invoice_status FROM Invoices AS T1 JOIN Payments AS T2 ON T1.invoice_id  =  T2.invoice_id

Question: What are the invoice ids and statuses for invoices without a payment?

What are the invoice ids and statuses for invoices without a payment ?


Question: SELECT avg(product_price) FROM Products WHERE product_type_code  =  "Clothes"

SELECT avg ( product_price ) FROM Products WHERE product_type_code = `` Clothes ''

select avg ( product_price ) from products where product_type_code = value

Question: Return the average price of Clothes.


Question: SELECT count(*) ,  T2.event_type_code ,  T3.event_type_description FROM Students AS T1 JOIN Student_Events AS T2 ON T1.student_id  =  T2.student_id JOIN Ref_Event_Types AS T3 ON T2.event_type_code  =  T3.event_type_code GROUP BY T2.event_type_code ORDER BY count(*) DESC LIMIT 1

SELECT count ( * ) , T2.event_type_code , T3.event_type_description FROM Students AS T1 JOIN Student_Events AS T2 ON T1.student_id = T2.student_id JOIN Ref_Event_Types AS T3 ON T2.event_type_code = T3.event_type_code GROUP BY T2.event_type_code ORDER BY count ( * ) DESC LIMIT 1

Question: How many students have joined in the most common type of event? List the number, the event type and description.

How many students have joined in the most common type of event ? List the number , the event type and description .


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

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

select order_status_code from customer_orders group by order_status_code order by count ( * ) desc limit value

Question: Give the order status code that is most frequent across customer orders.

Give the order status code that is most frequent across customer orders .


Question: SELECT client_id ,  client_details FROM Clients WHERE sic_code  =  "Bad";

SELECT client_id , client_details FROM Clients WHERE sic_code = `` Bad '' ;

select client_id , client_details from clients where sic_code = value

Question: What are the client ideas and details for clients with the sic code Bad?

What are the client ideas and details for clients with the sic code Bad ?


Question: SELECT StuID FROM Student EXCEPT SELECT StuID FROM City AS T1 JOIN Student AS T2 ON T1.city_code  =  T2.city_code WHERE country  =  "USA"

SELECT StuID FROM Student EXCEPT SELECT StuID FROM City AS T1 JOIN Student AS T2 ON T1.city_code = T2.city_code WHERE country = `` USA ''

select stuid from student except select stuid from city as t1 join student as t2 on t1 . city_code = t2 . city_code where country = value

Question: What the the student ids for students not living in the USA?

What the the student ids for students not living in the USA ?


Question: SELECT T1.name FROM Sailors AS T1 JOIN Reserves AS T2 ON T1.sid  =  T2.sid JOIN Boats AS T3 ON T3.bid  =  T2.bid WHERE T3.name  =  'Melon'

SELECT T1.name FROM Sailors AS T1 JOIN Reserves AS T2 ON T1.sid = T2.sid JOIN Boats AS T3 ON T3.bid = T2.bid WHERE T3.name = 'Melon '

select t1 . name from sailors as t1 join reserves as t2 on t1 . sid = t2 . sid join boats as t3 on t3 . bid = t2 . bid where t3 . name = value

Question: Find the names of sailors who reserved boat with the name Melon.

Find the names of sailors who reserved boat with the name Melon .


Question: SELECT name FROM store ORDER BY date_opened

select name from store order by date_opened

Question: Sort all store names by store open date.

Sort all store names by store open date .


Question: SELECT DISTINCT T1.item FROM items AS T1 JOIN goods AS T2 ON T1.item  =  T2.id WHERE T2.flavor  =  "Chocolate" GROUP BY item HAVING count(*)  <=  10

SELECT DISTINCT T1.item FROM items AS T1 JOIN goods AS T2 ON T1.item = T2.id WHERE T2.flavor = `` Chocolate '' GROUP BY item HAVING count ( * ) < = 10

select distinct t1 . item from items as t1 join goods as t2 on t1 . item = t2 . id where t2 . flavor = value group by item having count ( * ) < = value

Question: Find all the items that have chocolate flavor but were not bought more than 10 times.

Find all the items that have chocolate flavor but were not bought more than 10 times .


Question: SELECT T1.artistID FROM artists AS T1 JOIN paintings AS T2 ON T1.artistID  =  T2.painterID WHERE T2.year  <  1900 GROUP BY T1.artistID ORDER BY count(*) DESC LIMIT 1

SELECT T1.artistID FROM artists AS T1 JOIN paintings AS T2 ON T1.artistID = T2.painterID WHERE T2.year < 1900 GROUP BY T1.artistID ORDER BY count ( * ) DESC LIMIT 1

select t1 . artistid from artists as t1 join paintings as t2 on t1 . artistid = t2 . painterid where t2 . year < value group by t1 . artistid order by count ( * ) desc limit value

Question: What is the id of the artist with the most paintings before 1900?

What is the id of the artist with the most paintings before 1900 ?


Question: SELECT make FROM team GROUP BY team HAVING count(*)  >  1

SELECT make FROM team GROUP BY team HAVING count ( * ) > 1

select make from team group by team having count ( * ) > value

Question: Find the make that has more than one team.

Find the make that has more than one team .


Question: select sum(enrollment) from institution where city  =  "vancouver" or city  =  "calgary"

select sum ( enrollment ) from institution where city = "vancouver" or city = "calgary"

select sum ( enrollment ) from institution where city = value or city = value

Question: What are the total enrollment of institutions in city `` Vancouver '' or `` Calgary '' ?


Question: SELECT Stadium FROM institution ORDER BY Capacity DESC

select stadium from institution order by capacity desc

Question: Return the stadiums of institutions, ordered by capacity descending.

Return the stadiums of institutions , ordered by capacity descending .


Question: SELECT product_name FROM Products WHERE product_type_code  =  "Clothes" ORDER BY product_price DESC LIMIT 1

SELECT product_name FROM Products WHERE product_type_code = `` Clothes '' ORDER BY product_price DESC LIMIT 1

select product_name from products where product_type_code = value order by product_price desc limit value

Question: What is the name of the most expensive product with type Clothes?

What is the name of the most expensive product with type Clothes ?


Question: SELECT name ,  age FROM customers ORDER BY membership_credit DESC LIMIT 1

select name , age from customers order by membership_credit desc limit value

Question: What is the name and age of the customer with the most membership credit?

What is the name and age of the customer with the most membership credit ?


Question: SELECT T1.name ,  T3.name FROM countries AS T1 JOIN official_languages AS T2 ON T1.id  =  T2.country_id JOIN languages AS T3 ON T2.language_id  =  T3.id

select t1 . name , t3 . name from countries as t1 join official_languages as t2 on t1 . id = t2 . country_id join languages as t3 on t2 . language_id = t3 . id

Question: What are the names of the countries, as well as the names of their official langauges?

What are the names of the countries , as well as the names of their official langauges ?


Question: SELECT DISTINCT T1.name ,  T1.sid FROM Sailors AS T1 JOIN Reserves AS T2 ON T1.sid  =  T2.sid

select distinct t1 . name , t1 . sid from sailors as t1 join reserves as t2 on t1 . sid = t2 . sid

Question: Find the name and id of the sailors who reserved at least one boat?

Find the name and id of the sailors who reserved at least one boat ?


Question: SELECT count(*) FROM Products WHERE product_type_code  =  "Hardware"

SELECT count ( * ) FROM Products WHERE product_type_code = `` Hardware ''

select count ( * ) from products where product_type_code = value

Question: How many hardware type products do we have?

How many hardware type products do we have ?


Question: SELECT title ,  LOCATION FROM sculptures

Question: List the title and location of all sculptures.

List the title and location of all sculptures .


Question: SELECT invoice_status FROM Invoices GROUP BY invoice_status ORDER BY count(*) DESC LIMIT 1

SELECT invoice_status FROM Invoices GROUP BY invoice_status ORDER BY count ( * ) DESC LIMIT 1

select invoice_status from invoices group by invoice_status order by count ( * ) desc limit value

Question: Return the invoice status that has the most invoices.

Return the invoice status that has the most invoices .


Question: SELECT paintingID FROM paintings WHERE YEAR  <   (SELECT min(YEAR) FROM paintings WHERE LOCATION  =  'Gallery 240')

SELECT paintingID FROM paintings WHERE YEAR < ( SELECT min ( YEAR ) FROM paintings WHERE LOCATION = 'Gallery 240 ' )

select paintingid from paintings where year < ( select min ( year ) from paintings where location = value )

Question: What is the id of every painting created before the oldest painting in gallery 240?

What is the id of every painting created before the oldest painting in gallery 240 ?


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

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

select earpads from headphone except select earpads from headphone where construction = value

Question: Which earpads never use plastic construction?

Which earpads never use plastic construction ?


Question: SELECT Franchise FROM game GROUP BY Franchise HAVING COUNT(*)  >=  2

SELECT Franchise FROM game GROUP BY Franchise HAVING COUNT ( * ) > = 2

select franchise from game group by franchise having count ( * ) > = value

Question: What are the names of franchises that have two or more games?

What are the names of franchises that have two or more games ?


Question: SELECT count(DISTINCT document_id) FROM Documents_processes

SELECT count ( DISTINCT document_id ) FROM Documents_processes

select count ( distinct document_id ) from documents_processes

Question: How many documents have a process?


Question: SELECT T1.name FROM Affiliation AS T1 JOIN Author_list AS T2 ON T1.affiliation_id  =  T2.affiliation_id GROUP BY T1.affiliation_id ORDER BY count(*) DESC

SELECT T1.name FROM Affiliation AS T1 JOIN Author_list AS T2 ON T1.affiliation_id = T2.affiliation_id GROUP BY T1.affiliation_id ORDER BY count ( * ) DESC

select t1 . name from affiliation as t1 join author_list as t2 on t1 . affiliation_id = t2 . affiliation_id group by t1 . affiliation_id order by count ( * ) desc

Question: List all affiliations with ascending ordered number of papers.

List all affiliations with ascending ordered number of papers .


Question: SELECT title ,  isbn ,  SalePrice FROM Book

select title , isbn , saleprice from book

Question: List all Book titles, ISBNs, and sale prices.

List all Book titles , ISBNs , and sale prices .


Question: SELECT Completed_Year FROM building WHERE Number_of_Stories  >  20 INTERSECT SELECT Completed_Year FROM building WHERE Number_of_Stories  <  15

select completed_year from building where number_of_stories > value intersect select completed_year from building where number_of_stories < value

Question: In which years did both buildings with more than 20 stories and buildings with less than 15 stories were completed?

In which years did both buildings with more than 20 stories and buildings with less than 15 stories were completed ?


Question: SELECT T2.title FROM Books_Order AS T1 JOIN Book AS T2 ON T1.isbn  =  T2.isbn GROUP BY T1.isbn ORDER BY count(*) DESC LIMIT 1

SELECT T2.title FROM Books_Order AS T1 JOIN Book AS T2 ON T1.isbn = T2.isbn GROUP BY T1.isbn ORDER BY count ( * ) DESC LIMIT 1

select t2 . title from books_order as t1 join book as t2 on t1 . isbn = t2 . isbn group by t1 . isbn order by count ( * ) desc limit value

Question: What is the title of the book that has been ordered the greatest number of times?

What is the title of the book that has been ordered the greatest number of times ?


Question: SELECT T2.LastName FROM receipts AS T1 JOIN customers AS T2 ON T1.CustomerId  =  T2.id GROUP BY T2.id HAVING count(*)  >  10

SELECT T2.LastName FROM receipts AS T1 JOIN customers AS T2 ON T1.CustomerId = T2.id GROUP BY T2.id HAVING count ( * ) > 10

select t2 . lastname from receipts as t1 join customers as t2 on t1 . customerid = t2 . id group by t2 . id having count ( * ) > value

Question: What is the last name of the customers who shopped at the bakery more than 10 times?

What is the last name of the customers who shopped at the bakery more than 10 times ?


Question: SELECT t2.country FROM driver AS t1 JOIN country AS t2 ON t1.country  =  t2.country_id WHERE t1.Make  =  "Dodge" INTERSECT SELECT t2.country FROM driver AS t1 JOIN country AS t2 ON t1.country  =  t2.country_id WHERE t1.Make  =  "Chevrolet"

SELECT t2.country FROM driver AS t1 JOIN country AS t2 ON t1.country = t2.country_id WHERE t1.Make = `` Dodge '' INTERSECT SELECT t2.country FROM driver AS t1 JOIN country AS t2 ON t1.country = t2.country_id WHERE t1.Make = `` Chevrolet ''

select t2 . country from driver as t1 join country as t2 on t1 . country = t2 . country_id where t1 . make = value intersect select t2 . country from driver as t1 join country as t2 on t1 . country = t2 . country_id where t1 . make = value

Question: Find the countries in which there are both drivers with make "Dodge" and drivers with make "Chevrolet".

Find the countries in which there are both drivers with make `` Dodge '' and drivers with make `` Chevrolet '' .


Question: SELECT date_of_transcript ,  transcript_details FROM Transcripts

select date_of_transcript , transcript_details from transcripts

Question: What are the date and detail of each transcript?

What are the date and detail of each transcript ?


Question: SELECT T1.customer_id ,  T2.customer_name ,  T2.customer_phone ,  T2.customer_email FROM Customer_orders AS T1 JOIN Customers AS T2 ON T1.customer_id  =  T2.customer_id GROUP BY T1.customer_id ORDER BY count(*) DESC LIMIT 1

Question: Give the id, name, phone, and email corresponding to the customer who made the most orders.

Give the id , name , phone , and email corresponding to the customer who made the most orders .


Question: SELECT T1.Number_of_Stories FROM building AS T1 JOIN region AS T2 ON T1.Region_ID  =  T2.Region_ID WHERE T2.Name  =  "Abruzzo"

SELECT T1.Number_of_Stories FROM building AS T1 JOIN region AS T2 ON T1.Region_ID = T2.Region_ID WHERE T2.Name = `` Abruzzo ''

Question: Return the number of stories for each building in the region named "Abruzzo".

Return the number of stories for each building in the region named `` Abruzzo '' .


Question: SELECT count(DISTINCT T1.code) FROM movies AS T1 JOIN movietheaters AS T2 ON T1.code  =  T2.movie

SELECT count ( DISTINCT T1.code ) FROM movies AS T1 JOIN movietheaters AS T2 ON T1.code = T2.movie

select count ( distinct t1 . code ) from movies as t1 join movietheaters as t2 on t1 . code = t2 . movie

Question: How many different movies are playing?


Question: SELECT Stadium FROM institution ORDER BY Enrollment DESC LIMIT 1

select stadium from institution order by enrollment desc limit value

Question: Give the stadium of the institution which is the greatest enrollment.

Give the stadium of the institution which is the greatest enrollment .


Question: SELECT count(*) FROM Staff WHERE staff_id NOT IN ( SELECT staff_id FROM Staff_in_meetings )

SELECT count ( * ) FROM Staff WHERE staff_id NOT IN ( SELECT staff_id FROM Staff_in_meetings )

select count ( * ) from staff where staff_id not in ( select staff_id from staff_in_meetings )

Question: How many staff did not attend any meeting?

How many staff did not attend any meeting ?


Question: SELECT CLASS FROM headphone GROUP BY CLASS HAVING count(*)  >  2

SELECT CLASS FROM headphone GROUP BY CLASS HAVING count ( * ) > 2

select class from headphone group by class having count ( * ) > value

Question: Find the headphone class that does not contain more than two headphones.

Find the headphone class that does not contain more than two headphones .


Question: SELECT process_name FROM Business_processes WHERE process_id  =  (SELECT next_process_id FROM Business_processes WHERE process_id  =  9)

Question: What is the process name for the next process of the process with id 9?

What is the process name for the next process of the process with id 9 ?


Question: SELECT sum(value) ,  count(*) ,  CONTENTS FROM boxes GROUP BY CONTENTS

SELECT sum ( value ) , count ( * ) , CONTENTS FROM boxes GROUP BY CONTENTS

select sum ( value ) , count ( * ) , contents from boxes group by contents

Question: Find the total value and number of boxes for each content type.

Find the total value and number of boxes for each content type .


Question: SELECT count(*) ,  T2.Document_Object_ID FROM Collections AS T1 JOIN Documents_in_Collections AS T2 ON T1.Collection_ID = T2.Collection_ID GROUP BY T2.Document_Object_ID

SELECT count ( * ) , T2.Document_Object_ID FROM Collections AS T1 JOIN Documents_in_Collections AS T2 ON T1.Collection_ID = T2.Collection_ID GROUP BY T2.Document_Object_ID

Question: How many collections does each document belong to? List the count and the document id.

How many collections does each document belong to ? List the count and the document id .


Question: SELECT count(*) ,  t2.name FROM book AS t1 JOIN press AS t2 ON t1.press_id  =  t2.press_id WHERE sale_amount  >  1000 GROUP BY t2.name

SELECT count ( * ) , t2.name FROM book AS t1 JOIN press AS t2 ON t1.press_id = t2.press_id WHERE sale_amount > 1000 GROUP BY t2.name

select count ( * ) , t2 . name from book as t1 join press as t2 on t1 . press_id = t2 . press_id where sale_amount > value group by t2 . name

Question: For each press, return its name and the number of books that have sale amount above 1000.

For each press , return its name and the number of books that have sale amount above 1000 .


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

SELECT name FROM songs WHERE name LIKE `` % Is % ''

select name from songs where name like value

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

Which song names have the substring `` Is '' ?


Question: SELECT count(*) FROM Book AS T1 JOIN Books_Order AS T2 ON T1.isbn  =  T2.isbn WHERE T1.title  =  "Pride and Prejudice"

SELECT count ( * ) FROM Book AS T1 JOIN Books_Order AS T2 ON T1.isbn = T2.isbn WHERE T1.title = `` Pride and Prejudice ''

select count ( * ) from book as t1 join books_order as t2 on t1 . isbn = t2 . isbn where t1 . title = value

Question: How many orders do we have for "Pride and Prejudice"?

How many orders do we have for `` Pride and Prejudice '' ?


Question: SELECT DISTINCT T2.sid FROM Boats AS T1 JOIN Reserves AS T2 ON  T1.bid  =  T2.bid WHERE T1.color  =  'red' INTERSECT SELECT DISTINCT T2.sid FROM Boats AS T1 JOIN Reserves AS T2 ON  T1.bid  =  T2.bid WHERE T1.color  =  "blue"

SELECT DISTINCT T2.sid FROM Boats AS T1 JOIN Reserves AS T2 ON T1.bid = T2.bid WHERE T1.color = 'red ' INTERSECT SELECT DISTINCT T2.sid FROM Boats AS T1 JOIN Reserves AS T2 ON T1.bid = T2.bid WHERE T1.color = `` blue ''

select distinct t2 . sid from boats as t1 join reserves as t2 on t1 . bid = t2 . bid where t1 . color = value intersect select distinct t2 . sid from boats as t1 join reserves as t2 on t1 . bid = t2 . bid where t1 . color = value

Question: Find the id of Sailors (sid) that reserved red and blue boat.

Find the id of Sailors ( sid ) that reserved red and blue boat .


Question: select t1.packagenumber from package as t1 join client as t2 on t1.recipient  =  t2.accountnumber where t2.name = "leo wong";

select
t1.packagenumber
from
package
as
t1
join
client
as
t2
on
t1.recipient
=
t2.accountnumber
where
t2.name
=
"leo wong"
;

select t1 . packagenumber from package as t1 join client as t2 on t1 . recipient = t2 . accountnumber where t2 . name = value

Question: List all package numbers received by Leo Wong ?


Question: SELECT title FROM paintings WHERE YEAR BETWEEN 1900 AND 1950 UNION SELECT title FROM sculptures WHERE YEAR BETWEEN 1900 AND 1950

select title from paintings where year between value and value union select title from sculptures where year between value and value

Question: What are the names of both paintings and sculptures created between 1900 and 1950?

What are the names of both paintings and sculptures created between 1900 and 1950 ?


Question: SELECT title FROM movies ORDER BY title

Question: List in alphabetical order the titles of all movies.

List in alphabetical order the titles of all movies .


Question: SELECT T1.country FROM City AS T1 JOIN Student AS T2 ON T1.city_code  =  T2.city_code GROUP BY T1.country ORDER BY count(*) LIMIT 1

SELECT T1.country FROM City AS T1 JOIN Student AS T2 ON T1.city_code = T2.city_code GROUP BY T1.country ORDER BY count ( * ) LIMIT 1

select t1 . country from city as t1 join student as t2 on t1 . city_code = t2 . city_code group by t1 . country order by count ( * ) limit value

Question: Give the country with the fewest students.

Give the country with the fewest students .


Question: SELECT count(*) FROM district WHERE district_id NOT IN (SELECT district_id FROM spokesman_district)

SELECT count ( * ) FROM district WHERE district_id NOT IN ( SELECT district_id FROM spokesman_district )

select count ( * ) from district where district_id not in ( select district_id from spokesman_district )

Question: Find the number of districts which have no spokesmen.

Find the number of districts which have no spokesmen .


Question: SELECT count(DISTINCT customer_id) FROM Orders

SELECT count ( DISTINCT customer_id ) FROM Orders

select count ( distinct customer_id ) from orders

Question: How many different customers have ordered things?

How many different customers have ordered things ?


Question: SELECT name FROM movietheaters GROUP BY name ORDER BY count(*) DESC LIMIT 1

SELECT name FROM movietheaters GROUP BY name ORDER BY count ( * ) DESC LIMIT 1

select name from movietheaters group by name order by count ( * ) desc limit value

Question: Find the name of the theater that is playing the most number of movies.

Find the name of the theater that is playing the most number of movies .


Question: SELECT Collecrtion_Subset_Details FROM Collection_Subsets WHERE Collection_Subset_Name = "Top collection";

SELECT Collecrtion_Subset_Details FROM Collection_Subsets WHERE Collection_Subset_Name = `` Top collection '' ;

Question: What is detail of collection subset with name 'Top collection'?

What is detail of collection subset with name 'Top collection ' ?


Question: SELECT Driver_Name FROM driver ORDER BY Driver_Name DESC

select driver_name from driver order by driver_name desc

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

What are the names of drivers , ordered descending alphabetically ?


Question: SELECT max(power) ,  avg(power) FROM vehicle WHERE builder  =  'Zhuzhou'

SELECT max ( power ) , avg ( power ) FROM vehicle WHERE builder = 'Zhuzhou '

select max ( power ) , avg ( power ) from vehicle where builder = value

Question: What is the maximum and average power for the vehicles manufactured by 'Zhuzhou'?

What is the maximum and average power for the vehicles manufactured by 'Zhuzhou ' ?


Question: SELECT T1.age_category_code FROM Users AS T1 JOIN User_Searches AS T2 ON T1.user_id  =  T2.user_id ORDER BY T2.search_datetime LIMIT 1;

Question: What is the age range category of the user who made the first search?

What is the age range category of the user who made the first search ?


Question: SELECT T1.agency_id ,  T1.agency_details FROM Agencies AS T1 JOIN Clients AS T2 ON T1.agency_id  =  T2.agency_id GROUP BY T1.agency_id HAVING count(*)  >=  2

SELECT T1.agency_id , T1.agency_details FROM Agencies AS T1 JOIN Clients AS T2 ON T1.agency_id = T2.agency_id GROUP BY T1.agency_id HAVING count ( * ) > = 2

select t1 . agency_id , t1 . agency_details from agencies as t1 join clients as t2 on t1 . agency_id = t2 . agency_id group by t1 . agency_id having count ( * ) > = value

Question: Show agency ids and details with at least 2 clients.

Show agency ids and details with at least 2 clients .


Question: SELECT name FROM Sailors WHERE name LIKE '%e%'

SELECT name FROM Sailors WHERE name LIKE ' % e % '

select name from sailors where name like value

Question: What is the name of every sailor whose name contains the letter e?

What is the name of every sailor whose name contains the letter e ?


Question: SELECT T1.date_of_transcript FROM Transcripts AS T1 JOIN Student_Loans AS T2 ON T1.student_id  =  T2.student_id ORDER BY T2.amount_of_loan DESC LIMIT 1

Question: What is the transcript issuance date for the student with the largest amount of loan?

What is the transcript issuance date for the student with the largest amount of loan ?


Question: SELECT T1.id ,  T1.Name ,  T1.popularity FROM participants AS T1 JOIN performance_score AS T2 ON T2.participant_id  =  T1.id GROUP BY T1.id ORDER BY count(*)

SELECT T1.id , T1.Name , T1.popularity FROM participants AS T1 JOIN performance_score AS T2 ON T2.participant_id = T1.id GROUP BY T1.id ORDER BY count ( * )

select t1 . id , t1 . name , t1 . popularity from participants as t1 join performance_score as t2 on t2 . participant_id = t1 . id group by t1 . id order by count ( * )

Question: What are the ids, names and popularity of the participants, order by the number of songs they perform?

What are the ids , names and popularity of the participants , order by the number of songs they perform ?


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

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

select min ( price ) , max ( price ) , food from goods group by food order by food

Question: Return the lowest and highest prices of goods grouped and ordered by food type.

Return the lowest and highest prices of goods grouped and ordered by food type .


Question: SELECT avg(Population) FROM region

Question: What is the average population for all regions?

What is the average population for all regions ?


Question: SELECT T2.location FROM boxes AS T1 JOIN warehouses AS T2 ON T1.warehouse  =  T2.code WHERE T1.contents  =  'Rocks' EXCEPT SELECT T2.location FROM boxes AS T1 JOIN warehouses AS T2 ON T1.warehouse  =  T2.code WHERE T1.contents  =  'Scissors'

SELECT T2.location FROM boxes AS T1 JOIN warehouses AS T2 ON T1.warehouse = T2.code WHERE T1.contents = 'Rocks ' EXCEPT SELECT T2.location FROM boxes AS T1 JOIN warehouses AS T2 ON T1.warehouse = T2.code WHERE T1.contents = 'Scissors '

select t2 . location from boxes as t1 join warehouses as t2 on t1 . warehouse = t2 . code where t1 . contents = value except select t2 . location from boxes as t1 join warehouses as t2 on t1 . warehouse = t2 . code where t1 . contents = value

Question: Find the location of the warehouses which have contents Rocks but not Scissors.

Find the location of the warehouses which have contents Rocks but not Scissors .


Question: SELECT Neighborhood FROM store EXCEPT SELECT t1.Neighborhood FROM store AS t1 JOIN stock AS t2 ON t1.store_id  =  t2.store_id

select neighborhood from store except select t1 . neighborhood from store as t1 join stock as t2 on t1 . store_id = t2 . store_id

Question: Which neighborhood does not have any headphone in stock?

Which neighborhood does not have any headphone in stock ?