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




I had an very similar problem a week or so ago with an OPNQRYF format file,
if the OPNQRY was called
multiple times I received CPF4205, the only way I managed to get around
this was to perform / replace the
RETURN/RETRN's with ENDPGM / SETON LR.

I know that there will be a peformance issue however it maybe worth
changing the programs to End, even if
it is just see if the problem is removed.






"Mike Silvers" <msilvers@HBS-INC.COM>@midrange.com on 25/05/2001 13:13:19

Please respond to RPG400-L@midrange.com

Sent by:  owner-rpg400-l@midrange.com


To:   "RPG400-L" <RPG400-L@midrange.com>
cc:
Subject:  Trigger Problem


All,

I have a trigger program on a file.  I have a few problems with the program
and locks on files.  Here is the situation.....  I have a trigger program
written in RPG that is attached to a file.  The trigger program looks at
the
value of a data area and, depending on the value of the data area, either
calls a program to do some work, or does not call the program.  The program
ends with a RETURN and does not use the default activation group.  The
second program is where the problem lies.  The second program updates and
reads some files.  When it completes, it returns without setting on LR.
This was done for performance, because the file accesses will be high in
number and there are other trigger programs from another consultant on this
file.  The intent of this process is that by changing the value of the data
area, we can isolate the program that does the work from the trigger calls.
We can then change the program, if needed.  Here is the problem:  if the
program that does the work is called one time, there is a lock placed on
the
program (in other words, the object is allocated).  If we turn off the data
area so the program that does the work is not called anymore, the lock
still
exists.  This is the problem.  Does anyone have any suggestions on how to
resolve the locking issue (other than having the users sign off -- that is
not an option)?

Thanks!

Mike

================================

Mike Silvers
AS/400 Senior Programmer/Analyst
AS/400 IBM Certified RPG IV Developer
AS/400 IBM Certified Solutions Expert
Hainey Business Systems
8 E. Canal St
Dover, PA 17315
Branch Office:  (410) 397-8739
Phone:  (800) 932-3380
Fax:  (717) 292-9474
Web: http://www.hbs-inc.com
________________________________
Providing E-Commerce, EDI, AS/400
Development and related services
nationwide.
================================

+---
| 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
+---

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.