Skip site navigation (1) Skip section navigation (2)

Re: BUG #4603: float4 error

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Stefan Hoffmann" <hoffst(at)maxinf(dot)de>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #4603: float4 error
Date: 2009-01-07 15:24:39
Message-ID: 26423.1231341879@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-bugs
"Stefan Hoffmann" <hoffst(at)maxinf(dot)de> writes:
> some specific values such as 20048223 or -25771373 can't be stored in float4
> . they are replaced by 20048224 and 
> -25771372 when inserted or updated in float4 .
> is this a problem of 7.4 or caused by "inexact" float4 ?

The latter.  On most machines float4 is only good for about six
significant digits, and you're expecting eight ...

			regards, tom lane

In response to

pgsql-bugs by date

Next:From: Hiroshi InoueDate: 2009-01-07 16:04:19
Subject: Re: [BUGS] BUG #4186: set lc_messages does not work
Previous:From: Stefan HoffmannDate: 2009-01-07 15:15:21
Subject: BUG #4603: float4 error

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group