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
 

 

Problem in edited pictures

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

New User


Joined: 22 Aug 2005
Posts: 7
Location: India

PostPosted: Fri Sep 16, 2005 10:26 am    Post subject: Problem in edited pictures
Reply with quote

Dear Friends,
I faced a small problem in my code in COBOL.
I read a variable (PIC 9(03)V99) from a file record. In file, the value for this variable is 00450. Now, i wish to print this value in a report with a decimal point shown.

So, I moved this variable to another display variable with declaration
9(03).99

Now, I was expecting that, in the report, it should show the value as 004.50

But after execution, the value was getting printed as 000.04

If I change my variable declaration (in the copybook of the input file) as
9(05), instead of 9(03)V99, then the value is getting correctly displayed as 004.50

Could anybody please expalin why this is happening? As per my knowledge, moving of 9(03)V99 to 9(03).99 should work straight away and should diaplay the correct output. I dont understand why it is failing in this particular case.

thanks,
Sonali.
Back to top
View user's profile Send private message

Ravi gaur

New User


Joined: 12 Jul 2005
Posts: 38

PostPosted: Mon Sep 19, 2005 12:09 pm    Post subject: Re: Problem in edited pictures
Reply with quote

Use pic 9(3). 9(2)


believe would be eridicate with problem..


Let me know if u have any query.
Back to top
View user's profile Send private message
ritakaur

New User


Joined: 19 Sep 2005
Posts: 13
Location: Belgaum

PostPosted: Mon Sep 19, 2005 1:50 pm    Post subject: Re: Problem in edited pictures
Reply with quote

yes.Using pic 9(3). 9(2) will be correct.

bye
rita
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 SYMNAMES problem jacobdng DFSORT/ICETOOL 7 Thu Dec 22, 2016 7:47 am
No new posts Problem in writing Output file vickey_dw COBOL Programming 5 Mon Nov 14, 2016 11:14 pm
No new posts Problem in Running Query via JCL vickey_dw DB2 3 Tue Oct 18, 2016 11:11 pm
No new posts DB2 Streaming Batch Processing Problem Manshadi DB2 4 Sat Sep 24, 2016 12:14 pm
No new posts Problem with GETMAIN command amitc23 CICS 6 Thu Sep 01, 2016 1:01 pm


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