Re: Range Types - typo + NULL string constructor - Mailing list pgsql-hackers

From Jeff Davis
Subject Re: Range Types - typo + NULL string constructor
Date
Msg-id 1316450922.7281.185.camel@jdavis
Whole thread Raw
In response to Re: Range Types - typo + NULL string constructor  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
List pgsql-hackers
On Mon, 2011-09-19 at 11:00 -0500, Kevin Grittner wrote:
> On a practical level, our shop is already effectively doing this. 
> We have several tables where part of the primary key is "effective
> date" and there is a null capable "expiration date" -- with a NULL
> meaning that no expiration date has been set.  It would be nice to
> be able to have a "generated column" function which used these two
> dates to build a range for exclusion constraints and such.

Agreed, that's a good convenience argument for accepting NULL boundaries
in the constructors.

Underneath though, we don't use NULL semantics (because they don't make
sense for ranges -- in fact, avoiding the need to constantly
special-case NULLs is one of the reasons to use range types). So, we
want to avoid confusion where possible.

Regards,Jeff Davis



pgsql-hackers by date:

Previous
From: Christopher Browne
Date:
Subject: Re: Is there really no interest in SQL Standard?
Next
From: Marc Cousin
Date:
Subject: Review for EXPLAIN and nfiltered