syntax:functions:eval
This is an old revision of the document!
Table of Contents
Eval(text_expression)
Category: Special function
Description
This function evaluates the text_expression argument as an EasyMorph expression.
Use cases
This function makes it possible to define EasyMorph expressions externally using parameters.
Arguments
Argument | Type | Description |
---|---|---|
text_expression | Text | An expression in text format to be evaluated. |
Return value type: Any (The type of the expression output)
Remarks
The argument itself must not be an expression with a reference to column.
Examples
eval('1+1') //Returns 2 eval('1' & '+1') //Returns 2 eval('max(1,2)') //Returns 2 eval('[Count]+1') //Evaluated as [Count]+1 eval([Count] & '+1') //Invalid! Column references are not allowed in argument expressions. eval({Param1}) //Parameter references to expressions in text format are allowed. eval("1+" & "eval('1+1')") //Returns 3 (Nesting eval() is allowed.)
syntax/functions/eval.1631581429.txt.gz · Last modified: 2021/09/13 21:03 by craigt