pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Lew <lew@nospam.lewscanon.com>
To: pgsql-sql@postgresql.org
Subject: Re: Floating point type to store numbers
Date: Sat, 21 Apr 2007 01:20:46 -0400
Message-ID: <BN-dnWNvp_KzArTbnZ2dnUVZ_uninZ2d@comcast.com> (raw)
In-Reply-To: <20070417205318.GC9094@phlogiston.dyndns.org>
References: <4838.63.118.86.10.1176836034.squirrel@www.88thstreet.com>
	<20070417190443.GA9094@phlogiston.dyndns.org>
	<19968.63.118.86.10.1176842013.squirrel@www.88thstreet.com>
	<20070417205318.GC9094@phlogiston.dyndns.org>

Andrew Sullivan wrote:
> On Tue, Apr 17, 2007 at 04:33:33PM -0400, Radhika Sambamurti wrote:
>> Andrew,
>> This has been quite helpful. My main concern is CPU cost.  Thanks for the
>> input.
> 
> You're welcome.  Are you sure your main concern should be CPU cost?
> It's true that numeric is more costly that float in a lot of cases,
> but I know at least one auditor who will refuse to certify results
> from programs that anywhere use floating-point storage or calculation
> on accounting data.  The problem is really that you can get compound
> errors -- very small rounding errors several times can turn out to be
> a big problem.  (One quick primer that can help you understand this
> is at <http://www2.hursley.ibm.com/decimal/decifaq1.html;.)

Would you rather have wrong answers really, really fast, or right answers fast 
enough?

-- 
Lew



view thread (10+ messages)

Message-ID: <BN-dnWNvp_KzArTbnZ2dnUVZ_uninZ2d@comcast.com>
Permalink:  ../BN-dnWNvp_KzArTbnZ2dnUVZ_uninZ2d@comcast.com/
Also on:    postgresql.org/message-id/BN-dnWNvp_KzArTbnZ2dnUVZ_uninZ2d@comcast.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: lew@nospam.lewscanon.com
  Subject: Re: Floating point type to store numbers
  In-Reply-To: <BN-dnWNvp_KzArTbnZ2dnUVZ_uninZ2d@comcast.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox