Summary
You can use foreign keys to reference a property other than the primary key without providing a navigation property.
1
You can use the Fluent API to configure the principal key property for the relationship.
1
You can also use foreign keys and navigation properties to create and modify relationships.
2
According to
See more results on Neeva
Summaries from the best pages on the web
Summary
You don't necessarily need to provide a navigation property. You can simply provide a foreign key on one side of the relationship.
If you want the foreign key to reference a property other than the primary key, you can use the Fluent API to configure the principal key property for the relationship.
Relationships - EF Core | Microsoft Docs
microsoft.com
Summary
This article provides an overview of how Entity Framework manages relationships between entities, including how to map and manipulate relationships. It explains how to use foreign keys and navigation properties to create and modify relationships, and provides examples of how to use them to associate related entities with entities. It also provides tips on how to use navigation properties to navigate relationships in both directions.
Relationships, navigation properties, and foreign keys - EF6 | Microsoft Docs
microsoft.com