Export BinaryOperator function

This commit is contained in:
Karl Blomster 2024-03-26 15:49:17 +01:00
parent 1fd423bf8b
commit 1d310624d8
No known key found for this signature in database
GPG key ID: C12E5835375F3590
4 changed files with 13 additions and 0 deletions

View file

@ -188,3 +188,7 @@ func (c *caseOperatorImpl) serialize(statement StatementType, out *SQLBuilder, o
func DISTINCT(expr Expression) Expression { func DISTINCT(expr Expression) Expression {
return newPrefixOperatorExpression(expr, "DISTINCT") return newPrefixOperatorExpression(expr, "DISTINCT")
} }
func BinaryOperator(lhs Expression, rhs Expression, operator string) Expression {
return NewBinaryOperatorExpression(lhs, rhs, operator)
}

View file

@ -93,3 +93,6 @@ var Func = jet.Func
// NewEnumValue creates new named enum value // NewEnumValue creates new named enum value
var NewEnumValue = jet.NewEnumValue var NewEnumValue = jet.NewEnumValue
// BinaryOperator can be used to use custom or unsupported operators that take two operands.
var BinaryOperator = jet.BinaryOperator

View file

@ -142,3 +142,6 @@ var Func = jet.Func
// NewEnumValue creates new named enum value // NewEnumValue creates new named enum value
var NewEnumValue = jet.NewEnumValue var NewEnumValue = jet.NewEnumValue
// BinaryOperator can be used to use custom or unsupported operators that take two operands.
var BinaryOperator = jet.BinaryOperator

View file

@ -96,3 +96,6 @@ var Func = jet.Func
// NewEnumValue creates new named enum value // NewEnumValue creates new named enum value
var NewEnumValue = jet.NewEnumValue var NewEnumValue = jet.NewEnumValue
// BinaryOperator can be used to use custom or unsupported operators that take two operands.
var BinaryOperator = jet.BinaryOperator