A slight change in your query since you are anyway putting a filter on deptno:
select * from emp
where deptno = &dpt
order by decode(deptno,10,ename,
20,hiredate||','||job||','||sal,
30,deptno||','||ename,'')
Another observation is if you are already putting a filter on deptno, the sorting order for deptnos 10 and 30 pretty much amounts to the same, i.e., it would be on ename.
Bookmarks