Select to view content in your preferred language

Time field in repeat loses values when survey is accessed through Inbox (except first repeat)

150
1
a month ago
arc_ticodex
Regular Contributor

I'm encountering a problem with a Survey123 form that includes a repeat section. Inside the repeat, I have four questions, one of which is a time field. This time field is set with esri:fieldType as esriFieldTypeString.

Here's what's happening:

  • When users fill out the survey, all values (including time) are saved correctly to the feature layer.

  • The data looks fine when viewed in the feature service or in the Data tab.

  • However, when the survey is reopened through the Inbox by another user (or the same user) and submitted again, the time field values disappear for all repeats except the first one.

  • All other fields in the repeat load correctly.

    I've attached a screenshot showing repeats 2–5 where the time values are blank, even though they were filled out and saved previously.

     

     

     

arc_ticodex_0-1748000840240.png

 

Has anyone experienced something similar? Could this be related to how time values are handled in repeats or to the use of time question with esriFieldTypeString?

Thanks in advance for any help or insight!

 

0 Kudos
1 Reply
TylerGraham2
Frequent Contributor

The issue is almost certainly forcing a time question to be a string field.  If you're binding it as a field type you need to use a compatible type to the question.  You will want to use esriFieldTypeDate, esriFieldTypeDateOnly, esriFieldTypeTimeOnly as the field type for a dateTime field. 

Note there are some compatibility issues I've encountered with using Date Only and Time Only a table only (e.g. repeat table with no spatial geometry) where the underlying architecture of the table doesn't know how to do DateOnly or TimeOnly, it has to be Date field type.  

0 Kudos