Share via


CoreStrings.EntityRequiresKey(Object) Method

Definition

The entity type '{entityType}' requires a primary key to be defined. If you intended to use a keyless entity type, call 'HasNoKey' in 'OnModelCreating'. For more information on keyless entity types, see https://go.microsoft.com/fwlink/?linkid=2141943.

public static string EntityRequiresKey (object entityType);
public static string EntityRequiresKey (object? entityType);
static member EntityRequiresKey : obj -> string
Public Shared Function EntityRequiresKey (entityType As Object) As String

Parameters

entityType
Object

Returns

Applies to