Tree Rule
- 08 Oct 2021
- 1 Minute to read
- Print
- DarkLight
This documentation version is deprecated, please click here for the latest version.
Tree Rule
- Updated on 08 Oct 2021
- 1 Minute to read
- Print
- DarkLight
Article summary
Did you find this summary helpful?
Thank you for your feedback
Overview
A Tree Rule is a Rule that can be made up of a row and column of one axis. A Tree Rule is used to evaluate data with settings and can be customized. Each row and column can have a specific parameter set for Rule evaluations, and other Rule evaluations can be nested within.
Example
- In a Designer Project, click CREATE RULE. Select Matrix Rule and click CREATE. Name the Rule and click CREATE.
- Under the Settings category on the Properties panel, select the dropdown list under Rule Type and select Tree [One Axis].The Tree Rule will delete the top parameter to have the left column as its only parameter. The Output Data column will appear after inserting a new parameter into the Rule Column. Output Data will still be changed to a new type in the Output Data Column. For a Tree Rule to evaluate a string, this string will receive an input of what team an employee is in. The Tree will check if the String is empty. If it is not empty, then the Tree Rule will check if the string matches any of the teams listed in the Rule.
- Click SETUP INPUT DATA.
- In the Data Definitions window, enter "EmpoyeeTeam" in the Name field as a String[Text] Type and click CLOSE.
- Hover over Add Rule and click the plus sign. Navigate to All Rules > Data >Text and select Is Empty Rule. Click ADD.
- On the Edit Rule window, under Inputs, click Unknown and select Select From Flow. Select Employee Team and click DONE. Click CLOSE to close Edit
- Change the value of False to False by clicking on the checkbox next to True.
- Hover over the False cell under the Is Empty column and click on the plus sign. Navigate to All Rules > Data >Text and select String is in List. Click ADD.
- Under the Inputs category, select Unknown next to the Case Insensitive field and select Constant. Click the checkbox that appears. Change the List field to a Constant and enter "Accounting", "Marketing", and "IT”. For the Value field, select Unknown and select Select from Flow. Select EmployeeTeam and click DONE. Click CLOSE to close the Edit Rule window.
- Click the checkbox in the False row to make the output False. Click Save to save changes.
Debug
- On the top action bar, click Debug. Enter "IT" for the Employee Team field and click Run Capturing All.The Tree Rule will evaluate the input and display the output evaluation.
Was this article helpful?