Re: Money data type in PostgreSQL? - Mailing list pgsql-general

From Christopher Browne
Subject Re: Money data type in PostgreSQL?
Date
Msg-id m3n0aauhk1.fsf@wolfe.cbbrowne.com
Whole thread Raw
In response to Money data type in PostgreSQL?  (David Garamond <lists@zara.6.isreserved.com>)
Responses Re: Money data type in PostgreSQL?
List pgsql-general
Martha Stewart called it a Good Thing when clapidus@hotmail.com ("Claudio Lapidus") wrote:
> With regard to precision, it is common in certain applications the need to
> handle very small amounts, especially when used as factors of a larger
> calculation. I've even seen once some rates defined in hundredths of cents!

Well, you don't need terribly much precision in the currency exchange
rate if the amount being converted is small.  You only need a couple
significant digits to convert $0.24 USD to the appropriate amount in
$CDN.

But to get the pennies right on a $10,000 USD transaction converted
into GBP (UK Pounds), you need all the official precision that there
is.  And if your calculation is off by 4 cents, some of those
accounting folk are liable to thrash you mercilessly over it.  If you
get calculations WRONG, they get really uncomfortable, and want to
know why.
--
(reverse (concatenate 'string "ac.notelrac.teneerf" "@" "454aa"))
http://www3.sympatico.ca/cbbrowne/linuxdistributions.html
"Women who seek to be equal to men lack ambition. "
-- Timothy Leary

pgsql-general by date:

Previous
From: "Rick Gigger"
Date:
Subject: transaction in progress
Next
From: Randolf Richardson
Date:
Subject: Re: embedded postgresql + C++ IDE