Re: are foreign keys realized as indexes? - Mailing list pgsql-general

From Felix Kater
Subject Re: are foreign keys realized as indexes?
Date
Msg-id 20070508143429.d0728982.fkater@googlemail.com
Whole thread Raw
In response to Re: are foreign keys realized as indexes?  (Peter Eisentraut <peter_e@gmx.net>)
Responses Re: are foreign keys realized as indexes?
List pgsql-general
On Tue, 8 May 2007 14:19:12 +0200
Peter Eisentraut <peter_e@gmx.net> wrote:

> > I like to keep my pg interface small: Can I replace foreign keys by
> > using indexes somehow?
>
> Not while preserving the semantics.

I am not bound to indexes, however, wonder if foreign keys itself are
non-atomic functionality. I mean: if foreign keys are based on some
other lower level functionality like indexes or anything else which I
could use as a substitute--in what way ever. Of course, I want to
gain the same (referential integrity etc.).

If foreign keys are, however, something unique which can't be replaced
by any other pg function (I am of course not taking into account things
like multiple queries bound together by transactions...) then I have to
go though it and implement it into my pg interface (looking at the
information_schema: This seems to be quite a bunch of work...).

Thank You
Felix

pgsql-general by date:

Previous
From: Raymond O'Donnell
Date:
Subject: Re: are foreign keys realized as indexes?
Next
From: Felix Kater
Date:
Subject: pg_contraint: 'action code' ?