- PDF
Configure variables
- PDF
In this article you will find configuration instructions for conditions and actions referring to variables.
Variables are placeholders in a logical or mathematical expression that contain changeable values. To use variables in rules, you must first create them in the form of an action. You can then refer to it within the same rule.
đź’ˇVariables are only valid within the rule in which they are created. A variable can therefore not be used in another rule.
Comparison of a variable with a numerical value
Condition: A user-defined variable is compared with a value. If the condition is met, the platform executes the action.
Next to The following rule is triggered, select the option always.
Click on +Add an action > Select and action > Create a number variable.
Name the variable and enter a value or a calculation.
Click on +Add new action > Add a conditional action.
Click on Select a condition > If a variable is > / < / = /… a number
Under Variable value, select the variable you have just created.
Select the operator under equals.
Define the numerical value with which you are comparing the variable.
Options:Enter a numerical value in the gray field or
Select a number field from the questionnaire under Answer value. The platform uses this to compare the variable with the number stored by the user or
Under Variable value, select a user-defined variable or
Under Product attribute value, select an attribute from the product data. The platform then compares the variable with the values of the selected table column.
Click on Select an action next to if yes and/or if no and configure the desired action.
Workbench:
Result Page:
Comparison of a variable with a text
Condition: A user-defined variable is compared with a text. If the condition is met, the platform executes the action.
Next to The following rule is triggered, select the option always.
Click on +Add an action > Select and action > Create a text variable.
Name the variable and enter a text.
Click on +Add new action > Add a conditional action.
Click on Select a condition > If a variable is equal to / contains… a text
Under Variable value, select the variable you have just created.
Select the operator under equals.
Define the text with which you want to compare the variable.
Options:Enter a text in the gray field or
Select a text field from the questionnaire under Answer value. The platform uses this to compare the variable with the text stored by the user or
Under Variable value, select a user-defined variable or
Under Product attribute value, select an attribute from the product data. The platform then compares the variable with the texts in the selected table column.