This has been saved for the 8.4 release:
http://momjian.postgresql.org/cgi-bin/pgpatches_hold
---
Tom Lane wrote:
> Gregory Stark <[EMAIL PROTECTED]> writes:
> > In the case reported div_var was getting 70/70 = 0.99
Gregory Stark <[EMAIL PROTECTED]> writes:
> In the case reported div_var was getting 70/70 = 0.9. Which is
> really just wrong.
Agreed, but I think your proposed patch is just a band-aid. The real
problem with div_var is that it generates inaccurate output digits at
all --- it's assuming that
"Tom Lane" <[EMAIL PROTECTED]> writes:
> Gregory Stark <[EMAIL PROTECTED]> writes:
>> The source of the problem is the floating point arithmetic which is used to
>> do
>> the individual steps in the long division.
>
> I don't think so. The ultimate source of the problem is that div_var
> can onl
Gregory Stark <[EMAIL PROTECTED]> writes:
> The source of the problem is the floating point arithmetic which is used to do
> the individual steps in the long division.
I don't think so. The ultimate source of the problem is that div_var
can only report a finite number of digits.
"Tom Lane" <[EMAIL PROTECTED]> writes:
> "Filip Krska" <[EMAIL PROTECTED]> writes:
>> select mod (70.0,70) from dual;
>> returns
>> 70.0
>> instead of
>> 0.0
>
> PG 8.0 gets this right. I think this demonstrates that Bruce's 8.1 patch
> http://archives.postgresql.org/pgsql-committers/2005-06/msg0
"Filip Krska" <[EMAIL PROTECTED]> writes:
> select mod (70.0,70) from dual;
> returns
> 70.0
> instead of
> 0.0
PG 8.0 gets this right. I think this demonstrates that Bruce's 8.1 patch
http://archives.postgresql.org/pgsql-committers/2005-06/msg00045.php
didn't actually fix anything, merely move t
The following bug has been logged online:
Bug reference: 3387
Logged by: Filip Krska
Email address: [EMAIL PROTECTED]
PostgreSQL version: 8.1.5
Operating system: CentOS Linux 3.8 on x86_64
Description:mod on non-integer returns bad result
Details:
Hello,
select mod