Calculation Engine Logical Comparison Functions
The following are functions for logical comparison to be used in the OAS Calculation Engine:
AND
Logical operator placed between two boolean expressions or values. Returns true if both evaluate to true.
Example:
[Tag1.Value] & [Tag2.Value]
IF
If, Then, Else. Returns second parameter (Then) if first parameter is true, returns third parameter (Else) if first parameter is false.
Parameters:
- Condition to evaluate
- Value to return if condition is true
- Value to return if condition is false
Examples:
IF([Tag.Value],100,200)
IF([Tag1.Value],[Tag2.Value],[Tag3.Value])
IF([Tag.Value],"ON","OFF")
NOT
Logical operator placed before a boolean expression or value. Returns the opposite boolean value of the expression.
Example:
![Tag1.Value]
OR
Logical operator placed between two boolean expressions or values. Returns true if either evaluate to true.
Example:
[Tag1.Value] | [Tag2.Value]