Search

Physical File Names in the Database Restore Wizard Should Default to Database Name by Matthanielcm

Closed
as Fixed Help for as Fixed

2
0
Sign in
to vote
Type: Bug
ID: 777310
Opened: 1/23/2013 1:59:38 PM
Access Restriction: Public
0
Workaround(s)
1
User(s) can reproduce this bug
In SQL Server Management Studio versions 2008 R2 and previous, the database name was always used as the default in the Physical File Name in the Restore database wizard, which was correct for our workflow. In SQL Server 2012, this appears to no longer be the case. Now, the name of the original database appears to be the default file name, which causes us to have to change the file names manually to the correct database name when restoring a new database. If these changes are not made, then there are either errors in the restore process or the Physical File Name of the database and log files are incorrect, which means our DBAs have to constantly make sure that the file names are correct on the database server, which involves taking databases offline if they are not.
Details (expand)

Product Language

English

Version

SQL Server 2012 - Developer Edition

Category

Tools (SSMS, Agent, Profiler, Migration, etc.)

Operating System

Windows 7 (all editions)

Operating System Language

US English

Steps to Reproduce

1) Create a database on Server #1 called TEST1.
2) Backup that database.
3) On Server #2, create a database called TEST1 as well.
4) On Server #2, attempt to restore the database TEST1 database from the backup created on Server #1, and name that database TEST2.
5) Notice that an error is generated. In the Restore Database dialog for Server #1's TEST1 backup, select the Files page.
6) Notice that the Restore As filename for both the Rows Data and the Log files retain the original name of the database on the original server, TEST1. The database file name should automatically be named to TEST2.mdf and the Log file name should be named as TEST2_log.ldf. (This is the original behavior in SSMS 2008 R2 and earlier, which was correct.)

Actual Results

When different databases with the same name from many different servers are restore to one server, either errors are produced when trying to overwrite the same file with different databases, or the database and log files are overwritten, depending on whether the files are being used.

Expected Results

Data file physical names should automatically represent the name of the database on the new server during a restore process.

Platform

X64

Virtualization

 
File Attachments
0 attachments
Sign in to post a comment.
Posted by Microsoft on 1/29/2013 at 4:31 PM
Thank you for reporting this issue - we are investigating and will update you when we have more information.

Thanks,

Alex Grach [MSFT SQL SERVER]
Sign in to post a workaround.