Received: from localhost (maia-2.hub.org [200.46.204.187]) by postgresql.org (Postfix) with ESMTP id 0715C9FB8F0 for ; Sat, 30 Jun 2007 02:43:52 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.187]) (amavisd-maia, port 10024) with ESMTP id 90794-08 for ; Sat, 30 Jun 2007 02:43:45 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from mailbox.samurai.com (mailbox.samurai.com [205.207.28.82]) by postgresql.org (Postfix) with ESMTP id 364329FB8EA for ; Sat, 30 Jun 2007 02:43:47 -0300 (ADT) Received: from localhost (mailbox.samurai.com [205.207.28.82]) by mailbox.samurai.com (Postfix) with ESMTP id AB94B61D59; Sat, 30 Jun 2007 01:43:46 -0400 (EDT) X-Virus-Scanned: by amavisd-new at mailbox.samurai.com Received: from mailbox.samurai.com ([205.207.28.82]) by localhost (mailbox.samurai.com [205.207.28.82]) (amavisd-new, port 10024) with LMTP id UNS+7u+jm3TE; Sat, 30 Jun 2007 01:43:44 -0400 (EDT) Received: from [192.168.1.167] (adsl-76-225-157-29.dsl.pltn13.sbcglobal.net [76.225.157.29]) (using TLSv1 with cipher RC4-MD5 (128/128 bits)) (No client certificate requested) by mailbox.samurai.com (Postfix) with ESMTP id BDF7461D1B; Sat, 30 Jun 2007 01:43:43 -0400 (EDT) Subject: Re: rename of a view From: Neil Conway To: Tom Lane Cc: Euler Taveira de Oliveira , David Fetter , Susanne Ebrecht , pgsql-docs@postgresql.org In-Reply-To: <15084.1183181782@sss.pgh.pa.us> References: <46839C05.7050307@miracee.de> <3450.1183040211@sss.pgh.pa.us> <20070629183219.GO7636@fetter.org> <20070630001653.GQ7636@fetter.org> <4685D8C8.2070808@timbira.com> <12776.1183177571@sss.pgh.pa.us> <1183181585.20942.1.camel@goldbach> <15084.1183181782@sss.pgh.pa.us> Content-Type: text/plain Date: Fri, 29 Jun 2007 22:43:41 -0700 Message-Id: <1183182221.20942.8.camel@goldbach> Mime-Version: 1.0 X-Mailer: Evolution 2.10.1 Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200706/37 X-Sequence-Number: 4326 On Sat, 2007-30-06 at 01:36 -0400, Tom Lane wrote: > No objection to that; it'd square with our treatment of TYPE and DOMAIN > commands. What I'm wondering though is whether the whole patch has > a reason to live at all, as compared to documenting someplace more > prominent than now that ALTER TABLE works on views & sequences. Using ALTER TABLE to rename views and sequences is quite counter- intuitive, and has been a repeated source of confusion for users. Sure, we can document that behavior more prominently, but it seems to me it would be more straightforward in the long-run to just make the system behave more intuitively in the first place. As an added bonus, it takes very little new code to implement. For the ALTER SEQUENCE case, I think it's also a little weird to have an ALTER SEQUENCE command that modifies some of the properties of a sequence, but not the sequence's name. While that argument doesn't apply to ALTER VIEW at the moment, recent history suggests that it may only be a matter of time before we need to add an ALTER VIEW command anyway... (for instance, to control the properties of materialized or updateable views). -Neil