Structure
SQLCommonTableExpression
A clause describing a single Common Table Expressions, which in itws simplest form provides additional data to a primary query in the same way as joining to a subquery.
struct SQLCommonTableExpression
Overview
Note
There is no SQLDialect flag for CTE support, as CTEs are supported by all of the databases for which first-party drivers exist at the time of this writing (although they are not available in MySQL 5.7, which is long since EOL and should not be in use by anyone anymore).
Topics
Initializers
init(alias:query:)Create a new Common Table Expression.
Instance Properties
aliasThe name used to refer to the CTE’s data.columnsA list of column names yielded by the CTE. May be empty.isRecursiveIndicates whether the CTE is recursive, e.g. whether its query is aUNIONwhose second subquery refers to the CTE’s own aliased name.queryThe subquery which yields the CTE’s data.
Instance Methods
serialize(to:)Invoked when a request is made to serialize the expression to raw SQL.
Relationships
Conforms To
SQLExpressionSwift.SendableSwift.SendableMetatype