Postgresql problem with update double precision - Mailing list pgsql-general

From Condor
Subject Postgresql problem with update double precision
Date
Msg-id 5c3ada0c2a073d94f06843c15372dc9c@stz-bg.com
Whole thread Raw
Responses Re: Postgresql problem with update double precision  (Jerry Sievers <gsievers19@comcast.net>)
Re: Postgresql problem with update double precision  ("Igor Neyman" <ineyman@perceptron.com>)
List pgsql-general
Hello ppl,
for few years I have problem when update double precision field. I have
table and few double precision columns, here is example:

sumall double precision,
sumin double precision,

My php script do:

$get = 2.40

and sql code is:

UPDATE table1 SET sumall = sumall + $get WHERE id = 1 AND rd =
CURRENT_DATE;


When I browse the table some times i see incorrect values like:

955.599999999998

it's should be 955.60 after these updates ... some days is fine, some
days the value is incorrect.

I have this problem from version 7 of postgresql, Im now use 9.0.3

Anyone know what can be the problem and why some times records is fine,
some times isnt ?

--
Regards,
Condor

pgsql-general by date:

Previous
From: "Tomas Vondra"
Date:
Subject: Re: postgres table have a large number of relpages and occupied a big memory size
Next
From: Tim Uckun
Date:
Subject: Select count with offset returns nothing.