Display repeat group answers

Hi all,

I want to add a confirmation page at the end of my form so that the mobile user can see some data they entered and confirm that they are correct before they complete the form. I’m hoping to include the most important questions and some of them are answers to repeat group questions, e.g. the names of children in the household (we ask a set of questions, including their names, about each child and have a “child_repeat” repeat group). It looks like label cannot display repeat groups and I think a multiple-choice lookup table can but we don’t want to ask a question here. We just want to list all the information we want to display and ask a single question at the end like “Are they correct”, and if not, “Please go back and edit”. Is there any way we can do it?

Just wanted to check if it is doable in CommCare. If it’s not, I will let my team know as well. Thanks!


You can use the join() function to provide some amount of summary of previous repeat groups. If you use " " as part of the separator, it will split up the joined strings by newlines so you can have them appear in a list.

If you summarize the specific details you want to summarize in a hidden value in the repeat, that will let you show the interaction I think you are looking for.

Thanks, Clayton! What is the interaction that you were referring to?

I tried the join() function
join(" ", <output value="#form/mothers_repeat/mother_name/>)

and got this error:

XPath nodeset has more than one node [/data/mothers_repeat[1]/mother_name[1];/data/mothers_repeat[2]/mother_name[1]]; cannot convert multiple nodes to a raw value. Refine path expression to match only one node.

I’ve had this error before but that was a different matter (use repeat group in another repeat group, but this question is using repeat group in a label).

Put that code in a hidden calculation
then put that hidden calculation in the label display text

i think that’ll solve your problem