共用方式為


SqlServerModelBuilderExtensions.ForSqlServerHasHiLoSequence 方法

定義

警告

Use HasHiLoSequence

設定用於 hi-lo 模式的資料庫順序,以在鎖定SQL Server時產生標示為 OnAdd 的索引鍵屬性值。

[System.Obsolete("Use HasHiLoSequence")]
public static Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionSequenceBuilder ForSqlServerHasHiLoSequence (this Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionModelBuilder modelBuilder, string name, string schema, bool fromDataAnnotation = false);
[<System.Obsolete("Use HasHiLoSequence")>]
static member ForSqlServerHasHiLoSequence : Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionModelBuilder * string * string * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionSequenceBuilder
<Extension()>
Public Function ForSqlServerHasHiLoSequence (modelBuilder As IConventionModelBuilder, name As String, schema As String, Optional fromDataAnnotation As Boolean = false) As IConventionSequenceBuilder

參數

modelBuilder
IConventionModelBuilder

模型產生器。

name
String

序列的名稱。

schema
String

序列的架構。

fromDataAnnotation
Boolean

指出是否使用資料批註來指定組態。

傳回

進一步設定序列的建立器。

屬性

適用於