How to access spatial index grids (and their sizes)

274
2
12-11-2020 02:45 PM
KirkKuykendall1
Occasional Contributor III

With arcobjects I can use IField.GeometryDef.GridSize to retrieve spatial index grid sizes.

How do I do this with the Pro SDK?

Thanks, Kirk

Tags (1)
0 Kudos
2 Replies
RichRuh
Esri Regular Contributor

Hi Kirk,

What workflow are you trying to accomplish?  Right now, you cannot access this information with the Pro SDK or with Python.  The only way to get to it is by exporting the geodatabase schema to XML.  We've also removed it as an input option from geoprocessing.

I don't know much about how to use grid sizes, so any information you could offer would be helpful.

Thanks,

--Rich

0 Kudos
KirkKuykendall1
Occasional Contributor III

Hi Rich -

I'd like to avoid spatial index grid size is invalid error when programmatically adding a feature with a too-large envelope to a featureclass with a small grid size. 

I was thinking I would check to see if a feature's envelope is too big before attempting to insert it.  Would one be able to anticipate this error by comparing the feature's envelope with the grid size(s)?

In the past, with arcmap, I've adjusted grid sizes to tune draw and spatial query performance.  Nowadays with SSD's maybe that's not so critical.

Thanks, Kirk

0 Kudos