I really hate the never ending job, or the job that starts every x
minutes, to do this stuff. Some of these I've seen to be real I/O hogs.
Granted, if done right they do not need to be. But, having rewritten some
Stick with the trigger that is what it is there for.
Study the parameters to a trigger program very carefully. You can do this
without adding one single I/O. In the parameters is a 'before' buffer and
an 'after' buffer. You can take that one column and change it right there
in the trigger by setting the after buffer. Possibly the only file
declaration you'll need is not a file spec, but the file only to appear to
define an external data structure to define the before and after buffers.
If you want to, you can log audits of what you changed. In that log you
can put the name of the program, user, job, whatever. They're all
parameters to the trigger program.
To modify that buffer you'll also need ALWREPCHG.
As an Amazon Associate we earn from qualifying purchases.
This thread ...
Re: Update a field in a file from the trigger on the same file, (continued)
This mailing list archive is Copyright 1997-2021 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
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.