CreateTableBuilder<TColumns>.CheckConstraint(String, String) Methode

Definition

Konfiguriert eine Überprüfungseinschränkung für die Tabelle.

public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateCheckConstraintOperation> CheckConstraint (string name, string sql);
public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.AddCheckConstraintOperation> CheckConstraint (string name, string sql);
abstract member CheckConstraint : string * string -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateCheckConstraintOperation>
override this.CheckConstraint : string * string -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateCheckConstraintOperation>
abstract member CheckConstraint : string * string -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.AddCheckConstraintOperation>
override this.CheckConstraint : string * string -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.AddCheckConstraintOperation>
Public Overridable Function CheckConstraint (name As String, sql As String) As OperationBuilder(Of CreateCheckConstraintOperation)
Public Overridable Function CheckConstraint (name As String, sql As String) As OperationBuilder(Of AddCheckConstraintOperation)

Parameter

name
String

Der Name der Einschränkung.

sql
String

Der sql-Ausdruck, der in der CHECK-Einschränkung verwendet wird.

Gibt zurück

Derselbe Generator, sodass mehrere Aufrufe verkettet werden können.

Gilt für: