Share via


MigrationBuilder.AlterSequence Method

Definition

Overloads

AlterSequence(String, String, Int32, Nullable<Int64>, Nullable<Int64>, Boolean)
AlterSequence(String, String, Int32, Nullable<Int64>, Nullable<Int64>, Boolean, Int32, Nullable<Int64>, Nullable<Int64>, Boolean)

Builds an AlterSequenceOperation to alter an existing sequence.

AlterSequence(String, String, Int32, Nullable<Int64>, Nullable<Int64>, Boolean)

public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.AlterSequenceOperation> AlterSequence (string name, string schema = default, int incrementBy = 1, long? minValue = default, long? maxValue = default, bool cyclic = false);
abstract member AlterSequence : string * string * int * Nullable<int64> * Nullable<int64> * bool -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.AlterSequenceOperation>
override this.AlterSequence : string * string * int * Nullable<int64> * Nullable<int64> * bool -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.AlterSequenceOperation>
Public Overridable Function AlterSequence (name As String, Optional schema As String = Nothing, Optional incrementBy As Integer = 1, Optional minValue As Nullable(Of Long) = Nothing, Optional maxValue As Nullable(Of Long) = Nothing, Optional cyclic As Boolean = false) As OperationBuilder(Of AlterSequenceOperation)

Parameters

name
String
schema
String
incrementBy
Int32
minValue
Nullable<Int64>
maxValue
Nullable<Int64>
cyclic
Boolean

Returns

Applies to

AlterSequence(String, String, Int32, Nullable<Int64>, Nullable<Int64>, Boolean, Int32, Nullable<Int64>, Nullable<Int64>, Boolean)

Builds an AlterSequenceOperation to alter an existing sequence.

public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.AlterOperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.AlterSequenceOperation> AlterSequence (string name, string schema = default, int incrementBy = 1, long? minValue = default, long? maxValue = default, bool cyclic = false, int oldIncrementBy = 1, long? oldMinValue = default, long? oldMaxValue = default, bool oldCyclic = false);
public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.AlterOperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.AlterSequenceOperation> AlterSequence (string name, string? schema = default, int incrementBy = 1, long? minValue = default, long? maxValue = default, bool cyclic = false, int oldIncrementBy = 1, long? oldMinValue = default, long? oldMaxValue = default, bool oldCyclic = false);
abstract member AlterSequence : string * string * int * Nullable<int64> * Nullable<int64> * bool * int * Nullable<int64> * Nullable<int64> * bool -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.AlterOperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.AlterSequenceOperation>
override this.AlterSequence : string * string * int * Nullable<int64> * Nullable<int64> * bool * int * Nullable<int64> * Nullable<int64> * bool -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.AlterOperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.AlterSequenceOperation>
Public Overridable Function AlterSequence (name As String, Optional schema As String = Nothing, Optional incrementBy As Integer = 1, Optional minValue As Nullable(Of Long) = Nothing, Optional maxValue As Nullable(Of Long) = Nothing, Optional cyclic As Boolean = false, Optional oldIncrementBy As Integer = 1, Optional oldMinValue As Nullable(Of Long) = Nothing, Optional oldMaxValue As Nullable(Of Long) = Nothing, Optional oldCyclic As Boolean = false) As AlterOperationBuilder(Of AlterSequenceOperation)

Parameters

name
String

The sequence name.

schema
String

The schema that contains the sequence, or null to use the default schema.

incrementBy
Int32

The amount to increment by when generating the next value in the sequence, defaulting to 1.

minValue
Nullable<Int64>

The minimum value of the sequence, or null if not specified.

maxValue
Nullable<Int64>

The maximum value of the sequence, or null if not specified.

cyclic
Boolean

Indicates whether or not the sequence will re-start when the maximum value is reached.

oldIncrementBy
Int32

The previous amount to increment by when generating the next value in the sequence, defaulting to 1.

oldMinValue
Nullable<Int64>

The previous minimum value of the sequence, or null if not specified.

oldMaxValue
Nullable<Int64>

The previous maximum value of the sequence, or null if not specified.

oldCyclic
Boolean

Indicates whether or not the sequence would previously re-start when the maximum value is reached.

Returns

A builder to allow annotations to be added to the operation.

Remarks

See Database migrations for more information and examples.

Applies to