Re: Is this a bug? Deleting a column deletes the constraint. - Mailing list pgsql-sql

From Joe
Subject Re: Is this a bug? Deleting a column deletes the constraint.
Date
Msg-id 1160645987.51367.13.camel@pampa
Whole thread Raw
In response to Re: Is this a bug? Deleting a column deletes the constraint.  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Is this a bug? Deleting a column deletes the constraint.
List pgsql-sql
On Thu, 2006-10-12 at 01:25 -0400, Tom Lane wrote:
> It does seem like this is wrong, in view of SQL92's statement about
> ALTER TABLE DROP COLUMN:
> 
>          4) If RESTRICT is specified, then C shall not be referenced in
>             the <query expression> of any view descriptor or in the <search
>             condition> of any constraint descriptor other than a table con-
>             straint descriptor that contains references to no other column
>             and that is included in the table descriptor of T.
> 
> IOW we should only allow unique constraints to be auto-dropped if
> they reference just the one single column.  Ick.

I didn't realize before that you can also drop all columns, leaving a
table without *any* columns.  Is that a SQL92 "feature"?

Joe



pgsql-sql by date:

Previous
From: Tom Lane
Date:
Subject: Re: Is this a bug? Deleting a column deletes the constraint.
Next
From: Tom Lane
Date:
Subject: Re: Is this a bug? Deleting a column deletes the constraint.