FAQ: What indexes in Oracle should be frequently rebuilt to maintain optimal performance with versioned tables?
What indexes in Oracle should be frequently rebuilt to maintain optimal performance with versioned tables?
A versioned query's performance in Oracle is highly dependent on the table's delta table indexes. The version query performs multiple joins and applies several predicate filters that will leverage the table's indexes.
The version query's performance can be impacted if the indexes used in the access path must read or scan more index blocks then necessary. The fewer number of blocks read; the better the performance.
To maintain the highest level of performance and response time for a version query, it is strongly recommended that the delta table indexes are rebuilt on a regular basis to ensure the indexes are as packed with the least number of index blocks as possible. Rebuilding the indexes re-creates the index with just the number of blocks required. Over time the index may grow by adding index leaf blocks, as new values are inserted into the table.
The following indexes on the versioned table's adds and deletes table are the indexes that should be rebuilt.
Indexes on the adds table:
Indexes on the deletes table:
Where <#> equals the registration_id value from the sde.table_registry table for the given versioned feature class.
To obtain the registration_id value for a versioned table, execute the following query in SQL*Plus:
SQL> SELECT registration_id
2 FROM sde.table_registry
3 WHERE table_name = 'SEWERS'
4 AND owner = 'TOM';
To rebuild the index execute the ALTER INDEX REBUILD command.
SQL> ALTER INDEX a51_pk REBUILD;
Repeat the command for each of the four important delta table indexes.
The frequency for which one should rebuild the indexes is completely dependent on the volume of edits occurring each day for the versioned table. If the class is not being edited, then there is no need to rebuild the indexes.
Last Published: 5/5/2016
Article ID: 000010245
Software: ArcSDE 9.3.1, 9.3, 9.2, 9.1, 9.0