Select to view content in your preferred language

Indexed-repeat Circular reference warning, is it ok to ignore?

265
2
a month ago
JoshB123
New Contributor III

Hi,

I have created a transect survey where repeats collect a number of geopoints (sections), then a geotrace question in the main survey calculates a line based on the sum of the geopoints.

I am also using indexed-repeat as well as position functions so that I can pull coordinates from the previous repeat record then calculate the length of each section. I also use calculationMode=always so that the length of the section automatically updates if the user edits a point.

I have the circular warning when loading the survey as described here:

JoshB123_0-1716041801368.png

However I have tested and tested again, but I can not find an error or mis-calculation in any part of the survey.

My question is - is it ok to ignore this warning if I can't find an error, or have I just not been able to find the error and should therefor not use indexed-repeat?

Here's a snippet of the repeat and also attached the full form

JoshB123_1-1716042217691.png

Thanks

Josh

0 Kudos
2 Replies
DougBrowning
MVP Esteemed Contributor

Yes this got me a few weeks ago.  position seems to be now causing loops all over the place.  If you wait in Connect it actually comes up and warns you at the top right.  This will eventually start crashing your tablets with long log files.  Setting the calc mode to always actually makes this all worse and I do not think you need it.

In the end I went back to the old way of doing it - adding a hidden field with a calc of 1 then using count() or once(count()) to figure out the repeat number.  This fixed my forms.

Hope that helps

JoshB123
New Contributor III

Thanks Doug, really useful to know about issue with log files and also the hidden calc solution!

0 Kudos