When working with Order Management Rules (OMR), especially with low-level variables that access specific data points within the system, you may need auxiliary functions (or expressions) to process data before assigning them to variables. This article serves as a reference for those functions.

- Using custom or low level variables in OMR [Information] to learn about the data sources available for your expressions.
- Using Billing Account level variables in OMR [Information] to learn about the BillingAccountClient data source object.
All functions use the syntax @(function-name). For example: @(truncate(ShipToName, 3))
Functions can be nested. For example: @(trim(replace([Order.ShipToPhone], '+1','')))
WARNING: Function names are case-sensitive. Ensure you use the correct capitalization when invoking functions.
The following table lists available functions in alphabetical order:
SIGNATURE | EXAMPLES | |||
SYNTAX | PARAMETERS | INVOCATION | EXECUTION | RESULT |
replace( string, old, new) | string – The original string old – The substring to be replaced new – The replacement string | @(replace([Order.City], 'NYC', 'LAX')) | @(replace( 'Lorem ipsum', 'ipsum', 'dolor')) | Lorem dolor |
@(replace( 'Lorem ipsum', ' ipsum', '')) | Lorem | |||
trim( string) | string – A string with leading or trailing white spaces | @(trim([Order.ShipToPhone])) | @(trim(' text ')) | text |
truncate( string, position) | string – The text to truncate position – Character position to truncate from | @(truncate(ShipToName, 3)) | @(truncate('Lorem ipsum', 3)) | Lor |
A special case is concatenation, which uses the + operator to combine strings. For example:
EXAMPLES | |||
SYNTAX | INVOCATION | EXECUTION | RESULT |
stringA+stringB | @(@([CustomFields.CivName])+@([CustomFields.OrigFromComp])) | @('Lorem '+'ipsum') | Lorem ipsum |
Was this article helpful?
That’s Great!
Thank you for your feedback
Sorry! We couldn't be helpful
Thank you for your feedback
Feedback sent
We appreciate your effort and will try to fix the article