Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id BE4F81337BC8 for ; Thu, 17 Mar 2011 06:35:03 -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 07346-05 for ; Thu, 17 Mar 2011 09:34:56 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from elizabeth.gransy.com (elizabeth.gransy.com [89.187.132.199]) by mail.postgresql.org (Postfix) with ESMTP id 56D031337BC3 for ; Thu, 17 Mar 2011 06:34:56 -0300 (ADT) Received: from sq.gransy.com (localhost [127.0.0.1]) by elizabeth.gransy.com (Postfix) with ESMTP id 5FC1C15E4320; Thu, 17 Mar 2011 10:34:54 +0100 (CET) Received: from 85.162.173.75 (SquirrelMail authenticated user tv@fuzzy.cz) by sq.gransy.com with HTTP; Thu, 17 Mar 2011 10:34:54 +0100 Message-ID: <4874ad87076c4b2c743083543cae2334.squirrel@sq.gransy.com> In-Reply-To: <4D81A951.7030609@orkash.com> References: <4D807F42.7000906@orkash.com> <20110316163653.GF11541@aart.is.rice.edu> <4D81A951.7030609@orkash.com> Date: Thu, 17 Mar 2011 10:34:54 +0100 Subject: Re: Help with Query Tuning From: tv@fuzzy.cz To: "Adarsh Sharma" Cc: "Kenneth Marshall" , pgsql-performance@postgresql.org User-Agent: SquirrelMail/1.4.21 MIME-Version: 1.0 Content-Type: text/plain;charset=utf-8 Content-Transfer-Encoding: 8bit X-Priority: 3 (Normal) Importance: Normal X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.8 tagged_above=-10 required=5 tests=BAYES_50=0.8 X-Spam-Level: X-Archive-Number: 201103/180 X-Sequence-Number: 42859 > *Modified Query :- > > *SELECT count(*) from page_content > WHERE publishing_date like '%2010%' and content_language='en' and > content is not null and isprocessable = 1 and > to_tsvectOR('english',content) @@ to_tsquery('english','Mujahid' || > 'jihad' || 'Militant' || 'fedayeen' || 'insurgent' || 'terrORist' || > 'cadre' || 'civilians' || 'police' || 'defence' || 'cops' || 'crpf' || > 'dsf' || 'ssb'); I guess there should be spaces between the words. This way it's just one very long word 'MujahidjihadMilitantfedayeen....' and I doubt that's what you're looking for. regards Tomas