X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 5D56032A1EF for ; Sat, 2 Oct 2004 03:39:46 +0100 (BST) 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 27699-04 for ; Sat, 2 Oct 2004 02:39:33 +0000 (GMT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by svr1.postgresql.org (Postfix) with ESMTP id B95E232A0AE for ; Sat, 2 Oct 2004 03:39:36 +0100 (BST) Received: from news.hub.org (news.hub.org [200.46.204.72]) by news.hub.org (8.12.9/8.12.9) with ESMTP id i922dU5a028747 for ; Sat, 2 Oct 2004 02:39:30 GMT (envelope-from news@news.hub.org) Received: (from news@localhost) by news.hub.org (8.12.9/8.12.9/Submit) id i922DkKc024298 for pgsql-admin@postgresql.org; Sat, 2 Oct 2004 02:13:46 GMT From: William Yu X-Newsgroups: comp.databases.postgresql.admin Subject: Re: PLEASE GOD HELP US! Date: Fri, 01 Oct 2004 19:15:42 -0700 Organization: Hub.Org Networking Services Lines: 10 Message-ID: References: <007301c4a7eb$9353eac0$3402a8c0@shanepc> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@news.hub.org User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.3) Gecko/20040910 X-Accept-Language: en-us, en In-Reply-To: To: pgsql-admin@postgresql.org 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: 200410/44 X-Sequence-Number: 15038 William Yu wrote: > There are cases where seqscan will be faster than indexscans. For > example, your query to retrieve the latest 25 threads -- always faster > using seqscan. If it was using indexscan, that would explain the 9 > seconds to run because the HD heads would have to jump back & forth from Oops, I didn't write down my thoughts clearly. I meant to say -- DEPENDING ON THE DISTRIBUTION OF THE VALUES -- the query might be faster using seqscan.