Extracting Matching Text in Strings
AMPS includes a function, REGEXP_MATCH, that returns the first match of text within a string.
REGEXP_MATCH
REGEXP_MATCH
REGEXP_MATCH(string_to_transform, pattern_or_text_to_match)
Returns the first occurrence of the pattern_or_text_to_match. This can be either a literal match or PCRE pattern.
Parameters
string_to_transform: The string to search within.pattern_or_text_to_match: The literal text or PCRE pattern to match.
Returns
The first matching text, or NULL if there is no match.