You can create an XPath query predicate for a view in an XML source definition.
To create an XPath query predicate:
Open an XML source definition in the XML Editor.
Select a view in the XML Editor workspace.
The view columns appear in the Columns window.
Click View Row XPath.
The Specify Query Predicate for XPath window appears. You can enter an XPath query predicate in the XPath Predicate window, or you can choose elements, operators, and functions from the tabs in the dialog box.
Click the Child Elements and Attributes tab to display the elements and attributes that you can add to an XPath query predicate.
Double-click an element or attribute to add it to the XPath query predicate.
The component appears in the panel.
Click the Operators tab.
Use operators to create expressions. You can compare elements to values or other elements, or you can create mathematical expressions.
The following table describes the operators you can add to an XPath query predicate:
Operator
Description
+
Add
-
Subtract
*
Multiply
div
Divide
mod
Modulus
and
Boolean and
or
Boolean or
<
Less than
<=
Less than or equal to
>
Greater than
>=
Greater than or equal to
=
Equal
!=
Not equal
Double-click an operator to add the operator to the XPath query predicate.
To add the PowerCenter XPath query predicate functions, click the Functions tab. Functions accept arguments and return values.
Select another element or attribute from the Child Element and Attributes tab, or enter a value in the XPath Predicate window to complete an expression.
Click Validate to validate the XPath query predicate.