Skip to content

Advanced value comparison rule

Ryan Newington edited this page Sep 4, 2025 · 8 revisions

Advanced Value Comparison Rule

An advanced value comparison rule compares the output of two value declarations defined using ACMA declarative language. This type of rule can evaluate complex scenarios involving multiple attributes and transforms.

As ACMA does not know in advance what the resulting type of the value declarations will be, you must define the comparison type to use in the evaluation. If the value declarations expand to a data type that does not match the value specified in the compare as parameter, an error will be raised and the operation will fail.

Parameters

Parameter Description
Group operator If the first value parameter is expanded and returns a multivalued response, the group operator is used to determine how to evaluate the rule. The group operator can specify that any, all, none, or one of the first values must match the second value provided in the rule
First value The first value to use in the comparison. This can be any valid ACMA declarative language string
Operator The type of comparison to perform. This is dependent on the compare as parameter
Second value The second value to use in the comparison. This can be any valid ACMA declarative language string
Transforms The transform chain to apply to the expanded value from the value parameters
Compare as Specifies the type of data that will be compared

The value declarations provided will first be expanded, and then have any transforms applied, before being compared to each other.

Group Operator Values

Operator Description
Any True if any first value matches the second value
All True if all first values match the second value
None True if no first values match the second value
One True if exactly one first value matches the second value

Compare As Data Types

Data Type Description
String Text comparison with case sensitivity
Integer Numeric comparison
Boolean True/false comparison
Reference Object reference comparison
DateTime Date and time comparison
Binary Binary data comparison

Allowed Comparison Operators

String

  • Equals
  • Does not equal
  • Contains
  • Does not contain
  • Starts with
  • Ends with

Integer

  • Equals
  • Does not equal
  • Is greater than
  • Is greater than or equal to
  • Is less than
  • Is less than or equal to

Boolean

  • Equals
  • Does not equal

Reference

  • Equals
  • Does not equal

DateTime

  • Equals
  • Does not equal
  • Is greater than
  • Is greater than or equal to
  • Is less than
  • Is less than or equal to

Binary

  • Equals
  • Does not equal

Examples

Email Domain Validation

First Value: {mail>>ExtractEmailDomain}
Operator: Equals
Second Value: %corporateDomain%
Compare As: String
Transforms: ToLower

Display Name Format Check

First Value: {displayName}
Operator: Equals
Second Value: {sn}, {givenName} ({employeeNumber})
Compare As: String
Transforms: Trim

Multi-Valued Group Membership

First Value: {memberOf}
Group Operator: Any
Operator: Contains
Second Value: CN=Administrators
Compare As: String

Date Comparison

First Value: {lastLogonDate}
Operator: Is greater than
Second Value: {accountExpiryDate}
Compare As: DateTime

Clone this wiki locally