Re: Altering metadata to add inheritance

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Altering metadata to add inheritance
Дата
Msg-id 4096.1012501768@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Altering metadata to add inheritance  (jboes@nexcerpt.com (Jeff Boes))
Список pgsql-general
jboes@nexcerpt.com (Jeff Boes) writes:
> As an experiement, I want to turn a number of identically structured
> tables into "child" tables of a template. ... I suspect
> there's a way to do this directly in the pg_class table.

pg_class doesn't show inheritance.  I *think* all you'd have to do is
insert rows into pg_inherits, see

http://developer.postgresql.org/docs/postgres/catalog-pg-inherits.html

Oh, and you'd have to set pg_class.relhassubclass true for the parent
table.

But I've not tried to do this by hand myself.  Better experiment on
a test database ;-)

            regards, tom lane

В списке pgsql-general по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: process exited with status 11 after XLogFlush: request is not satisfied
Следующее
От: "Bjoern Metzdorf"
Дата:
Сообщение: Re: process exited with status 11 after XLogFlush: request is not satisfied