Can we dynamically increase the size of occurs clause? i.e
In case I an not sure of the size of array and want to
increase the size at run time.If yes , how?
Answer / lu
yes, ...you declare an array like this:
77 ws-counter pic 9(04) value zeroes.
01 ws-array.
07 ws-field pic x (01) ouccurs 1 to 1000
depending on ws-counter.
Procedure Division.
Perform Read-file until ws-end-of-file = 'y'.
Read-file.
Read file at end
move 'y' to ws-end-of-file.
if ws-end-of-file not = 'y'
add 1 to ws-counter
move aa of file to ws-field (ws-counter).
the maximun is 1000 occurrences and minimun is 1...
| Is This Answer Correct ? | 14 Yes | 0 No |
Can we use icetool in cobol program?
if a dataset is already created with fixed length but after that i want to change fixed length to variable length then how is it possible
In which area will you utilize 88 level items in cobol?
wht is structured cobol pgm and non structred cobol pgm ?
01 a pic s9(5) occupies how many bytes ?
How to get the last record in vsam file in cluster? And how can you get the ksds file records into your cobol program?
How can you declare the file ?
Write the code implementing the perform … varying.
How to use the same COBOL program in Batch and CICS on lines? explain with an example
how will u find out 3rd week's 2nd day using occurs ?
i declare a Table as OCCURS 2000 TIMES.If the input file has more than 2000 records will the COBOL program fail?
What rules are to be followed while using the corresponding options?