Survey123: Error Unpacking

262
3
12-30-2021 11:49 AM
jgoldman
New Contributor III

I am attempting to set up an Inspection Workflow which utilizes both Field Maps and Survey 123. The inspectors use Field Maps to navigate the feature data and the pop up has a button which leads to the Survey123 form. However I am having issues.

After I create the link in the pop up and select a feature to inspect in my Field Maps map, it takes me to Survey123 but says that there is an "Error Unpacking". Can't seem to figure out what the issue is.

Additionally, when I bypass Field Maps and use only Survey123 on its own to complete the form, it submits OK but none of the inspection records show up in my related table. Very frustrating!!!

Hoping someone might be able to shed a little light on why this is occurring. I have been following @EricWagner1 's workflow, located here (https://www.youtube.com/watch?v=zVdOG_caI4o&t=16s) with no luck so far.

 

Thank you Esri Community, you are my only hope!!!

0 Kudos
3 Replies
EricWagner3
New Contributor II

Hi Jennifer! Did you set up this workflow recently? Or has it been working for a while and stopped working recently?

Here are a few things to try (simple to complex). I apologize if any of these come off as too easy, but sometimes it's the little things...

1) Log out of Survey123 and log back in on your mobile device; try the workflow again

2) Delete the downloaded survey in Survey123 and then redownload it in Survey123. Go through the Field Maps workflow to create a new related record

3) Ensure that you have the latest version of Survey123 installed on your mobile device; it can be updated through the Apple or Google Play stores

4) Ensure that you're using the latest version of Survey123 Connect to build/publish your survey; the latest version is 3.13. If you need a newer version, download and install it. This won't impact your existing surveys. Republish the survey. Update the survey on your mobile device before trying the workflow again.

5) Uninstall and reinstall Survey123 on your mobile device. Be sure to submit any surveys in your outbox on your device first, they'll be deleted when you delete the app!

6) Double check the URL you built in Survey123. Make sure it has the right structure as shown at 11:26 in the video:

arcgis-survey123://?itemID=[Item ID]&field:ParentGUID={GlobalID}

Specifically, what item ID did you use? It should be the item ID of the Survey123 survey item in ArcGIS Online. Sometimes people will use the item ID of the hosted feature layer; this is incorrect.

Give these a try!

I wanted to touch on why submitting a survey directly with Survey123 doesn't link your submissions to features. Remember that this workflow is powered by the GlobalID value being copied from the parent feature to the ParentGUID field of the related record. This is how inspection records are paired with the correct parent feature. Specifically, the last part of the URL in the web map (&field:ParentGUID={GlobalID}) tells GIS "Hey! When you open the survey, copy the GlobalID value from this feature I clicked on and paste it into the survey's ParentGUID field." As a result, the GlobalID and ParentGUID values are linked when you use Survey123. If, however, you open the survey using ONLY Survey123, no GlobalID value is copied from a parent feature and pasted into the related table. As a result, the new inspection you submit has a blank ParentGUID field value and is not linked to any parent feature. It's considered an "orphan." It sits in the related table but isn't actually related to anything in the parent layer. In short, you need the ParentGUID field to be populated and the URL does this for you in the Field Maps/Survey123 workflow. Survey123 submissions will still be stored in the table, but they won't be related to a parent feature.

0 Kudos
jgoldman
New Contributor III

Hi Eric,

Thank you so so much for responding. I retried the workflow with a different inspection (using only one feature related to two inspection tables). This time it absolutely WORKED (yay!)! 

However what I was originally having issues with was when using multiple features relating to a single inspection table. Maybe this is not a function of the workflow? If that is the case, perhaps it would be best to create multiple forms for each feature even if they are the same inspection? Just thinking of possible work arounds if I'm not able to get the other (seemingly more complicated) survey up and running. 

Again, thank you so much for your response!

-Jenny

EricWagner3
New Contributor II

Hi Jenny,

Great job! Glad you got it working!

Ah! I see! Great test of the software though! I tried that once a few years ago... trying to put everything into one table. I ran into similar issues.

My recommendation is to have a seperate related tables for separate workflows. As you've seen, it's possible to have multiple tables related to a single feature and this is quite common in many industries. For example, I've seen many users who have two related tables attached to one hydrant feature class. One table is for hydrant flushing workflows and the other is for hydrant inspection workflows. Each related table has their own Field Maps "Map" and each table has their own survey.

There is a bit of initial effort needed to initially pull this together, but the perk is that if you need your hydrant inspection data, that's all in one table that you can sort/query. If you need your hydrant flushing data, that's in it's own table. The granualrity can help in the long run for exploring/understanding your related data.

But I'm curious, what did you mean by "even if they are the same inspection?" Is there a reason why you'd want two tables for the same inspection? If it's the same inspection (from a data management perspective) wouldn't it make more sense to just have one inspection table?

Thanks,

Eric

0 Kudos