Access Attachments & attributes of an existing feature service in Survey123

1542
4
Jump to solution
06-04-2021 12:07 PM
Kara_Shindle
Occasional Contributor III

Looking for answer to question and guidance - have an existing feature service hosted on my own server that has multiple related tables and attachments for each based on various workflows and reports that need done in the field.

Attachments enabled on main feature service itself - and I want to add fields into the Attachments table for collecting data in a Survey123 form - I want a user to be able to upload a photo / PDF and also enter their name and company along with the data an attachment was added.  I have added these fields into the Attachments table, and Global IDs are being used.

Photo of what the XLSForm looks like:

XLSForm.png

 

Note: I have already created multiple surveys off of this service for the related tables based on this blog post

When I attempt to do this with the attachments table on the main feature service, it tells me it cannot find the attachments table.  

Is this possible or do I need to create another related table populated with the fields I want to collect and enable attachments on that related table instead?

Picture of error I receive

bridge survey.png

 

0 Kudos
1 Solution

Accepted Solutions
Kara_Shindle
Occasional Contributor III

Update: Here is how I did it.  Couldn't add the additional metadata fields I needed in the attachments table so I created ANOTHER related table just for attachment information, and enabled attachments on that table!

Once I did that, it was showing up in Survey123 connect for me.  Screenshot of XLSForm.

Kara_Shindle_0-1676293910500.png

Ended up doing this for 3 tables and attaching them all to views & buttons in an experience for our requestor.  

View solution in original post

4 Replies
JamesTedrick
Esri Esteemed Contributor

Hi @Kara_Shindle ,

The error indicates that you are trying to create a form based on the attachment table.  This should not be done; in general, the attachment table should never be directly published from the feature service.  The image/files will automatically be added as attachments when the form is linked to the attachment's parent layer.

0 Kudos
ChristalHigdon_USFS
New Contributor III

I have attachments enabled and have additional attributes in the __ATTACH table. Is there a way to populate those additional attributes through a survey form? Specifically I have added PHOTO_CAPTION and would like the user to add a text sentence in the survey form to go into the attachments table with their photo. Is this possible?

MelissaAllen2
New Contributor

Same question as @ChristalHigdon_USFS  - Is this possible to add a photo caption to the attachments related table?

0 Kudos
Kara_Shindle
Occasional Contributor III

Update: Here is how I did it.  Couldn't add the additional metadata fields I needed in the attachments table so I created ANOTHER related table just for attachment information, and enabled attachments on that table!

Once I did that, it was showing up in Survey123 connect for me.  Screenshot of XLSForm.

Kara_Shindle_0-1676293910500.png

Ended up doing this for 3 tables and attaching them all to views & buttons in an experience for our requestor.