Received: from localhost (maia-5.hub.org [200.46.204.182]) by postgresql.org (Postfix) with ESMTP id B3FE99F9F47 for ; Tue, 26 Dec 2006 06:54:28 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.182]) (amavisd-new, port 10024) with ESMTP id 03610-10 for ; Tue, 26 Dec 2006 06:54:11 -0400 (AST) X-Greylist: delayed 13:02:01.756122 by SQLgrey-1.7.4 Received: from cicero0.cybercity.dk (cicero0.cybercity.dk [212.242.40.52]) by postgresql.org (Postfix) with ESMTP id B316C9F9F2C for ; Tue, 26 Dec 2006 06:54:20 -0400 (AST) Received: from agile.dk (0x3e42da3b.adsl.cybercity.dk [62.66.218.59]) by cicero0.cybercity.dk (Postfix) with ESMTP id E7D4667C048 for ; Tue, 26 Dec 2006 11:54:15 +0100 (CET) Received: from nc (unknown [192.1.1.100]) by agile.dk (Postfix) with ESMTP id C3E7930C94 for ; Tue, 26 Dec 2006 11:54:14 +0100 (CET) From: "Jan Andersen" To: Subject: Re: Related tables to a view Date: Tue, 26 Dec 2006 11:54:14 +0100 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook, Build 11.0.5510 In-Reply-To: <20061226041029.GA61490@winnie.fuhr.org> thread-index: Accoo9pDKP/pN5KET4urTwINpnVMHAAOEGLQ X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3028 Message-Id: <20061226105414.C3E7930C94@agile.dk> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.136 tagged_above=0 required=5 tests=BAYES_50, FORGED_RCVD_HELO X-Spam-Level: X-Archive-Number: 200612/171 X-Sequence-Number: 27127 > You could query pg_depend to find out which tables and columns the > view's rewrite rule depends on but that's not as specific as what > you're requesting. I'm not aware of a way to associate a particular > table column with a particular view column short of parsing the view > definition or rule action; doing so would have to allow for the > possibility of a view column deriving its value from an arbitrarily > complex expression involving multiple tables, subqueries, etc. Yes I'm aware of the "problem" about arbitrary or scalar values but this is not a problem in this specific case. If a field or value do not have a table reference then it is not needed in the resultset. I only need those values which have a direct connection to a table. Is the only possible way then to analyse the description field in pg_view? I was hoping for a more simple way to get the needed result. Regards Jan Andersen