SORT BY Statement
SORT BY causes the result rows to be sorted according to the specified expressions.
By default, results are sorted in ascending order.
<sortByStatement> ::= "SORT BY" <expression> ( "," <expression> )* ;A SORT BY expression can be the name of a column.
If two rows are equal according to the leftmost expression, they are compared according to the next expression and so on. If they are equal according to all specified expressions, they are returned in an implementation-dependent order.
Note: Sorting by an expression is not supported directly, but you can do it if you put the expression in the projection (COLUMNS statement) and assign it a column name with the AS statement
The following functions are supported:
Copyright © 2020. Cloud Software Group, Inc. All Rights Reserved.