MigrationBuilder.RestartSequence Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
RestartSequence(String, Int64, String) |
Builds a RestartSequenceOperation to re-start an existing sequence. |
RestartSequence(String, Nullable<Int64>, String) |
Builds a RestartSequenceOperation to re-start an existing sequence. |
RestartSequence(String, Int64, String)
- Source:
- MigrationBuilder.cs
- Source:
- MigrationBuilder.cs
- Source:
- MigrationBuilder.cs
- Source:
- MigrationBuilder.cs
- Source:
- MigrationBuilder.cs
- Source:
- MigrationBuilder.cs
- Source:
- MigrationBuilder.cs
Builds a RestartSequenceOperation to re-start an existing sequence.
public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.RestartSequenceOperation> RestartSequence (string name, long startValue = 1, string schema = default);
public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.RestartSequenceOperation> RestartSequence (string name, long startValue = 1, string? schema = default);
abstract member RestartSequence : string * int64 * string -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.RestartSequenceOperation>
override this.RestartSequence : string * int64 * string -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.RestartSequenceOperation>
Public Overridable Function RestartSequence (name As String, Optional startValue As Long = 1, Optional schema As String = Nothing) As OperationBuilder(Of RestartSequenceOperation)
Parameters
- name
- String
The name of the sequence.
- startValue
- Int64
The value at which the sequence will start, defaulting to 1.
- schema
- String
The schema that contains the sequence, or null
to use the default schema.
Returns
A builder to allow annotations to be added to the operation.
Remarks
See Database migrations for more information and examples.
Applies to
RestartSequence(String, Nullable<Int64>, String)
- Source:
- MigrationBuilder.cs
- Source:
- MigrationBuilder.cs
Builds a RestartSequenceOperation to re-start an existing sequence.
public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.RestartSequenceOperation> RestartSequence (string name, long? startValue = default, string? schema = default);
abstract member RestartSequence : string * Nullable<int64> * string -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.RestartSequenceOperation>
override this.RestartSequence : string * Nullable<int64> * string -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.RestartSequenceOperation>
Public Overridable Function RestartSequence (name As String, Optional startValue As Nullable(Of Long) = Nothing, Optional schema As String = Nothing) As OperationBuilder(Of RestartSequenceOperation)
Parameters
- name
- String
The name of the sequence.
The value at which the sequence will start. If null
(the default), the sequence restarts based
on the configuration used during creation.
- schema
- String
The schema that contains the sequence, or null
to use the default schema.
Returns
A builder to allow annotations to be added to the operation.
Remarks
See Database migrations for more information and examples.
Applies to
Entity Framework