Choice filtering in repeated group of questions

Dear KoBo users,
I’ve been trying to solve an issue for some days on a form with choice-filter in repeated questions.
The form attached is a subset of the full questionnaire. User should be able to choose commodities from a list, then chose among filtered units of measure for the specified commodity and provide a price value.
Filtering is managed also by a file with combination of commodities/units of measure allowed.

The form is working on ODK, but returns an error in KoBo Collect.
Error reported is “XPath evaluation: type mismatch, this field is repeated:”, pointing to a repeated evaluation of the field poss_units.

Glad to receive any suggestion!!

Hi @valerio_axsar,

Kindly please see the communication from the previous post. Going through some examples provided in the same could help sort out your problem.

Hi @Kal_Lam,
The form included in the post has no choice-filter in the repeat-group section. Since the problem is raised only for this combination of factors, I believe it’s not the same.

Hi @valerio_axsar,

Maybe you could add a cascading select question within a repeat group as shown in the image below:

In the survey tab of your xlsform:

Image 1

In the choices tab of your xlsform:

Image 2

Data entry screen as seen in Enketo:

Reference xlsform:

Cascading Select within a Repeat Group.xlsx (12.2 KB)

1 Like