613-518-1166 info@zimdatabases.com

Developing ZIM Applications

About Functional Expressions

< All Topics

The software provides a host of built-in functions that process given arguments in a variety of ways. An expression consisting of a function and its arguments (typically, value expressions) is called a functional expression.

Examples of functional expressions are


Evaluates to 5


Evaluates to 1


Evaluates to 2


Evaluates to 1999


Evaluates to 10

General Performance

Functions are a special class of operator, but they perform much like arithmetic operators; they take one or more given values, perform an operation using those values, and return a result. The value of the result depends on the function.

The function’s arguments are similar to the arithmetic operands. Like arithmetic operands, the arguments can consist of literals or value expressions, including other functional and arithmetic expressions as shown in the following example:


The functional expression shown above consists of the argument -7 and the function keyword $absolute. The function $absolute returns the absolute (i.e., unsigned) value of its argument (in this case, 7).

Complex Arguments

If the argument is a complex expression, the argument is evaluated before the function is applied. For example, in the expression


the arithmetic expression 6-11 is evaluated first, yielding $absolute(-5). Then the final result (5) is determined.

Functional expressions can act as arguments to other functions. For example, the expression


evaluates to


which in turn evaluates to


Data Type of Arguments and Results

Each function expects arguments of a certain data type; however, the function accepts arguments of any data type and appropriately converts any argument that does not conform to the expected type.

Related Information

About Data Types

Was this article helpful?
0 out Of 5 Stars
5 Stars 0%
4 Stars 0%
3 Stars 0%
2 Stars 0%
1 Stars 0%
How can we improve this article?
Table of Contents