RelationalModelExtensions.AddSequence Method

Definition

Overloads

AddSequence(IMutableModel, String, String)

Either returns the existing IMutableSequence with the given name in the given schema or creates a new sequence with the given name and schema.

AddSequence(IConventionModel, String, String, Boolean)

Either returns the existing IMutableSequence with the given name in the given schema or creates a new sequence with the given name and schema.

AddSequence(IMutableModel, String, String)

Either returns the existing IMutableSequence with the given name in the given schema or creates a new sequence with the given name and schema.

public static Microsoft.EntityFrameworkCore.Metadata.IMutableSequence AddSequence (this Microsoft.EntityFrameworkCore.Metadata.IMutableModel model, string name, string schema = default);
public static Microsoft.EntityFrameworkCore.Metadata.IMutableSequence AddSequence (this Microsoft.EntityFrameworkCore.Metadata.IMutableModel model, string name, string? schema = default);
static member AddSequence : Microsoft.EntityFrameworkCore.Metadata.IMutableModel * string * string -> Microsoft.EntityFrameworkCore.Metadata.IMutableSequence
<Extension()>
Public Function AddSequence (model As IMutableModel, name As String, Optional schema As String = Nothing) As IMutableSequence

Parameters

model
IMutableModel

The model to add the sequence to.

name
String

The sequence name.

schema
String

The schema name, or null to use the default schema.

Returns

The sequence.

Applies to

AddSequence(IConventionModel, String, String, Boolean)

Either returns the existing IMutableSequence with the given name in the given schema or creates a new sequence with the given name and schema.

public static Microsoft.EntityFrameworkCore.Metadata.IConventionSequence AddSequence (this Microsoft.EntityFrameworkCore.Metadata.IConventionModel model, string name, string schema = default, bool fromDataAnnotation = false);
public static Microsoft.EntityFrameworkCore.Metadata.IConventionSequence? AddSequence (this Microsoft.EntityFrameworkCore.Metadata.IConventionModel model, string name, string? schema = default, bool fromDataAnnotation = false);
static member AddSequence : Microsoft.EntityFrameworkCore.Metadata.IConventionModel * string * string * bool -> Microsoft.EntityFrameworkCore.Metadata.IConventionSequence
<Extension()>
Public Function AddSequence (model As IConventionModel, name As String, Optional schema As String = Nothing, Optional fromDataAnnotation As Boolean = false) As IConventionSequence

Parameters

model
IConventionModel

The model to add the sequence to.

name
String

The sequence name.

schema
String

The schema name, or null to use the default schema.

fromDataAnnotation
Boolean

Indicates whether the configuration was specified using a data annotation.

Returns

The sequence.

Applies to