Examples - excluding a symbol
Using Regex for specific filter: Exclude symbols
In this example we want to exclude everything that contains @ or /
To do this, we will use the following Regular Expression:
^((?![@/]).)*$
Breakdown of the Regex elements used
^ | Beginning of the string |
() | Capturing Group |
(?!) | Negative look ahead. This specifies a group that cannot match after the main expression. (i.e. if it matches, then the result is discarded) |
[] | Matches any character in the set |
@/ | Character |
. | Matches any character except line breaks |
* | Match 0 or more of the preceding token |
$ | End of the string |
Practical case
We can now use the expression explained above to single out group members.
The Filter By Regular Expression option will be used to exclude everything that contains @ (for emails) or / (for users).
Click on the filter icon and select Filter By Regular Expression.
Having used the expression ^((?![@/]).)*$ to filter the column, all lines that contained the symbols @ or / have now been excluded.