X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 56C8CD1B248 for ; Tue, 29 Jun 2004 10:21:38 -0300 (ADT) 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 56167-01 for ; Tue, 29 Jun 2004 13:21:40 +0000 (GMT) Received: from wolff.to (wolff.to [66.93.249.74]) by svr1.postgresql.org (Postfix) with SMTP id 88E88D1B252 for ; Tue, 29 Jun 2004 10:21:35 -0300 (ADT) Received: (qmail 28122 invoked by uid 500); 29 Jun 2004 13:28:13 -0000 Date: Tue, 29 Jun 2004 08:28:13 -0500 From: Bruno Wolff III To: Chris Cheston Cc: Christopher Kings-Lynne , pgsql-performance@postgresql.org Subject: Re: postgres 7.4 at 100% Message-ID: <20040629132813.GA28041@wolff.to> Mail-Followup-To: Chris Cheston , Christopher Kings-Lynne , pgsql-performance@postgresql.org References: <1088397641.1105.10.camel@localhost> <17884.1088399982@sss.pgh.pa.us> <200406280947.59420.josh@agliodbs.com> <40E1266D.3040607@familyhealth.com.au> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.6i 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: 200406/291 X-Sequence-Number: 7349 On Tue, Jun 29, 2004 at 01:37:30 -0700, Chris Cheston wrote: > ok i just vacuumed it and it's taking slightly longer now to execute > (only about 8 ms longer, to around 701 ms). > > Not using indexes for calllogs(from)... should I? The values for > calllogs(from) are not unique (sorry if I'm misunderstanding your > point). If you are hoping for some other plan than a sequential scan through all of the records you are going to need an index. You can have an index on a column (or function) that isn't unique for all rows.