How to refer to several questions in same if condition

Mehr
2 Monate 6 Tage her #173868 von UnserFranz
UnserFranz erstellte das Thema How to refer to several questions in same if condition
Hi,

how may I refer to several questions (answer codes of several questions) in the same if condition?
example:
A respondent answered q1, q2, and q3 with answer 2.
May I put some equation like "{if(q1, q2, q3 == 2, 'result 2', 'other result')}" in a follow-up question?

Or do I have to refer to each question specifically?

Thanks a lot

Bitte Anmelden oder Registrieren um an der Konversation teilzunehmen.

Mehr
2 Monate 6 Tage her #173872 von holch
holch antwortete auf das Thema: How to refer to several questions in same if condition
You will most probably have to use AND to join this. Here are a few examples similar to what you want to do.
manual.limesurvey.org/Expression_Manager...ons_.3D.3E_Relevance
{if(q1==2 && q2==2 && q3==2, "result 2", "other result)}

This should do the trick, I guess (not tested).

I'm not a LimeSurvey GmbH member. I answer at the LimeSurvey forum in my spare time. No support via private message.
Some helpful links: Manual (EN) | Question Types | Workarounds

Bitte Anmelden oder Registrieren um an der Konversation teilzunehmen.

Mehr
2 Monate 6 Tage her #173873 von holch
holch antwortete auf das Thema: How to refer to several questions in same if condition
{if(q1==2 AND q2==2 AND q3==2, "result 2", "other result)}

should work as well, I guess.

I'm not a LimeSurvey GmbH member. I answer at the LimeSurvey forum in my spare time. No support via private message.
Some helpful links: Manual (EN) | Question Types | Workarounds

Bitte Anmelden oder Registrieren um an der Konversation teilzunehmen.

Mehr
2 Monate 5 Tage her #173893 von DenisChenu
DenisChenu antwortete auf das Thema: How to refer to several questions in same if condition
Or :side:
{if(coutif("2",q1.NAOK, q2.NAOK, q3.NAOK) == 3, "result 2", "other result)}
:evil:

manual.limesurvey.org/Expression_Manager#Access_to_Functions

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand (or search sondages pro).
An error happen ? Before make a new topic : remind the Debug mode .
Folgende Benutzer bedankten sich: UnserFranz

Bitte Anmelden oder Registrieren um an der Konversation teilzunehmen.

Mehr
2 Monate 10 Stunden her #174222 von UnserFranz
UnserFranz antwortete auf das Thema: How to refer to several questions in same if condition
thanks a lot Denis!

for the sake of understanding: What's the difference between
countif and countifop?
Anhang:

Bitte Anmelden oder Registrieren um an der Konversation teilzunehmen.

Mehr
2 Monate 7 Stunden her #174234 von jelo
jelo antwortete auf das Thema: How to refer to several questions in same if condition
countifop allows to use a operator. countif only matches values.

E.g. countifop("<",2015,year1,year2,year3) is counting years before 2015.

Are you a student conducting a survey? If yes, tell me why you use LimeSurvey?
www.limesurvey.org/forum/development/116...y-you-use-limesurvey
Folgende Benutzer bedankten sich: holch, UnserFranz

Bitte Anmelden oder Registrieren um an der Konversation teilzunehmen.

Mehr
2 Monate 1 Stunde her #174244 von UnserFranz
UnserFranz antwortete auf das Thema: How to refer to several questions in same if condition
Oooh! That's cool :)

Bitte Anmelden oder Registrieren um an der Konversation teilzunehmen.

Jetzt loslegen!

Melden Sie sich jetzt an, und erstellen Sie in wenigen Minuten Ihre erste Umfrage.

Account einrichten

Abonnieren Sie unseren Newsletter

Abonnieren Sie unseren Newsletter für alle Neuigkeiten rund um LimeSurvey
captcha