String Functions

Operator Description Example
INDEXOF INDEXOF(string, ‘character’, startIndex) Returns the index of the first occurrence of a character in a string, searching forward from a start index.
LAST_INDEX LAST_INDEX_OF(expression) Returns the index of the last occurrence of a character in a string, searching backward from a start index.
LCFIRST LCFIRST(expression) Converts the first character in a string to lower case.
LOWER LOWER(expression) Converts all characters in a string to lower case.
REGEX_EXTRACT REGEX_EXTRACT (string, regex, index) Performs regular expression matching and extracts the matched group defined by an index parameter. The function uses Java regular expression form.
REGEX_EXTRACT_ALL REGEX_EXTRACT (string, regex) Performs regular expression matching and extracts all matched groups. The function uses Java regular expression form.
REPLACE REPLACE(string, ‘oldChar’, ‘newChar’); Replaces existing characters in a string with new characters.
STRSPLIT STRSPLIT(string, regex, limit) Splits a string around matches of a given regular expression.
SUBSTRING SUBSTRING(string, startIndex, stopIndex) Returns a substring from a given string.
TRIM TRIM(expression) Returns a copy of a string with leading and trailing white space removed.
UCFIRST UCFIRST(expression) Returns a string with the first character converted to upper case.
UPPER UPPER(expression) Returns a string converted to upper case.

Leave a comment