Skip to content

Instance Method

orderBy(_:_:)

Adds an ORDER BY clause to the query with the specified column and ordering.
@discardableResult func orderBy(_ column: String, _ direction: SQLDirection = .ascending) -> Self

Parameters

column

Name of column to sort results by. Appended to any previously added orderings.

direction

The sort direction for the column.