Afficher en anglais

Partage via


OwnedNavigationBuilder.HasIndex Method

Definition

Overloads

HasIndex(String[], String)

Configures an index on the specified properties and with the given name. If there is an existing index on the given list of properties and with the given name, then the existing index will be returned for configuration.

HasIndex(String[])

Configures an index on the specified properties. If there is an existing index on the given set of properties, then the existing index will be returned for configuration.

HasIndex(String[], String)

Source:
OwnedNavigationBuilder.cs

Configures an index on the specified properties and with the given name. If there is an existing index on the given list of properties and with the given name, then the existing index will be returned for configuration.

C#
public virtual Microsoft.EntityFrameworkCore.Metadata.Builders.IndexBuilder HasIndex (string[] propertyNames, string name);

Parameters

propertyNames
String[]

The names of the properties that make up the index.

name
String

The name to assign to the index.

Returns

An object that can be used to configure the index.

Applies to

Entity Framework Core 9.0
Produit Versions
Entity Framework Core 9.0

HasIndex(String[])

Source:
OwnedNavigationBuilder.cs
Source:
OwnedNavigationBuilder.cs
Source:
OwnedNavigationBuilder.cs
Source:
OwnedNavigationBuilder.cs
Source:
OwnedNavigationBuilder.cs
Source:
OwnedNavigationBuilder.cs
Source:
OwnedNavigationBuilder.cs

Configures an index on the specified properties. If there is an existing index on the given set of properties, then the existing index will be returned for configuration.

C#
public virtual Microsoft.EntityFrameworkCore.Metadata.Builders.IndexBuilder HasIndex (params string[] propertyNames);

Parameters

propertyNames
String[]

The names of the properties that make up the index.

Returns

An object that can be used to configure the index.

Applies to

Entity Framework Core 9.0 et autres versions
Produit Versions
Entity Framework Core 3.0, 3.1, 5.0, 6.0, 7.0, 8.0, 9.0