Pre-population with previous data in grouped repeats

1. What is the problem? Be very detailed.

We are pre-populating our xlsform with answers from a previous survey wave and have questions that repeat in a grouped repeat structure as below:

Q.1 select_one roomtype
Q.2 select_one heated_time
Q.3 select_one occupied_time

For example, a household may have 5 rooms (roomtype1, roomtype2, roomtype3, roomtype4, roomtype5) each with a different heated_time and occupied_time. I am wondering how I can pre-populate data for each repeat, corresponding to a different room for the same household? I use the pulldata() command for other variables but can only populate data for the first repeat/room with this method in the group repeat structure.

2. What app or server are you using and on what device and operating system? Include version numbers.
We use ODK collect with an xlsform to conduct the survey on android tablets.

5. Anything else we should know or have? If you have a test form or screenshots or logs, attach below.
Current set-up in xlsform:

Thanks in advance!


Not exactly the solution you were looking for, but a low-tech approach could be to repeat your "room " group for as many types you have, e.g. room1, room2, ..., room5.
This way the prepolutation should work.


1 Like