efcore/EFCore.NamingConventions

Some foreign keys are appended by temp_id(n)

7heViking opened this issue · 0 comments

There is a problem regarding naming of foreign keys at some occurrences. I do not see the reason though. The result is that the foreign keys will be postfixed by a _temp_id(n) in the name. Some examples are:

  1. temp
  2. _temp_id1
  3. _temp_id2

The database snapshot will have the following definition:
.HasConstraintName("fk_schema_table_property_temp_id1");

There is another report of the same bug type on stackoverflow here: https://stackoverflow.com/questions/73362141/ef-core-6-generates-foreign-keys-with-temp-idn