SqlServerEntityTypeBuilderExtensions.UseHistoryTableName Method
Definition
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.
Configures a history table name for the entity mapped to a temporal table.
public static Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionEntityTypeBuilder? UseHistoryTableName (this Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionEntityTypeBuilder entityTypeBuilder, string name, bool fromDataAnnotation = false);
static member UseHistoryTableName : Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionEntityTypeBuilder * string * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionEntityTypeBuilder
<Extension()>
Public Function UseHistoryTableName (entityTypeBuilder As IConventionEntityTypeBuilder, name As String, Optional fromDataAnnotation As Boolean = false) As IConventionEntityTypeBuilder
Parameters
- entityTypeBuilder
- IConventionEntityTypeBuilder
The builder for the entity being configured.
- name
- String
The name of the history table.
- 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 Using SQL Server temporal tables with EF Core for more information and examples.
Applies to
Entity Framework