XMLEXTRACTVALUE()

Scalar. Extracts the value of an XML element tree that matches a given XPATH expression.

Syntax

XMLEXTRACTVALUE( [value ,] xpath])
Parameters

value

The XML value. Can be omitted when used with XMLTABLE.

xpath

The XPATH expression.

Data Types

Return

value

xpath

String

XML

String

Usage

If value is Null, XMLEXTRACTVALUE returns Null. If the XPATH comparison returns more than one possible value, Sybase CEP Engine returns the first value and issues a warning that other values were found.

See Also

Example

The following example shows an extraction of all "items" element nodes:

INSERT INTO OutStream
SELECT XMLEXTRACTVALUE(OrderVal1,'//items')
FROM Orders;