Skip site navigation (1) Skip section navigation (2)

Possible bug in PGInterval class

From: Ľubomír Varga <luvar(at)plaintext(dot)sk>
To: pgsql-jdbc(at)postgresql(dot)org
Subject: Possible bug in PGInterval class
Date: 2009-08-31 19:34:12
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-jdbc

I have noticed imho bad behaviour of add methods for PGInterval class. 

First is unlogical adding sum to parameter and not to object on which is 
method invoked. (this is also writen in javadoc, so I accept it)

Second, critical for me, is to not using modulo in addition. So if you add 55 
minutes to 55 minutes, you get 110 minutes instead of 1 hour and 50 minutes.

Is this bug or feature? Should I use to postprocessing of sql query result 
some other date classes? (joda time, or java date class...)

Thanks for answer.

PS: If it is not bug, please add some description to javadoc also to this 

I am using 8.4-701 build and source...

Odborník na všetko je zlý odborník. Ja sa snažím byť výnimkou potvrdzujúcou 


pgsql-jdbc by date

Next:From: Kris JurkaDate: 2009-09-02 00:01:11
Subject: Re: Possible bug in PGInterval class
Previous:From: Thomas KellererDate: 2009-08-31 14:21:16
Subject: Re: Search content within a bytea field

Privacy Policy | About PostgreSQL
Copyright © 1996-2018 The PostgreSQL Global Development Group