Extracting Matching Text in Strings
AMPS includes a function, REGEXP_MATCH
, that returns the first match of text within a string. REGEXP_MATCH
can be either a literal match or PCRE pattern to match the text to. If there is no match, then a NULL
value is returned.
The following expressions all evaluate as true:
The following snippet shows REGEXP_MATCH
constructed as a field:
With the following data:
Would result in:
Function
Parameters
Description
REGEXP_MATCH
string to transform, pattern or text to match
Returns the first occurrence of the pattern or text to match, or NULL
Last updated