11

We have some software as part of a larger project written using ArcObjects via .NET. This software migrates and merges data from multiple file geodatabases in one schema to a single file geodatabase in a similar but different schema. Some steps in the migration involve looking up an existing row and updating it with data from a different table. This can get very slow when the destination geodatabase is large, so I have added some multi-field attribute indexes to improve the query/update performance.

Is there a way that I can confirm that the queries are using the new attribute indexes, and perhaps how the query is being executed?

I guess I'm really looking for the equivalent of a query plan - something similar to EXPLAIN PLAN in Oracle.

The queries are on a file geodatabase using ArcObjects directly (no RDBMS backend or SQL).

6
  • Have you timed the performance with and without attribute indexes? I think that's the only way to know that they're having an effect.
    – blah238
    Commented Nov 5, 2012 at 5:01
  • I'm running performance tests now with various sizes of dataset. I'll try to post results when I get them.
    – Gnat
    Commented Nov 5, 2012 at 5:12
  • I looked in the ArcObjects class libraries for something similar to Smallworld Magik's is_size_fast? method, which returns true if indexes are being used, but I couldn't see an equivalent ArcObjects call.
    – Gnat
    Commented Nov 5, 2012 at 10:20
  • fGDB is ESRIs' own database format, there is an API that will allow you to access data without ESRI objects but I doubt that would shed much light on your quandry. The use of indicies is automatic and can't be detected or affirmed. I agree with blah238 that's the only way to tell for sure. The 'unique' and 'ascending' options can have a big difference but only use these options if you are absolutely certain of uniqueness and/or ascention. Commented Oct 9, 2013 at 22:05
  • @blah238 I think you could turn your comment into an answer.
    – PolyGeo
    Commented Jun 11, 2016 at 8:36

1 Answer 1

1

File Geodatabase is Esri's own database format, there is an API that will allow you to access data without ArcObjects but I doubt that would shed much light on your quandary.

The use of indices is automatic, at the database level, and can't be detected or affirmed except for the timeliness of functions using them.

I agree with blah238 the only way to tell for sure is to run with and without indices built and compare the difference in time.

The 'unique' and 'ascending' options for building an index can have a big difference but only use these options if you are absolutely certain of uniqueness and/or ascension, should the data not be suitable the index will either not build or, if it does build, are likely to adversely affect performance rather than enhance.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.