Skip navigation

I'm getting an error 1117 in SQL Server. Can I rebuild the extents somehow?

A. It is recommended that you select/bcp out all the relevant data and then recreate the objects concerned. However, if you want to attempt a rebuild of the extents then make a backup first, and then try the following after putting the database into single-user mode first :-

dbcc rebuildextents (@db_id, @object_id, @index_id)

@db_id Id of the database
@object_id Id of the object to be rebuild
@index_id Id of the index to be rebuild

Alternatively you could just rename the object and leave it in the database with a dummy name - you won't be able to drop the object.

TAGS: SQL Server
Hide 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.