Re: BETWEEN Node & DROP COLUMN

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: BETWEEN Node & DROP COLUMN
Дата
Msg-id 10705.1025878493@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: BETWEEN Node & DROP COLUMN  ("Christopher Kings-Lynne" <chriskl@familyhealth.com.au>)
Список pgsql-hackers
"Christopher Kings-Lynne" <chriskl@familyhealth.com.au> writes:
>> What happens if I drop an inherited column in a child table?  Maybe it
>> works, but what happens when I SELECT the column in the parent table?

> Well, what happens if you rename a column in a child table?  Same problem?

Ideally we should disallow both of those, as well as cases like
changing the column type.

It might be that we can use the pg_depend stuff to enforce this (by
setting up dependency links from child to parent).  However that would
introduce a ton of overhead in a regular DROP TABLE, and you'd still
need specialized code to prevent the RENAME case (pg_depend wouldn't
care about that).  I'm thinking that it's worth adding an attisinherited
column to pg_attribute to make these rules easy to enforce.
        regards, tom lane




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

Предыдущее
От: "Marc G. Fournier"
Дата:
Сообщение: Re: Should next release by 8.0 (Was: Re: [GENERAL] I am
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Should next release by 8.0 (Was: Re: [GENERAL] I am being interviewed by OReilly )