Filtering from a multiple question to a Ranking question

Im building a form and want to filter a ranking question from a multiple question.How can I do this?Lets say Q1-is the multiple question and Q2 is the ranking question-how can I filter those options selected at Q1 to Q2.

Hi @mnelson,

Do you mean you wish to create a ranking question for Q2 based on the response selected from Q1? Could you kindly list a sample of questions for Q1 and Q2 along wit the choices so that we could help you out if it’s doable in KoBoToolbox.

Have a great day!

Hi @Kal
Yes I want to create a rankink Q2 the selections at Q1 as in the below Example.
Q1.What type of crop do you cultivate you in your parcels?

Other specify

Q2.If additional activity requires some time, which activity would you work less?Top 3 activity to work less on

Hi @mnelson,

Maybe you could try this out as outlined in the image below:

In the survey tab of your xlsform:

In the choices tab of your xlsform:

Image 2

Data entry screen as seen in Enketo:

Reference xlsform:

Ranking with Cascading.xls (28.5 KB)

Have a great day!


Thanks Kal,really appreciated.


Hello @mnelson,
Few hints in addition to solution from @Kal_Lam :

  • You - indirectly - force the respondent to select 3 items (or more) in the 1rst question, as the all 3 rankings are mandatory (checked on validation or on next in KoBoCollect). E.g. if you check less only 2 for example, the 3rd ranking will still be asked, but there is no option!
  • If the user moves back to the 1st question and deselects a choice ranked in the 2nd question, this ranking will be removed/emptied.
  • If the user first enters the 3rd ranking and than moves back and ranks the same item on ranking 2, the 3rd ranking will be removed/emptied. (Same for other back choice of the same, like 2nd and then 1st, or 3rd and then 1st).

The first issue might be optimised by applying a count-selected filter (relevant) for each ranking question (calculate variable preferable, as used 3 times).

What about a respondent who doesn’t find an item fitting for “a Man” in your 1st list? Maybe Add NONE of these or Other (specify)? (And adapt the form logic).

Healthy regards


This is a good idea,thanks @Wroos

1 Like

Ei @Kal_Lam, many thanks for this. It is very useful.

I have used this approach a few times and I would like to know it it is possible to:

  1. Add an “other” (which I have already done)
  2. Add a “specify” (which I have also already done)
  3. The “specify” text to appear in the 3 ranking questions. I am trying to achieve this but I have been unsuccessful. Any advice on how to get it?

Any help will be much appreciated.



Welcome back to the community, @17dan1991! Would you mind sharing your workaround made so far so that the community could add to it.

Yes sure. This is the xls form I have got so farRanking with Cascading.xls (29.5 KB)

So ideally I would like to add the option of specify, and the text from the speciffy to appear if it is 1,2 or 3rd factor

Hi @17dan1991
I would recommend a different approach where you create a second select multiple that is auto filled by the first multiple select

Ranking with Cascading.xls (31 KB)


1 Like

Stephane, this option sounds great!

I’m having a bit of trouble because the custom label doesn’t display correctly in the dropdowns. The dropdown shows ${specify} instead of the text entered. It does display correctly in the second “select multple”, however.

Here is what Enketo displays:

Any idea how to fix this?

Have you tried with with the Collect android app? The Collect android app should support this.

Dear Stephanealoo,

When I try out your approach in ODK - XLSForm Online, I receive the following error:

I changed nothing, but the problem persists. What could cause the problem? I would like to use this approach in my ODK form, if I can solve this.