Re: LIke and Indicies

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Dave Smith <dave(dot)smith(at)candata(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: LIke and Indicies
Date: 2005-02-25 17:05:31
Message-ID: 200502251805.31752.peter_e@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Am Freitag, 25. Februar 2005 17:54 schrieb Dave Smith:
> >From my reading of that statement it says it is going to use the index
>
> to match company_id=1000 and then fetch the row and compare
> product_desc. Where as in the the case without the like it is using
> product description in the Index Condition.

Well, the truth is that it has *the option* to use the index, but it doesn't
have to. This really mostly independent of the LIKE index issue. If you
think that the plan choice is not optimal, try EXPLAIN ANALYZE and post the
results if you need help interpreting them.

--
Peter Eisentraut
http://developer.postgresql.org/~petere/

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Dr. Stephane Schildknecht 2005-02-25 17:07:36 Association PostgreSQLFr, statuts et inscription
Previous Message Dave Smith 2005-02-25 16:54:01 Re: LIke and Indicies