This function returns a text list with all substrings matching a given regular expression.
Syntax
findPattern(text, regularExpression) #Output: Text list
If you want to ignore the case, have a look at the findPatternIgnoreCase() function.
Parser expression | Output |
---|---|
findPatternIgnoreCase("Grass is Green and Sky is Blue.", "red|green|blue") | ["Green", "Blue"] |
findPattern("Grass is Green and Sky is Blue.", "red|green|blue") | [ ] |