Any reason not to use inheritance? - Mailing list pgsql-general

From jao@geophile.com
Subject Any reason not to use inheritance?
Date
Msg-id 1095714229.414f45b60340b@geophile.com
Whole thread Raw
Responses Re: Any reason not to use inheritance?  (Thomas F.O'Connell <tfo@sitening.com>)
Re: Any reason not to use inheritance?  (David Garamond <lists@zara.6.isreserved.com>)
List pgsql-general
My company's product uses Postgres 7.4.3. Postgres is working well for
us, and we've worked through many performance issues by tweaking the
schema, indexes, and posgresql.conf settings.

Inheritance would be useful for our application, but we did not use
this feature initially. We're about to revise part of our application,
and this would be a good time to introduce inheritance -- it's a good
fit for our data model, and it would greatly simplify some of our
upcoming work.

I'd really like to use inheritance, but not if I'm asking for trouble.
The question is whether there are any performance-related surprises
lurking. Our use of inheritance would be very simple:

- The columns that would be inherited are not involved in any primary
or foreign keys.

- One of the columns would be used in indexes on some of the child
tables. In these cases, the index would combine an inherited column
with a column declared in an inheriting table.

- Queries will often restrict the inherited indexed column.

- We'll occasionally ORDER BY inherited columns.

Any reason not to use inheritance?

Jack Orenstein


----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.

pgsql-general by date:

Previous
From: Jeff Amiel
Date:
Subject: Re: using database for queuing operations?
Next
From: Ron St-Pierre
Date:
Subject: Re: using database for queuing operations?