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
 

 

Putting zeros in decimal field

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
vyasricha

New User


Joined: 17 Mar 2008
Posts: 27
Location: banaglore

PostPosted: Mon Aug 29, 2011 4:03 pm    Post subject: Putting zeros in decimal field
Reply with quote

Hi ,
I want to hard cord a decimal value through JCL,i am using the below card:

SORT FIELDS=COPY
OUTFIL OUTREC=(1,281,X'000000000000000C',X'000000000000000C',
X'000000000000000C')

282 - 289 , 8 bytes ,S9(13)V99
290-297 , 8 bytes ,S9(13)V99
298-305 , 8 bytes ,S9(13)VA99

but if i am using the above sysin it is giving 0 at 282,290,298 position but i want 0.00 , 0.00,0.00 .
i tried using edit

OUTFIL OUTROCK=(1,281,X'000000000000000C',8,PD,
EDIT=(STTTTTT.TT),SIGNS=(+,-,,),
but i am getting syntax error . please suggest !
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10211
Location: italy

PostPosted: Mon Aug 29, 2011 4:16 pm    Post subject: Reply to: Putting zeros in decimal field
Reply with quote

Quote:
S9(13)V99


according to the picture the decimal separator is virtual
so You have no reason to complain
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7255

PostPosted: Mon Aug 29, 2011 4:25 pm    Post subject: Reply to: Putting zeros in decimal field
Reply with quote

As enrico says, your V (and I'm assuming the VA is a typo, A is an alphabetic character) is an implied decimal place only.

Packed-decimals cannot contain actual decimal points, commas, currency symbols or anything. If you put them in, you'll get S0C7 when you use the fields.
Back to top
View user's profile Send private message
vyasricha

New User


Joined: 17 Mar 2008
Posts: 27
Location: banaglore

PostPosted: Mon Aug 29, 2011 5:05 pm    Post subject: Reply to: Putting zeros in decimal field
Reply with quote

Ok , thanks for the help !
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: Mon Aug 29, 2011 10:16 pm    Post subject:
Reply with quote

Hello,

So, how have you chosen to implement?
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts INVALID FIELD OR CONSTANT IN SORTOF ?? Ron Klop DFSORT/ICETOOL 8 Wed Jan 11, 2017 3:44 pm
No new posts Performing arithmetic on input field zh_lad DFSORT/ICETOOL 31 Tue Dec 06, 2016 8:04 pm
No new posts Add PD field from 2nd file to PD in 1st Sushant Garje DFSORT/ICETOOL 6 Thu Dec 01, 2016 4:32 pm
No new posts How to split the records using the am... vnktrrd DFSORT/ICETOOL 24 Fri Oct 28, 2016 7:33 pm
No new posts Comparing Decimal and CHAR columns rakesh17684 DB2 7 Thu Oct 20, 2016 2:33 am


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