Re: Optimizer not using index on 120M row table

Поиск
Список
Период
Сортировка
От Jim C. Nasby
Тема Re: Optimizer not using index on 120M row table
Дата
Msg-id 20030407232941.P31861@flake.decibel.org
обсуждение исходный текст
Ответ на Re: Optimizer not using index on 120M row table  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Optimizer not using index on 120M row table  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
On Tue, Apr 08, 2003 at 12:02:55AM -0400, Tom Lane wrote:
> The authoritative reference is pg_type.typalign ... see
> http://www.ca.postgresql.org/users-lounge/docs/7.3/postgres/catalog-pg-type.html
> In this example, your next field requires integer alignment, so the
> two bytes "saved" by using smallint disappear into the padding.

Thanks, makes sense to me now. Next question... will pgsql intelligently
order things in an item record so that they're stored most efficiently?
ie: group all the byte-align stuff together, all the 2-byte aligned
stuff, etc.? Or will it just go off of the order defined in the create
table statement? If it's the later, is there any way to re-organize
things without rebuilding the table from scratch? What other things
should be considered for column ordering?

Thanks!
--
Jim C. Nasby (aka Decibel!)                    jim@nasby.net
Member: Triangle Fraternity, Sports Car Club of America
Give your computer some brain candy! www.distributed.net Team #1828

Windows: "Where do you want to go today?"
Linux: "Where do you want to go tomorrow?"
FreeBSD: "Are you guys coming, or what?"


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

Предыдущее
От: Neil Conway
Дата:
Сообщение: Re: Optimizer not using index on 120M row table
Следующее
От: "Jim C. Nasby"
Дата:
Сообщение: Re: Optimizer not using index on 120M row table