empty function

The fn:empty function indicates whether an argument is an empty sequence.

Syntax

Read syntax diagramSkip visual syntax diagramfn:empty( item)
item
An expression of any data type, or the empty sequence.

Returned value

The returned value is true if item is the empty sequence. Otherwise, the returned value is false.

Example

The following example uses the empty function to determine whether the sequence in variable $seq is the empty sequence.

let $seq := (5, 10)
return fn:empty($seq)

The returned value is false.