There is no such thing as an enumeration type.  What there is is the char
type with a CHECK constraint. MySQL made up ENUMs out of whole cloth...they
should copy our way, not us theirs...


----- Original Message ----- 
From: "Andrew Dunstan" <[EMAIL PROTECTED]>
To: "PostgreSQL Hackers Mailing List" <[EMAIL PROTECTED]>
Sent: Sunday, June 15, 2003 4:49 AM
Subject: [HACKERS] enumeration type?

> This occurred to me yesterday as I was designing a little Db.
> Has anyone thought about support for a simple enumeration type creation
> mechanism? I know I could do it with CREATE TYPE and input/output
> but that does seem like a lot of work for a smallish thing.
> As it is, I settled on a char type with some constraint checking, but
> couldn't help thinking how nice a simple enumeration would have been.
> andrew
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend

Reply via email to