Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

On size error and On Overflow error

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
srinathangya

New User


Joined: 19 Dec 2005
Posts: 77

PostPosted: Mon Jan 08, 2007 11:29 am    Post subject: On size error and On Overflow error
Reply with quote

Hi Guys,

Can anyone tell me the difference between ON SIZE ERROR and ON OVERFLOW error.
Are they used interchangeably in programs or they both r different.. Please let me know

Thnx in advance
Srinath.
Back to top
View user's profile Send private message

William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3158
Location: Tucson AZ

PostPosted: Mon Jan 08, 2007 11:54 am    Post subject: Re: On size error and On Overflow error
Reply with quote

Hi Srinath,
srinathangya wrote:
Can anyone tell me the difference between ON SIZE ERROR and ON OVERFLOW error.
Are they used interchangeably in programs or they both r different.. Please let me know
I don't use either very often so I went to the Language Reference to double check and the index told the tale:
ON EXCEPTION phrase
.. CALL statement 264
.. on INVOKE statement 312
ON OVERFLOW phrase
.. CALL statement 265
.. DISPLAY statement 279
.. STRING statement 380, 389
ON phrase, SET statement 364
ON SIZE ERROR phrase
.. ADD statement 257
.. arithmetic statements 240
.. COMPUTE statement 272
.. DIVIDE statement 282
.. MULTIPLY statement 326
.. SUBTRACT statement 384, 385

Hope that helps,

Bill
Back to top
View user's profile Send private message
srinathangya

New User


Joined: 19 Dec 2005
Posts: 77

PostPosted: Tue Jan 09, 2007 3:42 pm    Post subject:
Reply with quote

Thompson,

I didnt get anything from what you sent. Pls. dont mistake me. What is that you thought of saying? Could you be bit more clear.
Are you asking me to refer to Language reference Manual??

Anyway thanx for responding

Reg,
Srinath.
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3158
Location: Tucson AZ

PostPosted: Tue Jan 09, 2007 6:07 pm    Post subject:
Reply with quote

Srinath,

You want to understand the difference between the two phrases. And then you ask:
Quote:
Are you asking me to refer to Language reference Manual??
as if it were a bad thing.

I posted:
Quote:
ON EXCEPTION phrase
.. CALL statement 264
.. on INVOKE statement 312
ON OVERFLOW phrase
.. CALL statement 265
.. DISPLAY statement 279
.. STRING statement 380, 389
ON phrase, SET statement 364
ON SIZE ERROR phrase
.. ADD statement 257
.. arithmetic statements 240
.. COMPUTE statement 272
.. DIVIDE statement 282
.. MULTIPLY statement 326
.. SUBTRACT statement 384, 385
explaining that this is from the index of the language reference.

I had thought that you would look at this and see that if you wanted to look up info on "ON SIZE ERROR" you would have to decide which aspect of "ON SIZE ERROR" you needed to look at, which arithmetic type statement you needed. Similarly, I had thought that you would look at this and see that if you wanted to look up info on "ON OVERFLOW" you would have to decide which aspect of "ON OVERFLOW" you needed to look at, the CALL, the DISPLAY or the STRING.

Well I guess I'll just have to be disappointed that you "didn?t get anything" from what I sent. But what is really crushing is the idea that you hadn't yet even looked at a manual and the further feeling that to do so was beneath you.

With the attitude you are projecting, I wish you luck in your future, (but to myself I pray I never have to maintain any of your code icon_eek.gif ),

Bill

BTW, if needed I can repost this and highlight the arithmetic stataments and the verbs CALL, DISPLAY and STRING..... icon_cry.gif
Back to top
View user's profile Send private message
RamsIBM

New User


Joined: 08 Jan 2007
Posts: 53
Location: Chennai

PostPosted: Tue Jan 09, 2007 7:14 pm    Post subject:
Reply with quote

Hi,

As per my knowledge.


On Size error used in Arithemetic operation.
i.e ADD A TO B ON SIZE ERROR
........
if the result is larger than B declartion then statement under the on size error will be fired...


Overflow :

This used in subprogram as well as String operation


i.e CALL A on OverFlow
......

if A is not found then statment under the OverFlow will be fired


Simillarly it will be used in String operation also ( i.e STRING & UNSTRING)

From my example you can understand the difference between those...

Correct me if I am wrong

Thanks
Rams
Back to top
View user's profile Send private message
csiva007

New User


Joined: 29 Sep 2005
Posts: 10

PostPosted: Tue Jan 16, 2007 2:00 pm    Post subject:
Reply with quote

Hi Srinath,

What Rams told is correct?



Regards
Siva
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts OO COBOL compile error Virendra Shambharkar COBOL Programming 3 Tue Jan 10, 2017 6:05 pm
No new posts ESQA overflow - high ECSA utilization vasanthz All Other Mainframe Topics 1 Thu Dec 29, 2016 7:06 am
No new posts S922 Error yuvan ABENDS & Debugging 3 Fri Dec 02, 2016 6:58 pm
No new posts Invoke Webservice Fails with DFHPI100... divated CICS 2 Thu Nov 24, 2016 5:57 pm
No new posts Error during restore rename archanamuthukrishnan All Other Mainframe Topics 2 Fri Oct 14, 2016 3:30 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us