Compartir a través de


MigrationBuilder.CreateIndex Método

Definición

Sobrecargas

CreateIndex(String, String, String[], String, Boolean, String, Boolean[])

Crea un CreateIndexOperation objeto para crear un nuevo índice compuesto (varias columnas).

CreateIndex(String, String, String, String, Boolean, String, Boolean[])

Crea un CreateIndexOperation objeto para crear un nuevo índice.

CreateIndex(String, String, String[], String, Boolean, String)

Crea un CreateIndexOperation objeto para crear un nuevo índice compuesto (varias columnas).

CreateIndex(String, String, String[], String, Boolean)
CreateIndex(String, String, String, String, Boolean)
CreateIndex(String, String, String, String, Boolean, String)

Crea un CreateIndexOperation objeto para crear un nuevo índice.

CreateIndex(String, String, String[], String, Boolean, String, Boolean[])

Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs

Crea un CreateIndexOperation objeto para crear un nuevo índice compuesto (varias columnas).

public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation> CreateIndex (string name, string table, string[] columns, string? schema = default, bool unique = false, string? filter = default, bool[]? descending = default);
abstract member CreateIndex : string * string * string[] * string * bool * string * bool[] -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation>
override this.CreateIndex : string * string * string[] * string * bool * string * bool[] -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation>
Public Overridable Function CreateIndex (name As String, table As String, columns As String(), Optional schema As String = Nothing, Optional unique As Boolean = false, Optional filter As String = Nothing, Optional descending As Boolean() = Nothing) As OperationBuilder(Of CreateIndexOperation)

Parámetros

name
String

Nombre de índice.

table
String

Tabla que contiene el índice.

columns
String[]

Lista ordenada de columnas que se indexan.

schema
String

Esquema que contiene la tabla o null para usar el esquema predeterminado.

unique
Boolean

Indica si el índice aplica o no unicidad.

filter
String

Filtro que se va a aplicar al índice o null sin filtro.

descending
Boolean[]

Un conjunto de valores que indica si cada columna de índice correspondiente tiene un criterio de ordenación descendente. Si nulles , todas las columnas tendrán un orden ascendente.

Devoluciones

Generador para permitir que las anotaciones se agreguen a la operación.

Comentarios

Consulte Migraciones de bases de datos para obtener más información y ejemplos.

Se aplica a

CreateIndex(String, String, String, String, Boolean, String, Boolean[])

Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs

Crea un CreateIndexOperation objeto para crear un nuevo índice.

public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation> CreateIndex (string name, string table, string column, string? schema = default, bool unique = false, string? filter = default, bool[]? descending = default);
abstract member CreateIndex : string * string * string * string * bool * string * bool[] -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation>
override this.CreateIndex : string * string * string * string * bool * string * bool[] -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation>
Public Overridable Function CreateIndex (name As String, table As String, column As String, Optional schema As String = Nothing, Optional unique As Boolean = false, Optional filter As String = Nothing, Optional descending As Boolean() = Nothing) As OperationBuilder(Of CreateIndexOperation)

Parámetros

name
String

Nombre de índice.

table
String

Tabla que contiene el índice.

column
String

Columna indizada.

schema
String

Esquema que contiene la tabla o null para usar el esquema predeterminado.

unique
Boolean

Indica si el índice aplica o no unicidad.

filter
String

Filtro que se va a aplicar al índice o null sin filtro.

descending
Boolean[]

Un conjunto de valores que indica si cada columna de índice correspondiente tiene un criterio de ordenación descendente. Si nulles , todas las columnas tendrán un orden ascendente. Si una matriz vacía, todas las columnas tendrán un orden descendente.

Devoluciones

Generador para permitir que las anotaciones se agreguen a la operación.

Comentarios

Consulte Migraciones de bases de datos para obtener más información y ejemplos.

Se aplica a

CreateIndex(String, String, String[], String, Boolean, String)

Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs

Crea un CreateIndexOperation objeto para crear un nuevo índice compuesto (varias columnas).

public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation> CreateIndex (string name, string table, string[] columns, string schema = default, bool unique = false, string filter = default);
public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation> CreateIndex (string name, string table, string[] columns, string? schema = default, bool unique = false, string? filter = default);
abstract member CreateIndex : string * string * string[] * string * bool * string -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation>
override this.CreateIndex : string * string * string[] * string * bool * string -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation>
Public Overridable Function CreateIndex (name As String, table As String, columns As String(), Optional schema As String = Nothing, Optional unique As Boolean = false, Optional filter As String = Nothing) As OperationBuilder(Of CreateIndexOperation)

Parámetros

name
String

Nombre de índice.

table
String

Tabla que contiene el índice.

columns
String[]

Lista ordenada de columnas que se indexan.

schema
String

Esquema que contiene la tabla o null para usar el esquema predeterminado.

unique
Boolean

Indica si el índice aplica o no unicidad.

filter
String

Filtro que se va a aplicar al índice o null sin filtro.

Devoluciones

Generador para permitir que las anotaciones se agreguen a la operación.

Comentarios

Consulte Migraciones de bases de datos para obtener más información.

Se aplica a

CreateIndex(String, String, String[], String, Boolean)

public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation> CreateIndex (string name, string table, string[] columns, string schema = default, bool unique = false);
abstract member CreateIndex : string * string * string[] * string * bool -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation>
override this.CreateIndex : string * string * string[] * string * bool -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation>
Public Overridable Function CreateIndex (name As String, table As String, columns As String(), Optional schema As String = Nothing, Optional unique As Boolean = false) As OperationBuilder(Of CreateIndexOperation)

Parámetros

name
String
table
String
columns
String[]
schema
String
unique
Boolean

Devoluciones

Se aplica a

CreateIndex(String, String, String, String, Boolean)

public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation> CreateIndex (string name, string table, string column, string schema = default, bool unique = false);
abstract member CreateIndex : string * string * string * string * bool -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation>
override this.CreateIndex : string * string * string * string * bool -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation>
Public Overridable Function CreateIndex (name As String, table As String, column As String, Optional schema As String = Nothing, Optional unique As Boolean = false) As OperationBuilder(Of CreateIndexOperation)

Parámetros

name
String
table
String
column
String
schema
String
unique
Boolean

Devoluciones

Se aplica a

CreateIndex(String, String, String, String, Boolean, String)

Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs
Source:
MigrationBuilder.cs

Crea un CreateIndexOperation objeto para crear un nuevo índice.

public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation> CreateIndex (string name, string table, string column, string schema = default, bool unique = false, string filter = default);
public virtual Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation> CreateIndex (string name, string table, string column, string? schema = default, bool unique = false, string? filter = default);
abstract member CreateIndex : string * string * string * string * bool * string -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation>
override this.CreateIndex : string * string * string * string * bool * string -> Microsoft.EntityFrameworkCore.Migrations.Operations.Builders.OperationBuilder<Microsoft.EntityFrameworkCore.Migrations.Operations.CreateIndexOperation>
Public Overridable Function CreateIndex (name As String, table As String, column As String, Optional schema As String = Nothing, Optional unique As Boolean = false, Optional filter As String = Nothing) As OperationBuilder(Of CreateIndexOperation)

Parámetros

name
String

Nombre de índice.

table
String

Tabla que contiene el índice.

column
String

Columna indizada.

schema
String

Esquema que contiene la tabla o null para usar el esquema predeterminado.

unique
Boolean

Indica si el índice aplica o no unicidad.

filter
String

Filtro que se va a aplicar al índice o null sin filtro.

Devoluciones

Generador para permitir que las anotaciones se agreguen a la operación.

Comentarios

Consulte Migraciones de bases de datos para obtener más información.

Se aplica a