How to disable identity (auto increment) in .NET Core code first approach?

Forums .NET CoreHow to disable identity (auto increment) in .NET Core code first approach?
Staff asked 3 years ago

Answers (1)

Add Answer
Staff answered 2 years ago
[System.ComponentModel.DataAnnotations.KeyAttribute()]
[System.ComponentModel.DataAnnotations.DatabaseGenerated(System.ComponentModel.DataAnnotations.DatabaseGeneratedOption.None)]

 

Subscribe

Select Categories