Class InsertDataOperation
- Namespace
- Microsoft.EntityFrameworkCore.Migrations.Operations
- Assembly
- Microsoft.EntityFrameworkCore.Relational.dll
A MigrationOperation for inserting seed data into a table.
public class InsertDataOperation : MigrationOperation, ITableMigrationOperation
- Inheritance
-
InsertDataOperation
- Implements
- Inherited Members
Constructors
InsertDataOperation()
public InsertDataOperation()
Properties
ColumnTypes
A list of store types for the columns into which data will be inserted.
public virtual string[] ColumnTypes { get; set; }
Property Value
- string[]
Columns
A list of column names that represent the columns into which data will be inserted.
public virtual string[] Columns { get; set; }
Property Value
- string[]
Schema
The schema that contains the table, or null if the default schema should be used.
public virtual string Schema { get; set; }
Property Value
Table
The name of the table into which data will be inserted.
public virtual string Table { get; set; }
Property Value
Values
The data to be inserted, represented as a list of value arrays where each value in the array corresponds to a column in the Columns property.
public virtual object[,] Values { get; set; }
Property Value
- object[,]
Methods
GenerateModificationCommands(IModel)
Generates the commands that correspond to this operation.
[Obsolete]
public virtual IEnumerable<ModificationCommand> GenerateModificationCommands(IModel model)
Parameters
model
IModel
Returns
- IEnumerable<ModificationCommand>
The commands that correspond to this operation.