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

Re: Patch for ALTER TABLE / TYPE

From: NAKANO Yoshihisa <nakano(dot)yosihisa(at)jp(dot)fujitsu(dot)com>
To: pgsql-patches(at)postgresql(dot)org
Subject: Re: Patch for ALTER TABLE / TYPE
Date: 2006-01-30 01:03:26
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-patches
Tom Lane wrote:
 > After looking at the test case a bit, I have an alternate approach:
> constraints on the column will have DEPENDENCY_AUTO type, while
> constraints using the column will have DEPENDENCY_NORMAL type.
> Therefore, if we drop the NORMAL ones before the AUTO ones, that
> should be enough to fix it.  This doesn't require much extra code,
> or any extra catalog searches, since the pg_depend record is already
> available in ATExecAlterColumnType where we need to decide whether
> to stick the item on the front or back of the list.

O.K.  It seems nicer than my solution.

Please find the patch attached.  I fixed the patch to decide the order
of the list by deptype of the pg_depend record.


Attachment: tablecmds.c.patch
Description: text/plain (2.5 KB)

In response to


pgsql-patches by date

Next:From: Mark WoodwardDate: 2006-01-30 02:27:19
Subject: Re: Want to add to contrib.... xmldbx
Previous:From: David FetterDate: 2006-01-30 01:03:02
Subject: Re: [PATCHES] BUG #2221: Bad delimiters allowed in COPY ... TO

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