Automatically passing Geopoint data from parent table to related table

2311
7
Jump to solution
05-27-2019 09:05 AM
VanceWorten
New Contributor II

I have a survey with a geopoint field which passes its coordinates to another geopoint field in a related table. I did this by using the formula pulldata("@geopoint", ${location}, "y")+" "+pulldata("@geopoint", ${location}, "x") in both the default column and the calculation column of the related table's geopoint field. I also set the related table's geopoint field to "read only" because I only want location to be defined in the parent table so that the relate table will inherit the exact same location.

In past versions of Survey123, as soon as the survey was opened the coordinates were automatically passed from the parent table to the related table without the user having to anything with the related table's geopoint field. Now however, the related map on the related table doesn't initially show up at all (see 1 below.) Instead I have to click the refresh button (see 2 below) prior to the coordinates being pulled from the geopoint field in the parent table. I added a lat long text field (see 3 below) which uses the same pulldata formula to test whether or not the coordinates were being properly passed through and they are. 

 

Below is a screenshot of the excel version of the form. (I also attached it in case it's too small .) For the purposes of this illustration I hid all of the columns that were blank.

So my questions are:

1.  Is there any way to make my form work like it previously did where the user does not have to hit refresh button in the related table to get the geopoint values from the parent table.

2.  Is it possible to hide the related table's geopoint field altogether? When I add more than one geopoint field to a survey it can create confusion among the users as some of them think that they need to map the location twice. It also clutters up the survey. If possible I would like to hide the geopoint fields in the related tables.

3.  Am I even going about this the right way? I need the attributes from the related table to be "mappable" and the only way I can figure out how to do this is by adding a geopoint field to each related table that I want to map. Is there another way to map data that is located in a related table? If so, any advice on this topic would be greatly appreciated.

0 Kudos
1 Solution

Accepted Solutions
by Anonymous User
Not applicable

Hi Vance,

The issue with geopoint questions in repeats using calculations and not displaying the calculated value or always showing the GPS location has been fixed. The latest 3.6 beta builds available on EAC include this fix, please test it out and let us know any feedback. You can find the 3.6 beta builds and announcement here.

Regards,

Phil.

View solution in original post

0 Kudos
7 Replies
JamesTedrick
Esri Esteemed Contributor

Hi Vance,

This sounds like an issue that has been addressed for the next release of Survey123.  If you can, could you log in the Early Adopter Community and confirm that the pulldata function is working properly in the 3.5 betas?

0 Kudos
VanceWorten
New Contributor II

James,

Thank you for the suggestion. I downloaded Survey123 Connect 3.5.152 beta from the Early Adopter Community site and at first glance it looked like the problem was solved. When I changed the geopoint location on the parent table, the geopoint location on the related table correctly changed as well for the first related record (see screenshot below). The "Coordinates Test" field also reflected the correctly adjusted coordinates.

However, when I added a second record to the related table, the form spent a few seconds acquiring my current location instead of pulling the coordinates from the parent table geopoint. (The screenshot below was taken during the coordinate acquisition time as you can see by the satellite symbol to the right of "My Survey".)

After acquiring my current coordinates, the related table map show my current location, not the pulled data location from the main table geopoint field as it should have been. This can be seen the the screenshot below in which the two maps are different. (I intentionally smudged my location and coordinates.) The "Coordinates Test" text does show the correctly location of the parent geopoint map however. I used the exact same formula for the "Coordinate Test" text field and the "Relate Location" geopoint field which was as follows: pulldata("@geopoint", ${location}, "y")+" "+pulldata("@geopoint", ${location}, "x")

Attached is the very short (8 lines) Survey123 form for the above screenshots which highlights this issue. I'm pretty sure that I've set it up correctly. As I mentioned in my previous post, in previous versions of Survey123 I didn't have this issue. Any help on this would be greatly appreciated.

0 Kudos
JamesTedrick
Esri Esteemed Contributor

Hi Vance,

I can see the behavior you are describing.  I have filed an issue to look into it.

0 Kudos
BrettStokes
Esri Contributor

Hi Vance,

Just an update on this issue.

We a working on a fix that will address the issue you've described here. The behaviour is occurring due to the timing of initialising a location from within the repeat. You will notice that if you move the parent geopoint while the repeated geopoint is aquiring your location, the repeat location will be immediately pulled from the parent. If that initialising isn't interrupted by moving the parent geopoint (which triggers the coord calculation), you will only get your current location as you described.

A possible workaround for now is to remove the readonly from your repeat geopoint so that you are presented with a recalculate button. Recalculating the location will have the same effect as moving the parent location.

Brett

0 Kudos
by Anonymous User
Not applicable

Hi Vance,

The issue with geopoint questions in repeats using calculations and not displaying the calculated value or always showing the GPS location has been fixed. The latest 3.6 beta builds available on EAC include this fix, please test it out and let us know any feedback. You can find the 3.6 beta builds and announcement here.

Regards,

Phil.

0 Kudos
VanceWorten
New Contributor II

Hi Phil,

I tested it out and it works great now. Thanks so much.

Vance

ChaimSchwartz4
Occasional Contributor

Hello phillip Wilson‌ - are you able to confirm if passing geopoint coordinates from the "parent" record to a repeat geopoint is not supported in the web form? I have successfully been using it in the mobile app, but it doesn't seem to work in the web form.

0 Kudos