Re: One byte integer support

Поиск
Список
Период
Сортировка
От Kris Jurka
Тема Re: One byte integer support
Дата
Msg-id Pine.BSO.4.56.0501071548420.30405@leary.csoft.net
обсуждение исходный текст
Ответ на Re: One byte integer support  (Keith Hankin <keith105@yahoo.com>)
Список pgsql-jdbc

On Fri, 7 Jan 2005, Keith Hankin wrote:

> But Postgres 'char' is just an alias for 'character',

Note that I did not say char.  I said "char".

db=# create table t (a char, b "char");
CREATE TABLE
db=# \d t
         Table "public.t"
 Column |     Type     | Modifiers
--------+--------------+-----------
 a      | character(1) |
 b      | "char"       |



> I don't understand why Postgres doesn't have a single-byte int support.
>

Postgresql's extensible type system allows users to create any number of
their own types.  One drawback of this flexibility is that it makes it
difficult to interpret what type a raw number is.  What type is 37? int2,
int4, int8?  Up until recently there were significant problems that
occurred if you got this wrong and people aren't rushing to add new types
that could resurrect those unhappy times.  This is also why postgresql
does not have unsigned types.

Kris Jurka

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

Предыдущее
От: Keith Hankin
Дата:
Сообщение: Re: One byte integer support
Следующее
От: "Julie Cottin"
Дата:
Сообщение: Driver Information-PostgreSQL 8