can u plz expain me how to declare dynamic array? what is
the meaning of depending on clause in dynamic array?
Answers were Sorted based on User's Feedback
Answer / amarnadh reddy
When a table of variable size is required, the occurs
depending clause may be used.
01 A1 PIC 99.
01 REC-1.
05 P1 PIC XX.
05 P2 PIC 99 OCCURS 1 TO 90 TIMES DEPENDING ON A1.
Here depending on the value of the data name A1 the size of
P2 Will be decided. It can be anything between 1 and 90.
Is This Answer Correct ? | 31 Yes | 4 No |
Answer / roger riek
You can indeed create dynamic arrays in MVS Cobol. You need
to use the heap facility in the language environment.
There is a discussion about how to do this at
http://home.centurytel.net/rjriek/
Is This Answer Correct ? | 0 Yes | 1 No |
dynaic array is notink but a two dimension array.
01 studet.
02 stunam occurs 3 to 4 times depanding on n.
03 stuname pic x(15).
03 stumrk occurs 2 times.
04 stumark pic 9(3).
this is dynamic array.now runtime will pass the input.because
using depanding clause.
depanding clause pass the value runtime.
Is This Answer Correct ? | 3 Yes | 12 No |
what is the difference between external and global variables?
INREC AND OUTREC? HOW TO SPLIT 5K RECORDS TO DIFFERENT FILES IN A FILE IN COBOL? RESTART IN COBOL-DB2? ISOLATION LEVELS?
In COBOL CALL-CALLING,if a program A is calling 3 sub- programs, dynamically, then it is said sub-programs will always will always in Initial Mode. My question is : Do we need to code CANCEL or (IS INITIAL) for dynamically called sub-programs or it is the property of Dynamically called pgms so every time sub-pgms are called they will be in initial mode. ***This question is only Dynamic call****, Please reply. Thank you in advance.
What are the rules of the move verb?
what is SYNCHRONIZATION?
how can we find total no of records in a file ....is there any utility......?
How can we find that module can be called – whether DYNAMICALLY or STATICALLY?
how to resolve the file status 47.......
sample code for read a 2nd record from last in flatfile how can do?
What is wrong with the following data declaration? 01 W-DATE PIC X(6). 05 DD PIC 99. 05 MM PIC 99. 05 YY PIC 99. (a) Nothing is wrong. (b) Under W-DATE all level 05 items are having a PIC 99 but level 01 has PIC X(6). (c) PIC can't be specified for a group item. (d) DD, MM, and YY are invalid datanames.
How you can delete a record from a ps file in cobol?
What is the difference between working storage copybook and linkage section copybook?