Hello Ness,
this might happen if you use SQL Server 2012.
DataObjects.Net 4.6 utilizes its new features such a native sequences.
There are two possible solutions:
Add ForcedServerVersion
property with value 10.50.1600.1
in your DomainConfiguration
. This forces usage of features available in SQL Server 2008 R2 only.
Manually replace Int32-Generator
table with sequence:
-- Figure out current state of key generator table: current value and increment
select ident_current('Int32-Generator'), ident_incr('Int32-Generator')
-- Drop it to avoid name collisions
drop table [Int32-Generator]
-- Create sequence
create sequence [Int32-Generator]
start with <current+increment>
increment by <increment>
Unfortunately create sequence
statement does not allow parameters for start with
and increment by
expressions. You'll have to cook constants using the above pseudo-code as example.
DataObjects.Net 4.6 provides new OnPrepare()
method in upgrade handlers. This could be used to perform such modifications of the database schema before DataObjects.Net starts upgrade.
answered
Nov 01 '12 at 13:24
Denis Krjuchkov
1793●2●5