The advanced string attribute operations can be set when you execute Code Search and when you have defined a search filter.
Note: The operations are available only for string objects.
You can execute a Code Search using different criteria. When you set a condition to search string attributes, you can specify
the following operations:
- Like / Not Like
- Performs a wildcard (mask) match where
? (question mark) represents any single character and
* (asterisk) represents any character sequence.
Name from the Name list, then select
Like from the Operations drop-down list, and then write
* DAY in the values field. The new criterion returns all names ending with "DAY".
- If the search criterion is:
"Name" like "???DAY", the search finds all 6 character long names ending with "DAY".
- Regular Expression
- Performs regular expression matching. This function uses syntax specific to the RDBMS.
Example (Oracle only): "Name" matches "^Ste(v|ph)en", will match names which begin with "Ste" and end with "en" with either
"v" or "ph" in between, so both "Steven" and "Stephen" will be selected.
On Microsoft SQL Server databases, you need to install an additional package on the SQL Server machine to get regular expression
support. This package is provided by Microsoft.
Note: There are significant differences in regular expression syntax between the Oracle and MS SQL Server implementations. For more
information check their corresponding documentation.
Note: Due to the nature of the regular expressions, utilization of a database index is not possible for their evaluation, therefore
the performance for such queries is expected to be relatively slower.
- Length is Less than / Length is Greater than
- Compares attribute value lengths.
Example: "Name" length is "6", finds all 6 character long names.
- Match other attribute value/ Do not match other attribute value
- Compares two attribute values.
Example: "Name" matches attribute "JobName", finds all names matching the "JobName" as well.
- Contain other attribute value/ Do not contain other attribute value
- Checks if an attribute value contains another attribute value.
Example: "Name" contains attribute "JobName", finds all names which also contain "JobName" value.
- Partial Attribute match
- Partial Match compares part of an attribute value with another part of another attribute value.
Example: "Name" pos 10-12 matches pos 5-7 of "JobName", finds all names where the value from character position 10 to 12 matches
the "JobName" value from character position 5 to 7.