View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
06188 | Bug reports | Conditions | public | 2012-06-10 05:00 | 2012-07-05 22:16 |
Reporter | TMSWhite | Assigned To | c_schmitz | ||
Priority | normal | Severity | minor | ||
Status | closed | Resolution | fixed | ||
Product Version | 1.92+ | ||||
Fixed in Version | 1.92+ | ||||
Summary | 06188: error in conditions generated by editor when selecting several options per sub-question | ||||
Description | Say have array style question with 4 sub-questions (sq1-sq4) and 5 choices (A-E). If to create the condition where sq1 is either A or B, and sq2 is either C or D, the conditions editor should show: (sq1 == 'A' or sq1 == 'B') and (sq2 == 'C' or sq2 == 'D') instead, it shows: (sq1 == 'A' and sq1 == 'B' and sq2 == 'C' and sq2 == 'D') This doesn't always happen with the addition of the second condition, but it does always happen if you add a third sub-question with one or more conditions. | ||||
Tags | No tags attached. | ||||
Attached Files | |||||
Bug heat | 18 | ||||
Complete LimeSurvey version number (& build) | 120608 | ||||
I will donate to the project if issue is resolved | No | ||||
Browser | |||||
Database type & version | Mysql 5.3 | ||||
Server OS (if known) | Windows XP | ||||
Webserver software & version (if known) | XAMPP | ||||
PHP Version | 5.3 | ||||
This appears to be an error in how the conditions editor displays the conditions. The generated relevance equation is correct. |
|
Thibault, my good old friend, any chance you can have a look at this one? Tom, did you try to reproduce this at an older 1.91 version as well? |
|
Yes, same error in 1.91+. Attaching a sample survey. |
|
the conditions-editor-error.jpg shows what the equations should be. conditions-editor-error2.jpg shows the conditions editor display for test4, for example. |
|
Hi Guys, The fact is that this equation was not supported by the old conditions system, and the GUI was built against the old condition system. When we decided to integrate the EE engine, we said that its GUI would use a simple syntax coloring tool (if user wanted to use new features) thus disabling the GUI. OR it could use the GUI but limitting its capabilities to what was possible in the past. So this is not a bug, it's just a feature that was never implemented so far. |
|
The odd thing, though, is that 1.91+ would let me create that condition (picking two options for each of three different array sub-questions), but the condition editor does not display the value correctly. Sounds like we should update the documentation to let people know that they can use the conditions editor to accurately create such conditions, but let them know that in this specific case, the GUI display may be inaccurate, so they should double check the relevance equation to ensure they're getting what they expect. |
|
Humm Weird. The only way to build such condition was to developp ===> (sq1 == 'A' and sq2 == 'C') OR (sq1 == 'A' and sq2 == 'D') OR (sq1 == 'B' and sq2 == 'C') OR (sq1 == 'B' and sq2 == 'D') So if the GUI lets you write the 1st condition this means that it was modifies by someone who forgot to update the VIEW panel. To be honest I haven't had a look at the LS codebase since we migrate to Git so it is possible that I missed that. |
|
"Sounds like we should update the documentation to let people know that they can use the conditions editor to accurately create such conditions, but let them know that in this specific case, the GUI display may be inaccurate, so they should double check the relevance equation to ensure they're getting what they expect." ^- I think fixing the GUI would be a better approach :-) Since it will be very irritating to the user to see the wrong conditions, we should definitely fix this. |
|
I can't see anything wrong done by the conditions editor. The conditions editor never supported the syntax that Thomas claims it should show. I would say that is an error in the EM conditions2EMsyntax conversion. |
|
Carsten- Please take a look at the attached survey and screen shots. The problem is definitely with how the conditions editor is displaying certain complex conditions. It is ANDing together different sub-questions, but it is not ORing the options within sub-questions. I tested the exact same survey on 1.91+ and see the identical behavior. |
|
yes, but that is how it was intended to work in 1.91+ and earlier versions. |
|
Carsten, I have to disagree. There must be an error in the conditions editor GUI. When you add the first one or two conditions, the logic looks fine. When you add the third, or try to do some of the conditions described in this and the linked bugs, the conditions editor display suddenly changes to show completely different logic. Then, if you delete or modify one of those conditions, the displayed logic changes again. There is no consistency in the errors generated by the GUI, so that is clearly a bug in the GUI, not EM's conversion process. |
|
Guys, something is very wrong there, see the file I just uploaded (first question group). Build in 191 and broken in 192, mostly due to conversion from inappropriate "OR" to "AND". Thanks for looking into this |
|
Marc, which question(s), specifically, are broken? |
|
Many thanks for the quick response! My questions A1.x and A2.x depend on conditions against their predecessors A1 and A2, which get interpreted badly in release 1.92+ 120611 (which we installed this morning). However, looking through related issues I think it's actually related to bug 6231, which was only solved less than two hours ago by a release incorporating the fix. Our admin will install the new version now and I'll re-check it on there. Will get back with results once I have them. Kind regards |
|
A1.x and A2.x look fine in 1.92+ 120620. Since 120611 runs an bulk update on conditions and updates your database version to 155.5, you may need to re-run the bulk update process. Options are: |
|
FYI, the question between A1.x and A2 actually combines "AND" and "OR" (as does the final one following A2.x), so I suspect this may still be broken in today's release. |
|
A1++ has this equation: ((is_empty(A1_a.NAOK)) and (is_empty(A1_b.NAOK)) and (is_empty(A1_c.NAOK)) and (is_empty(A1_d.NAOK)) and (is_empty(A1_e.NAOK)) and (A1_f.NAOK == "Y")) A2++ has this equation: ((is_empty(A2_a.NAOK)) and (is_empty(A2_b.NAOK)) and (A2_c.NAOK == "Y")) |
|
True, it's just a chain of "ANDs", sorry for the confusion. Many thanks for your help and the hints! Our admin will give me the latest version tomorrow, looking forward to having this fixed - it got me a little stressed shortly before the survey release. :-) |
|
Fix committed to Yii branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=8852 |
|
Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=8853 |
|
Good things come to those who wait. :) |
|
Looks good. Thanks. |
|
New 1.92+ version released. |
|
LimeSurvey: Yii 76517950 2012-06-23 10:03 Details Diff |
Fixed issue 06188: Display error in conditions editor when selecting several options per sub-question |
Affected Issues 06188 |
|
mod - application/controllers/admin/conditionsaction.php | Diff File | ||
LimeSurvey: master 553774ae 2012-06-23 10:03 Details Diff |
Fixed issue 06188: Display error in conditions editor when selecting several options per sub-question |
Affected Issues 06188 |
|
mod - admin/conditionshandling.php | Diff File |
Date Modified | Username | Field | Change |
---|---|---|---|
2012-06-10 05:00 | TMSWhite | New Issue | |
2012-06-10 05:25 | TMSWhite | Note Added: 19142 | |
2012-06-11 10:05 | Mazi | Assigned To | => lemeur |
2012-06-11 10:05 | Mazi | Status | new => assigned |
2012-06-11 10:06 | Mazi | Note Added: 19148 | |
2012-06-11 13:23 | TMSWhite | Note Added: 19152 | |
2012-06-11 13:23 | TMSWhite | File Added: limesurvey_survey_12345.lss | |
2012-06-11 13:25 | TMSWhite | File Added: conditions-editor-error.jpg | |
2012-06-11 13:28 | TMSWhite | Note Added: 19153 | |
2012-06-11 13:28 | TMSWhite | File Added: conditions-editor-error2.jpg | |
2012-06-11 14:58 | lemeur | Note Added: 19155 | |
2012-06-11 15:09 | TMSWhite | Note Added: 19156 | |
2012-06-11 15:16 | lemeur | Note Added: 19157 | |
2012-06-11 15:17 | lemeur | Note Edited: 19157 | |
2012-06-11 15:40 | Mazi | Note Added: 19159 | |
2012-06-11 15:40 | Mazi | Assigned To | lemeur => c_schmitz |
2012-06-11 19:05 | TMSWhite | Relationship added | related to 06199 |
2012-06-18 11:46 | c_schmitz | Note Added: 19300 | |
2012-06-18 11:48 | c_schmitz | Note Edited: 19300 | |
2012-06-18 11:48 | c_schmitz | Assigned To | c_schmitz => TMSWhite |
2012-06-18 13:07 | TMSWhite | Note Added: 19304 | |
2012-06-18 13:24 | TMSWhite | Assigned To | TMSWhite => |
2012-06-18 13:39 | TMSWhite | Relationship added | related to 06231 |
2012-06-18 16:52 | TMSWhite | Assigned To | => c_schmitz |
2012-06-18 16:53 | TMSWhite | Relationship added | related to 06234 |
2012-06-19 10:05 | c_schmitz | Note Added: 19335 | |
2012-06-19 13:21 | TMSWhite | Note Added: 19359 | |
2012-06-20 14:32 | marcrichter | Issue Monitored: marcrichter | |
2012-06-20 14:32 | marcrichter | File Added: caselaw_191vs192.lss | |
2012-06-20 14:33 | marcrichter | Note Added: 19414 | |
2012-06-20 15:14 | TMSWhite | Note Added: 19416 | |
2012-06-20 15:46 | marcrichter | Note Added: 19417 | |
2012-06-20 15:52 | TMSWhite | Note Added: 19418 | |
2012-06-20 15:55 | marcrichter | Note Added: 19419 | |
2012-06-20 16:11 | TMSWhite | Note Added: 19420 | |
2012-06-20 16:22 | TMSWhite | Relationship added | related to 06240 |
2012-06-20 16:44 | TMSWhite | Relationship deleted | related to 06240 |
2012-06-20 17:12 | marcrichter | Note Added: 19426 | |
2012-06-23 17:03 | c_schmitz | Changeset attached | => LimeSurvey Yii 76517950 |
2012-06-23 17:03 | c_schmitz | Note Added: 19516 | |
2012-06-23 17:03 | c_schmitz | Resolution | open => fixed |
2012-06-23 17:03 | c_schmitz | Changeset attached | => LimeSurvey master 553774ae |
2012-06-23 17:03 | c_schmitz | Note Added: 19517 | |
2012-06-23 17:04 | c_schmitz | Note Added: 19518 | |
2012-06-23 17:04 | c_schmitz | Status | assigned => resolved |
2012-06-23 17:04 | c_schmitz | Fixed in Version | => 1.92+ |
2012-06-24 02:11 | TMSWhite | Note Added: 19531 | |
2012-06-24 02:20 | TMSWhite | Relationship replaced | has duplicate 06234 |
2012-07-05 22:16 | c_schmitz | Note Added: 19627 | |
2012-07-05 22:16 | c_schmitz | Status | resolved => closed |
2021-08-02 18:36 | guest | Bug heat | 16 => 18 |