Skip navigation

I am getting an error 605 on SQL Server - what can I do?

A. This problem is caused by a cross-link in the page chains of two or more tables, causing them to point to each other's data. Make sure that is a "real" 605 by running the dbcc in single-user mode as they can be spuriously reported if updates are occuring at the time of the dbcc.

At this point if you have a good backup and will not lose any data, then now is the time to use it. If you don't have a good backup then look at your backup procedures! To try and resolve the problem read on :-

First, if you haven't already done a full dbcc checkdb/newalloc then do one. You need to ascertain how much corruption exists. You may have one 605 or hundreds - there may also be other corruptions. Make sure you have a backup, in case you make things worse.

Use DBCC PAGE (doc'd in the Books Online) to determine whether the page is a data or index page. 

If it is an index you are in luck and you may be able to drop and recreate the index.

If it is not an index page or this does not work then you will need to transfer all the data/objects into a new database. For the problem table(s) this may not work as the page chain is broken, so you will probably need to manually select out data in ranges based on keys above and below the broken point(s). 

Once you have transferred all the objects across drop the old database and rename the new one.

If you don't want to transfer all the data across then you can just do the broken tables. When this is done, rename the broken tables by directly updating their name in sysobjects. Then create new tables with the old names. Make sure no other errors are in the database first. Make sure you also re-create any views/stored-procedures that reference the tables so that they start pointing to the new ones.

If the above is not possible due to the size of the database or other reasons then your only alternative is to pay for Microsoft PSS support who may be able to patch the pointers in the tables/pages directly for you. However this sort of fix is not guaranteed and is done (if at all) on a best efforts basis totally at your risk.


TAGS: SQL
Hide comments

Comments

  • Allowed HTML tags: <em> <strong> <blockquote> <br> <p>

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
Publish