-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
Metadata: Discovering derived type with self ref relationship before base causes exception #9704
Comments
The base class |
Impact: Self-referencing relationships cause exceptions if a derived type is configured |
Deriving from a self-referencing entity is an important pattern for us. Is there a recommended work around? |
@SpiraMira The workaround is to force the derived type to be discovered last. This could be accomplished in several ways:
|
@AndriySvyryd Thanks for the quick turn-around. This will help. Regards. |
This patch bug is approved for the 2.0.x patch. Please send a PR to the |
Hi, we have a public test feed that you can use to try out the ASP.NET/EF Core 2.0.3 patch! To try out the pre-release patch, please refer to the following guide:
We are looking for feedback on this patch. We'd like to know if you have any issues with this patch by updating your apps and libraries to the latest packages and seeing if it fixes the issues you've had, or if it introduces any new issues. If you have any issues or questions, please reply on this issue to let us know as soon as possible. Thanks, |
I am migrating from .net core 1.1 to 2.0 and I meet a error when I add entityframeworkcore migrations.
I have two models.
And I configured an ApplicationDbContext.
Then I executed
add-migration init
in console. Following error occurredThe trick is that if I change the line
public DbSet<TestCase> TestCases { get; set; }
in ApplicationDbContext topublic DbSet<TestCase> XXXXs { get; set; }
, IT WORKS!Is
TestCases
a reserved word?Thanks,
Karl
The text was updated successfully, but these errors were encountered: