In ENA, attributes values in which you can free type also allow entry of regular expressions (Regex). When defining filter rules with regular expression, note that pattern matching is case-sensitive.
Character | Description |
---|---|
\ | backslash |
$ | dollar sign |
| | vertical bar (pipe symbol) |
* | asterisk (star) |
( | opening parenthesis |
[ | opening square bracket |
^ | caret |
. | period (full stop or dot) |
? | question mark |
+ | plus sign |
) | closing parenthesis |
{ | opening curly brace |
Examples:
- a name that includes lon:
lon
- a name that starts with lon:
^lon
- a name that starts with either lon or par:
^((lon)|(par))
- a name that ends in 1:
1$
- a name that ends in a, b or c:
[abc]$
- a name that contains at least one digit:
[0-9]
- a name that include s, t, u or v:
[!s-v]
- a name that include a pair of digits next to each other:
[0-9]{2}
- a name that has x as the fourth character:
^…x
- 1 or more special characters (metacharacters) in their name require that the character is escaped. For example, a name with a plus sign is escaped using the backslash:
eol\+us
This example filter excludes all devices that include bvt in their name:
^((?!bvt).)*$
Comments
0 comments
Please sign in to leave a comment.