- Apache Presto Tutorial
- Apache Presto - Home
- Apache Presto - Overview
- Apache Presto - Architecture
- Apache Presto - Installation
- Apache Presto - Configuration
- Apache Presto - Administration
- Apache Presto - SQL Operations
- Apache Presto - SQL Functions
- Apache Presto - MySQL Connector
- Apache Presto - JMX Connector
- Apache Presto - HIVE Connector
- Apache Presto - KAFKA Connector
- Apache Presto - JDBC Interface
- Custom Function Application
- Apache Presto Useful Resources
- Apache Presto - Quick Guide
- Apache Presto - Useful Resources
- Apache Presto - Discussion
regexp_extract_all(string,pattern,group)
Query
presto:default> SELECT regexp_extract_all('1a 2b 3c 6f', '(\d+)([a-z]+)', 2) as regexp_group;
Result
regexp_group -------------- [a, b, c, f]
Here,
- First arg - string
- Second arg - pattern
- Third arg - 2 indicates two groups are used (d+ and a-z)
Hence, the query returns the string matched by the regular expression pattern (a-z) characters with the group.
apache_presto_sql_functions.htm
Advertisements