unordered function
The fn:unordered function returns the items in a sequence in non-deterministic order.
Syntax
- sequence-expression
- Any sequence, including the empty sequence.
Returned value
The returned value is the items in sequence-expression in non-deterministic order. This assists the query optimizer in choosing access paths that are not dependent on the order of the items in the sequence.
Example
The following function returns the items in sequence (1,2,3) in non-deterministic order.
fn:unordered((1,2,3))