Received: from localhost (maia-1.hub.org [200.46.204.191]) by postgresql.org (Postfix) with ESMTP id 06FD19FBD19 for ; Fri, 9 Mar 2007 12:07:32 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.191]) (amavisd-new, port 10024) with ESMTP id 04035-09 for ; Fri, 9 Mar 2007 12:07:13 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from mail.telefor.hu (mail.telefor.hu [193.68.53.97]) by postgresql.org (Postfix) with ESMTP id 31ADE9FBCF9 for ; Fri, 9 Mar 2007 12:07:09 -0400 (AST) Received: from telefor-server.int.telefor-new.hu (telefor-server.int.telefor-new.hu [10.0.20.100]) by mail.telefor.hu (Postfix) with ESMTP id 670E21C05C; Fri, 9 Mar 2007 17:07:05 +0100 (CET) Received: from [10.0.20.33] ([10.0.20.33]) by telefor-server.int.telefor-new.hu with Microsoft SMTPSVC(6.0.3790.1830); Fri, 9 Mar 2007 17:07:05 +0100 Message-ID: <45F18629.4000808@telefor.hu> Date: Fri, 09 Mar 2007 17:07:05 +0100 From: =?UTF-8?B?TWV6ZWkgWm9sdMOhbg==?= Organization: Telefor kft. User-Agent: Thunderbird 2.0b2 (Windows/20070116) MIME-Version: 1.0 To: Richard Huxton CC: pgsql-performance@postgresql.org Subject: Re: Deceiding which index to use References: <45F15F0F.8080403@telefor.hu> <45F1715E.1050000@archonet.com> <45F174CF.8010302@telefor.hu> <45F1775A.8030701@archonet.com> <45F179AB.7040000@telefor.hu> <45F17B70.60001@archonet.com> <45F180D2.5080201@telefor.hu> <45F182B7.30507@archonet.com> In-Reply-To: <45F182B7.30507@archonet.com> Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 09 Mar 2007 16:07:05.0209 (UTC) FILETIME=[FB157E90:01C76264] X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.457 tagged_above=0 required=5 tests=AWL, BAYES_50, HTML_40_50, HTML_MESSAGE, MIME_HTML_ONLY X-Spam-Level: X-Archive-Number: 200703/201 X-Sequence-Number: 23606 Richard Huxton wrote:
Re: [PERFORM] Deceiding which index to use

There is a cost to increasing the stats values, otherwise it'd already
be set at 1000. In your case I'm not sure if 100-200 vs 8-9 messages is
enough to skew things. Only one way to find out...

Well, I tried. The situation is:

- when I look for a subscriber which the planner thinks to have more messages --> it uses the index on crd
- when I look for a subscriber which the planner thinks to have less messages --> it uses the index on subscriber_id

I think that's OK, even if it still don't do what I really would like to see it do :-)

Thanks for all your help, maybe I know a little bit more about poostgresql than before.

Zizi