Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I created a 2008 native database and I have the structures in place but need to load data from a 2005 backup.

share|improve this question
add comment

3 Answers

Restore the 2005 backup as a different database, then use a tool like Red-Gate SQL Compare to copy the data. Once you're happy, drop the restored copy of the 2005 data.

share|improve this answer
add comment

If you have a tool like Redgate's SQL Virtual Restore you can access the database inside the backup without restoring it, just mounting the backup as a real live db.

If not, after restoring it (it will work and will be upgraded as SQL 2008 db), if the structure of the tables is identical, then you can easily use Management Studio's Import and Export wizard to copy the data. You'll need just to point between the source and the destination of your copy operation and the wizard will build an SSIS package (can be saved and reused later) that will do everything for you.

In case the structure of the tables is not the same between the two databases, than you'll need to do your own custom scripts to do that (to map between tables..to cast necessary types).

share|improve this answer
add comment

Is your new structure different of the structure in SQL Server 2005? You may restore the backup entirely, there is no need to create first the structure and then load the data.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.