You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have 2 entities: root (Foo) and chidden (Bar) that can be in circular dependency between each other. Tring to delete root case exception:
Unable to save changes because a circular dependency was detected in the data to be saved: 'Bar [Deleted] ForeignKeyConstraint { 'BarId' } <-
Bar [Deleted] ForeignKeyConstraint { 'BarId' } <-
Bar [Deleted]
If Bars is not included or will be detached it works, database is able to cascade delete Bars itself.
I expect that EF will delete circular dependencies in this case in the same way as datebase.
Include provider and version information
EF Core version: 8.0.6
Database provider: (Npgsql.EntityFrameworkCore.PostgreSQL 8.0.4)
Target framework: (.NET 8.0)
Operating system: Windows 10
IDE: (eVisual Studio 2022 17.4)
The text was updated successfully, but these errors were encountered:
I have 2 entities: root (Foo) and chidden (Bar) that can be in circular dependency between each other. Tring to delete root case exception:
Minimal reproducible example:
Main:
If Bars is not included or will be detached it works, database is able to cascade delete Bars itself.
I expect that EF will delete circular dependencies in this case in the same way as datebase.
Include provider and version information
EF Core version: 8.0.6
Database provider: (Npgsql.EntityFrameworkCore.PostgreSQL 8.0.4)
Target framework: (.NET 8.0)
Operating system: Windows 10
IDE: (eVisual Studio 2022 17.4)
The text was updated successfully, but these errors were encountered: