Re: Proposed feature: Selective Foreign Keys - Mailing list pgsql-hackers

From Robert Haas
Subject Re: Proposed feature: Selective Foreign Keys
Date
Msg-id CA+TgmoZooANf1UAx9O+RTLOU-MvwyQ+Gb6Q9pnUHQ-meQVeMqg@mail.gmail.com
Whole thread Raw
In response to Re: Proposed feature: Selective Foreign Keys  (Andrew Dunstan <andrew@dunslane.net>)
List pgsql-hackers
On Wed, Dec 4, 2013 at 12:18 PM, Andrew Dunstan <andrew@dunslane.net> wrote:
>> Interestingly, the variant for which you can't think of a use case is
>> the one I've missed most.  Typical examples in my experience are
>> things like project.project_manager_id references person (id) where
>> person.is_project_manager, or alert (device_id) references device (id)
>> where not device.deleted.
>>
> OK, those make sense. I wonder whether this should be done via a USING
> clause on the constraint that pointed to the partial unique index. Or would
> that be too obscure?

I wondered that, too.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



pgsql-hackers by date:

Previous
From: Jeff Davis
Date:
Subject: Re: Extension Templates S03E11
Next
From: Sameer Kumar
Date:
Subject: Re: Changes in Trigger Firing