Manipulating character strings

When parsing, concatenating or accessing parts of a character string contained in CHAR, VARCHAR and STRING variables, the runtime system must follow the BDL language semantics, which can result in performance issues with very large character strings.

When heavy string manipulation is to be done, consider using the base.StringBuffer class instead of CHAR/VARCHAR/STRING variables: The base.StringBuffer class is designed for character string manipulation.

Furthermore, execution time of character iterations (to find a specific sub-string for example or get the position of a character in a string), can be affected when using the UTF-8 locale and CHAR length semantics usage: The runtime needs to compute the number of bytes representing a character when iterating through the string.