R
Remco
I am using the SET IDENTITY_INSERT command in an SP. However, we need
the table in the command to be in a different database, the name of
which is passed to the SP in a variable.
The command I am using would look like:
EXEC( 'SET IDENTITY_INSERT ' + @dbname + '..tax_transaction ON' )
However, this does not seem to work, as the following INSERT statement
gives the error that IDENTITY_INSERT is set OFF.
Any help is appreciated.
the table in the command to be in a different database, the name of
which is passed to the SP in a variable.
The command I am using would look like:
EXEC( 'SET IDENTITY_INSERT ' + @dbname + '..tax_transaction ON' )
However, this does not seem to work, as the following INSERT statement
gives the error that IDENTITY_INSERT is set OFF.
Any help is appreciated.