Fix ALTER COLUMN TYPE to preserve the tablespace and reloptions of indexes
authorTom Lane <[email protected]>
Sat, 13 Oct 2007 15:55:49 +0000 (15:55 +0000)
committerTom Lane <[email protected]>
Sat, 13 Oct 2007 15:55:49 +0000 (15:55 +0000)
commit53d7f0e8882eadb724e1bffc1adb529feb87db2a
treef05d89e77ff2cfc627b6acf65a49da940689c84f
parentb3be84e3a43a6fa3077bf0ec4ad3d25ce156466b
Fix ALTER COLUMN TYPE to preserve the tablespace and reloptions of indexes
it affects.  The original coding neglected tablespace entirely (causing
the indexes to move to the database's default tablespace) and for an index
belonging to a UNIQUE or PRIMARY KEY constraint, it would actually try to
assign the parent table's reloptions to the index :-(.  Per bug #3672 and
subsequent investigation.

8.0 and 8.1 did not have reloptions, but the tablespace bug is present.
src/backend/utils/adt/ruleutils.c
src/backend/utils/cache/lsyscache.c
src/include/utils/lsyscache.h