Previous Topic: Index LookasideNext Topic: Avoiding a Sort for an ORDER BY


Sorting

Sorting is used to support certain clauses in your SQL statement or in support of certain access paths.

DB2 can sort in support of the following functions:

Sorting in an application is always faster than sorting in DB2 for the small result sets. However, by placing the sort in the program, you remove some of the flexibility, power, and portability of the SQL statement, along with the ease of coding.