Re: How to modify ENUM datatypes?

From: Andreas 'ads' Scherbaum <adsmail(at)wars-nicht(dot)de>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: How to modify ENUM datatypes?
Date: 2008-04-24 21:43:26
Message-ID: 20080424234326.0d5f4630@iridium.wars-nicht.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Thu, 24 Apr 2008 14:02:07 -0400 Merlin Moncure wrote:

> On Thu, Apr 24, 2008 at 12:22 PM, Andrew Sullivan <ajs(at)crankycanuck(dot)ca> wrote:
> > The first time I encountered them, I thought enums were a filthy,
> > ill-conceived answer to a problem that didn't exist, implemented by people
> > who didn't understand relational databases. With considerably more
> > experience under my belt than then, I say now that my original estimation
> > was too kind.
>
> I think you're being a little too hard on enums here.

No, i don't think, Andrew is too hard here.

As said before: in some special cases enum makes sense, like you said:

> I was actually in the anti-enum camp until it was demonstrated to me
> (and in my own testing) that using enum for natural ordering vs. fielding the
> ordering of the type out to a join is can be a huge win in such cases
> where it is important.

But the problem are really not this special cases, the real problem are
all the people who don't understand about enum and just try to use it
because "it seems to fit best" - unless they run into problems.

So we have a good tool in your hands, we just have to tell/teach the
people, how to use it and especially when not to use it.

Kind regards

--
Andreas 'ads' Scherbaum
German PostgreSQL User Group

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Erik Jones 2008-04-24 21:55:05 Confused by result of pg_catalog.format_type()
Previous Message Rhys Stewart 2008-04-24 21:43:23 Re: query question really cant give a summary here so read the body ; -)