With a feature service that has a related table, is there a way to set a definition expression using the fields in the related table? For example, with the feature service located at https://sampleserver3.arcgisonline.com/ArcGIS/rest/services/SanFrancisco/311Incidents/FeatureServer/0, is it possible to create a definition expression that would only show me Incidents that had an Incident Priority record more recent than a certain date?

1 Answer 1


if you snoop the network traffic in this sample, you'll see that additional queries for the attributes of related records aren't made until an individual feature has been clicked. this is because only the attributes present in the feature service itself are available automatically for filtering.

as an alternative, you could:

  1. query the table of related records for rows that satisfy your condition
  2. use the results to generate a list of associated objectids
  3. use the list of object id's for filtering your feature layer with geometry
  • Right, and that's what I'm doing -- just wondering if there is a more compact way that would only involve a single trip.
    – Dante617
    Commented Jun 16, 2016 at 19:11
  • nope, not that i've ever heard of. Commented Jun 16, 2016 at 19:13

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.