Methods

Class/Module Index [+]

Quicksearch

Sequel::SQL::OrderMethods

Methods that create OrderedExpressions, used for sorting by columns or more complex expressions.

Public Instance Methods

asc(opts={}) click to toggle source

Mark the receiving SQL column as sorting in an ascending fashion (generally a no-op). Options:

:nulls

Set to :first to use NULLS FIRST (so NULL values are ordered before other values), or :last to use NULLS LAST (so NULL values are ordered after other values).

# File lib/sequel/sql.rb, line 831
def asc(opts={})
  OrderedExpression.new(self, false, opts)
end
desc(opts={}) click to toggle source

Mark the receiving SQL column as sorting in a descending fashion. Options:

:nulls

Set to :first to use NULLS FIRST (so NULL values are ordered before other values), or :last to use NULLS LAST (so NULL values are ordered after other values).

# File lib/sequel/sql.rb, line 841
def desc(opts={})
  OrderedExpression.new(self, true, opts)
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.