Module: Sequel::SQL::OperatorBuilders
- Included in:
- Sequel, VirtualRow
- Defined in:
- lib/sequel/sql.rb
Overview
Instance Method Summary collapse
-
#**(a, b) ⇒ Object
Return NumericExpression for the exponentiation:.
-
#~(arg) ⇒ Object
Invert the given expression.
Instance Method Details
#**(a, b) ⇒ Object
Return NumericExpression for the exponentiation:
Sequel.**(2, 3) # SQL: power(2, 3)
874 875 876 |
# File 'lib/sequel/sql.rb', line 874 def **(a, b) SQL::NumericExpression.new(:**, a, b) end |
#~(arg) ⇒ Object
884 885 886 887 888 889 890 |
# File 'lib/sequel/sql.rb', line 884 def ~(arg) if condition_specifier?(arg) SQL::BooleanExpression.from_value_pairs(arg, :OR, true) else SQL::BooleanExpression.invert(arg) end end |