Yes.  This is a terribly annoying problem.  Oh well, that's what happens
when there's only one "number" type.

> -----Original Message-----
> From: Sean A Corfield [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 17, 2002 10:03 PM
> To: CF-Talk
> Subject: Re: mySQL equivalent of MS Access "Money" fieldtype?
>
>
> On Tuesday, Dec 17, 2002, at 14:48 US/Pacific, Jochem van Dieten wrote:
> > I believe the rounding baheviour of SQL is not specified to the point
> > where you can say a priori that math will not introduce errors with any
> > datatype. You always have to check the manual, because even with
> > operations involving 2 exact numeric values the outcome is often
> > implementation-defined.
>
> Actually, although this was exactly my point (use a binary integer for
> cents), you have reminded me of a slight problem for us CFers: namely
> that CF doesn't actually have a binary integer type but uses "numeric"
> instead which is inherently floating point... :(
>
> Moral: if you're really doing heavy math in pennies and can't risk any
> rounding errors, you'll need to use Java and code the formulae in int
> or long types!
>
> Sean A Corfield -- Director, Architecture
> Web Technology Group -- Macromedia, Inc.
> tel: (415) 252-2287 -- cell: (415) 717-8473
> aim: seancorfield -- http://www.macromedia.com
> An Architect's View -- http://www.corfield.org/blog/
>
> Introducing Macromedia Contribute. Web publishing for everyone.
> Learn more at http://www.macromedia.com/contribute
>
> 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Get the mailserver that powers this list at http://www.coolfusion.com

Reply via email to