Re: CREATE LIKE INCLUDING COMMENTS and STORAGES

Поиск
Список
Период
Сортировка
От Itagaki Takahiro
Тема Re: CREATE LIKE INCLUDING COMMENTS and STORAGES
Дата
Msg-id 20090928111746.927F.52131E4D@oss.ntt.co.jp
обсуждение исходный текст
Ответ на Re: CREATE LIKE INCLUDING COMMENTS and STORAGES  (Brendan Jurd <direvus@gmail.com>)
Ответы Re: CREATE LIKE INCLUDING COMMENTS and STORAGES  (Brendan Jurd <direvus@gmail.com>)
Список pgsql-hackers
Brendan Jurd <direvus@gmail.com> wrote:

> I am doing an initial review of your patch.

Thank you for reviewing.
I merged your fix and add INCLUDING ALL option to the new patch.
I changed InhRelation.options to be a bitmap of CreateStmtLikeOption.
INCLUDING just adds bits, and EXCLUDING drops bits.

Now this patch adds:
    * CREATE TABLE LIKE ... INCLUDING COMMENTS (for columns and constraints)
    * CREATE TABLE LIKE ... INCLUDING STORAGE
    * CREATE TABLE LIKE ... INCLUDING ALL

> I think I'm failing to understand why this would be an issue.  Why
> would the user be specifying columns in the CREATE TABLE statement
> that already exist in the table they are cloning?

Without inline-STORAGE syntax, we cannot resolve conflictions of
storage parameters unless we can define tables without STORAGE
and then re-add options with ALTER TABLE.

There might be ToDo items:
    * Make INCLUDING COMMENTS also copy comments on indexes.
    * Add syntax to define storage options inline like
      CREATE TABLE tbl (col text STORAGE MAIN).

Regards,
---
ITAGAKI Takahiro
NTT Open Source Software Center


Вложения

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: TODO item: Allow more complex user/database default GUC settings
Следующее
От: Robert Haas
Дата:
Сообщение: Re: operator exclusion constraints