× 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 Mon, 1 Apr 2002, Wills, Mike N. (TC) wrote:
>
> I am looking at ways to make a program more dynamic. I have a program that
> will monitor outqs for spool files through a dataq and kick off a processing
> program.

What do you mean by "dynamic"?  (It doesn't sound like you're talking
about static calls vs. dynamic calls, since all calls to *PGM objects are
dynamic)

> The processing program then runs hard-coded processes based on the
> spool file information. Several processes could be the same or similar, but
> they could also be very different.

By "processes" are we talking about "routines"?  On Unix systems, a
"process" is (somewhat) similar to what we call "jobs" in OS/400.  So, I'm
not certain if you mean that you kick off a new job, or if you mean that
you run a different subroutine/subprocedure?

If you mean routine, couldn't you just call a different program to process
it?  Maybe you could design a PF that had fields containing the "attribute
to look for" or "string in the spooled file to search for" (or whatever
the criteria is) and also fields containing the program name to call?

Then, you read through the PF, and for each match, you run the appropriate
program?   Then, when you add some new criteria, it uses program name
field to figure out which program to call?

> So every time I need to add another spool file, I need to modify this
> program, recompile and test it. I would like to try and make this
> program more dynamic to eliminate this need. Can this be done either via
> RPG or Java?

Most likely, if it can be done at all, it can be done in RPG.  I still
have only the vaguest idea of what you're talking about, however.

>
> What this processing program does is set up the information I need to create
> the file name and path from the job and spool file information in the dataq
> for me to make different files that are either located on the IFS or an FTP
> server. I would prefer a RPG solution but would also do this in Java.

All it does is create a filename, and copy the spool file to the IFS?
Why would that require dynamic code?  Just build the filename from the
job/user/nbr/spoolnbr (using variables, of course) and then use Host Print
Transform or similar to transform it to a text file.

Or am I totally lost?



As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.