Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Restore .bak into a different name?
Message
 
 
To
26/08/2017 15:51:34
General information
Forum:
Microsoft SQL Server
Category:
Backups
Miscellaneous
Thread ID:
01653769
Message ID:
01653777
Views:
25
>>I made a backup of a customer SQL Server database (my app database) into a .BAK file.
>>I then copied this .BAK file to my computer, into my SQL Server database backup folder.
>>Now I want to restore this .BAK into my SQL Server but since I already have a DB of the same name, I want to restore it into a different name. E.g. the name of the DB in my SQL Server is MyAppDb and I want to restore the .BAK into MyAppDbCurrent.
>>I open/connect my SQL Server 2016 SSMS. I go to the Restore window and specify Destination as MyAppDbCurrent and then select the .BAK file as restore from. But the Restore of the DB fails. Is this because the database name (in .BAK) is MyAppDb (the same as one of my existing databases). How would I resolve it?
>
>Here is an example to customize the restore:
>
>
>USE Master
>RESTORE DATABASE [LevelExtreme] FROM DISK = N'D:\Data\Level Extreme\LevelExtreme.bak'
> WITH
> MOVE 'UniversalThread' TO 'D:\Data\Level Extreme\LevelExtreme.mdf',
> MOVE 'UniversalThread_log' TO 'D:\Data\Level Extreme\LevelExtreme.ldf',
> FILE = 1,  NOUNLOAD,  REPLACE,  STATS = 10
>GO
>
Thank you. My problem was, I think, that the backup was done on SQL Server 2008 R2 and my version is SQL Server 2008 Express. So I am thinking of installing SQL Server 2012 Express, if it can coexist with the 2008 I have.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform