× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Hello,

 C     STA_DATTIM    SUBDUR    SV_DATTIM       STA_DUR:*S
 STA_DATTIM            TIMESTAMP(26)        '2006-10-31-09.55.21.000000'
                     VALUE IN HEX         'F2F0F0F660F1F060F3F160F0F94BF5F54
 SV_DATTIM             TIMESTAMP(26)        '2006-10-29-01.14.15.000000'
                     VALUE IN HEX         'F2F0F0F660F1F060F2F960F0F14BF1F44
 STA_DUR            PACKED(5,0)          00007.           '00007F'X


The result of this SUBDIR operation should be 204066, which is larger than can fit in a 5,0 packed field.

On my system, it does not produce an error, but it chops off the leading digit, making it 04066 instead of 204066, and therefore anything you use this field for would produce invalid results.

On your system, it appears that it's producing an error. That's a good thing because it protects you against major problems in your calculations. Though, I don't see why yours gives you this error. It doesn't on my system, and I'm also running V5R3. You also said that you created a dummy program and did the calculation there, and it didn't produce an error. So I don't see why you'd get an error. But it's good that you did! Make the field bigger!





As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.