Saturday, October 23, 2010
Identity Key in Entity Framework
we have a sql table with a composite key , and later on we decided to use, an Identity key so altered the table to include a new identity column (we still kept the composite key), now after re-generating the edmx, the entitycreate method was expecting an ID to be passed, but this was supposed to be autogenerated, did not have enough time to debug the issue, but after searching the net for sometime i found that you have to pass an id (can be any int), to the create method as it complains and the savechanges ovverides it with an appropriate id value, i have a todo on that and hopefully i will update regarding the issue in the future.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment