Re: Eliminating phase 3 requirement for varlen increases via ALTER COLUMN

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Eliminating phase 3 requirement for varlen increases via ALTER COLUMN
Дата
Msg-id 24363.1161891471@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Eliminating phase 3 requirement for varlen increases via ALTER COLUMN  ("Jonah H. Harris" <jonah.harris@gmail.com>)
Ответы Re: Eliminating phase 3 requirement for varlen increases via ALTER COLUMN  ("Jonah H. Harris" <jonah.harris@gmail.com>)
Список pgsql-patches
"Jonah H. Harris" <jonah.harris@gmail.com> writes:
> The attached patch handles the simple case where a user wants to
> increase the user-defined storage size of a variable length object,
> such as VARCHAR or NUMERIC, without having to rebuild the table.

This makes some really quite unacceptable assumptions about the meaning
and encoding of typmod; in fact I don't believe it's even correct for
NUMERIC, which uses a two-field encoding in typmod.  NUMERIC(18,2) to
NUMERIC(20,0) cannot be a work-free conversion.  Given the plans to
allow user-defined types to have their own interpretation of typmod,
you can't just blithely assume you know the semantics of a typmod change.

I'm also wondering what's the point of comparing attbyval etc when
you've already checked it's the same type OID.

            regards, tom lane

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: GUC description cleanup
Следующее
От: "Jonah H. Harris"
Дата:
Сообщение: Re: Eliminating phase 3 requirement for varlen increases via ALTER COLUMN