Converting unpacked Packed Decimal Comp-3 data into doubles -


I have a fixed width text file, which is unpacked from the Comp-3 data to the fixed width string.

I need to explain the following areas:

  FIELD-NAME-1 PIC S9 (15) V9 (3) vibrate 3 field-NAME-2 PIC S9 (3) V9 (8) Comp of 3 field-NAME-3 PIC S9 (3) V9 (6) कंपेन 3  

These appear in my flat file in this form Giving:

  FIELD-NAME-1 0123456789123456780 field- NAME-2 01234567890 FIELD-NAME-3 012345670  

I should know that the above mentioned What do the numbers represent.

Is that correct:

  FIELD-NAME-1 123456789123456.780 - & gt; First 0 means + ve? FIELD-NAME-2 012.34567890 FIELD-NAME-3 012.345670  

Thanks for the help.

It is necessary to store in a single number):

  • One for the icon
  • 15 for the integer bit.
  • 3-bit for non-integer (V is a valid decimal, not real).

This signal typically ends with C or D so the answer to this question completely depends on unpacking.

Your first example is actually the correct number of digits without signature so I should be worried with your statement that one of them represented the signature either, or did you " 9 "in the other two examples, there are enough points for both sign and numerical part.

See the best bet, to see if you can get a negative number (and other test data like 1) to see what it generates. / P>


Comments

Popular posts from this blog

python - Overriding the save method in Django ModelForm -

html - CSS autoheight, but fit content to height of div -

qt - How to prevent QAudioInput from automatically boosting the master volume to 100%? -