Skip site navigation (1) Skip section navigation (2)

Re: How to modify ENUM datatypes?

From: "D(dot) Dante Lorenso" <dante(at)lorenso(dot)com>
To: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
Cc: Andrew Sullivan <ajs(at)crankycanuck(dot)ca>, pgsql-general(at)postgresql(dot)org
Subject: Re: How to modify ENUM datatypes?
Date: 2008-04-24 20:17:30
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-general
Alvaro Herrera wrote:
> D. Dante Lorenso wrote:
>> Or, here's another way to look at it ... make it easier to modify ENUM  
>> datatypes because we all know that you will eventually need that feature  
>> whether you males, females, and unknowns think so or not.
> Agreed.  Let's keep in mind that the current ENUM implementation is
> completely new.

Here's a use case that I doubt too many are aware of ... what's unique 
about ENUM is that the data for the ENUM becomes part of the schema of a 

This is actually something I like very much.  I have systems where the 
DEV and PROD databases are separate and must be synchronized when 
pushing out new features.  I currently use non-free tools to synchronize 
just the schemas for both databases.

Often if a new row is added to a lookup table, that row doesn't make it 
to the QA or PROD databases because it's part of the data of a table and 
is not part of the schema.  For data (like ENUM data) that should be 
consistent across databases, it helps if it gets deployed with the 
schema so that lookups will succeed properly.

-- Dante

In response to


pgsql-general by date

Next:From: Bruce MomjianDate: 2008-04-24 20:29:38
Subject: Re: How to modify ENUM datatypes?
Previous:From: Matthew T. O'ConnorDate: 2008-04-24 20:15:30
Subject: Re: How to modify ENUM datatypes?

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group