Interstage Shunsaku Data Manager Application Development Guide - Microsoft(R) Windows(R) 2000/ Microsoft(R) Windows Server(TM) 2003 - - UNIX -
Contents Index PreviousNext

Appendix B Format of Search, Return and Sort Expressions> B.3 Search Expressions

B.3.1 Conditional Expressions

Conditional expressions are used to compare the value of an element node specified by a path expression with a keyword, or the value of a text node specified by a text expression with a keyword. Conditional expressions are also used to compare the value of an attribute node specified by an attribute expression with a keyword.

The following figure shows the definition for conditional expressions.

[Figure B-10 Conditional Expression Definition]

Condition expressions are made up of path expressions, text expressions or attribute expressions, relational operators and keywords.

Patterns and strings are enclosed by either double-quotes (") or single-quotes ('). Double-quotes and single-quotes cannot be mixed.

The following section explains the item specified in condition expressions.

mark1Path Expressions

The path expression is used to identify the position of an element node in the XML document.

Specify an element node in the XML document to be compared.

Refer to B.2.1 Path Expressions for more information on the format for path expressions.

mark1Text Expressions

A text expression specifies the (string) value of the text node below element nodes of an XML document. Specify a text node below element nodes of an XML document to be compared. Refer to B.2.2 Text Expressions for more information on the format for text expressions.

If same text expression is specified at the path expression in the condition expression, the same result will be returned.

The example of condition expressions are shown as follow:

Example

Path expression : /root/company/name='Fraser'
Text expression: /root/company/name/text()='Fraser'

Result: the return result of both expressions will be the same

mark1Attribute Expressions

An attribute expression specifies the value of the particular attribute nodes of an XML document. Specify the value of the particular attribute nodes of an XML document to be compared. Refer to B.2.3 Attribute Expressions for more information on the format for attribute expressions.


Contents Index PreviousNext

All Rights Reserved, Copyright(C) FUJITSU LIMITED 2006