Good News Everybody!
The new search engine is LIVE!
Please report any problems to david (at) midrange.com.
|
Bob C. - this was my understanding as well, and the reason I asked the question. Since the code in the procedure (*MODULE object) is bound by copy, once the *PGM sets on LR, the program is no longer resident, and all storage should be freed...no?
Scott K. - As stated above, not a service program, a simple 'nomain' module. The job that is calling the RPG program belongs to IBM and is a listener job that once connected, stays active until the connection is terminated. Therefore, it makes multiple calls (dynamic I presume) from the same job. It does not submit a new job for each call. Never implied that one module should affect another...I was simply trying to ask the question of why a procedure (within a module that is bound by copy into a *PGM object that does set on LR) persists any data at all? I should have been more specific.
Eric D. - yes, I think all of what you stated is accurate. Named activation group for all programs (*PGM objects) called from this job. However, some of your comments contradict those of Bob C's regarding the persistence of data. Does LR have no impact on global variables within an activation group...period, the end?
Steve R. - I don't believe this is an example of traditional or non-modular programming at all. All of the variables and files in question are declared in the procedure (or in the case of the f specs, at the 'module' level since we still can't declare them within the PI). So, apparently this fact alone makes file fields global to an activation group? This is the part that intrigues and confuses me.
So, are we saying that all input field values from files (accessed by chain, read, etc.) during program execution within an activation group are persistent to every procedure that is used by the program in question? If so, then what ever happened to the concept of local variables in procedures? Does this simply not apply to file input fields? Maybe that is why we still can't declare the file spec within the PI?
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2026 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.