If it is a batch program don't worry about 200k, its 2005 not 1980, If it's not referenced then the pages it occupies is not paged in.
What is not said is how often does LP-TOKEN-COUNT change. Is it set once for the life of the program? or does it change for every transaction/record read. And how often is the table referenced. If you allocate memory and then free it every time you read a record then the overhead may out weigh the few extra bytes you use. I'd be more worried about how he is using this table, SEARCH verb, subscriptiing? what does the subscript look like. Sometimes the code that is generated for a "variable" length table is poor and it almost is better to define the table as a fixed lenght table and populate the table with a value that will naturally terminate a SEARCH. Just some more thoughts ----- Original Message ----- From: "Rob Wunderlich" <[EMAIL PROTECTED]> Newsgroups: bit.listserv.ibm-main To: <IBM-MAIN@BAMA.UA.EDU> Sent: Wednesday, May 11, 2005 7:10 PM Subject: COBOL OCCURS DEPENDING ON Storage usage > A of my colleague has asked me a COBOL (not my langauge) question. He is > using the construct below. His objective is to minimize storage > requirements. My RFTM does not make it clear if the use of DEPENDING ON > actually results in less getmained storage (assuming LP-TOKEN-COUNT < > 99999) than without using DEPENDING ON. > > Does anyone know for sure how this works? Will storage for 99999 occurences > be established regardless of the value of LP-TOKEN-COUNT? > > Thanks, > Rob > > 01 LP-TOKEN-BYTE-CODE. > 05 LP-TOKEN-X. > 10 LP-TOKEN-COUNT PIC S9(9) COMP VALUE 0. > 10 LP-TOKEN-ENTRY OCCURS 0 TO 99999 TIMES > DEPENDING ON > LP-TOKEN-COUNT. > 15 LP-TOKEN-TYPE PIC S9(2) COMP. > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, > send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO > Search the archives at http://bama.ua.edu/archives/ibm-main.html > ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html