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
 

 

Movement from S9(09) COMP-3 to 9(10)

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

New User


Joined: 27 Dec 2005
Posts: 21
Location: Bangalore

PostPosted: Tue Jun 06, 2006 8:09 pm    Post subject: Movement from S9(09) COMP-3 to 9(10)
Reply with quote

Hi,
I am not able to move from S9(09) COMP-3 to 9(10) when the value of S9(09) COMP-3 = 1234567890, the digit "1" is getting truncated( the value is coming to 234567890) Please help.

Geeta
Back to top
View user's profile Send private message

calspach

New User


Joined: 05 May 2006
Posts: 32
Location: USA

PostPosted: Tue Jun 06, 2006 9:22 pm    Post subject:
Reply with quote

Your value is getting truncated in the s9(9) comp-3, not in the move. 1234567890 is ten digits, s9(9) comp-3 or otherwise can only hold 9 digits.
Back to top
View user's profile Send private message
chk_25

New User


Joined: 09 Jun 2006
Posts: 2
Location: India

PostPosted: Fri Jun 09, 2006 11:17 pm    Post subject: Hi!
Reply with quote

In S9(9) comp-3, the maximum data size it can hold is 5bytes( Here five digits). But u have stated that it will hold 9 digits.

plz clear my doubt.

CHETAN KUMAR
Back to top
View user's profile Send private message
calspach

New User


Joined: 05 May 2006
Posts: 32
Location: USA

PostPosted: Fri Jun 09, 2006 11:30 pm    Post subject:
Reply with quote

an S9(9) comp-3 data fields holds 9 digits of numerical data, and a sign. It does this by storing two digits per byte, with the least significant byte of data holding one digit and the sign of the entire data field.


Check here for a more detailed description of how comp-3 data items are stored.

http://www.discinterchange.com/TechTalk_Packed_fields_.html
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 Protection Exception while move 0 to ... Kevin Vaz CICS 10 Tue Oct 18, 2016 4:19 pm
No new posts How can we create a flat file in JAVA... rakesh.v18 Java & MQSeries 7 Fri Sep 23, 2016 10:46 pm
No new posts Need help to populate date in COMP-3 ... chetanambi DFSORT/ICETOOL 3 Tue Jun 21, 2016 12:25 pm
No new posts comparing comp-3 and unpacked numbers juares castro COBOL Programming 3 Mon May 30, 2016 6:46 pm
No new posts SIGNED DECIMAL TO COMP-3 using cobol ... ram_vizag COBOL Programming 1 Tue Mar 01, 2016 11:32 pm


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