Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Correlated Subquery in ORDER BY

448221Nov 28 2005 — edited Nov 30 2005
The following is a valid sql. But, what is meant by a correlated scalar subquery in the ORDER BY clause?


SELECT employee_id, last_name
FROM employees e
ORDER BY (SELECT department_name
FROM departments d
WHERE e.department_id=d.department_id);
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 28 2005
Added on Nov 28 2005
5 comments
1,038 views