Why is setting the navigation property to null setting the foreignkey property also to null?
I use EFCore 7.0.3. Here is my Entity: [Table(“Common_T230”)] public class Employment { [Column(“F230_ID”)] public int Id { get; set; } [Column(“F230_14”)] public string VehicleNumber { get; set; } public virtual Vehicle Vehicle { get; set; } } and here the definition for the relationship: modelBuilder.Entity<Employment>() .HasOne(e => e.Vehicle) .WithMany() .HasPrincipalKey(e => e.VehicleNumber) .HasForeignKey(e => … Read more