From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Hannu Krosing <hannu(at)skype(dot)net> |
Cc: | Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, Stephan Szabo <sszabo(at)megazone(dot)bigpanda(dot)com>, "Milen A(dot) Radev" <milen(at)radev(dot)net>, pgsql-sql(at)postgresql(dot)org, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: [SQL] Interval subtracting |
Date: | 2006-03-01 20:35:28 |
Message-ID: | 14928.1141245328@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-patches pgsql-sql |
Hannu Krosing <hannu(at)skype(dot)net> writes:
> But unfortunately '2 mons -1 days' <> '1 mons 29 days'
> If I want something to happen 1 day less than two months from dome date,
> then the only way to say that consistently *is* '2 mons -1 days'.
Sure, but if you want to represent that then you don't pass the value
through justify_days(). The entire premise of justify_days() is that
1 month is interchangeable with 30 days and we should try to make the
value "look nice" given that assumption.
I think everyone's independently arrived at the same thought that
justify_days should not produce a result with different signs for month
and day (except for the case with month = 0, per my last message).
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Scott Marlowe | 2006-03-01 20:36:37 | Re: [SQL] Interval subtracting |
Previous Message | Bruce Momjian | 2006-03-01 20:33:33 | Re: [SQL] Interval subtracting |
From | Date | Subject | |
---|---|---|---|
Next Message | Scott Marlowe | 2006-03-01 20:36:37 | Re: [SQL] Interval subtracting |
Previous Message | Bruce Momjian | 2006-03-01 20:33:33 | Re: [SQL] Interval subtracting |
From | Date | Subject | |
---|---|---|---|
Next Message | Scott Marlowe | 2006-03-01 20:36:37 | Re: [SQL] Interval subtracting |
Previous Message | Bruce Momjian | 2006-03-01 20:33:33 | Re: [SQL] Interval subtracting |