Relational operators and functions

The Relational operators are listed in the following screenshot. Each of these is used in an expression of the format:

Expression RelationalOperator Expression

For example, (Variable1 + 97) > ((Variable2 * 14.5) / 57.332). The following operators can be used:

We will spend a little extra time on the IN operator, because this can be very handy and is not documented elsewhere. The term Valueset in the Evaluation column for IN refers to a list of defined values. It would be reasonable to define Valueset as a container of a defined set of individual values, expressions, or other Value sets. Some examples of IN as used in the standard NAV product code are as follows:

GLEntry."Posting Date" IN [0D,WORKDATE] 

Description[I+2] IN ['0'..'9']

"Gen. Posting Type" IN ["Gen. Posting Type"::Purchase, "Gen. Posting Type"::Sale]

SearchString IN ['','=><']

No[i] IN ['5'..'9']

"FA Posting Date" IN [01010001D..12312008D]

Here is another example of what the IN operator used in an expression might look like:

TestString IN ['a'..'d','j','q','l'..'p'];

If the value of TestString were a or m, then this expression would evaluate to TRUE. If the value of TestString were z, then this expression would evaluate to FALSE. Note that the Data Type of the search value must be the same as the Data Type of the Valueset.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.143.168.172