Skip to main content

Compare

Uncontrolled node

Overview​

Compare two values and return true or false.

Compare checks two values and returns a boolean. Connect the result to If when you want the comparison to choose an execution path.

It is evaluated when another node needs its output; it does not require an event trigger.

Inputs​

InputTypeDescription
aDataThe first value.
bDataThe second value.

Properties​

PropertyTypeDescriptionDefault
operationChoiceComparison between a and b: <, <=, ==, >= or >.==

Choose operation in the properties panel.

Comparison choices​

OperationMeaning
a < bLess than
a <= bLess than or equal to
a == bEqual; the default selection for a new node
a >= bGreater than or equal to
a > bGreater than

Outputs​

OutputTypeDescription
resultBooleantrue when the selected comparison matches, otherwise false.

Choose the right value types​

For numeric comparisons, supply numbers using Number or To Number. If both values are text, ordering is textual: "10" is less than "2".

Equality can treat different types as equal, such as the number 10 and text "10". It is not a strict type check or a comparison of the contents of entire lists and objects. Compare individual fields for record validation.

Example​

Connect a numeric total to a, a Number node containing 100 to b, and select a >= b. Connect result to If's test, then trigger If to choose the appropriate action.