pgsql: Allow new values to be added to an existing enum type.

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Allow new values to be added to an existing enum type.
Date: 2010-10-25 03:06:21
Message-ID: E1PADO9-0003ND-NU@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Allow new values to be added to an existing enum type.

After much expenditure of effort, we've got this to the point where the
performance penalty is pretty minimal in typical cases.

Andrew Dunstan, reviewed by Brendan Jurd, Dean Rasheed, and Tom Lane

Branch
------
master

Details
-------
http://git.postgresql.org/gitweb?p=postgresql.git;a=commitdiff;h=84c123be1de8a9955741e20c9f945571e40c545e

Modified Files
--------------
contrib/pg_upgrade/function.c | 2 +-
contrib/pg_upgrade_support/pg_upgrade_support.c | 19 +-
doc/src/sgml/catalogs.sgml | 34 ++-
doc/src/sgml/ref/alter_type.sgml | 67 ++++-
src/backend/catalog/pg_enum.c | 402 +++++++++++++++++++++--
src/backend/commands/typecmds.c | 73 ++++-
src/backend/nodes/copyfuncs.c | 16 +
src/backend/nodes/equalfuncs.c | 14 +
src/backend/parser/gram.y | 41 +++-
src/backend/tcop/utility.c | 19 +
src/backend/utils/adt/enum.c | 259 ++++++++++-----
src/backend/utils/cache/typcache.c | 322 ++++++++++++++++++
src/bin/pg_dump/pg_dump.c | 33 ++-
src/bin/psql/describe.c | 14 +-
src/include/catalog/catversion.h | 2 +-
src/include/catalog/indexing.h | 2 +
src/include/catalog/pg_enum.h | 11 +-
src/include/commands/typecmds.h | 1 +
src/include/nodes/nodes.h | 1 +
src/include/nodes/parsenodes.h | 12 +
src/include/utils/typcache.h | 11 +
src/test/regress/expected/enum.out | 153 +++++++++-
src/test/regress/sql/enum.sql | 86 +++++
23 files changed, 1423 insertions(+), 171 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Andrew Dunstan 2010-10-25 03:55:34 pgsql: Remove unnecessary use of trigger flag to hash plperl functions
Previous Message User Fxjr 2010-10-24 19:32:58 npgsql - Npgsql2: [#1010921] Data corrupted transferring bytea data