X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 4E4D2D1B1AC for ; Wed, 19 May 2004 00:19:41 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 11661-09 for ; Wed, 19 May 2004 00:19:20 -0300 (ADT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by svr1.postgresql.org (Postfix) with ESMTP id 8CD56D1B26E for ; Wed, 19 May 2004 00:19:20 -0300 (ADT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by news.hub.org (8.12.9/8.12.9) with ESMTP id i4J3JFSx013558 for ; Wed, 19 May 2004 03:19:15 GMT (envelope-from news@news.hub.org) Received: (from news@localhost) by news.hub.org (8.12.9/8.12.9/Submit) id i4J2pXF9092486 for pgsql-performance@postgresql.org; Wed, 19 May 2004 02:51:33 GMT From: Joseph Shraibman X-Newsgroups: comp.databases.postgresql.performance Subject: Re: Using LIKE expression problem.. Date: Tue, 18 May 2004 22:51:30 -0400 Organization: Hub.Org Networking Services Lines: 63 Message-ID: <40AACBB2.6060001@selectacast.net> References: <40A1D94E.9030605@familyhealth.com.au> <200405120804.i4C84gh9004444@mail.census.gov.ph> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@news.hub.org To: "Michael Ryan S. Puncia" User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040514 X-Accept-Language: en-us, en In-Reply-To: <200405120804.i4C84gh9004444@mail.census.gov.ph> To: pgsql-performance@postgresql.org X-Virus-Scanned: by amavisd-new at postgresql.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200405/150 X-Sequence-Number: 6981 Use the text_pattern_ops operator when creating the index, see: http://www.postgresql.org/docs/7.4/static/indexes-opclass.html Michael Ryan S. Puncia wrote: > Sorry .. I am a newbie and I don't know :( > How can I know that I am in C locale ? > How can I change my database to use C locale? > > > > -----Original Message----- > From: pgsql-performance-owner@postgresql.org > [mailto:pgsql-performance-owner@postgresql.org] On Behalf Of Christopher > Kings-Lynne > Sent: Wednesday, May 12, 2004 3:59 PM > To: Michael Ryan S. Puncia > Cc: pgsql-performance@postgresql.org > Subject: Re: [PERFORM] Using LIKE expression problem.. > > Are you in a non-C locale? > > Chris > > Michael Ryan S. Puncia wrote: > > >>Yes , I already do that but the same result .. LIKE uses seq scan >> >>-----Original Message----- >>From: pgsql-performance-owner@postgresql.org >>[mailto:pgsql-performance-owner@postgresql.org] On Behalf Of Christopher >>Kings-Lynne >>Sent: Wednesday, May 12, 2004 2:48 PM >>To: Michael Ryan S. Puncia >>Cc: pgsql-performance@postgresql.org >>Subject: Re: [PERFORM] Using LIKE expression problem.. >> >> >> >>>In the query plan ..it uses seq scan rather than index scan .. why ? I >>>have index on lastname, firtname. >> >> >>Have you run VACUUM ANALYZE; on the table recently? >> >>Chris >> >> >>---------------------------(end of broadcast)--------------------------- >>TIP 7: don't forget to increase your free space map settings >> > > > ---------------------------(end of broadcast)--------------------------- > TIP 5: Have you checked our extensive FAQ? > > http://www.postgresql.org/docs/faqs/FAQ.html > > > > ---------------------------(end of broadcast)--------------------------- > TIP 4: Don't 'kill -9' the postmaster >