Re: unsigned types

Поиск
Список
Период
Сортировка
Искать
От
Neil Conway
Тема
Re: unsigned types
Дата
Msg-id
1129658457.8219.59.camel@localhost.localdomain
Ответ на
Re: unsigned types (Jim C. Nasby)
Список
Дерево обсуждения
unsigned types jeff sacksteder <jsacksteder@gmail.com>
Re: unsigned types Neil Conway <neilc@samurai.com>
Re: unsigned types jeff sacksteder <jsacksteder@gmail.com>
Re: unsigned types Jeff Davis <jdavis-pgsql@empires.org>
Re: unsigned types "Jim C. Nasby" <jnasby@pervasive.com>
Re: unsigned types Neil Conway <neilc@samurai.com>
Re: unsigned types Tom Lane <tgl@sss.pgh.pa.us>
Re: unsigned types Greg Stark <gsstark@mit.edu>
Re: unsigned types Martijn van Oosterhout <kleptog@svana.org>
Re: unsigned types Michael Glaesemann <grzm@myrealbox.com>
On Mon, 2005-17-10 at 12:25 -0500, Jim C. Nasby wrote:
> So, if you have a bunch of int2's all next to each other in a table,
> they will happily just consume 2 bytes. The issue comes when you try
> and mix them with other fields randomly, since many other fields
> require int alignment. 

We could improve on this by reordering fields on-disk to reduce
alignment/padding requirements, during CREATE TABLE. We'd need to be
sure to present the same column order back to the client application, of
course, but that should be possible. The notion of a "physical column
number" (on-disk position of the column) as well as a "logical column
numer" (position of the column in the table -- e.g. in SELECT *
expansion) would also make it easy to implement column reordering in
ALTER TABLE, which has been requested a few times.

-Neil


В списке pgsql-general по дате отправления
От: Onyx
Дата:
От: Martijn van Oosterhout
Дата:
Сообщение: Re: unsigned types
FAQ