English

Problem: Domains do not appear in Collector for ArcGIS after a hosted feature service is modified in ArcGIS Online

Description

After modifying or adding a domain to the schema of a hosted feature service in ArcGIS Online, the domains do not appear in Collector for ArcGIS.

Cause

Domains can be missing from Collector for ArcGIS for the following reasons:

  • The domain is not added to the template section of the JavaScript Object Notation (JSON) when modifying the domain in ArcGIS Online.
  • When a map is taken offline, a replica of the geodatabase of each feature layer is downloaded to the device with Collector for ArcGIS. Collector for ArcGIS uses an older replica of the web map after the schema of the feature service is modified and republished to ArcGIS Online.

Solution or Workaround

If the domains of the hosted feature service are added in the schema in ArcGIS Online, ensure that the domains are also updated in the Template section of the schema.

To add a domain under the Template section of the JSON when editing the JSON in a JSON editor, follow the steps below:

  1. Search for "template" in the JSON.
  2. Add the following code:
"domains": {
    "status": {"type": "<type of domain>"}
   },
Alternatively, re-download the web map into Collector for ArcGIS after the changes to the schema of the hosted feature service are done in ArcGIS Online.
Note:
To ensure that no data collected by other users with Collector for ArcGIS is lost , upload the data before making the changes to the schema of the feature service.