Friday, March 9, 2012

Identity field settings not copied by Import Wizard (2005)

It appears that when you use the import/export wizard from within Microsoft SQL Server Managment Studio, the identity attributes of the table being copied are not transferred. For example, say the source table has a column

[ref] [int] IDENTITY ( 1 , 1 ) NOT NULL,

When the import wizard is done the destination table will have a column named ref, but will not be an identity column. The column definition will be

[ref] [int] NOT NULL,

instead. Is there a way to change this behavior somewhere in the gui? When doing the import, the only options seems to be 'Enable Identity Insert', but checking this does not affect the definition of the column.

-Eric

Hi Eric,
Did you ever find a solution to this? Do you know if this is due to a bug that is being addressed in sp1? Thanks.
Ryan
|||

I too have noticed this problem. I've installed SP1 and ticked the relevant Identity box but still does not create the Identity Columns.

Please help or sugest a workaround.

Thanks

Mark

|||If these is a copy of a database from one SQl Server to another, then I suggest looking at using the Copy Database Wizard instead of the Import/Export Wizard. The problem you might be hitting is that the IE wizard is generic, it works with any source/dest via OLE DB/ODBC and I am pretty sure that the identity property is not reported through those APIs. If you use Copy Database Wizard it is SQL to SQL only and hence can be more aware.|||If the target DB is SQL 2000, Copy Database is no good.
|||

Did you find any way to copy the identity columns from Sql 2005 to Sql 2000?

Need help ASAP

Thanks

Black.

No comments:

Post a Comment