These are the specifications about comp-3 and comp variables,might be it will help you
Sign is stored in comp-3 as:-It is stored in the last nibble. For example if your number is +100, it stores hex 0C in the last byte, hex 1C if
your number is 101, hex 2C if your number is 102, hex 1D if the number is -101, hex 2D if the number is -102
also it is a packed decimal format
S9(7) COMP-3 field occupy 4 bytes and . Sign is stored as hex value in the last nibble
S9(7) SIGN TRAILING SEPARATE will take 8 bytes (one extra for sign)
Joined: 22 Sep 2005 Posts: 104 Location: Concord, New Hampshire, USA.
Sign doesn't contribute to the size of the data name: s9(2)v9(3) usage display.For display purpose,edit characters can be used, -9(2)v9(3) usage display.Now your result must be -05000.