pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Bruce Momjian <pgman@candle.pha.pa.us>
Cc: Mark Dilger <pgsql@markdilger.com>
Cc: pgsql-hackers@postgresql.org
Subject: Re: [SQL] Interval subtracting
Date: Wed, 01 Mar 2006 18:07:42 -0500
Message-ID: <16750.1141254462@sss.pgh.pa.us> (raw)
In-Reply-To: <200603012302.k21N2Hm04879@candle.pha.pa.us>
References: <200603012302.k21N2Hm04879@candle.pha.pa.us>

Bruce Momjian <pgman@candle.pha.pa.us> writes:
> Tom Lane wrote:
>> Based on that, I guess I have to change my vote: justify_hours should
>> still not look at the month (because it shouldn't use the month=30days
>> assumption), but justify_days should be changed to be effectively a
>> combination of both functions --- that is, it should fix all three
>> fields using both the 30days and the 24hours assumptions.  Then it could
>> guarantee that all come out with the same sign.

> If we do that, we should just call it justify_interval().  I am thinking
> this is the direction to go, and for people who want more control they
> use the justify_hours and justify_days, and those are left unchanged.

Well, the question is whether justify_days has a sane definition that is
different from this.  Based on your example, I'm not seeing one.

			regards, tom lane



view thread (62+ messages)  latest in thread

Message-ID: <16750.1141254462@sss.pgh.pa.us>
Permalink:  ../16750.1141254462@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/16750.1141254462@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: tgl@sss.pgh.pa.us, pgman@candle.pha.pa.us, pgsql@markdilger.com, pgsql-hackers@postgresql.org
  Subject: Re: [SQL] Interval subtracting
  In-Reply-To: <16750.1141254462@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox