guid primary key issues with EF
Posted: Thu 07 Oct 2010 00:16
When I use Entity Framework and SQLite provider with a PK column that is of type guid I get an error even with a simple table.
I get an error stating that the Primary Key and the Property do not match. Full error message including below and I have included a link to the source code and database that is causing the issue.
I can see nothing wrong with what I have done and it looks like an issue.
Any help would be appreciated
http://dl.dropbox.com/u/2292728/TCT/Dev ... KIssue.zip
Error:
The value of a property that is part of an object's key does not match the corresponding property value stored in the ObjectContext. This can occur if properties that are part of the key return inconsistent or incorrect values or if DetectChanges is not called after changes are made to a property that is part of the key.
I get an error stating that the Primary Key and the Property do not match. Full error message including below and I have included a link to the source code and database that is causing the issue.
I can see nothing wrong with what I have done and it looks like an issue.
Any help would be appreciated
http://dl.dropbox.com/u/2292728/TCT/Dev ... KIssue.zip
Error:
The value of a property that is part of an object's key does not match the corresponding property value stored in the ObjectContext. This can occur if properties that are part of the key return inconsistent or incorrect values or if DetectChanges is not called after changes are made to a property that is part of the key.