Survey123 error when sending form with required non-relevant fields

4415
8
09-03-2020 04:12 PM
AdrianDoss
New Contributor III

I have a very simple survey. It has several required fields and some of them have an expression in the Relevant column in the XLSform (for simplicity's sake, 1=0 in the Relevant column hides the field). 

My survey is based on an existing feature service in our portal, in which the required fields are set to not nullable.

The questions are not in a group or a repeating group. Survey123 version 3.10.323

I publish the survey and it all works as it should except when I send the completed form to our portal. The first time I send it, it gives an error - see screen cap below. The error in the ArcGIS Server Manager is also shown below.

Survey123 send error

The strange thing is if I go to the Survey123 outbox, edit the form again, don't change anything but just send it, it works the 2nd time around. This behaviour is consistent. As well, the surveys in the Survey123 outbox won't send if you click the Send icon at the bottom of the outbox - it gives the same error as shown above.. 

Has anyone encountered this problem and do you have a fix or workaround?

0 Kudos
8 Replies
by Anonymous User
Not applicable

Hi Adrian,

What version of Portal are you using? And what version of Survey123 Connect did you publish the survey with? Are you able to provide a copy of your xlsx file so we can take a closer look? Also any files from the media folder if they are required to make the survey work correctly.

If you have any steps or workflows that make this issue occur, such which questions to complete and with what values.

Also, with the above error screenshot, if you select OK and then select the red error icon on the survey record in the Outbox, you should get a detailed error message. Can you provide that information if possible?

From the server error message, it looks like you have field in the feature layer that is not nullable, however you are trying to submit a null value to it. When you open the survey from Outbox again, it may be changing the null value to a blank ("") value which are treated differently by the server.

Regards,

Phil.

0 Kudos
AdrianDoss
New Contributor III

Hi Phil

We are running portal version 10.8.

I used Connect Version 3.9.120.

I have simplified the attached example file attached to its bare minimum. This is based on a simplified existing feature service.

The “required” column mirrors what is set up in the feature class- whether or not the field is nullable. No files in the media folder.

The “relevant” column just says the field is relevant if the user selects “yes” in the first answer.

If you select ‘no’ for the first answer, the other fields are not shown as they are irrelevant. BUT if you do this and send, this causes the error.

This consistently produces the error the first time you send the form, if you re-edit (no need to change any data) and send it consistently sends the data without an error.

If you simply try sending directly from the outbox, it also fails.

The error messages from the app and ArcGIS Manager are also shown below.

Cheers

Adrian

0 Kudos
by Anonymous User
Not applicable

Hi Adrian,

Thanks for sharing your xslx file and additional screenshots. Have been busy working on a few other issues this week, so will take a look at your issue today or Monday and getback to you early next week.

Regards,

Phil.

0 Kudos
ZacharySutherby
Esri Regular Contributor

Hello Adrian Doss‌, 

Thank you for passing along those resources for review on our end! I have been taking a look into the behavior and was able to reproduce the same behavior on my end. 

A few things to check: 

- If you add the Feature Service in ArcGIS Enterprise Portal to a new web map can you edit features there, or does it say that feature creation is disabled? 

- If feature creation is disabled when editing from the web map is the Feature Class in the Enterprise Geodatabase Z enabled? (Z values are enabled by default when creating a new Feature Class) You can check this in ArcGIS Pro by right clicking the Feature Class > Properties > Source > Data Source > Coordinates have Z value. 

   - If the data is Z enabled were default Z values configured when publishing the service? If not when you were publishing you should have seen the warning "24034: Layer's data source is z-aware and no default z-value is defined" when analyzing prior to publishing. 

If default Z values were not defined please use this link for reference regarding configuring default Z values with an existing Feature Service. 

Once I had enabled default Z values on my Feature Service I was able to edit the Feature Service from the Web Map and submit surveys from ArcGIS Survey123. 

Additionally since we are working with editing workflows in ArcGIS Enterprise one thing to confirm if the account running the ArcGIS Server Windows Service is a local account, please ensure that account has credentials in the Enterprise Geodatabase matching the exact credentials of the Windows account and has appropriate permissions to the Geodatabase and Feature Classes. 

Thank you, 

Zach

CC Philip Wilson

Thank you,
Zach
StanislausCounty
New Contributor III

Tried your suggestion; feature layer created by survey is listed as service_globalIDstring in hosted folder but there are no options to edit the Z value. Searching for named feature service yields nothing.

0 Kudos
AllenDailey1
Occasional Contributor III

Hi @AdrianDoss ,

Did you ever resolve this error?   I am currently facing the same problem.  Thanks!

Allen

0 Kudos
AdrianDoss
New Contributor III

Hi @AllenDailey1 ,

No, but then again I didn't follow through with the advice given by @ZacharySutherby in the thread regarding default values for Z.

I will experiment today and let you know the outcome.

Cheers

Adrian

0 Kudos
AllenDailey1
Occasional Contributor III

Hi Adrian,

Thanks for your reply!

It turns out that my survey's problem was actually due to a server being attacked by bots and timing out.

Good luck!

Allen

0 Kudos