X-Original-To: pgsql-performance@postgresql.org Received: from spampd.localdomain (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id EA08C47635A for ; Wed, 7 May 2003 11:54:03 -0400 (EDT) Received: from mail1.ihs.com (mail1.ihs.com [170.207.70.222]) by postgresql.org (Postfix) with ESMTP id C160F4764A7 for ; Wed, 7 May 2003 11:53:35 -0400 (EDT) Received: from css120.ihs.com (css120.ihs.com [170.207.105.120]) by mail1.ihs.com (8.12.9/8.12.9) with ESMTP id h47Fpw5g001137; Wed, 7 May 2003 09:51:58 -0600 (MDT) Date: Wed, 7 May 2003 09:42:27 -0600 (MDT) From: "scott.marlowe" To: Achilleus Mantzios Cc: Subject: Re: An unresolved performance problem. In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-MailScanner: Found to be clean X-MailScanner-SpamCheck: X-Spam-Status: No, hits=-32.3 required=5.0 tests=BAYES_01,EMAIL_ATTRIBUTION,IN_REP_TO,QUOTED_EMAIL_TEXT, QUOTE_TWICE_1,REPLY_WITH_QUOTES,USER_AGENT_PINE autolearn=ham version=2.50 X-Spam-Level: X-Spam-Checker-Version: SpamAssassin 2.50 (1.173-2003-02-20-exp) X-Archive-Number: 200305/82 X-Sequence-Number: 1861 On Wed, 7 May 2003, Achilleus Mantzios wrote: > > Hi, few days ago, i posted some really wierd (at least to me) > situation (maybe a potentian bug) to the performance and bugs list > and to some core hacker(s) privately as well, > and i got no response. > Moreover i asked for some feedback > in order to understand/fix the problem myself, > and again received no response. > > What i asked was pretty simple: > "1. Is it possible that the absense of statistics make the planer produce > better plans > than in the case of statistcs generated with vacuum > analyze/analyze? One of the common examples of this happening was posted a few weeks back. someone was basically doing this: delete from table; analyze table; insert into table (1,000,000 times); the problem was that the table had fk constraints to another table, and the query planner for the inserts (all 1,000,000 of them) assumed it was inserting into a mostly empty table, and therefore used seq scans instead of index scans. It's not a bug, not quite a feature, just a corner case.