Skip to content

Dynamic expression – an expression chosen at runtime

The dynamic expression evaluates an expression that is only known when it runs: another expression returns a reference to a stored expression, and the dynamic expression evaluates that one. It is meant for advanced cases in which the expression to use is stored as data, for example in a field of a configuration record.


1. At a glance

Purpose Evaluates a stored expression whose reference is computed at runtime
Typical use Rules that are configured per record or per customer in a configuration entity
Returns The value of the referenced expression
Related Case – the better choice when the possible expressions are known in advance

2. Settings

Setting Meaning
"Definition" An expression whose result is the reference to a stored expression, written as JSON, for example {"DefId":"3f2b6c1e-…"} – typically a field or variable holding that text

3. Behaviour

  1. "Definition" is evaluated.
  2. Its result is read as a reference to a stored expression.
  3. The referenced expression is evaluated for the same record and returned.

If the result of "Definition" is empty, is not such a reference, or the referenced expression does not exist, the dynamic expression returns an empty value.


4. Limitations

  • nexxcite cannot tell in advance which fields the referenced expression reads. Grids that show a dynamic expression therefore load all fields of their records, which makes them slower.
  • References to the expression are not visible anywhere else – an expression that is only used through a dynamic expression looks unused.
  • If the possible expressions are known when you configure, use a Case expression instead.