- Posts: 11
- Thank you received: 3
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
problems randomising survey using rand().
- FeCanever
- Offline
- New Member
Less
More
5 years 3 months ago #179378
by FeCanever
Replied by FeCanever on topic problems randomising survey using rand().
Hi, Tony,
first of all thanks for the quick answer. In my survey there will be 8 conditions, but I forgot to say that for now I was testing with 2. Sorry about that.
So you're saying it is possible to add the assigned info (random == 1, random == 2, and so on) to the relevance field for group instead of doing that for each question inside the group.
I just did what you said for the 2 groups I'm testing with and no question groups are displayed when I preview the survey.
What do you think I'm doing wrong?
first of all thanks for the quick answer. In my survey there will be 8 conditions, but I forgot to say that for now I was testing with 2. Sorry about that.
So you're saying it is possible to add the assigned info (random == 1, random == 2, and so on) to the relevance field for group instead of doing that for each question inside the group.
I just did what you said for the 2 groups I'm testing with and no question groups are displayed when I preview the survey.
What do you think I'm doing wrong?
The topic has been locked.
- FeCanever
- Offline
- New Member
Less
More
- Posts: 11
- Thank you received: 3
5 years 3 months ago #179380
by FeCanever
Replied by FeCanever on topic problems randomising survey using rand().
Hi again,
I tried ((random == "1")) instead of ((random == 1)) and now it works!
Thanks a lot!
I tried ((random == "1")) instead of ((random == 1)) and now it works!
Thanks a lot!
The following user(s) said Thank You: DenisChenu
The topic has been locked.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13597
- Thank you received: 2487
5 years 3 months ago #179383
by DenisChenu
I think you must report it.
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Replied by DenisChenu on topic problems randomising survey using rand().
It's an issue , because it work like you say in 2.6lts and 2.73.FeCanever wrote: Hi again,
I tried ((random == "1")) instead of ((random == 1)) and now it works!
Thanks a lot!
I think you must report it.
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10099
- Thank you received: 3589
5 years 3 months ago #179404
by tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic problems randomising survey using rand().
Yes, the result of rand() should be recognized as a number.
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13597
- Thank you received: 2487
5 years 3 months ago #179407
by DenisChenu
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Replied by DenisChenu on topic problems randomising survey using rand().
In fact : not exactly .
Because you can force it as number .
BUT Something.NAOK == 1 must work if Something.NAOK === "1" and Something.NAOK === 1
See this old discussion here : bugs.limesurvey.org/view.php?id=8324 (at this time : i think we must compare it as string if === "1")
And old issue here : bugs.limesurvey.org/view.php?id=7805
And new issue here : bugs.limesurvey.org/view.php?id=14337
There are a major issue in Expression for all numeric value in 3.X
Because you can force it as number .
BUT Something.NAOK == 1 must work if Something.NAOK === "1" and Something.NAOK === 1
See this old discussion here : bugs.limesurvey.org/view.php?id=8324 (at this time : i think we must compare it as string if === "1")
And old issue here : bugs.limesurvey.org/view.php?id=7805
And new issue here : bugs.limesurvey.org/view.php?id=14337
There are a major issue in Expression for all numeric value in 3.X
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10099
- Thank you received: 3589
5 years 3 months ago - 5 years 3 months ago #179412
by tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic problems randomising survey using rand().
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Last edit: 5 years 3 months ago by tpartner.
The topic has been locked.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13597
- Thank you received: 2487
5 years 3 months ago #179415
by DenisChenu
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Replied by DenisChenu on topic problems randomising survey using rand().
yes, but i think it must not depend on the way it was saved too
@FeCanever : can you test with manual.limesurvey.org/Question_type_-_Eq...y_.28numbers_only.29 to ON ?
And can you report the issue with a simple survey (2 group only)
@FeCanever : can you test with manual.limesurvey.org/Question_type_-_Eq...y_.28numbers_only.29 to ON ?
And can you report the issue with a simple survey (2 group only)
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
- FeCanever
- Offline
- New Member
Less
More
- Posts: 11
- Thank you received: 3
5 years 2 months ago #179449
by FeCanever
Replied by FeCanever on topic problems randomising survey using rand().
Hi,
I tested with manual.limesurvey.org/Question_type_-_Eq...y_.28numbers_only.29 to ON and it now works if I use ((random == 1)) and ((random == 2)), without the quotes. Awsome!
Sorry about my silly question, but what do you mean when you ask If I can report it? Do you mean here to you guys and to support?
I tested with manual.limesurvey.org/Question_type_-_Eq...y_.28numbers_only.29 to ON and it now works if I use ((random == 1)) and ((random == 2)), without the quotes. Awsome!
Sorry about my silly question, but what do you mean when you ask If I can report it? Do you mean here to you guys and to support?
The following user(s) said Thank You: DenisChenu
The topic has been locked.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13597
- Thank you received: 2487
5 years 2 months ago #179455
by DenisChenu
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Replied by DenisChenu on topic problems randomising survey using rand().
Support forum : the place to ask free help by LimeSurvey user.
Bug report : www.limesurvey.org/community/bug-tracker the place to report bug.
It's not because i'm on Forum and on Mantis than you don't have to report issue
A bug not reported on mantis is a bug not fixed
Bug report : www.limesurvey.org/community/bug-tracker the place to report bug.
It's not because i'm on Forum and on Mantis than you don't have to report issue
A bug not reported on mantis is a bug not fixed
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
- FeCanever
- Offline
- New Member
Less
More
- Posts: 11
- Thank you received: 3
5 years 2 months ago #179464
by FeCanever
Replied by FeCanever on topic problems randomising survey using rand().
Ok, great. I'll do that!
The following user(s) said Thank You: DenisChenu
The topic has been locked.
- FeCanever
- Offline
- New Member
Less
More
- Posts: 11
- Thank you received: 3
5 years 2 months ago - 5 years 2 months ago #179477
by FeCanever
Replied by FeCanever on topic problems randomising survey using rand().
Denis,
When I was getting ready to report the bug in the support forum, I turned off the "numbers_only" option, and somehow it now works even if I let ((random ==1)) without the quotes. Should I go ahead and report it anyway?
When I was getting ready to report the bug in the support forum, I turned off the "numbers_only" option, and somehow it now works even if I let ((random ==1)) without the quotes. Should I go ahead and report it anyway?
Last edit: 5 years 2 months ago by FeCanever.
The topic has been locked.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13597
- Thank you received: 2487
5 years 2 months ago #179483
by DenisChenu
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Replied by DenisChenu on topic problems randomising survey using rand().
In my opinion : since we have issue (fixed) with previous release, it's a bug in this new release.
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.