Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

Nested relevance equations

  • steve_81
  • steve_81's Avatar Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
9 years 9 months ago - 9 years 9 months ago #123535 by steve_81
Nested relevance equations was created by steve_81
Hi guys,

it's me again. I have trouble with cascaded questions which depends on previous answers.

At first I have a question (code QA) with two possible answers (optionlist) (QA_A1 and QA_A2).
After this I have two other questions (X1 and X2) with each two options again (X1_AA/X1_AB and X2_AC/X2_AD). X1 should be displayed if QA=A1 (relevance equation: QA=="A1"). X2 should be displayed if QA=A2 (relevance equation: QA=="A2"). That works perfect.

Now I want to display a question (code XY) either X1 is AA or X2 is AC. In the other two cases the question shouldn't be displayed.
First idea for the relevance equation in question XY was X1=="AA" or X2=="AC", but failed. I tried nearly everything to enter in the relevance equation of XY but nothing worked (if logics; is_empty, etc.). I become despair. I ecpect the problem, that there is no answer of X2 if I can answer X1 and vice versa, so the equation has no solution?

Attached the minimalized export of the group.

Thank you so much.
Stefan
Last edit: 9 years 9 months ago by steve_81.
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
9 years 9 months ago #123542 by tpartner
Replied by tpartner on topic Nested relevance equations
Try:
Code:
X1.NAOK == "AA" OR X2.NAOK == "AC"

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The following user(s) said Thank You: steve_81
The topic has been locked.
  • steve_81
  • steve_81's Avatar Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
9 years 9 months ago #123546 by steve_81
Replied by steve_81 on topic Nested relevance equations
Hooray!
it works. I tried this thing with the NAOK but obviously not correct.
I didn't know the exact difference before, but the manual helps as usual: "Not Applicable (NA) is alright (OK)" ( www.limesurvey.org/manual/Expression_Manager_HowTos )

Thanks a lot.
Stefan
The topic has been locked.
Moderators: tpartnerholch

Lime-years ahead

Online-surveys for every purse and purpose