X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id C4F8BD1CF5B for ; Sat, 5 Jun 2004 14:40:36 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 25736-07 for ; Sat, 5 Jun 2004 17:40:26 +0000 (GMT) Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by svr1.postgresql.org (Postfix) with ESMTP id 3DA29D1CCBD for ; Sat, 5 Jun 2004 14:36:40 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.12.11/8.12.11) with ESMTP id i55HaULh024846; Sat, 5 Jun 2004 13:36:30 -0400 (EDT) To: Laurent Martelli Cc: pgsql-performance@postgresql.org Subject: Re: Unused table of view In-reply-to: <87y8n2t6jd.fsf@stan.aopsys.com> References: <87y8n2t6jd.fsf@stan.aopsys.com> Comments: In-reply-to Laurent Martelli message dated "Sat, 05 Jun 2004 16:37:26 +0200" Date: Sat, 05 Jun 2004 13:36:30 -0400 Message-ID: <24845.1086456990@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200406/45 X-Sequence-Number: 7103 Laurent Martelli writes: > The pictures table is scanned, but it's not needed. Yes it is. For example, if pictures is empty then the view yields zero rows. Omitting the join to pictures could give a different result. regards, tom lane