Skip to main content

String

This section describes the following string functions:

Function Description
BASE64_DECODE Decode a base 64 string into a string
BASE64_TO_HEX Converts a base 64 string into a hex string
BYTES_SUBSTRING Returns a substring of the input, using the offsets in bytes of the UTF-8 encoded byte representation. Partial characters and invalid UTF-8 code points are removed from the result
CONCAT Returns the concatenation of string1, string2, ..., stringN
DATE Casts a string to a date
JOIN_ARRAYS Joins any number of arrays by index using a MessageFormat pattern
LENGTH Returns the length of the string
LOWER Converts the string to lowercase letters
LPAD Pad the input string to the left with a given padding string up until size
LTRIM Returns the given string without leading whitespaces
MD5 Hashes the input using MD5
PARSE_DATETIME Parses a string into a timestamp with time zone using a format
REPLACE Replaces all instances of search with replace in input. If the search is empty, inserts replace in front of every character and at the end of the input
REVERSE Returns a string with the characters in reverse order
RPAD Pad the input string to the right with a given padding string up until size
RTRIM Returns the given string without trailing whitespaces
SHA1 Hashes the input using SHA-1
SHA256 Hashes the input using SHA-256
SHA3_512 Hashes the input using SHA3-512
SORT_VALUES Returns the values sorted in dictionary order
SPLIT Returns the given string split by the provided delimiter. Does not remove empty entries
SPLIT_TO_RECORD Returns the given string split by the provided delimiter
STRING_FORMAT Format any number of inputs into a string using the given format
STRIP_MARGIN For each line remove the prefix of control or whitespace characters followed by the given margin char
STRIP_PREFIX Remove the given prefix string from the beginning of the string
STRIP_SUFFIX Remove the given suffix string from the end of the string
STRPOS Returns the starting position of the first instance of a given substring within a string
SUBSTR Extracts a substring of a certain length starting from a specified point within the given string
SUBSTRING Extracts a substring of a certain length starting from a specified point within the given string
TRANSLATE Translates the given value using a given dictionary
TRIM Returns the given string without leading or trailing whitespaces
TRIM_CHARS Returns the given string without leading or trailing characters
UPPER Converts the string to uppercase letters
UUID_GENERATOR Returns UUID
XX_HASH Hashes the input using xxHash

Did this page help you?

If you find any issues with this page or its content – a typo, a missing step, or a technical error – please let us know!