Please enable JavaScript to view this site.

 

Navigation: Tokens > Conditional Tokens

The Structure of Conditions

Scroll Prev Up Next More

The overall structure of a condition, in a conditional token or in a zap token, is:

 

AnyTokenRoot Operator RightSide

 

Where:

 

AnyTokenRoot

denotes any valid TokenRoot (ie. a token without braces, without LanguageTag and, usually, without DayValue)

Operator

specifies how to compare the value of AnyToken and RightSide.

There are 4 different operators: =, <, >, and ~ (different than)

RightSide

can be any value representing either text or numbers.

 

If the result of processing the AnyTokenRoot and the RightSide both represent numbers, then they will be compared as numbers. Otherwise they will be compared as text.

 

It is also possible to use tokens on the right side, but you must use underscores instead of braces, for example: [2zd<_2m_].

 

Comparing text

 

When the comparison of the operator is performed as text, then the operators > and < have a special meaning, as discussed in the topic evaluating conditions.

 

Current Month

 

You can use 0 (zero) as the DayValue of a token in a grid which is part of a month fit insert, to check if a date in in the current month as part of a zap or conditional token.

 

See also: DayValues inside the conditions of zap or conditional tokens and using tokens on the right side of conditions.

 


Topic 000141, last updated on 01-Aug-2020