Overview
The select function also allows users to order results the way they might in a typical relational database. Results may be ordered by one or more variables in both ascending or descending order.
Step By Step
- Begin with a simple select query.
If ascending or descending order is not specified the order by clause will default to ascending.
Order by VAR1 Ascendinghttp://{host}/rds/{collection}/{view}/select?orderby=VAR1
To specify descending order add "DESC" to the clause.
Order by VAR1 Descendinghttp://{host}/rds/{collection}/{view}/select?orderby=VAR1 DESC
Ordering by multiple variables is possible though separating the variables and their order by a comma.
Order by VAR1 Descending and VAR2 Ascendinghttp://{host}/rds/{collection}/{view}/select?orderby=VAR1 DESC,VAR2 ASC