MigrationBuilder.RestartSequence 方法

定义

重载

RestartSequence(String, Int64, String)

生成 以 RestartSequenceOperation 重新启动现有序列。

RestartSequence(String, Nullable<Int64>, String)

生成 以 RestartSequenceOperation 重新启动现有序列。

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

生成 以 RestartSequenceOperation 重新启动现有序列。

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)

参数

name
String

序列的名称。

startValue
Int64

序列将从其开始的值,默认为 1。

schema
String

包含序列的架构,或使用 null 默认架构。

返回

允许将批注添加到操作的生成器。

注解

有关详细信息和示例 ,请参阅数据库迁移

适用于

RestartSequence(String, Nullable<Int64>, String)

Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs

生成 以 RestartSequenceOperation 重新启动现有序列。

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)

参数

name
String

序列的名称。

startValue
Nullable<Int64>

序列将从其开始的值。 如果 null (默认) ,则序列将根据创建期间使用的配置重启。

schema
String

包含序列的架构,或使用 null 默认架构。

返回

允许将批注添加到操作的生成器。

注解

有关详细信息和示例 ,请参阅数据库迁移

适用于