david_32
asked on
REPAIRING A corrupt sql database
Hi Folks,
I was just looking at the documentation for dbcc checkdb and I took notice of the REPAIR OPTIONS. It recommends that to repair errors you should restore from backup. To my way of thinking that would defeat the purpose of running the command anyway. If the db was corrupt wouldn't restoring from a good backup fix all your problems anyway? Is there any good doco on this?
Kind Regards
I was just looking at the documentation for dbcc checkdb and I took notice of the REPAIR OPTIONS. It recommends that to repair errors you should restore from backup. To my way of thinking that would defeat the purpose of running the command anyway. If the db was corrupt wouldn't restoring from a good backup fix all your problems anyway? Is there any good doco on this?
Kind Regards
ASKER
Sorry .... question was a bit vague.
Microsoft recommends restoring from backup rather than dbcc checkdb
http://msdn.microsoft.com/en-us/library/ms176064.aspx
why is that?
Microsoft recommends restoring from backup rather than dbcc checkdb
http://msdn.microsoft.com/en-us/library/ms176064.aspx
why is that?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
thanks - I didn't know that it clears the plan cache as well - that helped me with another issue I am having - you should get double points :)
http://blogs.msdn.com/sqlserverstorageengine/archive/2007/03/05/oh-no-my-backup-is-corrupt-too-help.aspx
If your *.mdf or *.ldf is corrupt, then try this below
http://blog.sqlauthority.com/2008/04/10/sql-server-2005-restore-database-using-corrupt-datafiles-mdf-and-ldf-part-2/