pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Richard Huxton <dev@archonet.com>
To: Priem, Alexander <ap@cict.nl>
To: pgsql-performance@postgresql.org
Subject: Re: What index for 'like (%keyword%)' ???
Date: Wed, 31 Mar 2004 13:07:54 +0100
Message-ID: <200403311307.54680.dev@archonet.com> (raw)
In-Reply-To: <2A07EC2D0BC2774AAD6F74769F60D52A08329A@ahmose.cict_ad.nl>
References: <2A07EC2D0BC2774AAD6F74769F60D52A08329A@ahmose.cict_ad.nl>

On Wednesday 31 March 2004 10:51, Priem, Alexander wrote:
> Hi everyone,
>
> I am building a query which uses a clause like "Where doc_description like
> '%keyword%'". I know a normal index won't be of any use here, but since the
> table in question will get fairly big, I do want to use an index.
>
> Can anyone give me some advise on what kind of index I can use here? Or
> shouldn't I use one in this case?

You probably want to look at the contrib/tsearch2 full-text indexing module.

-- 
  Richard Huxton
  Archonet Ltd



view thread (3+ messages)  latest in thread

Message-ID: <200403311307.54680.dev@archonet.com>
Permalink:  ../200403311307.54680.dev@archonet.com/
Also on:    postgresql.org/message-id/200403311307.54680.dev@archonet.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: dev@archonet.com, ap@cict.nl
  Subject: Re: What index for 'like (%keyword%)' ???
  In-Reply-To: <200403311307.54680.dev@archonet.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox