L.esri.Related.Query

Extends L.esri.Task

An abstraction to assist querying related tables published in ArcGIS Server or ArcGIS Online. You can find more information and the source code for this plugin here.

Constructor

Extends L.esri.Task

Constructor Options Description
L.esri.Related.query(<L.esri.FeatureLayer> endpoint)
or
L.esri.Related.query(<Object> options)
<L.esri.FeatureLayer> or <Options> Accepts either an options object or an instance of L.esri.FeatureLayer.

Options

Accepts all L.esri.Task options. When used, the url option is required.

Methods

Method Returns Description
objectIds(<Array> objectIds or <String> objectId) this The ObjectId(s) of the features to query for related records.
relationshipId(<String> relationship id) this The id of the relationship itself.
run(<Function> callback) this Executes the query, passing the previously supplied input parameters.
fields(<Array> fields or <String> field) this (Optional) Indicates which fields from matched records to include in response (default is 'all').
returnGeometry(<Boolean> true, <Object> value) this (Optional) Indicates whether or request the geometry of response features (default is true).
returnZ(<Boolean> true, <Object> value) this (Optional) Indicates whether to request information about elevation in response features (default is true).
returnM(<Boolean> true, <Object> value) this (Optional) Indicates whether to request information about 4-D M values in response features (default is false).
precision(<Number> number, <Object> value) this (Optional) Indicates the desired decimal precision of response feature geometries.
definitionExpression(<String> sqlfilter, <Object> value) this (Optional) An opportunity to specify a SQL where clause to further filter results. (Example: "STATE_NAME = 'California'")

Results

Property Type Description
features [<L.geoJSON>] The result of a valid request will be composed of an array of L.geoJSON features.

Example

{
  features: [{
    "type": "Feature",
    "properties": {
      ...
    },
    "id": 1
  },
  ...
  ]
}

Edit this page on GitHub