On 25 April 2013 17:59, Frank Swarbrick <frank.swarbr...@yahoo.com> wrote:
> It's still not clear to me the situations when a business programmer would > want an explicit field to be DFP instead of PD. Perhaps someone can give a > good example of such? If you must deal with very large and very small numbers in the same calculation it becomes difficult to use fixed point arithmetic. Cowlishaw's canonical example is that of telephone call billing, where calls might be priced (and federal/state/local tax calculated) on a per second basis with tax values to six digits, but a day's or month's worth of total billing for a city or state could easily be in the millions. Of course for display purposes these are all eventually rounded, but that can't be done during the calculation without risk of losing a lot in the total. His FAQ at http://speleotrove.com/decimal/decifaq.html has many good (and a few implausible) examples. That page is mostly geared toward the need for decimal floating point vs binary floating point, rather than decimal fixed point, but is still the best reference around. Tony H. ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN