MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

PL1- Not able to display FIXED DEC (7,2)

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming
View previous topic :: View next topic  
Author Message
biswadeep_hota
Beginner


Joined: 09 Jan 2005
Posts: 2
Topics: 2

PostPosted: Sun Jan 09, 2005 6:00 am    Post subject: PL1- Not able to display FIXED DEC (7,2) Reply with quote

I have a variable 'A' havinf PIC clause: FIXED DEC (7,2)
The value stored is 93.74

When I move it to a variable PIC'(05)9.99' it shows a value of 00000.93

When I move it to a variable PIC'(05)9V99' It displays 0009374

I want 00093.74 to be displayed..

Its in PL1

Ne help guyzzzzzz 8)

Deep
Back to top
View user's profile Send private message
bauer
Intermediate


Joined: 10 Oct 2003
Posts: 315
Topics: 49
Location: Germany

PostPosted: Mon Jan 10, 2005 3:19 am    Post subject: Reply with quote

Hi,

specify PIC like sample below or use CHAR builtin function.


TEST: PROC OPTIONS (MAIN) REORDER ;

DCL X DEC FIXED(7,2) AUTO INIT(93.74) ;

DCL Y PIC '(5)9V.99' ;

Y = X ;

PUT SKIP EDIT(CHAR(X))(A);

PUT SKIP EDIT(Y)(A);

END;
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group