Received: from localhost (unknown [200.46.204.183]) by mail.postgresql.org (Postfix) with ESMTP id E39A7650088 for ; Tue, 2 Dec 2008 10:12:51 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 07009-04 for ; Tue, 2 Dec 2008 10:12:48 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from 42.mail-out.ovh.net (42.mail-out.ovh.net [213.251.189.42]) by mail.postgresql.org (Postfix) with SMTP id 8579E64FE2B for ; Tue, 2 Dec 2008 10:12:48 -0400 (AST) Received: (qmail 26845 invoked by uid 503); 2 Dec 2008 14:12:27 -0000 Received: from b6.ovh.net (HELO mail412.ha.ovh.net) (213.186.33.56) by 42.mail-out.ovh.net with SMTP; 2 Dec 2008 14:12:27 -0000 Received: from b0.ovh.net (HELO queue-out) (213.186.33.50) by b0.ovh.net with SMTP; 2 Dec 2008 14:12:45 -0000 Received: from par69-8-88-161-102-87.fbx.proxad.net (HELO soyouz) (88.161.102.87) by ns0.ovh.net with SMTP; 2 Dec 2008 14:12:44 -0000 Date: Tue, 02 Dec 2008 15:13:50 +0100 To: Andrus , pgsql-performance@postgresql.org Subject: Re: analyzing intermediate query From: PFC Content-Type: text/plain; format=flowed; delsp=yes; charset=utf-8 MIME-Version: 1.0 References: Content-Transfer-Encoding: 7bit Message-ID: In-Reply-To: User-Agent: Opera Mail/9.62 (Linux) X-Ovh-Tracer-Id: 4781696905700836998 X-Ovh-Remote: 88.161.102.87 (par69-8-88-161-102-87.fbx.proxad.net) X-Ovh-Local: 213.186.33.20 (ns0.ovh.net) X-Spam-Check: DONE|H 0.5/N X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests=none X-Spam-Level: X-Archive-Number: 200812/12 X-Sequence-Number: 32048 > My list can contain 1 .. 100000 records and table contains 3000000 > records and is growing. Ah. No IN(), then ;) Temp table + ANALYZE seems your only option...