cannot update identity column in Entity Framework Core

前端 未结 7 685
感情败类
感情败类 2021-01-04 00:52

I\'ve added a separate Identification to the AspNetUsers table called NumericId that will serve along with the GUID like ID that ASP has for default.

I\'ve added the

7条回答
  •  心在旅途
    2021-01-04 01:02

    Solution for asp.net core 3.1

    modelBuilder.Entity().Property(u => u.Property).Metadata.SetAfterSaveBehavior(PropertySaveBehavior.Ignore);
    

提交回复
热议问题