Re: float8 comparison failure

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Radek Kanovsky <rk(at)dat(dot)cz>
Cc: pgsql-bugs(at)hub(dot)org
Subject: Re: float8 comparison failure
Date: 2000-07-28 15:16:15
Message-ID: 29776.964797375@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Radek Kanovsky <rk(at)dat(dot)cz> writes:
> [ float8 values that appear equal are not always equal ]

This is not a bug, it's an inherent consequence of the inaccuracy of
floating-point math. Use some other data type (numeric, maybe) if
you expect to be able to do exact equality comparisons.

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Lutz Birkhahn 2000-07-28 15:29:20 postgresql-7.0.2: install-sh cannot install pgaccess
Previous Message Radek Kanovsky 2000-07-28 13:02:35 float8 comparison failure