This is a migrated thread and some comments may be shown as answers.

Issue With Identity on Entity Update

1 Answer 40 Views
Design Time (Visual Designer & Tools)
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Brian Mains
Top achievements
Rank 1
Brian Mains asked on 04 Dec 2012, 07:49 PM
Hello,

When I create a new table in SQL Server, with the first column setup as the primary key identity, OpenAccess brings the entity in, sets the Identity flag on the primary key column to true, and sets the Identity Mechanism as DatabaseServerCalculated.  But for some reason, when you create the table without the identity specified, then later alter the table to add an identity, on update of that entity using OpenAccess's "Update from Database" option, the Identity property is set to true, but the Identity Mechanism is not changed, so I have to manually switch the value to DatabaseServerCalculated (otherwise an error occurs).

Why would that be?  I am using custom templates with some modifications, and chose the attribute approach.

Thanks.

1 Answer, 1 is accepted

Sort by
0
Dimitar Tachev
Telerik team
answered on 07 Dec 2012, 03:49 PM
Hi Brian,

I am sorry for the inconvenience caused. 

Unfortunately this is a known issue which is already in our ”to do” list and you may see the fix included in a future version of OpenAccess ORM.

Greetings,
Dimitar Tachev
the Telerik team
Telerik OpenAccess ORM Meets ASP.NET Web API. Read more.
Tags
Design Time (Visual Designer & Tools)
Asked by
Brian Mains
Top achievements
Rank 1
Answers by
Dimitar Tachev
Telerik team
Share this question
or