Wednesday, September 16, 2009

Index Corruption in MS SQL Server Might Damage the Database

Index is the most critical component of a relational database. It ensures easy, quick and managed accessing of data from the database. In Microsoft SQL Server, a non-clustered index is an index that stores both logical and physical order of indexes and tables. But in case of corruption if the logical order of index doesn't match the physical order or rows on hard drive and thus you can not access data from the database. This situation generally occurs due to index corruption, which could be the outcome of self-update query, virus infection, improper system shutdown and may others. At this point, the database become inaccessible and you encounter data loss situations. To retrieve data in such cases, you are required to go for SQL Recovery using appropriate tools.

In a practical scenario, when you carry out any operation using self-update query on master table after which non-clustered index gets damaged or corrupted. Additionally, you encounter any of the below given error messages while trying to access any database table or entire database:

“Server: Msg 8952, Level 16, State 1, Line 1

Table error: Database 'badqueue', index 'repro.NC' (ID 1828201563) (index ID 2). Extra or invalid key for the keys:”


“Server: Msg 8956, Level 16, State 1, Line 1
Index row (1:308:2) with values (i2 = 369 and i1 = 1 and ? = 61) points to the data row identified by ().”

After above error message occurs, you can not access master table and thus stored data and require SQL Repair. The self-update query select over 3,000 rows of master table but not entire master table. To gain access of master table, you are recommended to download and use hotfix solution offered by Microsoft.

But even after applying the hotfix, you get same error message and can not access the database, you are required to repair and restore damaged database. This is best possible with the help of powerful and efficient third party applications, known as SQL Recovery tools.

These applications use high-end scanning mechanisms to methodically scan entire SQL Server database and retrieve all of its objects including tables, reports, forms, triggers, stored procedures and so forth. With interactive and rich graphical interface, they are quite easy to use. The SQL Repair software do not alter original data in the database.

No comments:

Post a Comment