SQLServer-DBA.com Links

Subscribe to newsletter

Dba_db2_button

Powered by TypePad
SQL Server restore problem - Error 3154: The backup set holds a backup of a database other than the existing database

31 December,2008 by Jack Vamvas

On SQLServer 2005 Standard Edition Service Pack 2  - we have a routine that backs up databases onto a dedicated drive. It is a full backup to disk. This routine does not drop the database

BACKUP DATABASE MY_DB TO  DISK = 'I:\backups\jvTest20081127.BAK' WITH NOFORMAT,COPY_ONLY, INIT,  NAME = MY_DB  , SKIP, NOREWIND,

NOUNLOAD,  STATS = 10;

 

 A couple of weeks later , I needed one of the databases and attempted a standard RESTORE DATABASE
but without the WITH REPLACE parameter.

   RESTORE DATABASE MY_DB FROM DISK =  'I:\backups\jvTest20081127.BAK'


An error was encountered : Error 3154: The backup set holds a backup of a database other than the existing database
The error occurs because I was  trying to restore the database on another existing active database.


The solution is :

RESTORE DATABASE myDB
   FROM DISK = N'I:\backups\jvTest20081127.BAK' 
WITH REPLACE

 Read More

SQL Server - BACKUP LOG WITH NO_LOG - SQL Server DBA

BACKUP failed to complete the command BACKUP LOG - SQL ...

Differential backup cannot be restored . BACKUP with COPY_ONLY ...


Author: Jack Vamvas (http://www.sqlserver-dba.com)

******** *******

Subscribe to SQLServer-DBA.com

Latest posts delivered to you daily

Delivered by FeedBurner

Verify your Comment

Previewing your Comment

This is only a preview. Your comment has not yet been posted.

Working...
Your comment could not be posted. Error type:
Your comment has been posted. Post another comment

The letters and numbers you entered did not match the image. Please try again.

As a final step before posting your comment, enter the letters and numbers you see in the image below. This prevents automated programs from posting comments.

Having trouble reading this image? View an alternate.

Working...

Post a comment


sqlserver-dba.com | SQL Server Performance Tuning | SQL Server DBA:Everything | FAQ | Contact|Copyright & Disclaimer