Description

These four operators allow the addition, subtraction, multiplication, and division of multi-value elements. Typically, these elements will be associated multi-value columns.

Syntax

expression operator expression

result = variable1***variable2

Parameters

The Multi-value arithmetic operators have the following parameters.

ParameterDescription
ExpressionAny BASIC+ expression that yields a dynamic array
OperatorAny of the five arithmetic operators:
+++     addition
----       subtraction 
***      multiplication
///         division
:::         concatenation

Remarks

This operation first determines which type of multi-value element is the highest ranking (in the order @FM, @VM, @SVM).

Then, it determines how many of the highest ranking elements there are, ignoring all lesser elements.

Then, it performs the specified operation, only on those highest elements.

If there is an unequal number of elements, the missing elements are treated as having a null value. This means that, arithmetically, the value of the missing element is zero. In cases of multiplication, any result will be zero, but if an element is subtracted from a non-existent element, then the result is the negative of the subtracted value.

Example

/* The result will be 3ý3ý3ý3ý22. Zero (0) is added to the fifth multi-value. */

A = 1ý1ý1ý1
B = 2ý2ý2ý2ý22
result = A+++B


  • No labels