SQL 2005 Can't Restore Backup to New Database

cgaDesign
cgaDesign used Ask the Experts™
on
I'm trying to Restore a Database Backup to a new database. If I create a new empty DB it says the backup is a different database.  If I only restore to a new name (w/o a new database, it tries to restore to the original database.  Need this right away ... how do I do this in Mgt Studio ?
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
SQL Server DBA & Architect, EE Solution Guide
Awarded 2009
Distinguished Expert 2018
Commented:
If you try to restore wizard using SSMS, then go to options page and choose Overwrite the Existing database option to get it fixed.

Or

Drop your existing new database created.
Right Click Database in SSMS and then choose Restore database and provide a new database name there which would restore fine..
AneeshDatabase Consultant
Top Expert 2009
Commented:
Make a copy of a database using BACKUP and RESTORE
This example uses both the BACKUP and RESTORE statements to make a copy of the Northwind database. The MOVE statement causes the data and log file to be restored to the specified locations. The RESTORE FILELISTONLY statement is used to determine the number and names of the files in the database being restored. The new copy of the database is named TestDB. For more information, see RESTORE FILELISTONLY.

BACKUP DATABASE Northwind
   TO DISK = 'c:\Northwind.bak'
RESTORE FILELISTONLY
   FROM DISK = 'c:\Northwind.bak'
RESTORE DATABASE TestDB
   FROM DISK = 'c:\Northwind.bak'
   WITH MOVE 'Northwind' TO 'c:\test\testdb.mdf',
   MOVE 'Northwind_log' TO 'c:\test\testdb.ldf'
GO

Author

Commented:
Thanks folks for your quick response.  Here is the trick that I luckily discovered:  
I restored from Device ... selected the .BAK file
I entered the name of a new database (not created)
Did NOT click on Overwrite in Options ( too scary )
Went to Options, "Restore Database Files As" ... and renamed the MDF and LDF filenames to my new database name. (THAT WAS THE TRICK I was missing)

Thanks much,
Steve
Build an E-Commerce Site with Angular 5

Learn how to build an E-Commerce site with Angular 5, a JavaScript framework used by developers to build web, desktop, and mobile applications.

Commented:
Steve...Did the steps mentioned by you solved your problem?

Author

Commented:
Yes ... my steps did indeed work.
Raja Jegan RSQL Server DBA & Architect, EE Solution Guide
Awarded 2009
Distinguished Expert 2018

Commented:
>> Yes ... my steps did indeed work.

Does that confirm whether your issue is resolved..
Kindly close the question accordingly if it is resolved.

Author

Commented:
Comments were good, but I solved the problem myself.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial