Re: Not able to update some rows in a table

From: Marco Fochesato <marcofoc(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "pgsql-generallists(dot)postgresql(dot)org" <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: Re: Not able to update some rows in a table
Date: 2018-07-03 05:29:40
Message-ID: CAECC44c87swS8RvZm1sbZCWrQZo=2oSs35AsvzEe8xzut46YZQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

>
>
> That seems like a remarkably strange definition of a primary key.
> Are all of those columns really identification of an object, and
> not properties of the object?
>

> In any case, I'll bet a lot of money that your can't-update problem
> is related to the fuzzy behavior of floating-point columns. Just
> because a float8 value prints out as "1.2345" doesn't mean that it'll
> be considered equal to a value you write as "1.2345". If this fact
> astonishes you, you should likely switch to type numeric.
>
> regards, tom lane
>

Dear Tom, you can bet all your money because you are right.
I drop the table and re-created using numeric instead double precision.
Now everything is ok, I can update every row of the table.
Thank you.

--
Marco Fochesato

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Rafal Pietrak 2018-07-03 07:30:45 FK v.s unique indexes
Previous Message Charles Clavadetscher 2018-07-02 16:09:41 Re: Not able to update some rows in a table