Re: bug in 7.4 SET WITHOUT OIDs

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Hackers <pgsql-hackers(at)postgresql(dot)org>, Rod Taylor <rbt(at)rbt(dot)ca>
Subject: Re: bug in 7.4 SET WITHOUT OIDs
Date: 2004-03-23 17:22:26
Message-ID: 200403231722.i2NHMQl16668@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Christopher Kings-Lynne wrote:
> >>Maybe it needs CASCADE/RESTRICT added?
> >
> > Seems like overkill, considering that this is a very marginal feature.
> > I'm happy to decree that it works in whichever way is the easiest to
> > implement.
>
> In that case, it seems to me that it has to be default RESTRICT. If
> anything depend on it, it must fail. Otherwise when you do it, it could
> drop views, functions, everything.

Seems it should behave just like dropping a column of a table that
already has an index on it:

test=> CREATE TABLE test(x int, y int);
CREATE TABLE
test=> CREATE INDEX ii ON test(y);
CREATE INDEX
test=> ALTER TABLE test DROP COLUMN y;
ALTER TABLE
test=> \d test
Table "public.test"
Column | Type | Modifiers
--------+---------+-----------
x | integer |

which I think means drop the index automatically.

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2004-03-23 17:29:46 Re: bug in 7.4 SET WITHOUT OIDs
Previous Message Dustin Sallings 2004-03-23 17:18:11 Re: linked list rewrite