Script Elements for Editing Strings

The Automation Engine scripting language includes several elements that you can use to edit strings. The original strings remain unchanged. The new string is stored in a script variable.

Add, Replace or Remove Characters

  • FORMAT

    Adds or removes leading zeros

  • STR_CUT, MID, SUBSTR

    Copies characters, optionally truncates leading or trailing characters

  • STR_LTRIM

    Deletes empty spaces at the beginning of a string

  • STR_PAD

    Extends a string to a certain length

  • STR_RTRIM

    Deletes empty spaces at the end of string

  • STR_SUBSTITUTE

    Replaces characters in a string

  • STR_TRIM

    Removes empty spaces at the beginning and the end of a string

Number and Position of Characters

Search and Compare Strings

  • STR_ENDS_WITH

    Checks whether a string ends with a certain other string

  • STR_FIND_REVERSE

    Searches for a character or a string within a string, starting at the end of the string

  • STR_MATCH

    Compares two strings

  • STR_STARTS_WITH

    Checks whether a string starts with a certain other string

Combine or Split Strings

  • STR_CAT

    Concatenates two strings

  • UC_CRLF

    Inserts a line break

  • STR_SPLIT

    Splits a string into several parts using a separator

Check Type and Case of Characters

  • ISNUMERIC

    Checks if a string is numeric

  • STR_ISLOWER

    Checks whether the characters in a string are written in lowercase

  • STR_ISUPPER

    Checks whether the characters in a string are written in uppercase

  • STR_LC, CONV_LC

    Converts all characters of a string to lowercase

  • STR_UC, CONV_UC

    Converts all characters of a string to uppercase

Convert Strings

  • ALPHA2RUNNR

    Converts the name of a Job or report file to a RunID

  • ARRAY_2_STRING

    Converts a script array to a string

  • CONVERT

    Converts the data type of a value

  • HEX

    Converts a string into hexadecimal form

  • HEX_2_STRING

    Converts hexadecimal Control Return (CR) and Line Feed (LF) characters to strings

  • RUNNR2ALPHA

    Converts the RunID to the corresponding file name

  • STR_REVERSE

    Reverses the order of the characters within a string

  • STR_SUBSTITUTE_VAR, STR_SUB_VAR

    Replaces script variable names by their values

See also:

Script Statements and Functions for String and Text Processing