The LIKE keyword is used to define an item like an existing one. For information about using LIKE with an object, see LIKE(object-name).
When the LIKE keyword is specified, the item being defined takes on the length and the data format of the item specified as the parameter. Standalone fields, prototypes, parameters, and data-structure subfields may be defined using this keyword. The parameter of LIKE can be a standalone field, a data structure, a data structure subfield, a parameter in a procedure interface definition, or a prototype name. The data type entry (position 40) must be blank.
If the parameter of LIKE is a prototype, then the item being defined will have the same data type as the return value of the prototype. If there is no return value, then an error message is issued.
The length of the item being defined can be adjusted.
You specify the length adjustment in the second parameter
of the LIKE keyword in free-form definitions, or the
Length entry in fixed-form definitions.
The length adjust must be specified with either a positive (+)
or negative (-) sign. 
For character fields, the length
adjustment is the number of additional (or fewer) characters. 
For numeric fields, the length
adjustment is the number of additional (or fewer) digits. For integer
or unsigned fields, adjustment values must be such that the resulting number
of digits for the field are 3, 5, 10, or 20. For float fields, length adjustment
is not allowed. 
For graphic or UCS-2 fields, the length
adjustment is the number of additional (or fewer) graphic or UCS-2
characters (1 graphic or UCS-2 character = 2 bytes). 
For date, time, timestamp, basing pointer, or procedure
pointer fields, length adjustment is not allowed. 
When LIKE is used to define an array, the DIM keyword is still required to define the array dimensions. However, DIM(%elem(array)) can be used to define an array exactly like another array.
Use LIKEDS to define a data structure like another data structure, with the same subfields.
The following examples are shown first in free-form and then in fixed-form.
DCL-S Name CHAR(20);
DCL-S Long_name LIKE(Name : +5); 1
DCL-DS Struct;
NameList LIKE(Name) DIM(20) INZ(*ALL'X'); 2
END-DS;
DCL-PR GetBonus LIKE(Salary : -2); 3
Employee_Id INT(10) VALUE;
END-PR;
*.. 1 ...+... 2 ...+... 3 ...+... 4 ...+... 5 ...+... 6 ...+... 7 ...+... 8
DName+++++++++++ETDsFrom+++To/L+++IDc.Keywords+++++++++++++++++++++++++++++
D.....................................Keywords+++++++++++++++++++++++++++++
D Name S 20
D Long_name S +5 LIKE(Name) 1
D Struct DS
D NameList LIKE(Name) DIM(20) INZ(*ALL'X') 2
D GetBonus PR -2 LIKE(Salary) 3
D Employee_Id 10I 0 VALUE