Received: from smtp010.mail.yahoo.com (smtp010.mail.yahoo.com [216.136.173.30]) by mail.postgresql.org (8.11.3/8.11.1) with SMTP id f2PD6uw14546 for ; Sun, 25 Mar 2001 08:06:56 -0500 (EST) (envelope-from janwieck@yahoo.com) Received: from pd957740d.dip.t-dialin.net (HELO jupiter.jw.home) (217.87.116.13) by smtp.mail.vip.sc5.yahoo.com with SMTP; 25 Mar 2001 13:06:52 -0000 X-Apparently-From: Received: (from janwieck@localhost) by jupiter.jw.home (8.9.3/8.9.3) id HAA24194; Sun, 25 Mar 2001 07:57:14 -0500 From: Jan Wieck Message-Id: <200103251257.HAA24194@jupiter.jw.home> Subject: Re: all views in database broken at once In-Reply-To: <10008.985481400@sss.pgh.pa.us> from Tom Lane at "Mar 24, 2001 07:50:00 pm" To: Tom Lane Date: Sun, 25 Mar 2001 07:57:14 -0500 (EST) CC: Andrew Perrin , pgsql-sql@postgresql.org X-Mailer: ELM [version 2.4ME+ PL68 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Archive-Number: 200103/487 X-Sequence-Number: 2158 Tom Lane wrote: > Andrew Perrin writes: > > But I'm intrigued: what is it that causes this? Is it *my* > > recreating the view on which the other views depend, > > Yes. You dropped and recreated the view --- the new version may have > the same name but it's not the same OID, so it isn't the same object. > And the other views refer to it by OID. > > The ultimate solution should have two parts, IMHO: > > 1. Dependency checking so that you *can't* drop a view that is still > referenced. However this will not be complete --- it's not clear that > we can detect references inside PL functions, for example. PL's aren't too critical. A simple reconnect will whipe out all SPI plans in PL functions and RI triggers, so they'll notice the changes. Jan -- #======================================================================# # It's easier to get forgiveness for being wrong than for being right. # # Let's break this rule - forgive me. # #================================================== JanWieck@Yahoo.com # _________________________________________________________ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com