English

FAQ: How do I author a Survey123 for ArcGIS survey that matches a feature service?

Question

How do I author a Survey123 for ArcGIS survey that matches a feature service?

Answer

Authoring a new survey that is linked to an existing feature service may be useful when not wanting to include all available fields in the survey. When authoring a new survey, consider the following requirements:

  • The form_id property on the Settings tab of the spreadsheet must match the name of the layer in the feature service where questions for the survey are stored.
Note:
If the form_id property is left blank, the survey attempts to target a layer in the feature service with the same name as the spreadsheet.
  • If using repeats, the name of the repeat must match the name of the related layer or table in the feature service. The name of the repeat cannot include non-ASCII characters, spaces, or start with a numeric value.
  • Every question in the survey must reference an existing field in the feature serviceā€™s layers or tables. Additionally, the esriFieldType and esriFieldLength columns in the spreadsheet must match (or be more restrictive than) those of the corresponding feature service field. Questions within the repeatĀ correspond to fields in the related layer or table. Questions outside the repeat correspond to fields in the feature service layer referenced in form_id.

When publishing a survey for the first time that contains a submission URL, only the survey form item is created. A relationship is created to the existing feature service, instead of a new feature service being created. When republishing a survey with a submission URL, the existing form item is updated (rather than being deleted and recreated), and the relationship is updated to the specified submission URL.

Note:
When republishing surveys on Portal for ArcGIS 10.3.1, new feature services are created and old feature services are not deleted. This is a limitation of Portal for ArcGIS 10.3.1. To avoid this accumulation, old feature services must be manually deleted. If republishing on Portal for ArcGIS 10.3.1 with a submission URL, the relationship to the specified URL is created but is not visible in the item.