Hi,
I have a backup file say x.bak.dap
I want to restore this file which has the .dap extension
How to do it?
Please suggest me
Thanks in advance,
Senthil N
If it's a SQL Server backup, you restore the same as any other backup file. SQL Server doesn't really care what the extension is, the file just needs to be a SQL Server backup file. It's a pretty standard practice to use bak for the database backup file extension though.
If you aren't sure about the file itself, try to just view the files in the backup file with:
restore filelistonly
from disk = 'X:\PathToFile\x.bak.dap'
-Sue
|||Hi,
Now I have the bakup file and I tried to restore 'Test' database from the Query Analyzer (master db).
I am getting the following error
Msg 3154, Level 16, State 4, Line 1
The backup set holds a backup of a database other than the existing 'Test' database.
Msg 3013, Level 16, State 1, Line 1
RESTORE DATABASE is terminating abnormally.
Please help me.
Thanks in advance,
Senthil N.
|||Hi Sue,
Thank you for ur reply.
I tried the command and i am getting the logical & Physical file name.
But still i am getting error.
see my reply.
|||It may be that your backup file contains more than one set of backups:
Try running:
restore headeronly
from disk = 'X:\PathToFile\x.bak.dap'
And if this is the case, you'll need to look at WITH FILE option in BOL for your restore.
Hope this helps!
|||I haven't actually been able to replicate your error but there does seem to be a fair few people who have had this issue. It looks like adding the WITH REPLACE clause to the RESTORE statement which overwrites the existing database does the trick.
|||You probably want to read up on the with move and replace options for restoring a database. To include the move and replace options in your restore statement, it would be something like:
Restore database YourDBName
From disk = 'X:\PathToFile\x.bak.dap'
with move 'LogicalDataFileName' to 'X:\NewLocation\YourDBName.mdf',
move 'LogicalLogFileName' to 'X:\NewLocation\YourDBName.ldf',
replace
-Sue
|||Thanks Sue,
It's working after adding the replace option.
Regards,
Senthil.N
|||Thank you Rich,
My problem sorted out after adding the restore options.
Regards,
Senthil.N
No comments:
Post a Comment