Monday, July 27, 2009

How to Resolve SQL Server Error 8961?

The rows of a SQL Server table are divided into partitions that are numbered from 1 to n. By default all rows are consisted in a single partition, however one can also define the size of partition. All rows of partition are stored as a B-tree or heap structure. The actual data is stored in leaf nodes of leaves (called text data node), while rest other nodes (called text index nodes) are used to store index values for leaf node. But sometimes, you observe table inconsistencies because of mismatch between one or more child nodes and their corresponding parent nodes. As a result, you receive table corruption errors. Such situations need to be resolved using DBCC CHECKDB command, backup or commercial SQL recovery utilities.

You might encounter the following error with your SQL Server database table:

Server: Msg 8961 , Level 23, State
Table error: Object ID O_ID. The text, ntext, or image node at page P_ID1, slot S_ID1, text ID TEXT_ID does not match its reference from page P_ID2, slot S_ID2.

Where, ‘state_number’ might be 1, 2 or 4.


SQL Server displays error 8961 when it finds mismatch between child node and parent node and corruption in a text object. Specifically, you might infer the exact cause of error message by the ‘state_number’ it is displaying:

State 1: It occurs when timestamps in node and parent don’t match with each other.

State 2: The child node is text data node and has greater size as what is supposed by its parent. It might also occur if the child node is text index node and has different size as what is supposed by its parent.

State 4: The child node is actually a text index node, but its parent supposes it to be a text data node or vice-versa. This might also occur due if the level of child node is different from what is supposed by its parent.


In order to solve such problems, you should follow these steps:

• Check your system for possible hardware problems
• Restore database from clean backup, if available
• Execute DBCC CHECKDB command without using repair clause if no valid backup is available. Again run DBCC CHECKDB but with the repair clause suggested by the previous check
• Running DBCC CHECKDB causes data loss. Thus, for safe SQL Repair, use third-party database repair applications. These SQL Recovery tools are built with powerful technology to safely scan and repair a damaged SQL Server database.

Stellar Phoenix SQL Recovery is a premier tool to repair damaged SQL databases. It supports SQL Server 2008, 2005 and 2000. With self-descriptive and exceptionally realistic interface, advanced repair options and read-only design, it is an effective SQL Repair tool to repair all database objects. The software is compatible with Windows Vista, XP, 2003, 2000 and NT.

No comments:

Post a Comment