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


  • Subject: RE: FTP Question, Urgent
  • From: NSmith@xxxxxxxxxxx
  • Date: Tue, 10 Apr 2001 16:42:31 -0400

I've found it much easier to manage triggers if you use the same program on
all six slots and let the logic internal to the program determine if it is
an insert, update, etc.  Also, much easier to maintain if the actual trigger
program is nothing but a shell that calls other programs or procedures to do
the actual work.  You add the shell program once and never touch it again.
This avoids all the hassle of file locks.

> -----Original Message-----
> From: Jim Langston [SMTP:jimlangston@conexfreight.com]
> Sent: Tuesday, April 10, 2001 11:32 AM
> To:   RPG400-L@midrange.com
> Subject:      Re: FTP Question, Urgent
> 
> Very good point, Scott, but it was intended.  This trigger is actually
> set on *INSERT and *CHANGE, and this one line will work for either case:
> 
> C                   If        (CRComp = 51) And (CRCtrN <> *Blanks) And 
> C                             (Or_CRCtrN <> CRCtrN)    
> 
> but it works in my situation because of the way I am using it.  I did some
> testing, and on an *insert the fields in the original buffer are *blanks.
> And since I want to add the record if it is a new record, or the container
> number has changed, it works for me.  In either case the container number
> will be different.
> 
> I actually had to go look at the program again to see where I was using
> the
> original buffer and why.
> 
> Although, I am using an undocumented "feature" of a trigger, that
> currently
> the original record on an insert trigger will contain *Blanks.  I guess to
> make sure this works with all future versions, I should do something like:
> 
> C                   If        (CRComp = 51) And (CRCtrN <> *Blanks) And 
> C                             ((Or_CRCtrN <> CRCtrN) Or NOT Insert)
> 
> which would make it work regardless of what happens to the original
> buffer in the future.
> 
> This was a modification I had made to the program different, when I found
> out my users were changing information I thought they wouldn't and
> couldn't
> (container number).  I'll update the program comments right now on my
> system.
> 
> Regards,
> 
> Jim Langston
> 
> 
> Scott Mildenberger wrote:
> > 
> > Jim,
> > 
> > Be careful with this trigger program!  You mentioned this is an *insert
> > trigger but you are referencing part of the 'old' buffer (field
> Or_CRCtrN
> > below) which is undefined for an *insert trigger.  Likewise, you should
> > never reference the 'new' buffer on a *delete.
> > 
> > Scott Mildenberger
> > 
> > > -----Original Message-----
> > > From: Jim Langston [mailto:jimlangston@conexfreight.com]
> > > Sent: Monday, April 09, 2001 4:06 PM
> > > To: RPG400-L@midrange.com
> > > Subject: Re: FTP Question, Urgent
> > >
> > >
> > > Here is a working version I have of an *insert trigger that
> > > writes a record to an external data queue.
> > >
> > > C                   If        (CRComp = 51) And (CRCtrN <>
> > > *Blanks) And
> > > C                             (Or_CRCtrN <> CRCtrN)
> > >
> > +---
> > | This is the RPG/400 Mailing List!
> > | To submit a new message, send your mail to RPG400-L@midrange.com.
> > | To subscribe to this list send email to RPG400-L-SUB@midrange.com.
> > | To unsubscribe from this list send email to
> RPG400-L-UNSUB@midrange.com.
> > | Questions should be directed to the list owner/operator:
> david@midrange.com
> > +---
> +---
> | This is the RPG/400 Mailing List!
> | To submit a new message, send your mail to RPG400-L@midrange.com.
> | To subscribe to this list send email to RPG400-L-SUB@midrange.com.
> | To unsubscribe from this list send email to RPG400-L-UNSUB@midrange.com.
> | Questions should be directed to the list owner/operator:
> david@midrange.com
> +---


************************************************************************************************************************************************************************************************************
This message originates from Lincare Holdings Inc. It contains information 
which maybe confidential or privileged and is intended only for the individual 
or entity named above.
It is prohibited for anyone else to disclose, copy, distribute or use the 
contents of this message. 
All personal messages express views solely of the sender, which are not to be 
attributed to Lincare Holdings Inc., and may not be copied or distributed 
without this disclaimer. 
If you received this message in error, please notify us immediately at 
MailAdmin@lincare.com or (800) 284-2006.
************************************************************************************************************************************************************************************************************
+---
| This is the RPG/400 Mailing List!
| To submit a new message, send your mail to RPG400-L@midrange.com.
| To subscribe to this list send email to RPG400-L-SUB@midrange.com.
| To unsubscribe from this list send email to RPG400-L-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator: david@midrange.com
+---

As an Amazon Associate we earn from qualifying purchases.

This thread ...


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.