Skip site navigation (1) Skip section navigation (2)

Re: SELECT from a list

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Markus Bertheau <twanger(at)bluetwanger(dot)de>
Cc: Jean-Luc Lachance <jllachan(at)sympatico(dot)ca>,Keith Gallant <keith(at)justhosting(dot)ca>, pgsql-sql(at)postgresql(dot)org
Subject: Re: SELECT from a list
Date: 2004-07-25 17:34:21
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-sql
Markus Bertheau <twanger(at)bluetwanger(dot)de> writes:
>  , 25.07.2004,  16:40, Jean-Luc Lachance :
>> Better yet:
>> SELECT * FROM table WHERE phrase ~ '^[0-9]';

> Not so sure if that's better - the regex engines aren't the fastest.

[ raised eyebrow... ]  I was under the impression that we had a pretty
good one as of PG 7.4.  Have you tested it lately?

It is true that the above won't be indexable whereas the more tedious OR
form potentially could use an index.  This is not the fault of the regex
engine however, but of limited understanding of regexes in the planner.

			regards, tom lane

In response to


pgsql-sql by date

Next:From: Markus BertheauDate: 2004-07-25 19:07:35
Subject: Re: regex engine
Previous:From: Markus BertheauDate: 2004-07-25 16:21:56
Subject: Re: SELECT from a list

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group