XML Record Filter Support


9.0D

 

To allow quicker access to records, a new record filter concept has been added to the READ statement. A record filter is a query string that is decoded and used during the initial READ statement and all subsequent READKG and READKGP statements.

Note the following:

  1. READKG and READKGP statements keep a separate file pointer when performing READ operations.

  2. The record filter query string consists of one or more expressions separated by logical operators.

  3. An expression consists of a field name, an operator, and a value. The operators supported are =, <>, <, <=, >, >= and LIKE (as in SQL syntax). The values can be either a quoted string for a string match, or a numeric value for a numeric comparison.

  4. The logical operators are OR, AND, and NOT.

  5. Expressions can be grouped by using the ( and ) characters.

  6. The LIKE operator performs a pattern matching string comparison where an underscore (_) matches any one character, a % matches zero or more characters, and the backslash (\) is the forcing character.

Examples:

 

     CompanyName = 'Bill' AND ShipperID = 10 OR Phone='(705) 495-5555'

 

     CompanyName = 'Bill' AND ( ShipperID = 10 OR Phone='(705) 495-5555' )

 

     CompanyName LIKE '%Bill%' AND ShipperID > 100

 

 

See Also: XML Support



PL/B Language Reference XML Schema Support XML Transaction Support