Is it possible to style AGSFeatureTableLayer using attributes from a related table?

10-29-2014 07:06 AM
Esri Contributor

Hello all,

Is there any means to apply a unique value renderer to an AGSFeatureTableLayer used in an AGSMapView, and have the unique values for the renderer be derived an attribute in a related table?

In ArcMap, this would be accomplished by joining the features to the table, then applying the style using the joined attribute in the unique value configuration.  Using the ArcGIS API for JavaScript, I could achieve the same effect by using a UniqueValueRenderer that returns an anonymous function instead of a field name for the first field in the Unique Value Renderer object (where this function can lookup and return the value of an attribute from a related table).

At the moment, I do not see the equivalent option in iOS.  I'm working with a feature class and a table that exist in a local geodatabase (created from a sync-enabled feature service).  Is there a way to join the features, or somehow create a view in the local SQLite geodatabase file that accomplishes this? there a way I could perform the equivalent of the JavaScript approach?  The iOS runtime SDK documentation doesn't suggest any means to do this (as far as I have been able to determine so far).

Perhaps I can sub-class the AGSUniqueValueRenderer object - if I do this, could I just override methods like symbolForGraphic or symbolForFeature, and perform my own logic to return the symbols I need?

0 Kudos
0 Replies