DBCC CHECKDB is a Transact-SQL command that is frequently used for checking the logical and physical integrity of databases. Essentially,
DBCC CHECKDB is a superset command that actually runs three checks (
CHECKCATALOG) by issuing a single command.
The following are some recommendations for using
DBCC CHECKDB to check and repair SQL database integrity:
• Always ensure that recent backups are on hand before running the command.
• Generally it is better to run the
DBCC CHECKDB superset command than to execute the individual operations, because this will serve to identify the majority of the errors and is generally safe to run in a production environment.
DBCC CHECKDB ...