Add DISTINCT operator support

This commit is contained in:
go-jet 2022-01-10 16:43:17 +01:00
parent 6fe9c26d30
commit a506a96d6a
7 changed files with 197 additions and 0 deletions

View file

@ -173,3 +173,8 @@ func (c *caseOperatorImpl) serialize(statement StatementType, out *SQLBuilder, o
out.WriteString("END)")
}
// DISTINCT operator can be used to return distinct values of expr
func DISTINCT(expr Expression) Expression {
return newPrefixOperatorExpression(expr, "DISTINCT")
}