Thursday, 14 March 2013

ORA-10631: SHRINK clause should not be specified for this object


PROBLEM:
ORA-10631:SHRINK clause should not be specified for this object

SOLUTION:
This error is due to the fact that an object you are trying to shrink has an "function-based" index on it. Objects with function-based indexes cannot be shrunk. To reclaim the space you need to drop and readd the function-based index after shrinking the object*.

*Before dropping any indexes make sure you understand what the index is for and have a script prepared to replace the index. Removing an index can affect performance of the query or the application

1-Drop the function-based index.
3- Shrink the table.
4- Recreate the index again on the table.

No comments:

Post a Comment