HOW TO
Instructions provided describe how to improve query performance when using ST_Geometry by reducing the number of index blocks read by each spatial query that uses the spatial index (ST_Spatial_Index). Reducing the logical or physical I/O operations for a Structured Query Language (SQL) statement improves query times and improves resources on the server, providing further scalability.
Code:
SQL> SELECT 'S'||index_id||'_IDX$' AS DOMAIN_INDEX
FROM sde.st_geometry_index
WHERE owner = USER
AND table_name = 'PARCELS';
DOMAIN_INDEX
------------
S15_IDX$
SQL> ALTER TABLE s15_idx$ SHRINK SPACE COMPACT CASCADE;
Table altered.
Code:
SQL> SELECT index_name, leaf_blocks
FROM user_indexes
WHERE table_name = 'S15_IDX$';
INDEX_NAME LEAF_BLOCKS
-------------------- -----------
S15$_IX2 18427
S15$_IX1 27465
Code:
SQL> SELECT index_name, leaf_blocks
FROM user_indexes
WHERE table_name = 'S15_IDX$';
INDEX_NAME LEAF_BLOCKS
-------------------- -----------
S15$_IX1 13973
S15$_IX2 17406
Code:
SQL> exec dbms_stats.gather_table_stats(user,'parcels');
Get help from ArcGIS experts
Download the Esri Support App