if the programs run in different jobs there's no way to communicate
via LDA. each job has it's own LDA.

I never said they DID run in different jobs; one whole reason for using
the LDA is so that different jobs can't interfere with each other. What I said was that neither calls the other.

Here is the scenario (I just yelled at somebody for being unnecessarily
obtuse with a question, and now I'm guilty of the same offense):

We have a standardized program with exit hooks in it, for
installation-specific actions. There is one exit hook for before the
program processes a user request, and another for after it processes the
user request.

In this particular installation, for a very specific type of request,
the "before" exit program needs data from the same job's immediately
previous call to the "after" exit program. And meanwhile, there could be
any arbitrary number of other jobs running the same application.

The obvious place to pass that data is the *LDA, since it doesn't have
to be created, and each job has its own. But the ILE RPG manual doesn't have any examples specific to the LDA, and it has this paragraph in the section on the IN statement:

Factor 1 must be blank when factor 2 contains the name of the local
data area or the Program Initialization Parameters (PIP) data area.

and this in the section on the OUT statement:

The data area must have been locked previously by a *LOCK IN
statement or it must have been specified as a data area data structure by a U in position 23 of the definition specifications.
(The RPG IV language implicitly retrieves and locks data area data structures at program initialization.)

So if you can't *LOCK an explicit IN from the *LDA, then how do you explicitly OUT to the *LDA?


This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2019 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].