Extracts all pattern matches from a string.
Result = SRP_Regex("ExtractAll", String, Pattern)
Returns
An @FM delimited list of all matches, if found, or "" if no matches are found.
Parameters
Parameter | Description |
---|---|
String | The target string to be pattern matched. (REQUIRED) |
Pattern | The regex pattern. (REQUIRED) |
Remarks
The ExtractAll service is a simplified version of the SearchAll service. Instead of returning a structure of information, this service simply returns an @FM delimited list of matched strings. This is useful when you are using regex to parse out information.
Examples
String = 'Call 800-555-1212 for info, or fax us at 888-555-3535' Pattern = '((\d{3})(?:\.|-))?(\d{3})(?:\.|-)(\d{4})' PhoneNums = SRP_Regex("ExtractAll", String, Pattern)