Skip to main content

I've got a geodatabase from which I am trying to read features based on an initiator intersect within a FeatureReader. The geodatabase contains polygons for a large area, and the initiators are areas I intend to spatially filter geodatabase features to and then write out as individual shapefiles for each area.

 

This is proving very slow, and i'm hoping someone can point me in the direction of a more efficient way to perform this operation?

 

Thanks

It's very probably due to either a sub-optimal spatial index, or to poor database performance (could be for a number of reasons). For the spatial index, the first thing to try is to re-create it, to see if that makes difference.

You may also want to look at the database logs when the spatial query runs, to see if there is excessive paging, for example.


It's very probably due to either a sub-optimal spatial index, or to poor database performance (could be for a number of reasons). For the spatial index, the first thing to try is to re-create it, to see if that makes difference.

You may also want to look at the database logs when the spatial query runs, to see if there is excessive paging, for example.

Is there a way to re-create the spatial index in FME? I do not have ArcGIS on the same computer as FME.


Is there a way to re-create the spatial index in FME? I do not have ArcGIS on the same computer as FME.

Re-creating the spatial index has nothing to do with FME, so you can do it from whichever PC that has an installation of e.g. ArcCatalog or similar. Since the spatial index resides in the SDE database, any changes will immediately be available to everyone using the database. See for example:

https://desktop.arcgis.com/en/arcmap/latest/manage-data/geodatabases/modifying-a-spatial-index.htm

 


@ewanrobertmclau​  Can you confirm which Geodatabase reader you are using:

  • ArcSDE Geodb
  • File Geodb
  • File Geodb Open API

If you don't have ArcGIS installed on the same computer as FME what Esri components are you using?


@ewanrobertmclau​  Can you confirm which Geodatabase reader you are using:

  • ArcSDE Geodb
  • File Geodb
  • File Geodb Open API

If you don't have ArcGIS installed on the same computer as FME what Esri components are you using?

I'm using File Geodb Open API on the FeatureReader.

I've got ArcGIS (map, catalog etc) on a laptop and the geodatabase takes far too long to open due to the laptops poor specs.

I tried a conversion of the geodatabase to a spatialite database and in the process rebuilding the spatial index via FME. Performing a read with spatial query on this spatialite database was significantly faster


I'm using File Geodb Open API on the FeatureReader.

I've got ArcGIS (map, catalog etc) on a laptop and the geodatabase takes far too long to open due to the laptops poor specs.

I tried a conversion of the geodatabase to a spatialite database and in the process rebuilding the spatial index via FME. Performing a read with spatial query on this spatialite database was significantly faster

@ewanrobertmclau​  Geopackage would have been a good alternative - also based on SQLite.

One alternative might be to rebuild spatial index of your File Geodb using ArcCatalog.

 

For most formats, the way that FeatureReader does a SQL query, is to use the bounding box of the Initiator to read the initial query features, and then use the actual area boundary to do an in memory spatial query using the Spatial Filter you selected. If the Initiator area is complex, then the initial bounding box query might be pulling back more result features than you need. this is compounded if you have several Initiator features that more or less cover the same region (i.e. picture two C shaped areas that face each other. So in some cases it might be quicker to read all the data and use SpatialFilter.

But most likely int's the Geodb Spatial Index that might need updating.


Reply