关于子查询中不能使用order by 的理解
select * from (select * from emp e where e.sal < 1000 order by e.empno) t order by t.sal desc;
这条SQL的子查询里面 包含了子查询 就可以执行
而下面这条SQL
select rownum , t.col1, t.col2, ... from( select col1, col2, ... from tab order by col1 ) twhere rownum <= n;
参考文章:http://blog.csdn.net/lee576/article/details/2685647