Formula - Equal
Easily check if values are equal using the Nodinite equal
Formula plugin. This page shows you how to compare message content, context values, or results from other formulas, ensuring your integrations are accurate and reliable.
✅ Instantly validate if values are equal for data consistency
✅ Use simple expressions for message content or context
✅ See clear, real-world examples with input, formula, and result
What does the equal Formula do?
The equal(<Expression>, <Content>, ..., <Content>, <MatchAllValues>)
Formula function checks whether two or more text values are equal. It returns true
if the values match, and you can specify if all or just one value must match.
Parameters
<Expression>
– A string or expression to compare against<Content>
– One or more values to compare<MatchAllValues>
– Boolean (true
orfalse
). Iftrue
, all values must match; iffalse
(default), only one match is required.
Example 1: Check if Message Body Equals Value
Input from Body
GMT
Formula Expression
equal('GMT', body)
Result
true
Example: Checking if message body equals a value
Example 2: Check if Context Value Equals Value
Suppose you have a message context value with the key id
containing GMT
.
Input
GMT
Formula Expression
equal('GMT', context('id'))
Result
true
Example: Checking if context value equals a value
Example 3: Check if Result from Another Formula Equals Value
You can use the result of another formula function as input. For example, extracting values with regex and checking if they equal a specific value:
Input
GMT UTC
Formula Expression
equal('UTC', regex('GMT|UTC', body))
Result
true
Example: Using another formula as input for equal
Features
- Check if two or more values are equal for data validation
- Return
true
if values match, with option to require all or just one match - Works with message body, Context, or results from other Formula functions
- Ensures data integrity across integrated systems
Important
The equal plugin loads the entire message into RAM. Only use this function on small messages to avoid performance issues.
How to use the equal Formula
- Select Formula as the expression type plugin.
- Enter your equal expression in the 'Expression' text area.
- Provide one or more string-based Content parameters (e.g., message body, context value, or another formula result).
Syntax
- Check from message body:
equal('Expression', body)
- Check from message context:
equal('Expression', context('MessageContextKey'))
- Check result from another formula:
equal('Expression', SomeOtherNestedFormulaFunction(Content))
Example: Using another formula as input for equal with message context.
Next Step
How to Add or manage Search Fields
How to Add or manage Log Views
Related Topics
- Expression Type Plugins are used in Search Fields
- What are Search Fields?
- What are Search Field Expressions?
- What are Message Types?
- What are Log Views?