TRIMR
The TRIMR function returns the given string with any trailing blacks removed, or the given string with any trailing specified characters removed.
The type of the function is alphanumeric, DBCS, or national depending on the class of its argument.
- argument-1
- Must be a nonnumeric literal or data item of class alphabetic, alphanumeric, DBCS, or national. Argument-1 identifies the source string for the trim.
- argument-2
- If specified, it must be a nonnumeric literal or data item of the same class as argument-1. It specifies the characters to trim off. If not specified, the trim character defaults to blank.
The length of the returned string depends on the content and the class of argument-1. It is the length of the returned string in number of character positions. If argument-1 is a DBCS or national data item, the length is in DBCS or national character positions.
For more information on returned values and examples, see TRIM.