SQL> Select Emp.Deptno, ENAME
2 from EMP, DEPT
3 WHERE Emp.deptno = Dept.deptno
4 ORDER BY Empno;
Execution Plan
-------------------------------------------------- ------------
0 Select Statement Optimizer = Choose
1 0 sort (Order by) -------- Sort_area_size
2 1 merge
3 2 sort (join) -------- Sort_Area_Retained_Size
4 3 Table Access (Full) of 'DEPT'
5 2 sort (join) -------- Sort_Area_Retained_Size
6 5 Table Access (Full) Of 'EMP'
Statistics
-------------------------------------------------- ------------
0 Recursive Calls
0 DB Block Get
14 Consistent Gets
0 Physical READS
0 redo size
478 BYTES SENT VIA SQL * NET to Client
503 Bytes Received Via SQL * Net from Client
2 SQL * NET ROUNDTRIPS TO / FROM Client
3 sorts (memory)
0 Sorts (Disk)
3 Rows Processed
SQL>
One execution plan can contain multiple sort cases, as described above, including two table sorting-merged coupling, and then execute the order of the ORDER BY clause, the total constitutes three sorting. If a single server is performing a sorting process, then it is used when performing the order of Order By:
? Sort_Area_size size (in bytes) for activity sort
• Two sizes are used by the area specified by sort_area_retained_size for join sorting