Select to view content in your preferred language

Upcoming changes to Survey123 web form's query parameters

12030
20
02-19-2020 09:53 AM
IsmaelChivite
Esri Notable Contributor
14 20 12K

[Updated March 28, 2020]

[Updated April 3, 2020]

What is changing?

 

Survey123 version 3.4 introduced the ability in the Survey123 web app (aka web form) to update and view existing GIS features using the mode URL query parameter. Essentially, this query parameter allows you to pass the objectId of an existing GIS feature to preload data into a web form to view or update its contents. More details about use cases and syntax can be found at:

We will be introducing changes to the mode query parameter in version 3.9, replacing the use of objectId with globalId as the means to set the GIS feature record to be updated or viewed. For example:

* [Update March 28,2020] To facilitate migration to the globalId parameter, we will be extending support for the objectId parameter until 3.10.

VersionobjectIdglobalIdComments
3.8 and earlier versionsSupportedNot supported
3.9SupportedSupportedUse this version to migrate!
3.10 and beyondNot supportedSupported

Why are we making this change?

 

The use of globalId to set the GIS feature to be updated is less susceptible to manipulation by end users.

 

How will this change affect me?

 

This change can potentially break existing workflows where static or dynamic links are used to update/view existing features using a web form. For example:

  • If you have embedded a web form within a dashboard to edit the selected record from a list element, this change in Survey123 query parameters can break your existing Survey123-Dashboard integration.
  • If you have a custom web map pop-up with a link to a survey web form in edit mode, this change may break your workflow.
  • If you have shared static HTML links in websites, e-mails or by other means, the links may stop loading the data to be updated.

Any survey published prior to 3.9 will continue to work normally and without modification to the query parameter, unless version locking is disabled or the survey is republished with 3.9 or a newer version.  

 

What should I do about this?

 

Now that 3.9 is released, it is time to act:

  1. Start now documenting web applications or workflows where you make use of the mode=edit or mode=view URL parameter.
  2. Re-publish your surveys affected and switch your URL calls from using the objectId parameter, to using the globalId parameter.

VersionobjectIdglobalIdComments
3.8 and earlier versionsSupportedNot supported
3.9SupportedSupportedUse this version to migrate!
3.10 and beyondNot supportedSupported
Tags (1)
20 Comments
SueJohnston
Regular Contributor

Hi Ismael Chivite

I'm currently embedding a survey into a dashboard, I'm using version 3.9.  The selection worked until I tried to add a filter to the list, now I get a random no data return, and I say random because sometimes it shows the data, sometimes it doesn't.  I thought maybe I should change the objectID to GlobalID to see if this resolved the issue but now i'm getting an error "Editing is not possible because the globalID parameter was not provided".  The globalID is in the data, how do i provide it?  Are filters on lists that have action set to an embedded survey, even possible?

Thanks, I love using survey123!

Sue

JonathanMcDougall
Frequent Contributor

Sue Johnston‌ Hi, I setup a dashboard with integrated survey back in March - I thought the same as you with regards to updating the capabilities. 
To fix;

Download the latest version of Survey123 Connect, assuming this is where you created the survey, and install. To update your published survey, sync the survey back to connect and re-publish, this updates it. Got to Survery123 only, choose your survey and Settings, make sure you have latest version selected.

Within the dashboard, make sure you update the url with globalid={globalid} and update this reference through-out any associated list panes etc..

Hope this is clear?

SueJohnston
Regular Contributor

Thanks Jonathan, I will try this

DenaS
by
Emerging Contributor

I've been running an online survey since February via the Connect app (v 3.9.120). I enabled users to be able to edit surveys after they have been submitted (I use integromat, following:https://community.esri.com/groups/survey123/blog/2019/05/24/survey123-tricks-of-the-trade-editing-re.... ) My surveys are now showing the following error "Editing is not possible because the objectId parameter is deprecated. Please use globalId instead." I read in this blog that I need to migrate to the GlobalID but I am not clear on how to do this. Do you have specific directions on how to migrate to the globalID instead of the ObjectID in Integromat?

Secondly, What will this change to the 100 survey responses I've received prior to now? Will those people who received links to edit their surveys no longer be able to edit their surveys?? If so, how would I reconcile this? Similarly, what does this do to data integrity?

Many thanks for your answers.

JonathanMcDougall
Frequent Contributor

https://survey123.arcgis.com/share/(your****survey****id)?mode=edit&globalId={globalid}&version=late... 

This is the syntax of the link that you need to change in the embedded element of your dashboard. You also need to ensure, where the ObjectID was used in the other details panes, it's changed to GlobalID. Within Survey123 online I made sure I selected "Always Use Latest Version" from the settings tab, so keeps things current.

Regarding any shared links or data already in the database, nothing changes. I was wary of this as the dashboard I was running formed part of a critical service to our community during our Covid-19 response, I didn't want to take down to lose the data, so made a copy to check first. I can assure you that there's no need to worry, everything is retained as per the original dataset.

DenaS
by
Emerging Contributor

hello again. I was able to update the syntax as you suggested as well as make the proper changes to use a globalID in integromat. However, for the surveys taken previous to this objectID change, the link sent to the survey taker to edit the survey is still not working. For example, if someone clicks on their link to edit the survey, they still get the error message when the survey opens: ""Editing is not possible because the objectId parameter is deprecated. Please use globalId instead."" Does this change away from the ObjectID break all previous survey links??

JonathanMcDougall
Frequent Contributor

Sorry for the crude graphics.

So, within the area of 1 in the image above;

First Tab "Call Details" is just a list pointing to the survey dataset. In the List options, under Line Item Template, ensure you have the {globalid} in the list of exposed fields.

Second Tab "Contact Form" is just the web version of the Survey123 Connect survey I created. As mentioned in the previous post, this is just the url with the edit mode and the globalid field set.

In area 2;

These tabs are just filtered lists, again of the dataset. Once again, in the List Line Template options ensure the {globalid} field is in the options. As you can see from above, I also made the field as small as possible or just turn the font colour to white.

I've just doubled checked the first test record I created, back at the end of March, and updated a field then submitted the update, I've no issues whatsoever. with a "pre-globalid" record.

Hope this helps? If not, please ask, I'll maybe post a video to show exactly what's what.

JamesTedrick
Esri Esteemed Contributor

Hi Dena,

If version locking is turned on (which is the default), then a survey published with 3.9 or earlier will continue to support objectID.  Turning the version locking off, or republishing with 3.10, will cause objectId to no longer work.

JonathanMcDougall
Frequent Contributor

Absolutely, I completely forgot to mention this point. Sorry.

DenaS
by
Emerging Contributor

Thanks James Tedrick‌. I do have my settings to use the most recent version. This explains why my surveys links were failing with the recent update.

 - I changed the settings to go back to 3.9 and the editable link for previous and new surveys now works. However, when the survey initially loads, all the code shows on the page for about 4 seconds before the survey renders correctly. Is there a fix for this?

- If I remain in the 3.9 version, is it still advised to use the globalID moving forward in integromat?

While It was advised to migrate to 3.10 I loose all previously submitted "edit survey" links, therefore I think I have to stay in the older version (3.9), is this right?

Thanks!

JamesTedrick
Esri Esteemed Contributor

Hi Dena,

- The HTML code loading was an issue fixed with 3.10.  Unfortunately you will either need to upgrade the links sent out or have the rendering be visible.

- Yes, it is still advisable to continue to migrate to GlobalID-based links.

As mentioned, you will either need to update the links sent or remain at 3.9 for the links to work.

TexasMike
Occasional Contributor

We've been using the URL parameters to display forms using mode=view without an issue.

Currently having an issue with the exact same URL not returning the record with message "The survey does not exist or is not accessible." It acts like it can't find the record or possibly an issue with the permissions.

If I change the 'mode=view' parameter to 'mode=edit' the form populates as expected.

View: https://survey123.arcgis.com/share/SURVEYID?portalUrl=OURPORTAL&mode=view&globalId={D0E42366-4732-46...}

Edit: https://survey123.arcgis.com/share/SURVEYID?portalUrl=OURPORTAL&mode=edit&globalId={D0E42366-4732-4696-BA8E-3B8DDCCC917B}

I suspect it is something with the _stakeholder view and permissions. I've deleted the view and that didn't work. I've tried changing the settings in the collaborate tab to even allow Everyone(Public) access and still no change.

We've also been having issues with the survey123 website not displaying the correct number of records. I found a post https://community.esri.com/thread/247938-duplicate-objectidsfeatures-in-view-layer and after enabling sync and editing was able to resolve the discrepancy.

We're @ Enterprise 10.7.1 and the form was published with 3.10.239

DenaS
by
Emerging Contributor

Hi James,

- I never had an issue with the HTML code loading previous to the 3.10 update. Have there been any advances to this? It severely changes the look and feel of the survey for the people I am asking to complete the survey

- You mentioned above that I have the option to upgrade the links sent out - do you mean to say I can change the editable links so that the previous surveys have a link that would work in 3.10. Or are you just speaking towards changing the link for future surveys?

Thank you

CillianAdamson_NZTA1
Occasional Explorer

Hi @IsmaelChivite,

I have a Survey123 WebFrom issue that it would be great to get an opinion on.

The context of the project is that I want to use Survey123 to capture and ‘maintain’ a picture of resilience risks on the State Highway network. Survey123 is the preferred option as I utilize calculations on string inputs to determine risk scores and therefore categorization.

I have configured this in Survey123 Connect to capture risks as points , and utilizing the calculation option I am simultaneously populating the same fields in a repeat. It is set up this way so that when a risk up revisited down the line, utilizing the Inbox function, as the user updates the risk they simultaneously create a new related record. Back in the office someone can then select a record within a WebApp and in the pop up view the current attributes, and in the related records tab see a related record for each visit and the attributes for each visit assessment - viewing the change in risk over time. 

CillianAdamson_NZTA1_1-1606362193071.png

 

To be clear this works perfectly using the mobile app.

 

However, I also need to use a Survey123 WebForm embedded in a Dashboard to update a risks, as some staff will operate by desktop only (the Survey123 desktop app is not currently available to use due to IT security).

I had utilized (and since removed) the List widget to filter the Embed Content (Survey123 WebForm) via URL parameters (pushed globalID). Once a selection is made the survey refreshes with the attributes of the selected record (as expected). However where the issue comes in is with repeats, as with this process once a revised survey is submitted, deletes all related records with the exception of the latest one. I don't want to edit repeats, simply create a new one upon submission of an edit. 

I have removed the functionality to select from the List to update via the embedded Survey123 WebForm as I don’t want users deleting related records during the currently live pilot.

It would be great to know if there was some sort of work around to get this to work?

Thanks,

Cillian in New Zealand

IsmaelChivite
Esri Notable Contributor

@CillianAdamson_NZTA1  The Survey123 web app cannot edit data with repeats. This is a known limitation.  I suggest you submit a new Enhancement Request through Eagle Technologies, our Esri Distributor in New Zealand. Thanks a lot!  

ScottLehto1
Occasional Contributor

Is there directions on how to modify an existing AGOL Dataset from using an ObjectID to a Global ID Relationship? 

Does this happen in desktop(ArcMap or Pro), AGOL, or Survey123 Connect? All of the above?

LJackson29
Frequent Contributor

Hi - 

I am trying to create the following workflow:

1. People request information using a survey123 form

2. Requests are tracked in an ArcGIS Dashboard 

3. Editors can update data in the feature service associated with the Survey123 form using an embedded webform in the dashboard.

I having done the following:

1. Created the Request Form in Survey123 connect and published

2. Created a second Editing Form in Survey123 connect with the submission URL=Submission URL of Request Form

3. Embedded the Editing Form in the dashboard using the following: https://survey123.arcgis.com/share/2f1ff15947b24aec9b7b322133751701?mode=edit&globalId={globalid}&ve....  Where the ID is the form ID of the Editing Form

However, I am getting the following error "Editing is not possible because the record specified by the globalid parameter cannot be accessed". Why is this error occurring, and how does one pull up a record to edit?

Many thanks!

Leila

 

MJBiazar
Esri Contributor

Hi @TexasMike ,

I know your post here is from about a year ago. But the issue you were experiencing with not being able to access your existing surveys in view mode should be resolved by republishing your survey from a newer version of Survey123 Connect app (version 3.12).

 

Best,

MJ

TexasMike
Occasional Contributor

@MJBiazar thanks for the reply. Our issue has already been fixed.

JackFanZhang
Regular Contributor

Hi @MJBiazar @IsmaelChivite ,

I'm using Survey123 Connect 3.16 and we publsihing survye123 by refering to our portal, just like what TexasMike did. e.g. https://survey123.arcgis.com/share/b95811a5839f4d53801b92dcd5fa6258?portalUrl=https://myportal.com.a...}

The mode=view works fine on hosted feature layer. However, if the survey form refers to a non-hosted feature layer (e.g. refering to our SDE databse), it returns the following error with a non-populated form.

You do not have permission to submit this survey record. 

  • The feature service for this survey does not exist or is not accessible.

Interestly, if I set mode=edit and open the link as Viewer-type user, the form gets popularted, though the submit button is disabled, which is fine for us, as we would just want to provide a direct link to our Viewre-type users to view a specfic submitted survey form.

Could you please confirm if mode=view works with survy form refering to non-hosted feature layer?
 
Thanks.