Is it showing any entry no. in error? Probably it is resetting as you are changing the Primary key. Delete the data from table, if it is test db, and start doing with above code again.
↧