Title: RE: Sub-query in order by clause

Yes, I see that. (hangs head in shame)

> -----Original Message-----
> From: Nicoll, Iain [mailto:[EMAIL PROTECTED]]

> As I believe has been pointed out already it may possibly be
> more efficient
> if dept is very small and emp is very large (especially if
> there are filters
> and a join would be done before a filter was applied). 
> Alternatively it may
> be that Oracle believe it is more intuitive to people with no
> preconceived
> ideas.

> -----Original Message-----
> Sent: 04 April 2003 20:24
>
> Why would you do that instead of
> SELECT emp.deptno, empno, ename
> FROM emp a, dept b
> WHERE dept.deptno = emp.deptno
> order by dept.deptname ;
>
> > -----Original Message-----
> > From: Nicoll, Iain [ mailto:[EMAIL PROTECTED]
> <mailto:[EMAIL PROTECTED]> ]
> >
> > Don't really know but couldn't it be useful if you had
> > 
> > ORDER BY ( SELECT deptname FROM dept
> >             WHERE dept.deptno = emp.deptno)

Reply via email to