Syntax and types
This page describes the shared syntax and the Entity Definition profiles. Availability is decided by the profile of the setting you edit. Also consult Board Statements, Security and Workflow conditions and Task completion for their roots, functions and restrictions. They share the language, but do not expose identical operands.
Literals
Section titled “Literals”| Kind | Examples | Notes |
|---|---|---|
| Number | 1, 100, 12.50 | Decimal separator is always . (invariant culture). |
| String | 'active', "VIP" | Single or double quotes; escapes \n, \r, \t, \\, \', \". Not available inside calculated-field arithmetic. |
| Boolean | TRUE, FALSE | Case-insensitive. |
| Null | NULL | Case-insensitive. |
| Classifier category | CATEGORY('product-area', 'operations', 'platform') | Statements and validation rules only. The first key identifies the Classifier Catalog; the remaining keys are the category path. |
Field references
Section titled “Field references”- A bare identifier references a field of the record by its key:
Qty,Status,DueDate. Rule and validation expressions resolve field keys case-sensitively —qtydoes not matchQty. Newly authored calculated-field expressions also require the exact field key. - A dotted path reads one step through a reference field:
Customer.DisplayName. Entity rule profiles allow at most one Reference hop; deeper chains such asCustomer.Owner.Departmentare rejected there. Security and Workflow conditions have their own bounded relationship paths. - Calculated-field expressions are same-table only and do not accept dotted paths.
Operators
Section titled “Operators”In precedence order, lowest first (parentheses override as usual):
| Level | Operators |
|---|---|
| Boolean | OR, then AND, then NOT |
| Comparison | =, ==, !=, <>, >, >=, <, <= |
| Text | CONTAINS, STARTS WITH, ENDS WITH |
| Membership and range | IN (a, b, …), NOT IN (a, b, …); BETWEEN low AND high (statements and validation rules only — see Availability by surface) |
| Null and empty | IS NULL, IS NOT NULL, IS EMPTY, IS NOT EMPTY |
| Arithmetic (calculated fields only) | +, -, *, /, unary +/- |
Keywords and operators are case-insensitive: and, And, and AND are the
same operator.
Board Statements additionally support BETWEEN, typed date/time and duration
arithmetic, and the exact function set published by their authoring profile.
They do not inherit calculated-field arithmetic merely because the operator
tokens are the same.
Null and empty semantics
Section titled “Null and empty semantics”- Conditions use three-valued logic. A comparison (
=,<>,>,<,BETWEEN,IN,NOT IN,CONTAINS,STARTS WITH,ENDS WITH) with a missing (NULL) value is unknown, andNOTof an unknown value is unknown. A condition holds only when it is true:NOT (Code = 'x')andCode NOT IN ('x')do not hold for a record without a code. - State what a missing value means with a null test in the same
ANDorORchain:Code IS NULL OR Code <> 'x'. IS NULL,IS NOT NULL,IS EMPTY, andIS NOT EMPTYare always true or false.IS EMPTYtreatsNULL, text made only of whitespace, and a multi-value field without items as empty.= NULL,<> NULL, and aNULLmember of a list (IN (NULL, 'a')) are refused: writeIS NULLorIS NOT NULL.- A field used as a condition by itself holds when it is a true Bool, a number
that is present and not zero, text or a lookup that is
not empty, or a multi-value field with at least one item. Text such as
'false'or'0'is not empty, so it holds. - Whole Money and Address values in field behavior, presentation and validation
support presence/null/empty checks only. A present Money value with a zero
amount is still present. Compare
Price.AmountorPrice.CurrencyCodewhen a value comparison is needed; calculated Money arithmetic is a separate profile. - Classifier equality, inequality,
IN, andNOT INnever match a null value. UseIS NULLorIS NOT NULLexplicitly for a Classifier field. A Classifier cannot be used as a condition by itself.
Board Statements follow the same rules; see the Board Statement null contract.
Classifier category values
Section titled “Classifier category values”Statements and validation rules use a portable typed literal for a Classifier category:
CATEGORY('catalog-key', 'root-key', 'child-key')The first argument is the stable Catalog key. The remaining arguments are the stable node keys from the Catalog’s logical root to the selected category. Display names and rendered breadcrumbs are not part of the comparison. The logical root itself is not a value, while a stored non-leaf category is valid.
Classifier fields support =, !=, IN, NOT IN, IS NULL, and
IS NOT NULL. Field-to-field equality or inequality is valid only when both
fields use the same Classifier Catalog. Field behavior, presentation, and
calculated-field expressions do not support Classifier values.
Value comparison rules
Section titled “Value comparison rules”- Text, lookup, and Classifier values are equal only when they are the same
characters:
'01'differs from'1'and'a'from'A'. A record stores text trimmed, and blank text as missing. CONTAINS,STARTS WITH, andENDS WITHcompare text without regard to case.- Numbers compare by value across Integer and Decimal fields; a text field is compared with text only.
- Ordering (
>,>=,<,<=,BETWEEN) applies to numbers, dates, times, date-times, and durations. A date, time, or date-time field compares with a literal in invariant format, such as'2026-07-25'. - A date compared with a date-time field stands for the instant its day starts in the workspace time zone.
Variables
Section titled “Variables”Statements and validation rules support runtime variables; field behavior and presentation expressions do not.
| Variable | Meaning | Available in |
|---|---|---|
@currentUserId | Identifier of the acting user | Statements, validation rules |
@today | Current date in the workspace time zone | Statements, validation rules |
@today+7d, @today-7d | Date offset by a signed number of days | Statements, validation rules |
Example: DueDate BETWEEN @today AND @today+30d.
In Entity Statements and validation rules, @currentUserId comparisons
require an admitted User field, including supported user-id system fields;
it is not a general text constant to compare with any path.
Board Statements expose @today, @now, and event-only @currentUserId under
their own eligibility rules. See
Board Statement date and time values
and the server-owned authoring profile; this Entity Definition availability
table does not describe the Board surface.
Availability by surface
Section titled “Availability by surface”Most Entity Definition condition surfaces share comparisons, AND/OR/NOT,
the text operators, IN / NOT IN, and null/empty checks. A few constructs
are gated to specific surfaces and are rejected at validation time everywhere
else — most notably BETWEEN, which is not available in field-behavior or
presentation conditions even though IN / NOT IN are.
| Construct | Field behavior | Presentation | Statements | Validation rules | Calculated fields |
|---|---|---|---|---|---|
BETWEEN low AND high | — | — | ✓ | ✓ | — |
Variables (@today, @currentUserId) | — | — | ✓ | ✓ | — |
CATEGORY(...) classifier literal | — | — | ✓ | ✓ | — |
MATCHES(value, "regex") | — | — | — | ✓ | — |
EXISTS / ANY / ALL / COUNT(child) child-table forms (details) | — | — | ✓ | — | — |
Numeric / aggregate functions (IF, COALESCE, ROUND, SUM, …) | — | — | — | — | ✓ |
Text functions (trim, upper, lower, coalesce) | — | template only | — | — | — |
This table covers Entity Definition profiles. Security, Workflow and Task completion have separate availability tables on their linked profile pages.
Field-behavior and presentation conditions are operator-only: they accept
no function calls, and a range must be written as >= low AND <= high. The
text functions apply only inside presentation templates. See the
Function reference for the per-surface function catalog.
Error reporting
Section titled “Error reporting”Expressions are parsed and bound against the entity schema when you save or call a validation endpoint. Rule-expression and validation-rule errors include a message, the offending token, the resolved field path where relevant, and a stable error code — enough to locate and fix the error programmatically. Calculated-field errors return the request field, localized message, and stable code. Board Statement diagnostics also return an exact source offset; the authoring UI renders it as a one-based line and column.