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 D0A8353C92 for ; Thu, 3 Mar 2005 22:03:50 +0000 (GMT) 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 13522-01 for ; Thu, 3 Mar 2005 22:03:46 +0000 (GMT) Received: from mail.logix-tt.com (wallaby.dingens.org [212.75.36.180]) by svr1.postgresql.org (Postfix) with ESMTP id 49D0952A66 for ; Thu, 3 Mar 2005 22:03:45 +0000 (GMT) Received: from kingfisher.intern.logi-track.com (pD95DCDF2.dip0.t-ipconnect.de [217.93.205.242]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.logix-tt.com (Postfix) with ESMTP id A4413A859A; Thu, 3 Mar 2005 22:03:49 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by kingfisher.intern.logi-track.com (Postfix) with ESMTP id 3BF55AB3D8; Thu, 3 Mar 2005 23:03:45 +0100 (CET) Message-ID: <422789C0.20201@logix-tt.com> Date: Thu, 03 Mar 2005 23:03:44 +0100 From: Markus Schaber User-Agent: Mozilla Thunderbird 1.0 (X11/20050116) X-Accept-Language: de-DE, de, en-us, en MIME-Version: 1.0 To: Jeremiah Jahn Cc: Dave Held , John A Meinel , postgres performance Subject: Re: name search query speed References: <49E94D0CFCD4DB43AFBA928DDD20C8F90261845D@asg002.asg.local> <1109882849.16326.99.camel@bluejay.goodinassociates.com> In-Reply-To: <1109882849.16326.99.camel@bluejay.goodinassociates.com> X-Enigmail-Version: 0.90.1.0 X-Enigmail-Supports: pgp-inline, pgp-mime Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.05 tagged_above=0 required=5 tests=AWL, FORGED_RCVD_HELO X-Spam-Level: X-Archive-Number: 200503/66 X-Sequence-Number: 10771 Hi, Jeremiah, Jeremiah Jahn schrieb: > doesn't that cause two queries? I used to do it that way and cut my time > substantially by counting in-line. Even though the results were cached > it still took more time. This sounds rather strange. > Also since the tables is constantly be updated > the returned total would not always match the number of results on the > second query. Did you run both queries in the same transaction, with transaction isolation level set to serializable? If yes, you found a serious bug in PostgreSQL transaction engine. Markus -- Markus Schaber | Dipl. Informatiker | Software Development GIS Fight against software patents in EU! http://ffii.org/ http://nosoftwarepatents.org/