Is This Content Helpful?
We're glad to know this article was helpful.
There are specific workflows that can cause the recalculation of a spatial index grid to fail with the following error message:
"Failed to add spatial index. Spatial index grid is too small."
ArcGIS has built-in checks for the limits to the number of features allowed per grid. This is to avoid spatial query performance issues for inappropriate grid size calculations. When the spatial index is recalculated on a versioned feature class, the index is calculated based on the features currently in that version. However, when the index is applied, it is applied to the non-versioned feature table, which could have different representations and numbers of features than those in a specific version.
While ArcGIS is recalculating the correct grid size, it is based on a versioned representation of those features and might not be an ideal grid size for all the features in the feature table.
The cause of the bug is an application of an invalid grid size to the non-versioned feature table.
The workaround for this issue is to generate the spatial grid index from the ArcSDE command line using the sdelayer ALTER operation.
sdelayer –o describe_long -l myFC,shape
sdelayer –o normal_io –l myFC,shape
sdelayer –o alter –g 0 –l myFC,shape