|
>> Numeric truncation - Like it or not, some programmers have come to depend on the old truncation rules. ...... For maximum compatibility, use control spec TRUNCNBR(*YES) to restore the old rules for the initial conversion. "Restore" is not the right word here. TRUNCNBR(*YES) is the default behavior for RPG IV and always has been. It is only on EVAL that you get an error - ADD, MULT etc. behave the way they always have. The *NO option was introduced (V4R2?) for those who preferred truncation to cause an error the way that EVAL does. The other thing I might add to your list is that most people find *RESDECPOS to be a useful default option when first using expressions because it uses what (in my opinion) are more sensible rules when deciding the size of intermediate results. Jon Paris Partner400
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 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.