Database porting to SQL Server 2008r2 "3145 error" what to do

Source: Internet
Author: User
Tags sql error

"3145 errors" encountered in SQL Server 2000 database porting to SQL Server 2008R2 database server and Solutions

After one weeks of hard work, the TFS server was finally installed and assigned accounts and mailboxes to each team member. However, some of the data in the old machine needs to be backed up into the new machine, which is a bit of a problem when porting a forum that uses Dvbbs, and is recorded as follows, in case of a search, and hopefully to help others.

Since the forum has been running for some time, including important information such as company registered users, related discussion shares, it needs to be ported to the newly installed TFS server machine and exposed to public access. The old machine was installed with SQL Server 2000, and after the Forum database was backed up, the following 3145 errors occurred during the restore on the SQL Server 2008R2 database:

The database backup in the backup set is different from the existing ' xxx ' database.

It has always been assumed that the SQL Server database is compatible, how can there be such a problem? However, after checking, determine that two database servers are not a problem, and the Forum's backup on the original database server can restore normal. No way, change it, it is still the same error to change the new database on SQL Server 2008R2 to SQL Server 2000 format and then try to restore. Looked up on the Internet, said the method, tried a lot, one of them is "backup set of database backup and existing database different SQL error:3145 solution", provides the following command method:

1. Create a new database with the same name as an existing database

2. Run the following statement in the query window:

Use master

Restore Database AdventureWorks from disk = ' E:databasebackupadventureworks.bak '

With replace, move N ' adventureworks_data ' to n ' c:program filesmicrosoft SQL servermssql.5mssqldataadventureworks.mdf ', Move N ' Adventureworks_log ' to n ' c:program filesmicrosoft SQL servermssql.5mssqldataadventureworks_log.ldf '

From the statement point of view, and in the graphical interface of the operation is the same, but the result is the success of the statement, the graphical interface how to pass.

A similar approach was seen on other web pages, and there were a number of successful fixes to this error, but on the SQL Server 2008R2 server, there was no way to properly back up, and there were no other ways to solve the problem of restoring backups on SQL Server 2008r2.

However, by separating the Forum database from the old SQL Server 2000 and attaching it to SQL Server 2008R2, the data is fully restored!

It's not clear why you can do this on SQL Server 2005, but you cannot restore backups in SQL Server 2008r2. However, it is good to use separate and additional methods to successfully migrate the forum. Write it down here as a reference.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.