Re: Proposal: temporal extension "period" data type - Mailing list pgsql-hackers

From Hannu Krosing
Subject Re: Proposal: temporal extension "period" data type
Date
Msg-id 1211825403.8025.12.camel@huvostro
Whole thread Raw
In response to Re: Proposal: temporal extension "period" data type  (Jeff Davis <pgsql@j-davis.com>)
Responses Re: Proposal: temporal extension "period" data type  (Jeff Davis <pgsql@j-davis.com>)
List pgsql-hackers
On Mon, 2008-05-26 at 10:59 -0700, Jeff Davis wrote:
> On Mon, 2008-05-26 at 06:49 -0400, Andrew Dunstan wrote:
> > >  * temporal foreign keys
> > >  * temporal joins
> > >   
> > 
> > Maybe I'm being dense, but how does inclusion in core help you do these 
> > things? Or, more precisely, how does non-inclusion in core prevent them.
> 
> Temporal FK's can be implemented with triggers, but can't be
> implemented with the current FK syntax and mechanism. Any extensions to
> the FK syntax to support this would need to be done in postgres. 
> 
> Temporal joins can be implemented by joining with the "overlaps"
> operator and selecting the intersection of the two period columns.
> Anything added would be syntactic sugar.

Either overlaps or contains seem valid join operators

Will there be UNIQUE (non-overlapping) indexes for period ?

--------------
Hannu




pgsql-hackers by date:

Previous
From: Hannu Krosing
Date:
Subject: Re: Read Uncommitted
Next
From: "Heikki Linnakangas"
Date:
Subject: Re: Proposal: temporal extension "period" data type