Purpose
Returns the string that results from removing blanks on the right side of a string value, shifting the remainder of the string value to the right side, then filling the left side with as many blanks as were removed from the right side.
Syntax
►►─┬─ RIGHT-JUSTify ─┬─ ( string ) ───────────────────────────────────────────►◄ └─ RIGHTjus ──────┘
Parameters
Specifies the string value that is right justified.
String can be:
Example
In the following example, the right justify function is used to right justify EMP-LNAME (PIC X(20)):
Initial value:
EMP-LNAME: ' SMITH '
Statement:
MOVE RIGHT-JUSTIFY(EMP-LNAME) TO EMP-LNAME.
Returned string:
' SMITH'
|
Copyright © 2014 CA.
All rights reserved.
|
|