By gst
via people.planetpostgresql.org
Published: Sep 17 2007 / 12:36
I've never been a big fan of enum types in databases. In my experience, they are often used in places where other datatypes are more appropriate (true/false text vs. boolean), or used in ways that a better served with either a more relational design (a list of options that should be in a lookup table, so that additions are dml operations, not ddl operations), or a more object-relational design, such as using a domain, so that the constraints are declared in a single place and used consistently throught the database. So when the enum type feature was discussed for 8.3, I didn't get too excited, but I also didn't object because I knew there was at least 1 use case that it would solve that isn't handled well by the other methods available.



Add your comment