Re: Support of INHERIT in existing tables (8.2+ releases)

Поиск
Список
Период
Сортировка
От Dave Page
Тема Re: Support of INHERIT in existing tables (8.2+ releases)
Дата
Msg-id 937d27e10807140121m7b9dabfbq90b9e42b591ef946@mail.gmail.com
обсуждение исходный текст
Ответ на Support of INHERIT in existing tables (8.2+ releases)  (Guillaume Lelarge <guillaume@lelarge.info>)
Ответы Re: Support of INHERIT in existing tables (8.2+ releases)  (Guillaume Lelarge <guillaume@lelarge.info>)
Список pgadmin-hackers
On Fri, Jul 11, 2008 at 11:30 PM, Guillaume Lelarge
<guillaume@lelarge.info> wrote:

> So, here is a patch to add support on adding inherited tables on already
> existing tables. The feature is available since PostgreSQL 8.2 release.
>
> Tested on Linux. It works fine there. I didn't check Win32 platform because
> I didn't change any xrc files :) Didn't check on Mac OS X either cause I
> don't have one (btw, I'm following ebay's Mac Mini list to get one soon).

Hmm, testing on 8.3.3 on Windows, I created parent and child table,
then tried to add parent to child's inherit list separately and got:

ERROR:  syntax error at or near "from"
LINE 1: ALTER TABLE child ADD COLUMN id Inherited from table ...

The actual SQL generated is:

ALTER TABLE child ADD COLUMN id Inherited from table parent;
ALTER TABLE child INHERIT parent;

Shouldn't it just be doing:

ALTER TABLE child INHERIT parent;


--
Dave Page
EnterpriseDB UK: http://www.enterprisedb.com

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

Предыдущее
От: "Maheswari Selvam"
Дата:
Сообщение: Need a help
Следующее
От: Guillaume Lelarge
Дата:
Сообщение: Re: Support of INHERIT in existing tables (8.2+ releases)