pub.string:lookupTable
WmPublic. Locates a key in a String Table and returns the string to which that key is mapped.
Input Parameters
lookupTable | String [ ] [ ] A multi-row, multi-column string table in which to search. |
keyColumnIndex | String Index of the "key" column. Default is 0. |
valueColumnIndex | String Index of the "value" column. Default is 1. |
key | String Key to locate. Note: The key is case sensitive. |
ignoreCase | String Optional. Flag indicating whether to perform a case-sensitive or case-insensitive search. Set to: true to perform a case-insensitive search. false to perform a case-sensitive search. This is the default. |
useRegex | String Optional. Flag indicating whether the values in the table are to be interpreted as regular expressions. Note: The regular expressions in the table should not include slashes. For example, use hello.*, not /hello.*/. Set to: true to interpret the key column values in the table as regular expressions. false to interpret the key column values in the table as literal values (that is, not regular expressions). This is the default. |
Output Parameters
value | String First value in the "value" column whose key matches key. If no match is found, this parameter is null. |
Usage Notes
The pub.string:lookupTable service can treat the key column values of the table as regular expressions when useRegex is set to true. By default, Integration Server uses the Perl 5 pattern matching provided by the Jakarta ORO libraries. If you want Integration Server to use Java regular expression pattern matching provided in the java.util.regex.Pattern class, set watt.server.usejavaregex to true. After enabling Java regular expression pattern matching, if execution of pub.string:lookupTable service results in the java.util.regex.PatternSyntaxException, you may need to change the syntax of the supplied pattern in delim. As an example, if your regular expression has a value of “(\\|\*|\?|{)”, it needs to be changed with “(\\|\*|\?|\{)” i.e., characters like { or }, need to be escaped with \.
Important:
The Jakarta ORO project was retired by Apache in September 2010 because there were not any new features or releases planned.
Software AG strongly recommends modifying regular expressions that relied on Perl 5 pattern matching to use Java regular expressions.The java.util.regex.Pattern class API documentation can be found here:
https://docs.oracle.com/en/java/javase/11/docs/api/index.html The section “Comparison to Perl 5” identifies Perl 5 constructs that are not supported by java.util.regex.Pattern. Keep in mind that there could be issues that are not described in the documentation.
Note:
The watt.server.usejavaregex parameter and the use of Perl 5 regular expression pattern matching as the default was introduced in PIE-80824 (IS_10.15_Core_Fix4 and higher). Prior to application of this fix, Integration Server 10.15 did not include the Jakarta ORO libraries. As a result, Integration Server performed Java regular expression pattern matching as described in the java.util.regex.Pattern class.