Answer the question
In order to leave comments, you need to log in
Why is ID ignored?
Hello.
The ID is ignored when added to the table.
Table:
Add code:
Constantly trying to add a user with ID'om = 0, what's the problem? (I first thought about int ?, but no, it doesn’t even work with int).
The error is something like this: Duplicate entry '0' for key 'PRIMARY'
Answer the question
In order to leave comments, you need to log in
[DatabaseGenerated(DatabaseGeneratedOption.None)]
public int ID { get; set; }
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question