Обсуждение: using inheritance in production application.

Поиск
Список
Период
Сортировка

using inheritance in production application.

От
Larry White
Дата:
How 'ready for prime-time' is the table inheritance feature?  I've
seen some postings about particular issues (lack of full FK support,
for example), but would like to get an overall sense of the stability
and robustness of the feature.

Also, is there a performance hit in using inheritance?  For example if
I have a sub-table that adds a couple of columns to a base table,
would it be slower to query that structure than it would to represent
the extra columns as a separate table that would be joined with the
base table?

thanks for your help.

Re: using inheritance in production application.

От
Bruce Momjian
Дата:
Larry White wrote:
> How 'ready for prime-time' is the table inheritance feature?  I've
> seen some postings about particular issues (lack of full FK support,
> for example), but would like to get an overall sense of the stability
> and robustness of the feature.
>
> Also, is there a performance hit in using inheritance?  For example if
> I have a sub-table that adds a couple of columns to a base table,
> would it be slower to query that structure than it would to represent
> the extra columns as a separate table that would be joined with the
> base table?

All inheritance problems are mentioned on the TODO list, and none are
performance-related.  They all revolve around the inability of an index
to span multiple tables.

--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073