BUG #1577: round(dp) function does not round to nearest integer properly - Mailing list pgsql-bugs

From Roman Schayuk
Subject BUG #1577: round(dp) function does not round to nearest integer properly
Date
Msg-id 20050404140444.B78DBF0B58@svr2.postgresql.org
Whole thread Raw
Responses Re: BUG #1577: round(dp) function does not round to nearest integer properly
List pgsql-bugs
The following bug has been logged online:

Bug reference:      1577
Logged by:          Roman Schayuk
Email address:      rschayuk@rogers.com
PostgreSQL version: 7.2.2
Operating system:   RedHat Linux 8.0 x86
Description:        round(dp) function does not round to nearest integer
properly
Details:

SQL command:
gap=> select round(42.5);
 round
-------
    42
(1 row)
Result has to be 43

In contrast round(numeric, int) function works properly:
gap=> select round(42.5,0);
 round
-------
    43
(1 row)

pgsql-bugs by date:

Previous
From: Enrico Weigelt
Date:
Subject: Re: float conversion / presentation problem ?
Next
From: "David Elliott"
Date:
Subject: BUG #1580: pg_dumpall aborts when cwd is unreadable