Re: trgm regex index peculiarity - Mailing list pgsql-hackers

From Tom Lane
Subject Re: trgm regex index peculiarity
Date
Msg-id 3920.1371785158@sss.pgh.pa.us
Whole thread Raw
In response to trgm regex index peculiarity  ("Erik Rijkers" <er@xs4all.nl>)
Responses Re: trgm regex index peculiarity
List pgsql-hackers
"Erik Rijkers" <er@xs4all.nl> writes:
> In a 112 MB test table (containing random generated text) with a trgm index (gin_trgm_ops), I consistently get these
timings:
> select txt from azjunk6 where txt ~ '^abcd';
>    130 ms
> select txt from azjunk6
> where txt ~ 'abcd' and substr(txt,1,4) = 'abcd';
>    3 ms

Hm, could you provide a self-contained test case?
        regards, tom lane



pgsql-hackers by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: single-user vs standalone in docs and messages
Next
From: David Fetter
Date:
Subject: Re: FILTER for aggregates [was Re: Department of Redundancy Department: makeNode(FuncCall) division]