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
 

 

Is a negative numeric value displayed with a "J"

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

New User


Joined: 19 Sep 2006
Posts: 1
Location: Syracuse, NY

PostPosted: Tue Sep 19, 2006 8:23 pm    Post subject: Is a negative numeric value displayed with a "J"
Reply with quote

Is a negative numeric value displayed with a "J" at the right hand side of the value?
Back to top
View user's profile Send private message

DavidatK

Active Member


Joined: 22 Nov 2005
Posts: 700
Location: Troy, Michigan USA

PostPosted: Tue Sep 19, 2006 10:27 pm    Post subject: Re: Numeric Value
Reply with quote

ravneet,

Yes, and No.

The 'J' represents a '1' with the sign being negative. Take a look at the code below. a 'J' is a hex 'D1', 'K' = hex 'D2' etc. A 'D' in the hex number represents a negative sign, a 'C' a positive sign and a 'F' unsigned (default positive). So, a S9(4), or S9(4) COMP-3 value of -1234 will be displayed as '123M' or hex 'F1F2F3D4'. A value of +1234 will be displayed as '123D' or hex 'F1F2F3C4'

Code:

JKLMNOPQR {ABCDEFGHI 0123456789
DDDDDDDDD4CCCCCCCCCC4FFFFFFFFFF
1234567890012345678900123456789


Dave
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 numeric field. Alks SYNCSORT 2 Wed Oct 19, 2016 10:14 pm
No new posts Amount field is getting corrupted whe... thesumitk SYNCSORT 5 Tue Oct 18, 2016 8:20 pm
No new posts hot to get details when "EXEC CI... Andi1982 CICS 11 Tue Sep 20, 2016 5:01 pm
No new posts Multi row fetch - "for read only... Nileshkul DB2 3 Sun Aug 14, 2016 12:52 am
No new posts "DFSRRC00 vs IKJEFT01" for ... arunsoods All Other Mainframe Topics 5 Fri Aug 12, 2016 9:54 pm


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