text

regexp_split_to_array

Splits at matching delimiters and returns a text array; PostgreSQL ignores certain zero-length delimiter matches.

Formal Syntax & Structure

sql syntaxsql
regexp_split_to_array(string, pattern [, flags])

Working Example

Example Snippetsql
SELECT regexp_split_to_array('red, blue;green', '[,; ]+');
SQL Reference