SSIS to import data to SQL Server 2005 from another SQL Server 2005 Database
Hi all, I am have created a new empty SQL Server 2005 DB using script from an existing SQL Server 2005 DB with tables having foreign key relationships. I need to transfer data from the master tables of the old DB to the new DB. When I use the Import/Export Wizard the task fails because of the foreign key issue. I want the transfer of the data from selected tables in a sequential order so that the foreign key constraints are met. I would like to know the easiest way to do this considering the fact that I have got numerous tables to deal with. Any help is much appreciated.
Easiest way? Drop the FK relationships, move the data, recreate the FKs. Or restore the new database from a backup of the old, and remove the data you don't want. There's probably something in SSIS that'll do the job too.