Re: column ordering, was Re: [PATCHES] Enums patch v2

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: column ordering, was Re: [PATCHES] Enums patch v2
Дата
Msg-id 20900.1166720387@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: column ordering, was Re: [PATCHES] Enums patch v2  (Martijn van Oosterhout <kleptog@svana.org>)
Список pgsql-hackers
Martijn van Oosterhout <kleptog@svana.org> writes:
> I was envisiging the physical number to be fixed and immutable (ie
> storage position = permanent position).

There are two different problems being discussed here, and one of them
is insoluble if we take that position: people would like the system to
automatically lay out tables to minimize alignment overhead and access
costs (eg, put fixed-width columns first).  This is not the same as
"I would like to change the display column order".

It's true that for an ADD COLUMN that doesn't already force a table
rewrite, forcing one to improve packing is probably bad.  My thought
would be that we leave the column storage order alone if we don't have
to rewrite the table ... but any rewriting variant of ALTER TABLE could
optimize the storage order while it was at it.
        regards, tom lane


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

Предыдущее
От: Andrew Dunstan
Дата:
Сообщение: Re: Release 8.2.0 done, 8.3 development starts
Следующее
От: Andrew Dunstan
Дата:
Сообщение: Re: column ordering, was Re: [PATCHES] Enums patch v2