Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Problem with S9(18) Comp field

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

New User


Joined: 22 Nov 2007
Posts: 77
Location: noida

PostPosted: Fri Dec 07, 2012 11:23 am    Post subject: Problem with S9(18) Comp field
Reply with quote

I have defined a field with S9(18) Comp field in which data is stored as X'01B69B4BA630F34E' which in decimal has value 123,456,789,012,345,678 but when I am doing a edited display using edit pattern BZZZZ,ZZZ,ZZZ,ZZZ,ZZZ,ZZZ its truncating 2 rightmost bytes and displaying 1,234,567,890,123,456.

Am I doing something wrong here? Please help me in this.
Back to top
View user's profile Send private message

Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1542
Location: Andromeda Galaxy

PostPosted: Fri Dec 07, 2012 11:40 am    Post subject:
Reply with quote

Can you paste the code and its output using code tags??
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10326
Location: italy

PostPosted: Fri Dec 07, 2012 12:52 pm    Post subject: Reply to: Problem with S9(18) Comp field
Reply with quote

did You try with ARITH(EXTENDED) ?
when working with borderline values it is better to be safe than sorry
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7315

PostPosted: Fri Dec 07, 2012 1:27 pm    Post subject: Reply to: Problem with S9(18) Comp field
Reply with quote

enrico, it is even over the border.

abhay pratap singh,

You have specified 19 digit positions in your edited field. To do that you should compile with ARITH(EXTEND). However, if that was a mistake, chop the leading Z entirely or make it into a second B.
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 sort records based on length exceeds ... maxsubrat DFSORT/ICETOOL 7 Wed Oct 04, 2017 4:48 pm
No new posts Partial color change of a field in CI... waseem0424 CICS 5 Fri Sep 29, 2017 7:56 pm
No new posts LMINIT problem - not finding DDNAME Danielle.Filteau CLIST & REXX 7 Tue Sep 19, 2017 9:57 pm
No new posts Remove leading spaces from numeric field rexx77 SYNCSORT 6 Wed Sep 06, 2017 2:15 am
No new posts JES2 job size field matching Windows ... SRICOBSAS All Other Mainframe Topics 4 Tue Sep 05, 2017 5:49 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us