dotnet / dotnet/efcore

Consider scaffolding default value configuration even when it's the default CLR type

Open
#37,381 7 comments 0 reactions 0 assignees View on GitHub
area-scaffolding
Dominant language
C#
Stars
14.8k
Forks
3.4k
PR merge metrics
PR metrics pending

Description

We currently have [code](https://github.com/dotnet/efcore/pull/30927/changes#diff-9995d5a8e30e4189fdb601342142612479f1fbb25ca5682e69d63a08379e03ef) in the reverse engineering template which skips scaffolding default value config when the default value is the CLR default. We can consider removing that, always scaffolding default value config if there's a default value in the database. That would provide a more faithful model, improve roundtripability of the database schema, etc.

Raised by @sciutand in https://github.com/npgsql/efcore.pg/issues/3683

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.