Name

split — Split a string and return a list of strings.

Syntax

split(string)
split(string, regex)
              

The SPLIT function has the following arguments:

string

A string to be split in to parts to make up the list.

regex

(Optional) A regular expression that will be used to delimit the input string in to parts.

Description

Split a string and return a list of strings. The input string will be split in to parts at the sequences that match to the regular expression. The splitting sequences are discarded.

By default the string will be split at comma characters, but any splitting sequence can be specified using reqular expressions.

The resulting list will contain string values.

White space within the input string is not removed and will be included in the value elements.

Examples

Formula

Description

Result

split('a,b,c')Return a list of strings.list('a','b','c')
split('a, b ,c')Return a list of strings with embedded white space.list('a',' b ','c')
split('1,2,3')Return a list of strings.list('1','2','3')
split('a:b:c', ':')Return a list of strings at the colon character.list('a','b','c')