dbcc

Adaptive Server 15.7 SP100 includes changes to the dbcc command.

zapdefraginfo

For every data partition undergoing incremental reorganization, a row is stored in sysattributes. Use the dbcc command zapdefraginfo to delete this information from sysattributes before performing a downgrade.

The syntax is:

dbcc zapdefraginfo( dbid | dbname, objid | objname 
[, indexid | indexname 
[,  ptnid | ptnname | 0, 
['print' | 'zap' | 'zap_no_log' ]]]) 

where:

In cases where the sysattributes incremental reorganization rows are accidentally deleted, use dbcc zapdefraginfo to reset the extent version information of the object so that reorg defrag does not mistakenly skip the supposedly fragmented extents while reorganizing.

shrinkdb_setup

Checks whether backlink pointers exist for each partition of a table in the database. If the backlink pointers do not exist, shrinkdb_setup creates them. The syntax is:
dbcc shrinkdb_setup(dbname[,object_name[, force [, verbose]]]
where:
  • dbname – is the name of the database you are checking.
  • object_name – is the name of the object you are checking.
  • force – is:
    • true – check tables and partitions whether or not they are already marked as being maintained.
    • false – do not check the tables or partitions.
  • verbose – print messages at the beginning of each check performed (on by default).
Usage:
  • After you run dbcc shinkdb_setup
    • Mark any large object columns that include replication indexes as "suspect" to ensure that Replication Server uses the backlink pointers on these LOB columns.
    • Databases are marked to indicate that dbcc shinkdb_setup has configured backlink pointers for text and image columns. You cannot run a use index command to create replication indexes.

dbrepair

Repairs corruption caused by a shrink database operation that stopped due to an uncontrolled situation.

The syntax is:
dbcc dbrepair(dbname, redo_shrink)
where:
  • dbname – is the name of the database you are checking.
  • redo_shrink – indicates that you are repairing a database that suffered an uncontrolled halt.