Re: Index Usage and Running Times by FullTextSearch with prefix matching
От | rawi |
---|---|
Тема | Re: Index Usage and Running Times by FullTextSearch with prefix matching |
Дата | |
Msg-id | 1371137966540-5759046.post@n5.nabble.com обсуждение исходный текст |
Ответ на | Re: Index Usage and Running Times by FullTextSearch with prefix matching (Tom Lane <tgl@sss.pgh.pa.us>) |
Список | pgsql-sql |
Tom Lane-2 wrote > 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). Short or long prefixes seem to be equaly unfavorable. Even with the full length of the words, but queried as prefix I get a runtime of 25342ms compared to 353ms without prefixes: SELECT count(a) FROM t1 WHERE a_tsvector @@ to_tsquery('aaaaa:* & bbbbb:* & ccccc:* & ddddd:*') Total query runtime: 25342 ms "Aggregate (cost=804.02..804.03 rows=1 width=36)" " -> Bitmap Heap Scan on t1 (cost=800.00..804.02 rows=1 width=36)" " Recheck Cond: (a_tsvector @@ to_tsquery('aaaaa:* & bbbbb:* & ccccc:* & ddddd:*'::text))" " -> Bitmap Index Scan on a_tsvector_idx (cost=0.00..800.00 rows=1 width=0)" " Index Cond: (a_tsvector @@ to_tsquery('aaaaa:* & bbbbb:* & ccccc:* & ddddd:*'::text))" Kind Regards Rawi -- View this message in context: http://postgresql.1045698.n5.nabble.com/Index-Usage-and-Running-Times-by-FullTextSearch-with-prefix-matching-tp5759021p5759046.html Sent from the PostgreSQL - sql mailing list archive at Nabble.com.
В списке pgsql-sql по дате отправления: