Re: Enum proposal / design

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: Enum proposal / design
Дата
Msg-id 200608171713.k7HHDwL17536@momjian.us
обсуждение исходный текст
Ответ на Re: Enum proposal / design  ("Jim C. Nasby" <jnasby@pervasive.com>)
Ответы Re: Enum proposal / design
Список pgsql-hackers
Jim C. Nasby wrote:
> On Wed, Aug 16, 2006 at 07:21:06PM -0400, Gregory Stark wrote:
> > This is the same issue we have with char(n) and numeric(x,y) already. If we
> > found a general solution for getting the type name to the enum would it also
> > help getting the typmod to char(n) and numeric(x,y)? Would it let us store
> > those as fixed sized data types?
> 
> Hopefully. It would be great to also have a fixed-width raw/bytea field.
> See the recent discussions about adding a guid type, etc.
> 
> How about this for a TODO:
> 
> * Allow for field widths to be stored in the catalog instead of each tuple
> 
>     Data types such as char are usually used when the user knows that a
>     field will always contain a fixed amount of data. In these cases,
>     our char implementation is wasteful, because the varlena header
>     always contains the same value. If there was a mechanism to obtain
>     field widths from the catalog there would be no need to store the
>     field width in each tuple. This would be useful for other types as
>     well (UUID and ENUM, for example).

I don't think there is concensus on adding that.

--  Bruce Momjian   bruce@momjian.us EnterpriseDB    http://www.enterprisedb.com
 + If your life is a hard drive, Christ can be your backup. +


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

Предыдущее
От: Jens-Wolfhard Schicke
Дата:
Сообщение: Re: insert/update/delete returning and rules
Следующее
От: "Jim C. Nasby"
Дата:
Сообщение: Re: Adjust autovacuum naptime automatically