What is SQL ORDER BY?
The SQL ORDER BY clause is the part of the SELECT statement that controls the sequence of information returned.
How To Use SQL ORDER BY
SQL ORDER BY is used as follows.
SQL ORDER BY Syntax
Multiple columns can be included in the ORDER BY clause. The direction of the sort is controlled by:
SQL ORDER BY Example
The following example displays rows from the branch in region_nbr and branch_nbr ascending sequence.
Here are the contents of the table:
This SQL Statement with ORDER BY is executed:
Here is the result.
|HOME | SQL OVERVIEW | SQL BASICS | SQL ADMINISTRATION | SQL ADVANCED | SQL SYNTAX|
|Copyright© 1999-2012, First Place Software, Inc.|