| From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
|---|---|
| To: | Andrew Dunstan <andrew(at)dunslane(dot)net> |
| Cc: | Tom Dunstan <pgsql(at)tomd(dot)cc>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org> |
| Subject: | Re: Proposed feature: Selective Foreign Keys |
| Date: | 2013-12-04 17:55:38 |
| Message-ID: | CA+TgmoZooANf1UAx9O+RTLOU-MvwyQ+Gb6Q9pnUHQ-meQVeMqg@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Wed, Dec 4, 2013 at 12:18 PM, Andrew Dunstan <andrew(at)dunslane(dot)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
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Sameer Kumar | 2013-12-04 17:56:38 | Re: Changes in Trigger Firing |
| Previous Message | Jeff Davis | 2013-12-04 17:52:51 | Re: Extension Templates S03E11 |