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
 

 

Decimal Data error on first login only

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

New User


Joined: 03 Jul 2008
Posts: 2
Location: India

PostPosted: Thu Jul 03, 2008 10:47 am    Post subject: Decimal Data error on first login only
Reply with quote

Hi all..

I am faced a very wierd problem today, it goes like this -

When I logon to the AS400 server and try executing a program, it crashed for the first time giving a decimal data erro on certain line of code, but the same program with same set of libraries and all gives no error whatsoever if I execut it again instantly after I received the error first time.

The next time I logged on first thing i did is keep the program in debug and execute it, the decimal data error comes on a MOVE statemet for which the values of variables on the line of code in picture are already valid but I can't figure out why is it happening.

Is it because of some system variable intialization or something else?

Please help me out on this issue.

I thank you in advance.
Back to top
View user's profile Send private message

dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Thu Jul 03, 2008 7:13 pm    Post subject:
Reply with quote

Hello ram and welcome to the forums,

Quote:
Is it because of some system variable intialization or something else?
I'd suggest you make sure that all of the variables in your code are initialized to some valid value.

If you code uses any "common" definitions, make sure your definition exactly matches the original.

It may be that the first time thru, your code moves a proper value to the problem field after the problem has been raised and then the next time thru the code, there is no error.
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2502
Location: Atlanta, Georgia, USA

PostPosted: Thu Jul 03, 2008 8:38 pm    Post subject: Re: Decimal Data error on first login
Reply with quote

Long ago and far away, IBM devised SAA, which (as the idea went) allowed programs to be used on multiple platforms.

One of the idiosecrencies was that Cobol COMP on a MAINFRAME is interpreted as COMP-3 on an AS400.

Hence, this is the reason SAA (System Application Architecture) pushed the use of BINARY (instead of COMP) and PACKED-DECIMAL (instead of COMP-3) for program portability compliance.

Could your decimal error have anything to do with programs which were ported?

Just a SWAG.... icon_wink.gif

Regards,

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

New User


Joined: 03 Jul 2008
Posts: 2
Location: India

PostPosted: Tue Jul 08, 2008 10:30 am    Post subject: Re: Decimal Data error on first login
Reply with quote

Hey guys... thanks for the tips.

I spotted the problem. dick scherrer you were right, I had a file with garbage values and was copying it into a QTEMP file and using the temporary file data for first time. the next time I did not have such error because I did clear the file and wrote new records into it...

thanks again you guys.. you have a good time..
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Tue Jul 08, 2008 12:53 pm    Post subject: Reply to: Decimal Data error on first login only
Reply with quote

You're welcome - thank you for letting us know it is now working icon_smile.gif

d
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 Export flat file data into excel sheet murali.andaluri DFSORT/ICETOOL 2 Mon Mar 20, 2017 5:39 pm
No new posts Need help with below DB2 error ashek15 DB2 3 Sat Mar 18, 2017 5:56 am
No new posts Append data from two files into a sin... Praveen04 DFSORT/ICETOOL 5 Thu Mar 16, 2017 7:29 pm
No new posts FINDREP Syntax Error seahawk789 DFSORT/ICETOOL 4 Thu Mar 09, 2017 10:11 pm
No new posts INVOKE WEBSERVICE error danik56 CICS 11 Thu Mar 09, 2017 11:52 am


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