Re: [HACKERS] Inheritance, referential integrity and other constraints - Mailing list pgsql-hackers

From Chris Bitmead
Subject Re: [HACKERS] Inheritance, referential integrity and other constraints
Date
Msg-id 3890DE7F.5409C776@bitmead.com
Whole thread Raw
In response to Re: [HACKERS] Inheritance, referential integrity and other constraints  (Peter Eisentraut <peter_e@gmx.net>)
List pgsql-hackers
Oliver Elphick wrote:

> No, the inheritance system doesn't allow them to be different types.
> You get an error if you try to create such a table:

Hmm. While it might allow it, I can't see the logic in it. Can't think
of any OO language that thinks this way. All other languages you get
two different variables either with :: scope resolution in C++ or
renaming in Eiffel.

> Because the column names are identical, they are overlaid and treated
> as the same column.  This is so whether or not they ultimately derive
> from the same parent, so it isn't strictly a case of repeated inheritance
> as in Eiffel. (There, repeatedly inherited features of the same parent
> are silently combined, but identical names from unrelated classes are
> conflicts.)

Which seems like the right thing to me.


pgsql-hackers by date:

Previous
From: Chris Bitmead
Date:
Subject: Re: OIDS (Re: [HACKERS] Well, then you keep your darn columns)
Next
From: The Hermit Hacker
Date:
Subject: PostgreSQL 7.0beta Freeze Postponed ... (fwd)