Error when trying to restore SQL 2000 db to SQL 2008

I get this error when trying to restore a 2000 db to 2008:

System.Data.SqlClient.SqlError: File 'E:\Program Files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\DATA\NGTest.mdf' is claimed by 'NextGen_Core_Data_1'(4) and 'NextGen_System_Data'(1). The WITH MOVE clause can be used to relocate one or more files. (Microsoft.SqlServer.Smo)
biotecAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Mark WillsTopic AdvisorCommented:
Sounds like you have a few partitions involved, or filesystems...

Need to include the "MOVE" command, or if using SSMS, then overwrite the backup file names to be what they really are for the target database being restored into, and click the overwrite existing...

or use SQL :

RESTORE DATABASE TestDB
   FROM AdventureWorksBackups
   WITH  MOVE 'AdventureWorks_Data' TO 'C:\MySQLServer\testdb.mdf',
              MOVE 'AdventureWorks_Log' TO 'C:\MySQLServer\testdb.ldf';
GO
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
biotecAuthor Commented:
Msg 3234, Level 16, State 2, Line 1
Logical file 'NGTest_Data' is not part of database 'NGTest'. Use RESTORE FILELISTONLY to list the logical file names.
Msg 3013, Level 16, State 1, Line 1
RESTORE DATABASE is terminating abnormally.
0
Mark WillsTopic AdvisorCommented:
The logical filename needs to be the one on the original backup...

Might be best to use SSMS (sql server management studio)

from the top...

in windows explorer (all on the server), create a new folder C:\EE, then in SSMS, create a new database call it EE_TEST put files on C:\EE  -- SSMS will create the names for you - they should be EE_TEST.mdf and EE_TEST_log.ldf go and check in Windows explorer.

Now right click on that database, go into tasks, then restore, then files. A new pop-up window should appear. Select "From Device" then go into the browse function and ADD your backup file to the empty screen, push OK and you should be back on the Restore window. That file name should appear in the list, and you now need to select it by clicking on the check box.

Towards the top left of the restore window, there should be a folder called "Options" - click on it and you should now see some details about the backup you have chosen. Now, select the radio button option against overwrite the existing database. Then click on the button next to the "restore as" column. browse to and select c:\ee\ee_test.mdf and same thing for the next row (being the log file). the press OK down the bottom... and it should start restoring.
0
biotecAuthor Commented:
I figured it out. I wasn't using the logical names that the filelistonly gave me.
0
biotecAuthor Commented:
So from SSMS if I had just created a blank db with the same name I might not have had to use the query to restore the db?
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft SQL Server 2008

From novice to tech pro — start learning today.