View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
20315 | Bug reports | Survey editing | public | 2025-10-22 10:08 | 2025-10-22 12:19 |
Reporter | Jmantysalo | Assigned To | tibor.pacalat | ||
Priority | none | Severity | text | ||
Status | closed | Resolution | won't fix | ||
Product Version | 6.6.x | ||||
Summary | 20315: Terminology: 'Condition' vs. 'Relevance equation' | ||||
Description | A question and a question group have 'condition'. Subquestions should have that too instead of 'relevance equation'. | ||||
Tags | No tags attached. | ||||
Bug heat | 6 | ||||
Complete LimeSurvey version number (& build) | 6.15.12+250916 | ||||
I will donate to the project if issue is resolved | No | ||||
Browser | |||||
Database type & version | N/A | ||||
Server OS (if known) | |||||
Webserver software & version (if known) | |||||
PHP Version | N/A | ||||
The {questions} table has a relevance field. This field contains the actual script that will determine relevancy, i.e., whether the current entity is to be hidden (not relevant) or shown (relevant). There is a {conditions} tables too, where you can create/update/delete/view conditions. A condition is an atomic entity that you can define and whenever you do a write operation on a condition, then the question it refers to will re-generate its relevance script based on the conditions that you have. So the condition is an atomic expression that can be created/updated/deleted/viewed in a user-friendly manner via the condition designer and the conditions are aggregated into an expression in the question's relevance field. You can also directly edit the relevance of a question which will automatically remove all conditions. Hence, the relevance script is the end result of a script that determine relevancy, whilst conditions are a way to generate this script by defining individual conditions, but can be directly edited by power-users. |
|
Ok, might be that I understood -- but where I can set up conditions? There is Tools > Reset conditions, but I see no way to add a condition. Is it still available on a now 6.x installation? I am testing as a superadmin. |
|
If you want to set condition for a specific question, it is under General Settings -> Condition. |
|
From Arpad: On the question page you have the ... menu at the left-hand sidebar and then click on Condition designer. This will redirect you to the condition designer where you can define your conditions. Please, be aware the mechanism that re-generates the relevance script when you save/remove a condition, so if you have a carefully written relevance script and you want to keep it, then you might want to save it someplace. If you just want to generate the script with conditions, then the conditions designer is the exact place you need to be at. The condition designer has this URL pattern: where you can of course replace the protocol, the domain as well as the values. But the numeric values, notably 396954, 770 and 7741 specify the survey id, the group id and the question id. The algebra of the condition designer works like this:
Scenario1 OR ... OR Scenarion where each scenario above represents the logical evaluation of the conditions inside the scenario.
Condition1 AND ... AND Conditionn as long as the conditions are not referring the same thing. So if your first condition is that question1 was answered by a1 as value and the second condition is that question2 was answered by a2 as value, then both conditions need to be true at the same time in order for the scenario to be evaluated as true
So if condition1 and condition2 are inside the same scenario, but both of them depend on the value of the LASTNAME, for example, then they are ORed. Example: Scenario1:
Then the expression will be this: (q1's answer is 'foo') OR (q1's answer is not 'foo' AND q2's answer is 'bar') OR ((LastName is 'Doe' OR LastName contains 'son') AND FirstName is not 'John') I hope this clarifies the matter. |
|
Ok, this clarifies it, kind of. But still: I can use the Condition designer for a question. I can not use it for a question group, nor for a subquestion. But the term 'condition' is used for a question group too. And for a normal user it is anyways strange to have two terms for one thing. |
|
Date Modified | Username | Field | Change |
---|---|---|---|
2025-10-22 10:08 | Jmantysalo | New Issue | |
2025-10-22 11:12 | lajosarpad | Note Added: 83635 | |
2025-10-22 11:12 | lajosarpad | Bug heat | 0 => 2 |
2025-10-22 11:28 | Jmantysalo | Note Added: 83637 | |
2025-10-22 11:28 | Jmantysalo | Bug heat | 2 => 4 |
2025-10-22 11:39 | tibor.pacalat | Note Added: 83638 | |
2025-10-22 11:39 | tibor.pacalat | Bug heat | 4 => 6 |
2025-10-22 11:39 | tibor.pacalat | Assigned To | => tibor.pacalat |
2025-10-22 11:39 | tibor.pacalat | Status | new => closed |
2025-10-22 11:39 | tibor.pacalat | Resolution | open => won't fix |
2025-10-22 11:58 | tibor.pacalat | Note Added: 83640 | |
2025-10-22 12:19 | Jmantysalo | Note Added: 83641 |