Sorry, stupid me - it's not a bug, pg is perfectly right!
The query was just wrong, because I used the wrong column in the SUM(...) function.
Sorry again, Corin -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs