Facilitates reporting on aborted checkverify and checkstorage operations.
sp_dbcc_patch_finishtime dbname, opid [,optype [,seq [,finishtime]]]
dbcc checkstorage (my_db) Checking my_db: Logical pagesize is 2048 bytes 00:00000:00014:2003/01/20 11:50:05.01 server Error: 9960, Severity: 20, State: 1 A non-recoverable error has occurred in the CHECKSTORAGE operation. The operation has been aborted. Msg 9970, Level 20, State 1: Line 2: DBCC cannot update the finish time in dbcc_operation_log table for this operation(opid = '1') of database 'my_db'. This can be patched by executing sp_dbcc_patch_finishtime.
dbcc checkstorage (my_db) Checking my_db: Logical pagesize is 2048 bytes 00:00000:00014:2003/01/20 11:50:05.01 server Error: 9960, Severity: 20, State: 1 A non-recoverable error has occurred in the CHECKSTORAGE operation. The operation has been aborted. Msg 9970, Level 20, State 1: Line 2: DBCC cannot update the finish time in dbcc_operation_log table for this operation(opid = '1') of database 'my_db'. This can be patched by executing sp_dbcc_patch_finishtime.
sp_dbcc_patch_finishtime my_db, 1
When a checkstorage or checkverify operation aborts, it prints a message that contains the operation’s ID and the name of the database that was being examined when the operation aborted. An aborted checkverify operation also provides a sequence number in the message. The message instructs the user to run sp_dbcc_patch_finishtime, and provides the dbname, opid, and if it was a checkverify operation, the sequence number, seq. After executing sp_dbcc_patch_finishtime, you can create fault reports on the aborted operation.
The permission checks for sp_dbcc_patch_finishtime 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 specified database or a user with sa_role. |