Single Byte values

Поиск
Список
Период
Сортировка
От Jason Hihn
Тема Single Byte values
Дата
Msg-id NGBBLHANMLKMHPDGJGAPEEHKCGAA.jhihn@paytimepayroll.com
обсуждение исходный текст
Ответы Re: Single Byte values
Re: Single Byte values
Список pgsql-general
As someone pointed out, CHAR(1) costs 5 bytes. Is there a better way to
store it? I can see one or three bytes as being bad (byte-alignment issues
and speed) Two could be ok, but at the very least 4 should be the max for
char(1).

Two is ok, once you consider multi-bytes strings (unicode)
Three is right out -
Four bytes could store two multibyte, two single byte (cast as 2 byte for
unicode) or four single byte characters.

But in returning to my question, what should I be using for char(1) to
char(4) storage?

Thanks again!


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