Order by clause in Oracle

Oracle, PL SQL, SQL Server,

        It is the last clause of select statement responsible to arrange the records in a proper manner either ascending or descending order. To do so order by clause provides two attributes, asc and desc. The default order is asc.
Select empno, ename, sal, job, deptno from emp
Order by deptno desc;
(Single column wise ordering)
Select empno, ename , job, deptno from emp
Order by deptno, sal desc;


0 Comments