Need some help populating repeat records in a report template in a different order than they were entered

904
4
Jump to solution
09-22-2022 07:29 AM
Katie_Clark
MVP Regular Contributor

Hoping I can maybe get some help with brainstorming here...I am working on a survey design but having some issues with how to populate the information into the report template.

I have a repeat that the users will enter information in as they collect data in the field, so it would be safe to assume they will be entered in chronological order. However, in the final report template, these answers need to be grouped in a way that isn't chronological, so it's not as simple as just printing out the repeat data into a table.

Here's an example of the table - you can see that the order in which they were collected (green numbers) are different than the order they are printed. They are grouped so that there is a background and a compliance measurement for each water column strata (bottom, mid-depth, and surface). This is done usually three times a day (so 18 table rows total) but could potentially be much more so I need to allow for that in the survey.

Katherine_Clark_0-1663854988534.png

One idea I had was to try reformatting the survey schema so that each repeat record had questions for the background measurement and compliance measurement, and then the user would just have to navigate to that record in the repeat when they wanted to fill out the rest of it. However, I need coordinates for both points, and I can't have two geopoint questions in a single repeat...

I know that's a lot, but....any ideas are appreciated! Not opposed to using a JS function, but still need to think things through a bit. 

 

Best,
Katie


“The goal is not simply to ‘work hard, play hard.’ The goal is to make our work and our play indistinguishable.”
- Simon Sinek
0 Kudos
2 Solutions

Accepted Solutions
DougBrowning
MVP Esteemed Contributor

Do you just need lat/long or a full geopoint?  If just lat/long you can set the bind esri to null and have as many geopoint fields as you want.  Just use pulldata to grab the lat/long.  I have a form with like 5 in it no prob.

View solution in original post

0 Kudos
LaurenceTait
Occasional Contributor II

It’s not entirely clear what you are trying to achieve here, mostly because I don’t understand the field work flow.


It seems you are saying there could potentially be four or more background and compliance records for each depth, all taken at different times. But the table that you have provided has the records sorted into one background record followed by one compliance record for each depth. IOW each site will have a pair of data triplicates, possibly followed by an arbitrary number of additional data triplicates, but always in triplicates. Is that correct?

I assume that the way that human operators were doing this with paper forms was to simply collect the background recordings, then collect the compliance recordings, and when those were all filled out they moved on the next set of three. If that’s the case, you should probably just replicate that within your repeat.

If you then assign each repeat a unique sorting field by concatenating the type and the time, you can simply do a sort on that field and it should all fall out.

View solution in original post

0 Kudos
4 Replies
DougBrowning
MVP Esteemed Contributor

Do you just need lat/long or a full geopoint?  If just lat/long you can set the bind esri to null and have as many geopoint fields as you want.  Just use pulldata to grab the lat/long.  I have a form with like 5 in it no prob.

0 Kudos
Katie_Clark
MVP Regular Contributor

Good idea Doug, I didn't realize that you could do that, so that's really good to know! 

I do need the points to be able to map the locations of the compliance and background samplings spots, but I could create those points from the coordinates if needed. I also have another idea I'm going to try (having the geometry collected outside the repeat, and including a unique ID to link the data). I'll post back here if I make progress!

Thanks for your response 🙂

Best,
Katie


“The goal is not simply to ‘work hard, play hard.’ The goal is to make our work and our play indistinguishable.”
- Simon Sinek
0 Kudos
LaurenceTait
Occasional Contributor II

It’s not entirely clear what you are trying to achieve here, mostly because I don’t understand the field work flow.


It seems you are saying there could potentially be four or more background and compliance records for each depth, all taken at different times. But the table that you have provided has the records sorted into one background record followed by one compliance record for each depth. IOW each site will have a pair of data triplicates, possibly followed by an arbitrary number of additional data triplicates, but always in triplicates. Is that correct?

I assume that the way that human operators were doing this with paper forms was to simply collect the background recordings, then collect the compliance recordings, and when those were all filled out they moved on the next set of three. If that’s the case, you should probably just replicate that within your repeat.

If you then assign each repeat a unique sorting field by concatenating the type and the time, you can simply do a sort on that field and it should all fall out.

0 Kudos
Katie_Clark
MVP Regular Contributor

Thanks @DougBrowning and @LaurenceTait for your responses!

I needed this form to go "live" as soon as possible, so I used Doug's tip about using a null data type for the point geometry and only recording the coordinates. With that schema, the report printed out the way I needed!

I will definitely investigate the sorting method that Laurence mentioned though, thanks so much for sharing your form!

 

Best,

Katherine

Best,
Katie


“The goal is not simply to ‘work hard, play hard.’ The goal is to make our work and our play indistinguishable.”
- Simon Sinek