CompTextConstructor

Construct a text node by computing an expression.

Top of page

Related Syntax Constructs

The following construct(s) refer to this construct:


Syntax

CompTextConstructor

graphics/CompTextConstructor.png

Expr

Description

A CompTextConstructor constructs a text node by computing the enclosed expression. This expression is evaluated and, after atomization, converted into a sequence of atomic values each of which is cast into a string and concatenated with a space character between each pair of values. If the result of the expression after atomization is an empty sequence, no text node is constructed.

Example

  • This is the XQuery version of the classic example of printing "Hello World":

    text{"Hello World"}