IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Bytes used by S9(09) COMP in Memory?


IBM Mainframe Forums -> COBOL Programming
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
hey_its_me
Warnings : 1

New User


Joined: 23 Aug 2006
Posts: 14
Location: USA

PostPosted: Mon Jan 01, 2007 3:56 pm
Reply with quote

hi all,

What is the is size of memory used by S9(09) COMP?
since the 9(09) comp uses 4 bytes of memory, is it the same with the case of S9(09) comp?


With regards,
Anil
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3156
Location: Tucson AZ

PostPosted: Mon Jan 01, 2007 4:22 pm
Reply with quote

Quote:
S9(5) through S9(9)
Binary full-word (4 bytes)
-2,147,483,648 through
+2,147,483,647
Since the sign bit is the single high bit in the high byte of the word, the length does not change.
Back to top
View user's profile Send private message
DavidatK

Active Member


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

PostPosted: Wed Jan 03, 2007 6:37 am
Reply with quote

Anil,

What Bill posted is correct, the memory used for S9(9) COMP and 9(9) COMP are the same, however the value you can store in the field does change.

For the 9(9) COMP (4 bytes unsigned) the values you can store are 0 through 4,294,967,295
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> COBOL Programming

 


Similar Topics
Topic Forum Replies
No new posts COBOL - Move S9(11)v9(7) COMP-3 to -(... COBOL Programming 5
No new posts Masking variable size field - min 10 ... DFSORT/ICETOOL 4
No new posts Converting ASCII values to COMP-3 (ZD... JCL & VSAM 2
No new posts Interviewers are surprised with my an... Mainframe Interview Questions 6
No new posts Cobol COMP-2 fields getting scrambled... Java & MQSeries 6
Search our Forums:

Back to Top