Re: Index Usage and Running Times by FullTextSearch with prefix matching

From: rawi <only4com(at)web(dot)de>
To: pgsql-sql(at)postgresql(dot)org
Subject: Re: Index Usage and Running Times by FullTextSearch with prefix matching
Date: 2013-06-21 09:31:29
Message-ID: 1371807089696-5760297.post@n5.nabble.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Tom Lane-2 wrote
> rawi &lt;

> only4com@

> &gt; writes:
>> And querying: FTS with prefix matching:
>
>> SELECT count(a)
>> FROM t1
>> WHERE a_tsvector @@ to_tsquery('aaa:* & b:* & c:* & d:*')
>
>> (RESULT: count: 619)
>> Total query runtime: 21266 ms.
>
> FWIW, I get fairly decent performance for cases like this in HEAD
> (at least with a GIN index; GIST seems much less able to do well with
> short prefixes). What PG version are you testing?

Last tests with PG 9.2:

Whereas the "whole words" full text search stays at ~350ms for 900,000
records I tryed the number of records, which are becoming to make one
suffer, querying for prefixes:

RECORDS RUNTIME (ms)
10,000 13
100,000 81
200,000 172
400,000 7,284
900,000 20,888

Regards, Rawi

--
View this message in context: http://postgresql.1045698.n5.nabble.com/Index-Usage-and-Running-Times-by-FullTextSearch-with-prefix-matching-tp5759021p5760297.html
Sent from the PostgreSQL - sql mailing list archive at Nabble.com.

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Dev Kumkar 2013-07-03 09:12:17 Unquoted column names fold to lower case
Previous Message David Johnston 2013-06-20 13:34:17 Re: UNNEST result order vs Array data