One thing to keep in mind with regard to trigger programs is all
processing must be complete before the next record of the triggered file
is changed. So, I would suggest that you keep your trigger program as
simple as possible.
With regard to the Deleted record question, I believe the image of the
original data is in the Old Record. By definition the new record image
would be null.
As for commit(Run Commit), I've never used commitment control with
regard to a trigger but if the files in question are input only I would
think you wouldn't care about including them in a commit group.
Hope this helps
Bill Erhardt
-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx
[mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of
sjones@xxxxxxxxxxxxxx
Sent: Wednesday, June 29, 2011 9:22 AM
To: rpg400-l@xxxxxxxxxxxx
Subject: Trigger program
I posted this on Midrange-L yesterday, but have not had a response so
thought I may get more from this side of things.
We have used the trigger program below to do some very simple trigger
stuff. Now I need to make it a bit more complicated & have some
questions
before I screw it up. I have one ancillary file in the program currently
& I now need to have a few more. Do I define the other files with the
Commit(RunCommit)? They will only be used for input if that makes any
difference. I also need to track deletes, so will the information on the
record being deleted be stored in the ORrecord or the NWrecord?
Thanks in advance.
http://archive.midrange.com/midrange-l/201105/msg00276.html
Steve Jones
As an Amazon Associate we earn from qualifying purchases.