IReadOnlyEntityType.FindPrimaryKey Method

Definition

Gets primary key for this entity type. Returns null if no primary key is defined.

public Microsoft.EntityFrameworkCore.Metadata.IReadOnlyKey? FindPrimaryKey ();
abstract member FindPrimaryKey : unit -> Microsoft.EntityFrameworkCore.Metadata.IReadOnlyKey
Public Function FindPrimaryKey () As IReadOnlyKey

Returns

The primary key, or null if none is defined.

Applies to