Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Also mention NRTs in a 5.0 breaking change #3468

Merged
merged 2 commits into from
Oct 9, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: Breaking changes in EF Core 5.0 - EF Core
description: Complete list of breaking changes introduced in Entity Framework Core 5.0
author: bricelam
ms.date: 11/07/2020
ms.date: 10/08/2021
uid: core/what-is-new/ef-core-5.0/breaking-changes
---

Expand All @@ -17,7 +17,7 @@ The following API and behavior changes have the potential to break existing appl
| [EF Core 5.0 does not support .NET Framework](#netstandard21) | Medium |
| [IProperty.GetColumnName() is now obsolete](#getcolumnname-obsolete) | Medium |
| [Precision and scale are required for decimals](#decimals) | Medium |
| [Required on the navigation from principal to dependent has different semantics](#required-dependent) | Medium |
| [Required or non-nullable navigation from principal to dependent has different semantics](#required-dependent) | Medium |
| [Defining query is replaced with provider-specific methods](#defining-query) | Medium |
| [Non-null reference navigations are not overwritten by queries](#nonnullreferences) | Medium |
| [ToView() is treated differently by migrations](#toview) | Medium |
Expand Down Expand Up @@ -130,13 +130,13 @@ Or use `HasPrecision` in the model building APIs. For example:

<a name="required-dependent"></a>

### Required on the navigation from principal to dependent has different semantics
### Required or non-nullable navigation from principal to dependent has different semantics

[Tracking Issue #17286](https://github.com/dotnet/efcore/issues/17286)

#### Old behavior

Only the navigations to principal could be configured as required. Therefore using `RequiredAttribute` on the navigation to the dependent (the entity containing the foreign key) would instead create the foreign key on the defining entity type.
Only the navigations to principal could be configured as required. Therefore using `RequiredAttribute` on the navigation to the dependent (the entity containing the foreign key) or marking it as non-nullable would instead create the foreign key on the defining entity type.
AndriySvyryd marked this conversation as resolved.
Show resolved Hide resolved

#### New behavior

Expand Down