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 of COMP-3 fields

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

New User


Joined: 12 Jan 2007
Posts: 19
Location: Pune (India)

PostPosted: Thu Aug 06, 2009 11:25 am    Post subject: Movement of COMP-3 fields
Reply with quote

Hi,

I have two fields A and B, both are COMP-3 S9(17)

A is being moved to B.

Some Displays of A and B after the program execution

A=0000000000020920C
B=00000000000209203

A=0000000000000187M
B=0000000000000187M

A=0000000000000900}
B=0000000000000900}

The field is being used as an input in some other program which is giving the SOC7 error.

Please advice.
Back to top
View user's profile Send private message

dilipbiradar

New User


Joined: 12 Jan 2007
Posts: 19
Location: Pune (India)

PostPosted: Thu Aug 06, 2009 11:34 am    Post subject: Reply to: Movement of COMP-3 fields
Reply with quote

Beg your pardon........

The A field is PIC S9(17) only..not the COMP-3
Back to top
View user's profile Send private message
Binop B

Active User


Joined: 18 Jun 2009
Posts: 407
Location: Nashville, TN

PostPosted: Thu Aug 06, 2009 1:02 pm    Post subject:
Reply with quote

Hi Dilip,

As per you post, it looks like you are having a loop which is processing each record. Most probably one of these records might be having corrupt data for this field which is causing the SOC7 abend.
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2502
Location: Atlanta, Georgia, USA

PostPosted: Thu Aug 06, 2009 3:30 pm    Post subject: Reply to: Movement of COMP-3 fields
Reply with quote

The last position is the SIGN byte.

Please review the following Sticky -

http://ibmmainframes.com/viewtopic.php?t=40254

Bill
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Thu Aug 06, 2009 8:03 pm    Post subject:
Reply with quote

Hello,

In the program that does the "move", suggest you code an IF to check if the A value is numeric before doing the move. . .

A decision needs to be made on what action to take if the value is not numeric (abend the code, issue an error, etc).
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2502
Location: Atlanta, Georgia, USA

PostPosted: Thu Aug 06, 2009 8:24 pm    Post subject: Reply to: Movement of COMP-3 fields
Reply with quote

Adding to Dick's suggestion, if the field is display-numeric signed but the data has an 'F' zone in the last-byte, instead of a 'C' or a 'D', the numeric check will fail because the translate-table being used to validate the display-numeric signed-field doesn't consider an 'F' zone as a valid sign for a display-numeric signed-field.

This is also true vice-versa, if you had a 'C' or 'D' zone in the last-byte of an unsigned display-numeric field, the numeric test will fail as well, because the translate-table is expecting an 'F' zone in the last-byte.

Just my .02 cents....

Bill
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 DFSORT MUL FIELDS tspr52 DFSORT/ICETOOL 16 Fri Mar 03, 2017 11:53 pm
No new posts Sort two file having same field, one ... himanshu malik DFSORT/ICETOOL 7 Thu Feb 02, 2017 10:09 am
No new posts SYNCSORT SEQNUM and FI fields. nartcr SYNCSORT 7 Sat Jan 21, 2017 4:02 am
No new posts Syncsort Help to group fields sudhakarraju SYNCSORT 6 Thu Dec 29, 2016 1:38 am
No new posts Access SQLCA fields inside a stored p... gangapd DB2 6 Thu Oct 27, 2016 10:20 am


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