Returns a substring from a string, using a delimiter character to divide the string into a sequence of tokens.
SPLIT ( string_expression, deliminator, token_number )
A valid string expression.
deliminator The substring used to divide the string_expression.
token_number The instance of the divided tokens to return. When the token number is positive, tokens are counted starting from the left end of the string; when the token number is negative, tokens are counted starting from the right.
Returns a STRING.
Examples in this section use the example blockchain.
The following example splits each value in
str at each instance of "e" and returns the first instance.
SELECT SPLIT(str, "e", 1) FROM example;
SELECT SPLIT(str, "e", 1) [STRING]