RE: Decimal versus Float Point Type

2006-09-08 Thread Jerry Schwartz
Message- From: Renato Golin [mailto:[EMAIL PROTECTED] Sent: Thursday, September 07, 2006 6:40 PM To: Gerald L. Clark Cc: mysql@lists.mysql.com Subject: Re: Decimal versus Float Point Type How do you expect to split a dollar 3 ways? Sorry, I should have added more smiles, it was supposed

Re: Decimal versus Float Point Type

2006-09-08 Thread Renato Golin
Jerry Schwartz wrote: An employee of a financial institution realized a similar vulnerability in their systems. It was common to calculate batch totals, which were cross checked to make sure that no transactions went astray, but he realized that so long as the batch totals came out right you

Decimal versus Float Point Type

2006-09-07 Thread Bruno Rodrigues Silva
Dear all. The MySQL Manual inform that Decimal Data Type is used for represent exact-number, but like Float Point Data Type, Decimal use rounding case the fractional part is not sufficient. Therefore, what the difference? Regards Bruno R. Silva

Re: Decimal versus Float Point Type

2006-09-07 Thread Renato Golin
Bruno Rodrigues Silva wrote: Dear all. The MySQL Manual inform that Decimal Data Type is used for represent exact-number, but like Float Point Data Type, Decimal use rounding case the fractional part is not sufficient. Therefore, what the difference? Hi Bruno, FLOAT rounds as floating point

RE: Decimal versus Float Point Type

2006-09-07 Thread Jerry Schwartz
-Original Message- From: Bruno Rodrigues Silva [mailto:[EMAIL PROTECTED] Sent: Thursday, September 07, 2006 6:47 AM To: mysql@lists.mysql.com Subject: Decimal versus Float Point Type Dear all. The MySQL Manual inform that Decimal Data Type is used for represent exact-number, but like Float

Re: Decimal versus Float Point Type

2006-09-07 Thread Renato Golin
Jerry Schwartz wrote: The difference is that, for example, .01 can be represented exactly in decimal; but float types are binary, so .01 cannot be represented exactly. This can lead to all kinds of trouble when doing arithmetic, the errors accumulate. Yes! but that can also lead to some other

Re: Decimal versus Float Point Type

2006-09-07 Thread Gerald L. Clark
Renato Golin wrote: Jerry Schwartz wrote: The difference is that, for example, .01 can be represented exactly in decimal; but float types are binary, so .01 cannot be represented exactly. This can lead to all kinds of trouble when doing arithmetic, the errors accumulate. Yes! but that can

Re: Decimal versus Float Point Type

2006-09-07 Thread Renato Golin
How do you expect to split a dollar 3 ways? Sorry, I should have added more smiles, it was supposed to be a joke about the dollars... ;) But still, I could win a lot of money by distributing people's money to their three kids and getting 1 cent out of every operation. :D It is not the math