× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



On 26 March 2010 09:42, Dennis Lovelady <iseries@xxxxxxxxxxxx> wrote:
I was shocked to see that, at V5R3 there is no Retrieve
Program References API that I can find.  I do know about
DSPPGMREF to an output file, and all that, but this surprises
me.


Dennis, I didn't know about this API. What advantages are there in
using it over DSPPGMREF?

I've grown accustomed to the List ... APIs, I guess.  This case shows an API
advantage, I think.  Remember I want to find all the things impacted by
altering this program.  Since a program can reference other programs I will
need DSPPGMREF output from those programs as well.  So here's a vision:

Display Program References to an output file.  Now in RPG open that output
file, begin reading.  Ack, my first record refers to PROGRAMB, so I need its
references.  I (probably) cannot DSPPGMREF to the file I've opened, so I'll
need to go to an alternate.  OK, can handle that.  But when I'm processing
the alternate file, I see that there's a reference to PROGRAMC.  Et cetera.

With recursion and APIs, this would all be SOP.  But it gets complex with
DSPPGMREF.

Dennis

As long as the *OUTFILE you use is closed before running the DSPPGMREF
there's no problem in putting everything into the one file. I do this
in a couple of my utilities (CHKLVLCHK & DBG/400 -
http://www.dbg400.net/foswiki/bin/view/DBG400/RpgleDBG108R4 is the
routine for the latter).

Regards, Martin

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

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

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