Note

Access to this page requires authorization. You can try signing in or .

Access to this page requires authorization. You can try .

SqlServerIndexBuilderExtensions.HasFillFactor Method

Definition

Namespace:
Microsoft.EntityFrameworkCore
Assembly:
Microsoft.EntityFrameworkCore.SqlServer.dll
Package:
Microsoft.EntityFrameworkCore.SqlServer v10.0.0
Package:
Microsoft.EntityFrameworkCore.SqlServer v5.0.0
Package:
Microsoft.EntityFrameworkCore.SqlServer v6.0.0
Package:
Microsoft.EntityFrameworkCore.SqlServer v7.0.0
Package:
Microsoft.EntityFrameworkCore.SqlServer v8.0.0
Package:
Microsoft.EntityFrameworkCore.SqlServer v9.0.0

Important

Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.

Overloads

Name Description
HasFillFactor(IConventionIndexBuilder, Nullable<Int32>, Boolean)

Configures whether the index is created with fill factor option when targeting SQL Server.

HasFillFactor(IndexBuilder, Int32)

Configures whether the index is created with fill factor option when targeting SQL Server.

HasFillFactor<TEntity>(IndexBuilder<TEntity>, Int32)

Configures whether the index is created with fill factor option when targeting SQL Server.

HasFillFactor(IConventionIndexBuilder, Nullable<Int32>, Boolean)

Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs

Configures whether the index is created with fill factor option when targeting SQL Server.

public static Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionIndexBuilder? HasFillFactor(this Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionIndexBuilder indexBuilder, int? fillFactor, bool fromDataAnnotation = false);
public static Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionIndexBuilder HasFillFactor(this Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionIndexBuilder indexBuilder, int? fillFactor, bool fromDataAnnotation = false);
static member HasFillFactor : Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionIndexBuilder * Nullable<int> * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionIndexBuilder
<Extension()>
Public Function HasFillFactor (indexBuilder As IConventionIndexBuilder, fillFactor As Nullable(Of Integer), Optional fromDataAnnotation As Boolean = false) As IConventionIndexBuilder

Parameters

indexBuilder
IConventionIndexBuilder

The builder for the index being configured.

fillFactor
Nullable<Int32>

A value indicating whether the index is created with fill factor option.

fromDataAnnotation
Boolean

Indicates whether the configuration was specified using a data annotation.

Returns

The same builder instance if the configuration was applied, null otherwise.

Remarks

See Modeling entity types and relationships, and Accessing SQL Server and Azure SQL databases with EF Core for more information and examples.

Applies to

HasFillFactor(IndexBuilder, Int32)

Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs

Configures whether the index is created with fill factor option when targeting SQL Server.

public static Microsoft.EntityFrameworkCore.Metadata.Builders.IndexBuilder HasFillFactor(this Microsoft.EntityFrameworkCore.Metadata.Builders.IndexBuilder indexBuilder, int fillFactor);
static member HasFillFactor : Microsoft.EntityFrameworkCore.Metadata.Builders.IndexBuilder * int -> Microsoft.EntityFrameworkCore.Metadata.Builders.IndexBuilder
<Extension()>
Public Function HasFillFactor (indexBuilder As IndexBuilder, fillFactor As Integer) As IndexBuilder

Parameters

indexBuilder
IndexBuilder

The builder for the index being configured.

fillFactor
Int32

A value indicating whether the index is created with fill factor option.

Returns

A builder to further configure the index.

Remarks

See Modeling entity types and relationships, and Accessing SQL Server and Azure SQL databases with EF Core for more information and examples.

Applies to

HasFillFactor<TEntity>(IndexBuilder<TEntity>, Int32)

Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs
Source:
SqlServerIndexBuilderExtensions.cs

Configures whether the index is created with fill factor option when targeting SQL Server.

public static Microsoft.EntityFrameworkCore.Metadata.Builders.IndexBuilder<TEntity> HasFillFactor<TEntity>(this Microsoft.EntityFrameworkCore.Metadata.Builders.IndexBuilder<TEntity> indexBuilder, int fillFactor);
static member HasFillFactor : Microsoft.EntityFrameworkCore.Metadata.Builders.IndexBuilder<'Entity> * int -> Microsoft.EntityFrameworkCore.Metadata.Builders.IndexBuilder<'Entity>
<Extension()>
Public Function HasFillFactor(Of TEntity) (indexBuilder As IndexBuilder(Of TEntity), fillFactor As Integer) As IndexBuilder(Of TEntity)

Type Parameters

TEntity

Parameters

indexBuilder
IndexBuilder<TEntity>

The builder for the index being configured.

fillFactor
Int32

A value indicating whether the index is created with fill factor option.

Returns

IndexBuilder<TEntity>

A builder to further configure the index.

Remarks

See Modeling entity types and relationships, and Accessing SQL Server and Azure SQL databases with EF Core for more information and examples.

Applies to


Feedback

Was this page helpful?