- Beiträge: 32
- Dank erhalten: 0
Marking array answers based on previous array
1 Jahr 2 Monate her #161138
von vadikcoma
COM_KUNENA_MESSAGE_CREATED_NEW
Hello, first of all - thanks for the awesome and free software!
We have a following survey - opros.comadev.noc.lv/index.php/836943?lang=lv - there are 2 arrays and questions are about radio-station audience.
First question - How often do you listen to this station
Second question - How do you listen to this station
My task is to make options from second array being marked as NOT LISTENING in case there answer I DONT KNOW THIS STATION in first array.
In my mind there should be this logic:
if array_1 question_1 answer = A6 then
array_2 question_1 answer A4 = "yes"
We have a following survey - opros.comadev.noc.lv/index.php/836943?lang=lv - there are 2 arrays and questions are about radio-station audience.
First question - How often do you listen to this station
Second question - How do you listen to this station
My task is to make options from second array being marked as NOT LISTENING in case there answer I DONT KNOW THIS STATION in first array.
In my mind there should be this logic:
if array_1 question_1 answer = A6 then
array_2 question_1 answer A4 = "yes"
Bitte Anmelden oder Registrieren um an der Konversation teilzunehmen.
Weniger
Mehr
- Beiträge: 7798
- Karma: 618
- Dank erhalten: 2286
1 Jahr 2 Monate her #161143
von tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
COM_KUNENA_MESSAGE_REPLIED_NEW
Why not place relevance on the sub-questions in Q2 so they don't show at all if the corresponding row in Q1 is "A6"?
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Bitte Anmelden oder Registrieren um an der Konversation teilzunehmen.
1 Jahr 2 Monate her #161144
von vadikcoma
COM_KUNENA_MESSAGE_REPLIED_NEW
Could you please advise me how to do it? I’m totally new to this
Bitte Anmelden oder Registrieren um an der Konversation teilzunehmen.
Weniger
Mehr
- Beiträge: 7798
- Karma: 618
- Dank erhalten: 2286
1 Jahr 2 Monate her - 1 Jahr 2 Monate her #161149
von tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
COM_KUNENA_MESSAGE_REPLIED_NEW
When editing the sub-questions you can place relevance on them to hide/show them based on answers to previous questions.
So, for example, if your first question has a code "Q1" and sub-question codes "SQ001, SQ002...", the relevance for the Q2 sub-questions would look something like this.
It basically says only show this row if the corresponding row in Q1 is answered and is not "A6".
Check out Expression Manager in the manual for more info - manual.limesurvey.org/Expression_Manager
So, for example, if your first question has a code "Q1" and sub-question codes "SQ001, SQ002...", the relevance for the Q2 sub-questions would look something like this.
It basically says only show this row if the corresponding row in Q1 is answered and is not "A6".
Check out Expression Manager in the manual for more info - manual.limesurvey.org/Expression_Manager
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Last edit: 1 Jahr 2 Monate her by tpartner.
Folgende Benutzer bedankten sich: vadikcoma
Bitte Anmelden oder Registrieren um an der Konversation teilzunehmen.
Weniger
Mehr
- Beiträge: 7798
- Karma: 618
- Dank erhalten: 2286
1 Jahr 2 Monate her #161150
von tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
COM_KUNENA_MESSAGE_REPLIED_NEW
Here is a sample survey that also has relevance on Q2 to only show it if there are some answers in Q1 and not all Q1 answers are "A6".
count(that.Q1) > 0 AND count(that.Q1) != sum(Q1_SQ001=='A6', Q1_SQ002=='A6', Q1_SQ003=='A6', Q1_SQ004=='A6')
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Bitte Anmelden oder Registrieren um an der Konversation teilzunehmen.