Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id 277281337B5C for ; Wed, 27 Oct 2010 16:43:22 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 20374-09 for ; Wed, 27 Oct 2010 19:43:15 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by mail.postgresql.org (Postfix) with ESMTP id 93C191336FA7 for ; Wed, 27 Oct 2010 16:43:14 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.2/8.14.2) with ESMTP id o9RJhDpU026191; Wed, 27 Oct 2010 15:43:13 -0400 (EDT) To: Jon Nelson cc: pgsql-performance@postgresql.org Subject: Re: temporary tables, indexes, and query plans In-reply-to: References: <4CC864F8.3060801@vmsinfo.com> <7C0800F63CCF4149AC0FC5EE2A041226D52361@sr002-2k3exc.ateb.com> Comments: In-reply-to Jon Nelson message dated "Wed, 27 Oct 2010 13:52:05 -0500" Date: Wed, 27 Oct 2010 15:43:13 -0400 Message-ID: <26190.1288208593@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.91 tagged_above=-10 required=5 tests=BAYES_00=-1.9, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201010/504 X-Sequence-Number: 40922 Jon Nelson writes: > The most recent experiment shows me that, unless I create whatever > indexes I would like to see used *before* the large (first) update, > then they just don't get used. At all. You're making a whole lot of assertions here that don't square with usual experience. I think there is some detail about what you're doing that affects the outcome, but since you haven't shown a concrete example, it's pretty hard to guess what the critical detail is. regards, tom lane