[cfaussie] Re: Strange FIX() behaviour

2007-08-13 Thread Simon Haddon
Of Haikal Saadh Sent: Monday, 13 August 2007 12:19 PM To: cfaussie@googlegroups.com mailto:cfaussie@googlegroups.com Subject: [cfaussie] Re: Strange FIX() behaviour I remember a thread from here a while back discussing the various idiosyncrasies of floating point

[cfaussie] Re: Strange FIX() behaviour

2007-08-12 Thread Steve Onnis
I would have thought from a decimal though. Looks like it is VERY literal _ From: cfaussie@googlegroups.com [mailto:[EMAIL PROTECTED] On Behalf Of grant Sent: Monday, 13 August 2007 11:38 AM To: cfaussie@googlegroups.com Subject: [cfaussie] Re: Strange FIX() behaviour it seems

[cfaussie] Re: Strange FIX() behaviour

2007-08-12 Thread David Harris
Something odd is happening there If you do this: cfset cents = 995 cfoutput #FIX(cents)# /cfoutput you get the expected result. eg: 995 The only thing that springs to mind is that maybe: 9.95 * 100 = 994. ? not sure how to prove this theory tho... Steve Onnis wrote: Has anyone

[cfaussie] Re: Strange FIX() behaviour

2007-08-12 Thread Haikal Saadh
I remember a thread from here a while back discussing the various idiosyncrasies of floating point arithmetic, and that you should be really storing money in cent amounts. I've got no first hand experience in this, but have a flip thru the archives. David Harris wrote: Something odd is

[cfaussie] Re: Strange FIX() behaviour

2007-08-12 Thread Andrew Scott
Steve use Ceiling(number) instead, much better than Fix() Andrew Scott Senior Coldfusion Developer Aegeon Pty. Ltd. www.aegeon.com.au Phone: +613 8676 4223 Mobile: 0404 998 273 From: cfaussie@googlegroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Steve Onnis Sent: Monday, 13 August

[cfaussie] Re: Strange FIX() behaviour

2007-08-12 Thread Steve Onnis
have changed it from FIX() to ROUND() anyway Steve -Original Message- From: cfaussie@googlegroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Haikal Saadh Sent: Monday, 13 August 2007 12:19 PM To: cfaussie@googlegroups.com Subject: [cfaussie] Re: Strange FIX() behaviour I remember

[cfaussie] Re: Strange FIX() behaviour

2007-08-12 Thread AJ Mercer
PROTECTED] On Behalf Of Haikal Saadh Sent: Monday, 13 August 2007 12:19 PM To: cfaussie@googlegroups.com Subject: [cfaussie] Re: Strange FIX() behaviour I remember a thread from here a while back discussing the various idiosyncrasies of floating point arithmetic, and that you should be really

[cfaussie] Re: Strange FIX() behaviour

2007-08-12 Thread Brett Payne-Rhodes
mailto:cfaussie@googlegroups.com [mailto: cfaussie@googlegroups.com mailto:cfaussie@googlegroups.com] On Behalf Of Haikal Saadh Sent: Monday, 13 August 2007 12:19 PM To: cfaussie@googlegroups.com mailto:cfaussie@googlegroups.com Subject: [cfaussie] Re: Strange FIX() behaviour