Tamino XML Server Version 9.7
 —  XQuery 4 Reference Guide  —

ValueComp

Compare single values.


Syntax

ValueComp

graphics/ValueComp.png

Expr Expr

Top of page

Description

A value comparison compares two single items. Each operand is atomized so that it is either a single atomic value or an empty sequence. If one of the operands is atomized to an empty sequence, the result of the operation is also an empty sequence. If the atomized operand is a sequence of length greater than one, an error is raised.

If one of the operands is of the type xs:anySimpleType, that operand is cast to a required type which is determined as follows:

If the cast fails, a dynamic error is raised.

The result is true if the value of the first operand is equal, not equal, less than or equal, less, greater than, greater than or equal to the value of the second operand. Otherwise the result is false.

Top of page

Example

Top of page

Related Syntax Construct

The following construct(s) refer to this construct:

This construct is also related to the following construct(s):

GeneralComp

Top of page