Re: One byte integer support

From: Kris Jurka <books(at)ejurka(dot)com>
To: Keith Hankin <keith105(at)yahoo(dot)com>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: One byte integer support
Date: 2005-01-07 20:59:07
Message-ID: Pine.BSO.4.56.0501071548420.30405@leary.csoft.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: 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

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Tom Lane 2005-01-07 21:01:38 Re: One byte integer support
Previous Message Keith Hankin 2005-01-07 20:39:16 Re: One byte integer support