It says to use EXTERNAL clause in working storage section. I have not used this clause before. Is it recommended to use this clause when needed or any other solution is available?. I am checking the IBM library. Meanwhile if someone who encountered the same issue can help me, that will be great.
There is a business requirement for the existing program to increase the OCCURS XXXX TIMES clause for accomodating, processing one more table data. That is why it needs more than 128 MB(reasoned it when I got this error). Since it is an existing program which is running live without issue for no of years with more business logic. I can't reduce it without thorough analysis.
It is main program.
By the way, I tried with EXTERNAL clause during compilation by giving
01 WS-XXXXX EXTERNAL
05 TABLE-DATA OCCURS XXXXX TIMES
Compilation goes thru fine. Is it okay to use EXTERNAL or as you said I can try various ways if it is necessary. Please advise.
Mainly is unless people at the site are used to using EXTERNAL there is going to be a larger element of "uncertainty" about it. The LOCAL-STORAGE for a main program is more like an "extra WORKING-STORAGE" without having to wonder about the details.
The LOCAL-STORAGE is initialised by Cobol each time the program is entered. This is why it would not work in a program entered more than once.
The WORKING-STORAGE is initialised by Cobol the first time a program is entered. If a program is entered only once, WORKING-STORAGE and LOCAL-STORAGE are equivalent, each with their own separate 128mb, which should be enough for you.
As they are, for a main program, the same, this is why I'd go with LOCAL-STORAGE - it is the simplest, and won't get other people wondering "what's all that about?".
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum