- 에러

Microsoft.EntityFrameworkCore.DbUpdateException: An error occurred while updating the entries. See the inner exception for details. ---> System.Data.SqlClient.SqlException: PRIMARY KEY 제약 조건 'PK_StudioAppLog'을(를) 위반했습니다. 개체 'dbo.StudioAppLog'에 중복 키를 삽입할 수 없습니다. 중복 키 값은 (0)입니다.

문이 종료되었습니다.


 - 해결방법

[Key]

[DatabaseGenerated(DatabaseGeneratedOption.Identity)]


해당 모델안의 변수에 위의 식별자 추가

Posted by moyaiori
,