pig tutorial - apache pig tutorial - Pig - String extraction using regex ? - pig latin - apache pig - pig hadoop
REGEX_EXTRACT_ALL
- Performs regular expression matching and extracts all matched groups.
Syntax
Terms
string | The string in which to perform the match. |
regex | The regular expression. |
Usage
- Use the REGEX_EXTRACT_ALL function to perform regular expression matching and to extract all matched groups. The function uses Java regular expression form.
- The function returns a tuple where each field represents a matched expression. If there is no match, an empty tuple is returned.
Example
- This example will return the tuple (192.168.1.5,8020).