Re: pg_trgm word_similarity query does not use index for input strings longer than 8 characters

2021-12-09 Thread pgsql-performance
Thank you both a lot for the insights and your input. > Yeah, this test case seems very unrealistic, both as to table size > and as to the lack of variability of the table entries. The example was based on real data with a more complicated query which prompted me to investigate the issue. The di

pg_trgm word_similarity query does not use index for input strings longer than 8 characters

2021-12-06 Thread pgsql-performance
Hello, recently I wrote a query that provides suggestions from a Postgres table. It should be able to work despite smaller typos and thus I chose to use the pg_trgm extension (https://www.postgresql.org/docs/current/pgtrgm.html). When measuring the performance, I observed great differences in th