For Programmers: Free Programming Magazines  


Home > Archive > Cobol > May 2007 > Re: Question on Cobol Move statement - mixed move x to zzz9.









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: Question on Cobol Move statement - mixed move x to zzz9.
Clark F Morris

2007-05-22, 9:55 pm

On 22 May 2007 11:59:07 -0700, Alistair
<alistair@ld50macca.demon.co.uk> wrote:

>On 22 May, 03:41, Clark F Morris <cfmpub...@ns.sympatico.ca> wrote:
>
>No PACK involved. The move was a simple move. If EBCDIC then
>X'F3404040' would result in an S0C7 (I presume) unless only the low-
>order nibbles are moved for each character and the X'F' nibble put in
>to all high order positions ie X'F3404040' becomes X'F3F0F0F0'. My
>money says that as there was no reported abend then it isn't IBM
>hardware.


The original posting stated that when the sending field contained 0003
the receiving field became space space space 3. The Language
Reference Manual states that a PIC X(4) sending field is treated as if
it is PIC 9(4) when the receiving field is numeric edited thus
conforming to what the original poster stated was happening. This
implies
MVC TEMPEDIT,EDITMASK
PACK TEMP,WS-PROP-PREMISE
ED TEMPEDIT,TEMP
MVC WS-FORMAT-4,TEMPEDIT+1.
on an IBM z series (or predecessor). Thus TEMP would become
x'030004' when WS-PROP-PREMISE is packed and since the edit mask would
not contain a sign position based on the picture, the sign position is
probably not used and thus the data exception would not be raised.
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com