AggregatingRequest
public protocol AggregatingRequest
The protocol for all requests that can aggregate.
-
Creates a request grouped according to expressions promise.
Declaration
Swift
func groupWhenConnected(_ expressions: @escaping (Database) throws -> [any SQLExpressible]) -> Self -
Creates a request with the provided predicate promise added to the eventual set of already applied predicates.
Declaration
Swift
func havingWhenConnected(_ predicate: @escaping (Database) throws -> any SQLExpressible) -> Self
-
group(_:Extension method) Creates a request grouped according to expressions.
Declaration
Swift
public func group(_ expressions: [any SQLExpressible]) -> Self -
group(_:Extension method) Creates a request grouped according to expressions.
Declaration
Swift
public func group(_ expressions: any SQLExpressible...) -> Self -
group(sql:Extension methodarguments: ) Creates a request with a new grouping.
Declaration
Swift
public func group(sql: String, arguments: StatementArguments = StatementArguments()) -> Self -
group(literal:Extension method) Creates a request with a new grouping.
Declaration
Swift
public func group(literal sqlLiteral: SQL) -> Self -
having(_:Extension method) Creates a request with the provided predicate added to the eventual set of already applied predicates.
Declaration
Swift
public func having(_ predicate: some SQLExpressible) -> Self -
having(sql:Extension methodarguments: ) Creates a request with the provided sql added to the eventual set of already applied predicates.
Declaration
Swift
public func having(sql: String, arguments: StatementArguments = StatementArguments()) -> Self -
having(literal:Extension method) Creates a request with the provided SQL literal added to the eventual set of already applied predicates.
Declaration
Swift
public func having(literal sqlLiteral: SQL) -> Self
View on GitHub
Install in Dash
AggregatingRequest Protocol Reference