Re: Cascaded Column Drop
От | Tom Lane |
---|---|
Тема | Re: Cascaded Column Drop |
Дата | |
Msg-id | 21519.1033105417@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | Re: Cascaded Column Drop (Alvaro Herrera <alvherre@atentus.com>) |
Список | pgsql-patches |
Alvaro Herrera <alvherre@atentus.com> writes: > But think about the inheritance case again: suppose > create table p (f1 int); > create table c (f2 int) inherits (p); > Now you just change your mind and want to drop p but not c. You can't > do it because f1 is the last column on it, and c inherits it. So a way > to drop the last column inherited (thus freeing the dependency on p) > makes c independent, and you can drop p. Hmm, no I don't think so. Parent-to-child dependence is a property of the two tables, not of their columns, and should not go away just because you reduce the parent to zero columns. I would expect that if I dropped p.f1 (assuming this were allowed) and then added p.g1, that c would also now have c.g1. So the parent/child relationship outlives any specific column ... IMHO anyway. regards, tom lane
В списке pgsql-patches по дате отправления: