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
 

 

Issue about add COMP-3 with non-integer numeric data

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

New User


Joined: 09 Oct 2006
Posts: 36

PostPosted: Thu Sep 13, 2007 4:22 pm    Post subject: Issue about add COMP-3 with non-integer numeric data
Reply with quote

Hi All,
format is like:
Code:
A X(8)
B S(9)V9(3) USAGE IS DISPLAY
C S9(12)V9(3) USAGE IS COMP-3

I want move A to B and accumulate B with C, the results are to be stored in C.
confusing about this kind of operation...

Thanks,
Coria Xu
Back to top
View user's profile Send private message

CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 2150
Location: At my coffee table

PostPosted: Thu Sep 13, 2007 4:39 pm    Post subject:
Reply with quote

Would you like to reconsider the PIC for B?
Back to top
View user's profile Send private message
UmeySan

Active Member


Joined: 22 Aug 2006
Posts: 755
Location: Germany

PostPosted: Thu Sep 13, 2007 5:00 pm    Post subject:
Reply with quote

Hi !

Using PIC-X is a little bit dangerous for the afterwards computation.
So field A could be something like "123A9G"

Regards, Umeysan
Back to top
View user's profile Send private message
vasanthkumarhb

Active User


Joined: 06 Sep 2007
Posts: 276
Location: Bang,iflex

PostPosted: Wed Sep 26, 2007 1:15 pm    Post subject: Hi All.......
Reply with quote

Check and validate the variable A for numeric, if it is numeric move that variable in to working-storage variable, having pic 9(8), take thi variable and then move it to Variable B which is mentioned above. since its stored in numeric EBCIDIC format, we can use that variable for COMP or COMP-3 variables.

Let me knw more info from Cria..

Thanks,
Vasanth......... icon_smile.gif
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 Export flat file data into excel sheet murali.andaluri DFSORT/ICETOOL 2 Mon Mar 20, 2017 5:39 pm
No new posts Append data from two files into a sin... Praveen04 DFSORT/ICETOOL 5 Thu Mar 16, 2017 7:29 pm
No new posts SPUFI -- Joining 3 tables – data in... Sysaron DB2 2 Wed Mar 08, 2017 4:18 am
No new posts Overriding PS data in rexx Shaheen Shaik CLIST & REXX 8 Fri Mar 03, 2017 5:08 pm
No new posts JCL to get submitted once dataset has... vinu78 JCL & VSAM 17 Thu Feb 16, 2017 7:32 am


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