Re: [GENERAL] indexed regex select optimisation missing?

From: Peter Eisentraut <e99re41(at)DoCS(dot)UU(dot)SE>
To: Stuart Woolford <stuartw(at)newmail(dot)net>
Cc: "Gene Selkov, Jr(dot)" <selkovjr(at)mcs(dot)anl(dot)gov>, pgsql-general(at)postgreSQL(dot)org
Subject: Re: [GENERAL] indexed regex select optimisation missing?
Date: 1999-11-04 09:40:21
Message-ID: Pine.GSO.4.02A.9911041037050.1524-100000@Hund.DoCS.UU.SE
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Thu, 4 Nov 1999, Stuart Woolford wrote:

> unfortunately '^whatever.*' is what I'm trying to locate (ie: all words
> starting with whatever, but with nay trailing text), the problem seems to be in
> the termination of the index scan, not in the actual regex match (which actually
> seems very good, speed wise..) otherwise I could just use ='whatever', which
> runs very very fast.

Isn't "all words that start with whatever but without trailing text" the
same as = 'whatever'? From a regex point of view '^whatever' and
'^whatever.*' are exactly equivalent, but I can see where one could fail
to optimize properly. But that could even be a problem in the regex
library, which is not any of the PostgreSQL developers' domain and which
is used in other products as well.

-Peter

--
Peter Eisentraut Sernanders vaeg 10:115
peter_e(at)gmx(dot)net 75262 Uppsala
http://yi.org/peter-e/ Sweden

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Robert 1999-11-04 11:45:00 Re: [GENERAL] 6.5 connection time: too slow (?)
Previous Message Peter Eisentraut 1999-11-04 09:26:24 Re: [GENERAL] users in Postgresql