Updates the dbcc_config table in dbccdb with the configuration information of the target database.
sp_dbcc_updateconfig dbname, type, "str1" [, "str2"]
sp_dbcc_updateconfig pubs2, "max worker processes", "4"
sp_dbcc_updateconfig null, 'max worker processes', '2'
sp_dbcc_updateconfig pubs2, "dbcc named cache", pubs2_cache, "10K"
sp_dbcc_updateconfig pubs2, "scan workspace", scan_pubs2
sp_dbcc_updateconfig pubs2, "text workspace", text_pubs2
sp_dbcc_updateconfig pubs2, "OAM count threshold", "5"
sp_dbcc_updateconfig pubs2, "IO error abort", "3"
sp_dbcc_updateconfig pubs2, "linkage error abort", "8"
sp_dbcc_updateconfig my_db, "enable automatic workspace expansion", "1"
sp_dbcc_updateconfig updates the dbcc_config table for the target database.
If the name of the target database is dbccdb, and the database dbccalt exists, sp_dbcc_updateconfig updates the dbcc_config table in dbccalt.
If the target database name is not found in dbcc_config, sp_dbcc_updateconfig adds it and sets the operation sequence number to 0 before updating other configuration information.
If the expected value for the specified type is a number, sp_dbcc_updateconfig converts the values you provide for str1 and str2 to numbers.
The OAM count threshold parameter represents the percentage by which the actual row count can vary from the row count (as reported by the OAM pages) before dbcc checkstorage raises error 100025, row count error. Generally, you can leave OAM count threshold at the default value of 2%.
The valid type names to use for type and the expected value for str1 or str2 are:
type Name |
Value Expected for str1 or str2 |
---|---|
dbcc named cache |
The name of the cache, specified by str1, and the new size (in kilobytes or megabytes) or the number of 2K pages, specified by str2. |
IO error abort |
The new error count, specified by str1. The value must be a number greater than 0. str2 is not used with this type. |
linkage error abort |
The new linkage error count value specified in str1. The value must be a number greater than 0. str2 is not used with this type. |
max worker processes |
The new number of worker processes, specified by str1. The value must be a number greater than 0. str2 is not used with this type. |
OAM count threshold |
The new threshold count, specified by str1. The value must be a number greater than 0. str2 is not used with this type. |
scan workspace |
The new name for the scan workspace, specified by str1. str2 is not used with this type. |
text workspace |
The new name of the text workspace, specified by str1. str2 is not used with this type. |
automatic workspace expansion |
Allows checkstorage to automatically expands the workspace if adequate space is available on the respective segments. The default value of 1 enables automatic workspace expansion, and the value of 0 disables it. |
dbcc in Reference Manual: Commands
System Administration Guide for more information on the type names and values.
The permission checks for sp_dbcc_updateconfig differ based on your granular permissions settings.
Setting | Description |
---|---|
Enabled | With granular permissions enabled, you must be the database owner of dbccdb (or dbccalt), or have the manage checkstorage privilege on the specified database. |
Disabled | With granular permissions disabled, you must be the database owner of the specifed database or a user with sa_role. |