Survey123 Connect - Unable to add a new survey question. Error 400

11-17-2022 10:03 AM
Occasional Contributor

There was recently a question on this. Maybe I'm misinterpreting the question and responses, but I don't think I've got the issue. In that question, it looked like the survey was pointing to a view layer? I seem to be having the same issue, but with the feature layer created by Survey 123 when I originally made the survey.

All I'm trying to do is add a field. When I go to publish the survey, I get the following (which is expected, as I've added a question that wasn't there before.)


I select to add the field and then click the "Publish survey" button. After a few moments, it errors out with the same error the linked question got.



This seems odd, as I've been able to add and remove questions from this survey via Survey123 Connect in the past without issue. I had one issue, which I mentioned in that previous thread, but it was quickly resolved (I wasn't creating the field correctly.)

The layer in question:


Entirely possible I don't know my GIS terminology (Feature Layer = View Layer?) but I don't understand why something would go from working to broken by adding a question.

Roger Asbury
Analyst/Programmer - Fairbanks North Star Borough
0 Kudos
2 Replies
Esri Regular Contributor

Hello @RogerAsbury

Looking at the screen capture supplied it looks like your survey was published using the Survey123 Web Designer. By default the Survey123 Web Designer names the layer in the feature service "survey":



When a survey is created using the web designer a '_form' view layer is created (previously _fieldworker). This view layer is the layer that the form item points to as it's submission endpoint. To confirm this is where your survey is pointing to navigate to your form item in your content and under layers you will see the exact layer the survey is pointing to which if it was published from the web designer should be a view layer: 




For your survey form item is it pointing to a view layer? 


Thank you,
Occasional Contributor

Ok, looking at this, yes, it appears to be pointing at: DEV - Citizen Problem Reporter - New Table_fieldworker, which is a view layer.

But that still leaves me with the question, why would I be able to update questions before but not now, and what can I do to fix it?

Edit - After posting this, I went back to the linked post and followed the instructions there (add the necessary field to the feature layer, and it will propagate to the views.) I could once again publish the survey from Survey123 Connect. I guess this leaves me with the questions above, sans the "How can I fix it", but with the additional question of "Why does this happen, and how can I prevent it in the future?"

Roger Asbury
Analyst/Programmer - Fairbanks North Star Borough
0 Kudos