× 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 *MODULE is part of a *PGM, using CRTPGM.

-----Original Message-----
From: Charles Wilt [mailto:charles.wilt@xxxxxxxxx]
Sent: Wednesday, September 05, 2018 1:20 PM
To: RPG programming on the AS400 / iSeries <rpg400-l@xxxxxxxxxxxx>
Subject: Re: Record lock, no retry?

Jon,

Justin said the failing code was in a *MODULE, so I'm assuming this is a sub-procedure in a *SRVPGM...

Without error handling in the procedure or it's calling *PGM, wouldn't the error get percolated up as a "The call to &1 ended in error." rather than the original "record lock".

From your own RPG Exception handling Redpaper...
- All exception/error handling has been removed and the processing logic has been placed in two subprocedures, ProgramProc and FileProc.
- The divide by zero error has been reintroduced.

When you run this program you might expect it to fail with the RNQ0102 Attempt to divide by zero message at (3) above, but it doesn’t! Instead, the program fails with a RNQ0202 The call to PROGRAMPRO ended in error (C G D F) message at (2) above. You see the following information in the joblog:

Attempt made to divide by zero for fixed point operation.
Function check. MCH1211 unmonitored by ERROR10 at statement 0000002100, instruction X'0000'.
The call to PROGRAMPRO ended in error (C G D F).

Charles


As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.