Re: Packed Fields



Pete,
It is difficult to answer your question with the information you
provide. COBOL supports several different formats for numeric data, as
do most languages. There is zoned decimal (same as display, except the
last digit can contain a sign), packed decimal, where each half-byte
contains a decimal digit, with a sign in the last half byte (nibble),
and various binary formats including 16, 32 and 64-bit integers, and two
different floating point formats. If you could post some before and
after data, we could possibly give you a more definite answer.

John Clogg

-----Original Message-----
From: HP-3000 Systems Discussion [mailto:HP3000-L@xxxxxxxxxxxxx] On
Behalf Of Peter Osborne
Sent: Friday, November 25, 2005 11:03 AM
To: HP3000-L@xxxxxxxxxxxxx
Subject: Packed Fields

Hi All,

I'm looking at a field in a dataset. It's an X40 field but it seems that
the
data stored in it is server integers "packed" by a Cobol program. I've
used
the program to change the values that are stored in this field and the
data
is indeed changing but I cannot figure out how the data is actually
stored.
Is there a formula on how one would unpack a field that has been packed
by a
Cobol program?

Thanks,
Pete

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

.



Relevant Pages

  • Re: Micro Focus - "new" Releases
    ... On Jul 26, 2:20 am, "Pete Dashwood" ... true in terms of workstation COBOL, but that is a declining market anyway. ... fragile market and they both seem intent on eroding support from the ... Some companys come to me and say that the must pay ober 15 Million? ...
    (comp.lang.cobol)
  • Re: CoBOL and Contracting (Was: All X0D lost during...)
    ... And the topic is not just Contracting, ... Contracting in the CoBOL world. ... people who wish to profit from a marketplace do well ...
    (comp.lang.cobol)
  • Re: Thoughts on MF COBOL, Unix, and RDBMS
    ... On May 3, 12:51 pm, "Pete Dashwood" ... COBOL compiler available but it doesn't support SQL, ... the Unix Database (given ODBC for that). ...
    (comp.lang.cobol)
  • Re: Thoughts on MF COBOL, Unix, and RDBMS
    ... On May 3, 12:51 pm, "Pete Dashwood" ... I would like to have these programs run in a Unix environment. ... COBOL compiler available but it doesn't support SQL, ...
    (comp.lang.cobol)
  • Re: CoBOL and Contracting (Was: All X0D lost during...)
    ... On Aug 4, 9:40 pm, "Pete Dashwood" ... And the topic is not just Contracting, ... Contracting in the CoBOL world. ... The marketplace, though it may resemble a sentient being, is not one. ...
    (comp.lang.cobol)