ScalarFunction
public enum ScalarFunction : Buildable
An enumeration of the supported scalar functions that can applied on a column.
-
The SQL NOW function.
Declaration
Swift
case now
-
The SQL UCASE function.
Declaration
Swift
case ucase(field: Field)
-
The SQL LCASE function.
Declaration
Swift
case lcase(field: Field)
-
The SQL ROUND function.
Declaration
Swift
case round(field: Field, to: Int)
-
The SQL MID function.
Declaration
Swift
case mid(field: Field, start: Int, length: Int)
-
The SQL LEN function.
Declaration
Swift
case len(field: Field)
-
Build the query component using
QueryBuilder
.Throws
QueryError.syntaxError if query build fails.Declaration
Swift
public func build(queryBuilder: QueryBuilder) throws -> String
Parameters
queryBuilder
The QueryBuilder to use.
Return Value
A String representation of the query component.