SqlServerMigrationSqlGenerator.Statement Method
Adds a new Statement to be executed against the database.
Assembly: EntityFramework.SqlServer (in EntityFramework.SqlServer.dll)
Name | Description | |
---|---|---|
![]() | Statement(IndentedTextWriter, String) | Adds a new Statement to be executed against the database. |
![]() | Statement(String, Boolean, String) | Adds a new Statement to be executed against the database. |
SqlServerMigrationSqlGenerator.Statement Method (IndentedTextWriter, String)
Adds a new Statement to be executed against the database.
[SuppressMessageAttribute("Microsoft.Design", "CA1026:DefaultParametersShouldNotBeUsed")] protected void Statement( IndentedTextWriter writer, string batchTerminator = null )
Parameters
- writer
-
Type:
System.Data.Entity.Migrations.Utilities.IndentedTextWriter
The writer containing the SQL to be executed.
- batchTerminator
-
Type:
System.String
The batch terminator for the database provider.
SqlServerMigrationSqlGenerator.Statement Method (String, Boolean, String)
Adds a new Statement to be executed against the database.
[SuppressMessageAttribute("Microsoft.Design", "CA1026:DefaultParametersShouldNotBeUsed")] protected void Statement( string sql, bool suppressTransaction = false, string batchTerminator = null )
Parameters
- sql
-
Type:
System.String
The statement to be executed.
- suppressTransaction
-
Type:
System.Boolean
Indicates whether this statement should be performed outside of the transaction scope that is used to make the migration process transactional. If set to true, this operation will not be rolled back if the migration process fails.
- batchTerminator
-
Type:
System.String
The batch terminator for the database provider.