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

RevEng: Do not generate ValueGenerated.Never for key columns with default values #5428

Closed
lajones opened this issue May 19, 2016 · 2 comments
Assignees
Labels
closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. providers-beware type-bug
Milestone

Comments

@lajones
Copy link
Contributor

lajones commented May 19, 2016

See #5366. For the SQL Server Scaffolding provider we currently generate ValueGenerated.Never for single integer or Guid key columns unless they are marked as IDENTITY columns. See https://github.com/aspnet/EntityFramework/blob/dev/src/Microsoft.EntityFrameworkCore.SqlServer.Design/Internal/SqlServerScaffoldingModelFactory.cs#L92. We need to also not generate ValueGenerated.Never for the same key columns if the ColumnModel has non-null ValueGenerated or DefaultValue.

@lajones
Copy link
Contributor Author

lajones commented May 26, 2016

Fix checked in with 552d6ec.

@lajones
Copy link
Contributor Author

lajones commented May 26, 2016

Adding the providers-beware tag just in case any provider out there is re-using this code.

@ajcvickers ajcvickers added the closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. label Oct 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. providers-beware type-bug
Projects
None yet
Development

No branches or pull requests

3 participants