pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Mark Dilger <pgsql@markdilger.com>
Cc: pgsql-hackers@postgreSQL.org
Subject: Re: [SQL] Interval subtracting
Date: Thu, 02 Mar 2006 09:49:32 -0500
Message-ID: <2476.1141310972@sss.pgh.pa.us> (raw)
In-Reply-To: <440647D4.9060601@markdilger.com>
References: <200603012326.k21NQOv08610@candle.pha.pa.us>
	<4406331A.6080307@markdilger.com>
	<17317.1141257505@sss.pgh.pa.us>
	<44063632.20505@markdilger.com>
	<17752.1141259857@sss.pgh.pa.us>
	<440647D4.9060601@markdilger.com>

Mark Dilger <pgsql@markdilger.com> writes:
> Tom Lane wrote:
>> The problem is that you can't determine "what answer justify_days would
>> give" without using the assumption "1 month == 30 days", which is an
>> assumption that justify_hours must not depend on.

> Ahhh.  So the fact that justify_days already makes the 1 month == 30 days 
> assumption is ok in that function but can't be propagated to justify_hours.

Right.  I don't want us to define things so that none of this
functionality is available in situations where the 30-day assumption is
untenable.  justify_hours can still do something useful (ie, trim
oversize hours fields) without that.

justify_interval will probably be the new "normal" way to do things when
you are prepared to make both assumptions.  I'm not entirely sure about
the use-case for justify_days, but seems we ought to keep it for reasons
of backwards compatibility.

			regards, tom lane



view thread (62+ messages)  latest in thread

Message-ID: <2476.1141310972@sss.pgh.pa.us>
Permalink:  ../2476.1141310972@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/2476.1141310972@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, pgsql@markdilger.com, pgsql-hackers@postgreSQL.org
  Subject: Re: [SQL] Interval subtracting
  In-Reply-To: <2476.1141310972@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