ADO.NET Entity Framework and identity columns

前端 未结 10 1517
甜味超标
甜味超标 2020-12-29 18:06

Is the Entity Framework aware of identity columns?

I am using SQL Server 2005 Express Edition and have several tables where the primary key is an identity column. w

10条回答
  •  感情败类
    2020-12-29 18:33

    What worked for me was setting the StoreGeneratedPattern to None, when it was an Identity column. Now it all works consistently. The main problem with this is editing the models is an extreme chore if you have many models.

提交回复
热议问题