Send Error - Only on Mobile Device

2228
9
Jump to solution
09-16-2021 05:13 AM
JohnnyHarley232
New Contributor III

Hello all!

   I have a complex survey that includes photos, links, webhooks, and calculations that is currently only giving me an error when trying to send in a survey on any mobile device. When loaded in a browser, it submits just fine. I have attached the XLS form and link to the public survey. I am thinking its an incorrect field name or long string but again, it submits on a browser...

 

https://arcg.is/8qfa0

Tags (1)
0 Kudos
1 Solution

Accepted Solutions
DougBrowning
MVP Esteemed Contributor

I think these are your issue - String or binary data would be truncated.\r\nThe statement has been terminated.

This is saying you are trying to put something in that is too big for the field.  It is usually a string.  Find out which once and bump up the field size like you said.  I would not just do all of them I would try and find it.  Look for anything over 255 chars.

My quick look it may be percent_work_complete field.  You have it set to a size of 5 but you never round the value.  So you are prob getting a percent like 33.333333333333% and that is more than 5 so it is mad.  Remove the size 5 or add a round() in there so it looks pretty and is smaller.

Hope that is it.

View solution in original post

0 Kudos
9 Replies
DougBrowning
MVP Esteemed Contributor

I see a few things.  Overall the form is large and hard to read so I may have missed something.  May want better names then concrrete2 and repeat5.  You also flip between using caps and lower case in field names and sometimes _.

Size is a reserved word.  See the little green box - cannot ignore these they are errors.

DougBrowning_0-1631798821334.png

You named a repeat parentglobalid.  That is a field 123 uses for tracking children.  Not sure if this an error but good chance.

You have green errors on the label field also but that is prob from a copy paste.  In excel always use Paste values or you will mess all the column formulas up.

I hope one of those does it.

0 Kudos
JohnnyHarley232
New Contributor III

Doug, 

 

   Thank you for getting back to me. I have cleaned up the survey.. eliminating mismatched numbers and text in field names and going strictly lower case on field names and published a new survey. I have gotten rid of reserved names as well. 

The only other thing I can think of is if the field lengths need to be increased? Do you think that the app data wont send because field lengths are too long? What would hurt if I just made every field length 1000 for safety? I have attached the new spreadsheet to this thread. 

Thank you!

0 Kudos
JohnnyHarley232
New Contributor III

Heres the link 

https://arcg.is/1iOanf

0 Kudos
DougBrowning
MVP Esteemed Contributor

Not sure.  I would check the log file next in the app.  Turn it on in settings.

0 Kudos
JohnnyHarley232
New Contributor III

Does the log file record errors that are submitted through the Survey123 mobile app? When update the Connect form and then try to submit a record through the Connect app, it says "Data values are valid". 

0 Kudos
DougBrowning
MVP Esteemed Contributor

You need to check the log on the device that is failing.  It should tell you why.

0 Kudos
JohnnyHarley232
New Contributor III

Sweet! Thank you so much. Below is the error from the log file. Main red flag is Feature Service Error, right?

<15>1 2021-09-17T13:36:26Z iPhone ArcGISSurvey123 16961 - [AppStudio@11205 category="XFormFeatureService" function="onSuccess" filename="XFormFeatureService.qml" line="766"] XFormFeatureService: applyEdits:errors: [
  {
    "code": 1003,
    "description": "Operation rolled back.",
    "tableId": 0
  },
  {
    "code": 1003,
    "description": "Operation rolled back.",
    "tableId": 7
  },
  {
    "code": 1000,
    "description": "String or binary data would be truncated.\r\nThe statement has been terminated.",
    "tableId": 11
  }
]
<15>1 2021-09-17T13:36:26Z iPhone ArcGISSurvey123 16961 - [AppStudio@11205 category="qml" function="onFailed" filename="SurveyFolderPageOutbox.qml" line="378"] qml: Feature service error: [
  {
    "code": 1003,
    "description": "Operation rolled back.",
    "tableId": 0
  },
  {
    "code": 1003,
    "description": "Operation rolled back.",
    "tableId": 7
  },
  {
    "code": 1000,
    "description": "String or binary data would be truncated.\r\nThe statement has been terminated.",
    "tableId": 11
  }
]
0 Kudos
JohnnyHarley232
New Contributor III

Do you think it has to do with all the repeats inside of the survey and the GlobalID's?

0 Kudos
DougBrowning
MVP Esteemed Contributor

I think these are your issue - String or binary data would be truncated.\r\nThe statement has been terminated.

This is saying you are trying to put something in that is too big for the field.  It is usually a string.  Find out which once and bump up the field size like you said.  I would not just do all of them I would try and find it.  Look for anything over 255 chars.

My quick look it may be percent_work_complete field.  You have it set to a size of 5 but you never round the value.  So you are prob getting a percent like 33.333333333333% and that is more than 5 so it is mad.  Remove the size 5 or add a round() in there so it looks pretty and is smaller.

Hope that is it.

0 Kudos