Entity Framework Core Navigation Property vs Foreign Key Property — FIGHT!

Suppose we have an entity A that has a direct, 1:1, relationship with entity B. So… What happens if we try to assign two different Bs to an A like this? b1 wins. A.B is set to b1 and A.BId is set to b1.Id. How did I know that? I wrong a bunch of unit […]

Scroll Up