Declarative Objectivity (DO) Language : Data Clauses : ORDER BY Clause
ORDER BY Clause
An ORDER BY clause sorts returned objects according to specified criteria.
Syntax 
orderByClause : ORDER BY condition (',' condition)*;
condition : expression ('ASC' | 'DESC')?;
Used In 
RETURN Statement, CREATE Statement, UPDATE Statement, DELETE Statement
Quick Look 
Return the last names and first names of customers, listing them by last name in alphabetical order:
FROM Customers ORDER BY lastName RETURN lastName, firstName;
Return the last names and first names of customers, listing them in alphabetical order by last name; if multiple customers have the same last name, list those customers by ascending first name:
FROM Customers ORDER BY lastName, firstName RETURN lastName, firstName;
Return the last names and first names of customers, listing them in reverse alphabetical order by last name; if multiple customers have the same last name, list those customers by ascending first name:
FROM Customers ORDER BY lastName DESC, firstName ASC RETURN lastName, firstName;
Discussion 
An ORDER BY clause causes output to be returned in ascending or descending order, according to the values of specified expressions. Ascending order is used by default. If multiple expressions are specified, sorting precedence follows the order in which the expressions are listed (with the first expression indicating the primary sort).