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



The trigger program doesn't have an F-Spec for the file, but I do call
another program to insert the record.

The Dataq solution might work, but the shop floor device can't write to data
queues. I would have to use the trigger to receive the record, write the
entry to the dataqueue, another program would have to be running to receive
the dataq entry, and write the record back to the physical file.

I think I might be able to use an update trigger to change the record, then
the shop floor device would just receive the same record# back.

Thanks, Jack.

-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Booth Martin
Sent: Monday, March 25, 2013 3:41 PM
To: Midrange Systems Technical Discussion
Subject: Re: PF Trigger question

A couple of thoughts:

- Perhaps the issue is that the trigger program should not have an F-spec
for the file?
- A *BEFORE trigger allow you do update the field in the record before it is
actually inserted into the file.

Trigger programs are handy, but is listening for a dataqueue the better
solution to this problem?



On 3/25/2013 2:26 PM, Jack Tucky wrote:
I'm working on a project where a shop floor device will use FTP to insert
a
record into a PF file. The plan is to use a trigger to process the
incoming
record, but the specs also call for the trigger to write a result record
into the same file.



For instance, the shop floor device might put a record in the file that
says
"SERIAL#=12345678', then I need to write a result record, either
'SERIAL#=12345678 not found' or 'SERIAL#=12345678,PCS=100', or several
other
replies



The trigger will fire again when we write the record. I've tried setting
the trigger to *DISABLED before I write my result record, but I'm still
getting RNX8888, RPG program TRIGGER was called recursively.



I'm not sure that the shop floor device could receive the result
transactions in a different file. Is there a way for the trigger to
ignore
certain events?



Thanks, Jack





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.