On Thu, May 26, 2005 at 08:56:34AM -0400, Paul Tillotson wrote:
> Tom Lane wrote:
>
> >Paul Tillotson <[EMAIL PROTECTED]> writes:
> In other words, no arbitrary number of extra decimal places when calling
> div_var() will be always sufficient to prevent rounding up at some other
> decimal place
Tom Lane wrote:
Paul Tillotson <[EMAIL PROTECTED]> writes:
I don't think anyone wants to defend the negative modulus as such, but to fix
it, we have to do one of these:
(1) Keep rounding division, but rewrite the numeric modulus operator to use a
form of division that always rou
Paul Tillotson <[EMAIL PROTECTED]> writes:
> I don't think anyone wants to defend the negative modulus as such, but to fix
> it, we have to do one of these:
> (1) Keep rounding division, but rewrite the numeric modulus operator to use a
> form of division that always rounds towards zero.
> or
Alvaro Herrera (and others) have noticed that the numeric modulus operator
sometimes gives negative results even when the dividend and divisor are
positive:
Oh, and while at it, it would be nice to solve the modulo bug that still lurks
there:
alvherre=# select 12345678901234567890 % 123;
?c