AnsweredAssumed Answered

Query local geodatabase replica directly

Question asked by jmburns on Sep 25, 2014
Latest reply on Sep 29, 2014 by jmburns

Hi,

 

Has anyone had success executing queries against a local (offline) geodatabase replica through non-ESRI libraries?  When we execute a query containing a JOIN statement using FMDatabase for iOS recently added records from all tables are essentially deleted.

 

For example, consider a geodatabase that has a point feature class representing baseball stadium locations (BallparkLocations), a table containing information on the team (TeamInfo) and tables for events (Events, Games, etc).  Say I create a new ball park and associated team info, using the ArcGIS Runtime SDK for iOS saveFeature method.  The records are linked by primary key/foreign key GUID values.  If I then turn around and execute a query using FMDatabase that contains a JOIN statement, something like:

 

SELECT e.Name, e.StartTime, g.Opponent FROM Events_evw e JOIN Games_evw g ON e.primaryGuid = g.foreignGuid WHERE e.BallparkGuid = '{some ballpark guid}'

 

The query executes fine and returns results, but the records I just added to BallparkLocations and TeamInfo are gone.  This is a real problem with complex applications since the SDK does not provide a means to execute complex select statements and querying multiple tables with the asynchronous blocks, the only option provided by the SDK, is very cumbersome.  Any ideas or lessons learned would be appreciated.

 

Thanks,

Justin Burns

Sr. Geospatial Developer

GISi

Outcomes