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