× 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: Eval Exception Error Trapping
  • From: Joe Giusto <JGiusto@xxxxxxxxxxxx>
  • Date: Fri, 23 Jul 1999 06:32:40 -0400

I'll have to look into that.  I've never used before.  I guess it's time to
learn it.

Thank you,

Joe Giusto II
Patuxent Publishing Company
 <mailto:jgiusto@patuxent.com> mailto:JGiusto@patuxent.com
http://www.lifegoeson.com <http://lifegoeson.com> 


-----Original Message-----
From:   Dave Mahadevan [SMTP:mahadevan@fuse.net]
Sent:   Thursday, July 22, 1999 10:18 PM
To:     RPG400-L@midrange.com
Subject:        Re: Eval Exception Error Trapping

Joe:

Have you investigated the *PSSR internal subroutine?  When an error occurs
(most
of the time), control will transfer to this routine, you can do what you
want
inside the routine (like escape, bypass, return etc.).

Joe Giusto wrote:

> I recently got an error on the EVAL statement "The target for a numeric
> operation is too small to hold the result (C G D F)."
>
> I know what the problem is and have corrected it by increasing the field
> size.  Luckily I was available when the error occurred and was able to
> re-run the procedure.
>
> My question is:  Is there any way to trap for this error in the RPG
program?
> I have read in the manuals that the exception error will occur when the
> result is too big to fit into the variable. But no where did I find
anything
> telling me how to test for the error so that I could do some other
> processing and the program will not bomb in production.  In this case, it
> was a percentage of change calculation and I would put something on the
> report to indicate that the calculation could not be made.  The only idea
I
> can think of would be to use a very large working variable for all my EVAL
> statements and then test the work field for > the largest value that would
> fit in the field that I really want to use (like on the report).
>
> There has to be a better way.  Any suggestions would be appreciated.
>
> Thank you,
>
> Joe Giusto II
> Patuxent Publishing Company
>  <mailto:jgiusto@patuxent.com> mailto:JGiusto@patuxent.com
> http://www.lifegoeson.com <http://lifegoeson.com>
>
> * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
> * This is the RPG/400 Discussion Mailing List!  To submit a new         *
> * message, send your mail to "RPG400-L@midrange.com".  To unsubscribe   *
> * from this list send email to MAJORDOMO@midrange.com and specify       *
> * 'unsubscribe RPG400-L' in the body of your message.  Questions should *
> * be directed to the list owner / operator: david@midrange.com          *
> * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

--
Thank You.

Regards

Dave Mahadevan.. mailto:mahadevan@fuse.net


* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* This is the RPG/400 Discussion Mailing List!  To submit a new         *
* message, send your mail to "RPG400-L@midrange.com".  To unsubscribe   *
* from this list send email to MAJORDOMO@midrange.com and specify       *
* 'unsubscribe RPG400-L' in the body of your message.  Questions should *
* be directed to the list owner / operator: david@midrange.com          *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* This is the RPG/400 Discussion Mailing List!  To submit a new         *
* message, send your mail to "RPG400-L@midrange.com".  To unsubscribe   *
* from this list send email to MAJORDOMO@midrange.com and specify       *
* 'unsubscribe RPG400-L' in the body of your message.  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.