Re: BUG #8176: problem with the "ALTER TYPE name RENAME TO new_name [ CASCADE | RESTRICT ]" syntax - Mailing list pgsql-bugs

From Stephen Frost
Subject Re: BUG #8176: problem with the "ALTER TYPE name RENAME TO new_name [ CASCADE | RESTRICT ]" syntax
Date
Msg-id 20130527142352.GT8597@tamriel.snowman.net
Whole thread Raw
In response to Re: BUG #8176: problem with the "ALTER TYPE name RENAME TO new_name [ CASCADE | RESTRICT ]" syntax  (Stephen Frost <sfrost@snowman.net>)
List pgsql-bugs
Maxim,

* Stephen Frost (sfrost@snowman.net) wrote:
> * maxim.boguk@gmail.com (maxim.boguk@gmail.com) wrote:
> > It seems that documentation wrong or [ CASCADE | RESTRICT ] feature of =
ALTER
> > TYPE ... RENAME TO isn't implemented.
>=20
> Actually, I'm pretty sure it's implemented but the grammar for it was
> broken during refactoring to have all the ALTER .. RENAME operations go
> through the same code paths.

Nope, I was wrong- this looks to be a documentation bug, actually.  The
documentation should be:

ALTER TYPE name RENAME ATTRIBUTE attribute_name TO new_attribute_name [ CAS=
CADE | RESTRICT ]
ALTER TYPE name RENAME TO new_name

Which makes more sense (to me at least) anyway.  Do you have a need for
this version:

ALTER TYPE name RENAME TO new_name [ CASCADE | RESTRICT ]

or were you just playing with things..?

    Thanks,

        Stephen

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #8176: problem with the "ALTER TYPE name RENAME TO new_name [ CASCADE | RESTRICT ]" syntax
Next
From: Stephen Frost
Date:
Subject: Re: BUG #8176: problem with the "ALTER TYPE name RENAME TO new_name [ CASCADE | RESTRICT ]" syntax