Formula - startswith
Easily determine if your data starts with a specific value using the startswith Formula in Nodinite. This page provides clear, real-world examples that separate input, formula, and result, making it simple to understand and apply.
✅ Quickly check if a string or message starts with a given value
✅ Use with message body, context, or nested formulas
✅ Get unique, reliable results for your integration scenarios
What is startswith?
The startswith
formula checks if a text value (string) begins with a specific letter, word, or pattern. If the value matches at the start, the result is true
; otherwise, the result is empty. Use this function to filter or validate data in your log views and search fields.
Syntax
- From Message Body:
startswith('Expression', body)
- From Message Context:
startswith('Expression', context('MessageContextKey'))
- From Nested Formula:
startswith('Expression', SomeOtherFormula(Content))
Features
- Check if text starts with a specific value (case-sensitive)
- Returns a unique
true
value if a match occurs - Works with any valid Content, including message body, Context, and nested formulas
- Ideal for filtering and validating integration data in Nodinite
Note: This plugin loads the entire message into RAM. For best performance, use it only on small messages.
Examples: Input, Formula, and Result
Below are practical examples showing exactly what input is used, the formula expression, and the resulting output.
Example 1: Message Body as Content
Input
GMT
Formula
startswith('G', body)
Result
true
The result is true because the message body starts with 'G'.
Example 2: Message Context as Content
Input
GMT
Formula
startswith('G', context('id'))
Result
true
The result is true because the context value for 'id' starts with 'G'.
Example 3: Nested Formula as Content
Input
GMT UTC
Formula
startswith('U', regex('GMT|UTC', body))
Result
true
The result is true because the regex function extracts 'UTC', which starts with 'U'.
Next Steps
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?