Poor-man's enumeration type

From: Keith Worthington <KeithW(at)NarrowPathInc(dot)com>
To: PostgreSQL Novice <pgsql-novice(at)postgresql(dot)org>
Subject: Poor-man's enumeration type
Date: 2005-04-26 02:52:39
Message-ID: 426DACF7.1040004@NarrowPathInc.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Hi All,

I found this in the documentation.
http://www.postgresql.org/docs/8.0/interactive/datatype-character.html

The type "char" (note the quotes) is different
from char(1)in that it only uses one byte of
storage. It is internally used in the system
catalogs as a poor-man's enumeration type.

Is this a SQL standard data type? Can I expect this type
to be supported in PostgreSQL 'forever'? I need an enum
type and obviously this works. At the moment I am not
faced with an imminent port but I hate to back myself into
a corner if I do not have to.

--
Kind Regards,
Keith

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message Bruce Momjian 2005-04-26 02:57:57 Re: Poor-man's enumeration type
Previous Message Tom Lane 2005-04-25 21:08:49 Re: audit information