Your Browser is not longer supported

Please use Google Chrome, Mozilla Firefox or Microsoft Edge to view the page correctly
Loading...

{{viewport.spaceProperty.prod}}

String functions

&pagelevel(4)&pagelevel

This section presents all functions that process or analyze strings.

String processing

The following functions process one or more strings and return a new string as a result:

Uppercase/
lowercase

UPPER-CASE( )

Changes lowercase letters to uppercase

LOWER-CASE( )

Changes uppercase letters to lowercase

String length

FILL( )

Lengthens a string with fill characters

TRIM( )

Removes repeated characters at the beginning or end of a string

Substring

SUBSTRING( )

Returns a specific substring

REPLACE( )

Replaces a specific substring

SDF list

EXTEND-SDF-LIST( )

Appends a new element to an SDF list

New name

RENAME( )

Gives a new name to the specified string; wildcards may be used

Field extraction

EXTRACT-FIELD( )

Extracts a field from a string

String analysis

The following functions analyze a specified string:

Initial position

INDEX( )

Searches for the position of a substring within a full string

String length

LENGTH( )

Determines the length of a string

Character search

VERIFY( )

Checks whether particular characters are contained in the specified string

Pattern

WILDCARD( )

Checks whether a string contains a particular pattern

C-Literal

IS-C-LITERAL( )

Checks whether a string is a C literal

X-Literal

IS-X-LITERAL( )

Checks whether a string is an X literal

Number

IS-INTEGER( )

Checks whether a string represents an integer (i.e. can be converted into an INTEGER value)

SDF structure

SDF-STRUCTURE- VALUE( )

Returns the value of an SDF structure as a string

IS-SDF-STRUCTURE()

Checks whether a string is an SDF structure

SDF list

IS-SDF-LIST( )

Checks whether a string is an SDF list
(an SDF list is a string that is interpreted in accordance with the rules for operand lists in commands)

SUBLIST( )

Returns an element in an SDF list

SUBLIST-NUMBER( )

Returns the number of elements in an SDF list

SDF data type

CHECK-DATA-TYPE( )

Checks whether a string satisfies the SDF data type requirements

List variable

SEARCH-LIST- INDEX( )

Searches a list variable for a string (including regular POSIX expression)

Name checking

The following function checks whether the specified string complies with the necessary naming conventions:

Variable name

IS-VARIABLE-NAME()

Functions for accessing variables

The functions presented in this section return as a return value a variable name, the contents of a variable or entries for building up a variable. They make it possible to process complex variables.

Complex variable

FIRST-VARIABLE-NAME( )

Returns the variable name of the first variable element

NEXT-VARIABLE-NAME( )

Returns the variable name of the next variable element

Number of variable elements

SIZE( )

Returns the number of elements in a complex variable

Upper limit for list elements

LIMIT( )

Outputs the maximum number of elements that the specified list variable can contain

Value of an array index

ARRAY-INDEX( )

Returns the value of an array index, i.e. the array index that complies with the specified conditions

Variable attributes

Variable type

CURRENT-TYPE( )

Returns the current data type of a simple variable

Attribute occurrence

VARIABLE-ATTRIBUTE( )

Returns the value of the specified attribute

Variable declaration

IS-DECLARED( )

Checks whether a variable is declared

Initialization

IS-INITIALIZED( )

Checks whether a variable contains a valid value

Scope

LAYOUT-SCOPE( )

Returns the scope of a structure layout