skip to main content

Procedure Division Statements : INITIALIZE

INITIALIZE
General Format
INITIALIZE { Identifier-1 } ... [ WITH FILLER ] 
  [ REPLACING { {ALPHABETIC         } DATA BY Identifier-2 } ... ] 
                {ALPHANUMERIC       } 
                {NUMERIC            } 
                {ALPHANUMERIC-EDITED
                {NUMERIC-EDITED     }
  [ {ALL           } TO VALUE ]
  [ THEN REPLACING { ALPHABETIC          } DATA BY { identifier-3 } ]
Syntax Rules
1.
2.
3.
4.
5.
6.
General Rules
1.
2.
3.
 
The implicit statement is:
 
MOVE sending-operand TO receiving-operand.
4.
A.
i.
ii.
iii.
B.
i.
ii.
C.
i.
a.
ii.
iii.
5.
A.
i.
B.
C.
6.
7.
8.
Examples
The following examples are applied to the following group data item
01 var1.
   05 num1   pic 9(3value 125.
   05 str1   pic x(3value "abc".
   05 num-ed pic zz,zz9 value 1234.
Initialize group item to the default values by type
Initialize group item to specific values by type
initialize var1 replacing 
                alphanumeric   by all "x"
                numeric        by all "9"
                numeric-edited by "0"

Copyright (c) 2017 Veryant
Contact us
Please share your comments on this manual or on any
Veryant product documentation with the email button at the top left