× 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.



But you're forgetting the whole point of a trigger!

Ok, now for a little history...

Back in the dark ages one would have the Never Ending Program (NEP) that
would occasional query the database for changes. If it found any, it would
perform the actions you are talking about. I have a coworker who
installed one of these in the last year or two despite my STRONG
encouragement to use a trigger.

Then they came up with triggers. Why do you insist on querying the
database for changes? The G..D... trigger has the changes in it. You do
not need to restore a before and after image someplace to see what was
changed. They are passed as parameters to the trigger. Please see the
two data structures NEW and OLD in the sample I posted.

In your technique if someone updates three PO's you are going to query the
whole stinking database 3 times looking for any changes. However, if you
use a trigger you would already know which particular PO got updated
during the trigger by looking at the fields in the datastructure NEW. If
you wanted to know if the PO status field changed you could compare
NEW.PSTAT against OLD.PSTAT (we're running BPCSCD also).


Rob Berendt

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.