Checks for consistency in and between system tables in the specified database.
) [ WITH NO_INFOMSGS ]
Is the database for which to check system table consistency. If not specified, the default is the current database. Database names must conform to the rules for identifiers. For more information, see Using Identifiers.
Suppresses all informational messages and the report of space used when there are less than 200 error messages. If not specified, DBCC CHECKCATALOG displays all error messages. DBCC CHECKCATALOG messages are sorted by object ID, except for those messages generated from tempdb.
DBCC CHECKCATALOG checks that every data type in syscolumns has a matching entry in systypes and that every table and view in sysobjects has at least one column in syscolumns.
If no database is specified, DBCC CHECKCATALOG returns this result set (message):
DBCC results for 'current database'. DBCC execution completed. If DBCC printed error messages, contact your system administrator.
If Northwind is provided as a database name, DBCC CHECKCATALOG returns this result set (message):
DBCC results for 'Northwind'. DBCC execution completed. If DBCC printed error messages, contact your system administrator.
DBCC CHECKCATALOG permissions default to members of the sysadmin fixed server role, the db_owner and db_backupoperator fixed database roles, and are not transferable.
This example checks the allocation and structural integrity of objects in both the current database and in the pubs database.
-- Check the current database. DBCC CHECKCATALOG GO -- Check the pubs database. DBCC CHECKCATALOG ('pubs') GO