Re: abuse of inheritance?

From: Curt Sampson <cjs(at)cynic(dot)net>
To: Alex Rice <alex_rice(at)arc(dot)to>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: abuse of inheritance?
Date: 2002-07-11 03:57:36
Message-ID: Pine.NEB.4.44.0207111255410.436-100000@angelic.cynic.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, 10 Jul 2002, Alex Rice wrote:

> Should I be using table inheritance in this scenario?
>
> Table "contact" has name, address, phone, email, etc. columns.
> Table "staff" inherits from "contact because it has many columns in
> common with "contact".

So I'm ok with relational theory, I think, and I know OO pretty
well, at least from a programmer's viewpoint.

But I'm unsure about this table inheritance thing. What is the advantage
of using inheritance over having a staff table with the staff columns
and a FK into the contact table? What are the disadvantages? Can anyone
point to some literature on this?

cjs
--
Curt Sampson <cjs(at)cynic(dot)net> +81 90 7737 2974 http://www.netbsd.org
Don't you know, in this new Dark Age, we're all light. --XTC

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Arguile 2002-07-11 04:14:27 Re: abuse of inheritance?
Previous Message Bruce Momjian 2002-07-11 03:56:38 Re: Linux max on shared buffers?