Re: [HACKERS] enumeration type?
Tom Lane writes: > ENUMs do seem to have some advantages in convenience though. And > providing them or something closely comparable would ease porting > from MySQL ... which is an important consideration in our plan for > world domination ;-) Now that domains have check constraints, I think enumerations can be easily created without having to invent nonstandard features. There's also the advantage that you can create domains out of data types other than text. -- Peter Eisentraut [EMAIL PROTECTED] ---(end of broadcast)--- TIP 2: you can get off all lists at once with the unregister command (send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])
Re: [HACKERS] enumeration type?
"Christopher Kings-Lynne" <[EMAIL PROTECTED]> writes: > MySQL made up ENUMs out of whole cloth...they > should copy our way, not us theirs... ENUMs do seem to have some advantages in convenience though. And providing them or something closely comparable would ease porting from MySQL ... which is an important consideration in our plan for world domination ;-) In short I wouldn't object to having this on the TODO list. It's just not real high priority in my mind. regards, tom lane ---(end of broadcast)--- TIP 9: the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match
Re: [HACKERS] enumeration type?
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... Chris - 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 functions, > 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