programming-examples/sql/Subqueries/22. Write a query to display the customers who have a greater gradation than any customer who belongs to the alphabetically lower than the city New York.sql

8 lines
282 B
MySQL
Raw Normal View History

2019-11-18 14:05:53 +01:00
/*22. Write a query to display the customers who have a greater gradation than any customer who belongs to the alphabetically
lower than the city New York.*/
SELECT *
FROM customer
WHERE grade > ANY
(SELECT grade
FROM CUSTOMER
WHERE city < 'New York');