Class CreateTableOptions
Options for materialising a query into a table with TempTableExtensions. Providers that cannot express a given option reject it with NotSupportedException when the SQL is built.
public sealed record CreateTableOptions : IEquatable<CreateTableOptions>
- Inheritance
-
CreateTableOptions
- Implements
- Inherited Members
- Extension Methods
Properties
Columns
The column names to declare on the created table, or null to derive them from
the query. Not every provider accepts a column list together with AS SELECT (SQLite does not).
public IReadOnlyList<string>? Columns { get; init; }
Property Value
DropExisting
Whether an existing table with the target name is dropped first (DROP TABLE IF EXISTS),
so the materialisation always reflects the current query. Only valid for a persistent table
(see TempTableExtensions); mutually exclusive with IfNotExists.
Defaults to false.
public bool DropExisting { get; init; }
Property Value
IfNotExists
Whether the statement carries IF NOT EXISTS. Defaults to false.
public bool IfNotExists { get; init; }
Property Value
OnCommit
The ON COMMIT action of a temporary table (PostgreSQL only). Only valid for a temporary
table (see TempTableExtensions); defaults to
PreserveRows.
public TempTableOnCommit OnCommit { get; init; }
Property Value
WithData
Whether the table is populated from the query; false renders WITH NO DATA
(PostgreSQL only). Defaults to true.
public bool WithData { get; init; }