Received: from localhost (unknown [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id DA34B65035D for ; Mon, 28 Jul 2008 10:47:36 -0300 (ADT) Received: from postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 28214-01-3 for ; Mon, 28 Jul 2008 10:47:16 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from lists.commandprompt.com (host-159.commandprompt.net [207.173.203.159]) by postgresql.org (Postfix) with ESMTP id 8C403650408 for ; Mon, 28 Jul 2008 10:47:14 -0300 (ADT) Received: from perhan.alvh.no-ip.org (190-95-31-93.bk17-dsl.surnet.cl [190.95.31.93]) (authenticated bits=0) by lists.commandprompt.com (8.13.8/8.13.8) with ESMTP id m6SDnamk032315 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 28 Jul 2008 06:49:40 -0700 Received: by perhan.alvh.no-ip.org (Postfix, from userid 1000) id A119E47C86; Mon, 28 Jul 2008 09:47:02 -0400 (CLT) Date: Mon, 28 Jul 2008 09:47:02 -0400 From: Alvaro Herrera To: Craig Ringer Cc: Faludi =?iso-8859-1?Q?G=E1bor?= , pgsql-performance@postgresql.org Subject: Re: how does pg handle concurrent queries and same queries Message-ID: <20080728134702.GA14617@alvh.no-ip.org> References: <000301c8f07d$4bee0f10$e3ca2d30$@hu> <488D8754.2010208@postnewspapers.com.au> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <488D8754.2010208@postnewspapers.com.au> User-Agent: Mutt/1.5.18 (2008-05-17) X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.0 (lists.commandprompt.com [207.173.203.159]); Mon, 28 Jul 2008 06:49:41 -0700 (PDT) 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: 200807/237 X-Sequence-Number: 30837 Craig Ringer wrote: > Faludi Gábor wrote: > > > . Why does the second and the later queries take the whole on second > > if the dataset is the same . Shouldn't PG realise that the query is the same > > so i give the user the same resultset ? > > That would require a result cache. I don't know if Pg even has a query > result cache - I don't think so, but I'm not sure. It doesn't. -- Alvaro Herrera http://www.CommandPrompt.com/ PostgreSQL Replication, Consulting, Custom Development, 24x7 support