Trying to insert rows, using import, into a table with auto increment
primary key and seeing this error (the insert includes the primary key
because I am wanting to preserve them):
Sequel::DatabaseError:
WIN32OLERuntimeError: (in OLE method `Execute': )
OLE error code:80040E14 in Microsoft OLE DB Provider for ODBC
Drivers
[Microsoft][ODBC SQL Server Driver][SQL Server]Cannot insert
explicit value for identity column in table 'Categories' when
IDENTITY_INSERT is set to OFF.
I have tried to run/execute_ddl("SET IDENTITY_INSERT Categories ON") but it
has no effect. How can I set IDENTITY_INSERT in mssql so the inserts with
the primary key will work?
Thanks,
Michael
--
You received this message because you are subscribed to the Google Groups
"sequel-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/sequel-talk/eb30db63-34d0-4442-b62b-2c414e71b0f0n%40googlegroups.com.