fn:data function

The fn:data function converts a sequence of items to a sequence of atomic values.

Syntax

>>-fn:data(sequence)-------------------------------------------><

sequence
Any sequence, including the empty sequence.

Returned values

The returned value is a sequence of items of type xs:anyAtomicType. For each item in the sequence:
  • If the item is an atomic value, the returned value is that value.
  • If the item is a node, the returned value is the typed value of the node.

Example

The following function returns the typed values of all qualifying name nodes. Qualifying name nodes are all name nodes that are children of a billTo node in the document.
fn:data(//billTo/name)