Re: BUG #3431: age() gets the days wrong

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Pelle Johansson" <pelle(at)morth(dot)org>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #3431: age() gets the days wrong
Date: 2007-07-06 17:27:13
Message-ID: 6662.1183742833@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers pgsql-patches

"Pelle Johansson" <pelle(at)morth(dot)org> writes:
> The age() function seem to work by first counting months until less than a
> month remains to to the second argument, then counting days left. This
> doesn't give the correct result, as shown by this example:

age() isn't intended to give the same result as minus, so I'm not
convinced that this behavior is wrong. I'm more worried about what
applications we might break by changing it --- age() has always worked
the way it does now.

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Rainer Bauer 2007-07-06 19:55:10 Re: BUG #3427: Autovacuum crashed server
Previous Message Magnus Hagander 2007-07-06 16:45:54 Re: BUG #3427: Autovacuum crashed server

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2007-07-06 17:32:27 Re: usleep feature for pgbench
Previous Message Michael Glaesemann 2007-07-06 17:24:58 Re: script binaries renaming

Browse pgsql-patches by date

  From Date Subject
Next Message Alvaro Herrera 2007-07-06 19:04:27 Re: Still recommending daily vacuum...
Previous Message Michael Glaesemann 2007-07-06 17:24:58 Re: script binaries renaming