Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id 6FC57B5E065 for ; Wed, 8 Jun 2011 06:21:05 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 91233-04 for ; Wed, 8 Jun 2011 09:20:58 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from www.postnewspapers.com.au (www.postnewspapers.com.au [173.230.139.50]) by mail.postgresql.org (Postfix) with ESMTP id 48491B5DEE9 for ; Wed, 8 Jun 2011 06:20:58 -0300 (ADT) Received: from localhost (localhost [127.0.0.1]) by www.postnewspapers.com.au (Postfix) with ESMTP id B8E2110D; Wed, 8 Jun 2011 05:20:57 -0400 (EDT) X-Virus-Scanned: amavisd-new at postnewspapers.com.au.com Received: from www.postnewspapers.com.au ([127.0.0.1]) by localhost (www.postnewspapers.com.au [127.0.0.1]) (amavisd-new, port 10024) with LMTP id e6PlEEpgJ8-5; Wed, 8 Jun 2011 05:20:56 -0400 (EDT) Received: from mail.postnewspapers.com.au (ppp171-128.static.internode.on.net [150.101.171.128]) by www.postnewspapers.com.au (Postfix) with ESMTP id 8D1A32D; Wed, 8 Jun 2011 05:20:56 -0400 (EDT) Received: from localhost (localhost [127.0.0.1]) by mail.postnewspapers.com.au (Postfix) with ESMTP id 98569AF268; Wed, 8 Jun 2011 17:20:55 +0800 (WST) X-Virus-Scanned: Debian amavisd-new at postnewspapers.com.au Received: from mail.postnewspapers.com.au ([127.0.0.1]) by localhost (mail.postnewspapers.com.au [127.0.0.1]) (amavisd-new, port 10024) with LMTP id VSKSXJhgClOb; Wed, 8 Jun 2011 17:20:50 +0800 (WST) Received: from [10.1.1.3] (58-7-128-152.dyn.iinet.net.au [58.7.128.152]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client CN "Craig Ringer", Issuer "POST Certificate Authority" (verified OK)) by mail.postnewspapers.com.au (Postfix) with ESMTPSA id 36B63AECB6; Wed, 8 Jun 2011 17:20:50 +0800 (WST) Message-ID: <4DEF3EEE.1080203@postnewspapers.com.au> Date: Wed, 08 Jun 2011 17:20:46 +0800 From: Craig Ringer User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.17) Gecko/20110414 Thunderbird/3.1.10 MIME-Version: 1.0 To: John Williams CC: pgsql-performance@postgresql.org Subject: Re: Set of related slow queries References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.91 tagged_above=-10 required=5 tests=BAYES_00=-1.9, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201106/59 X-Sequence-Number: 43992 On 8/06/2011 10:58 AM, John Williams wrote: > -> Bitmap Heap Scan on logparser_entry > (cost=4119.06..21520.55 rows=68787 width=8) (actual > time=107.032..444.864 rows=16168 loops=1) > Recheck Cond: ((event_type)::text = ANY > ('{Attack,"DoT Tick","Critical Attack"}'::text[])) > Filter: ((((target_relation)::text<> ALL > ('{Other,N/A}'::text[])) OR (NOT (target_relation IS NOT NULL))) AND > (log_id = 2)) > -> Bitmap Index Scan on > logparser_entry_event_type_like (cost=0.00..4101.86 rows=217733 > width=0) (actual time=46.392..46.392 rows=237151 loops=1) > Index Cond: ((event_type)::text = ANY > ('{Attack,"DoT Tick","Critical Attack"}'::text[])) > -> Hash (cost=196.49..196.49 rows=9749 width=23) > (actual time=19.606..19.606 rows=9749 loops=1) Thanks for including explain analyze output. Is there any chance you can pop the full explains (not just excerpts) in here: http://explain.depesz.com/ ? Big query plans tend to get mangled into unreadable garbage by mail clients, unfortunately. -- Craig Ringer Tech-related writing at http://soapyfrogs.blogspot.com/