Search Postgresql Archives

full text search and ILIKE type clauses.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I want to be able to search a lot of fields using queries that use
ILIKE and unfortunately many of the queries will be  using the
'%SOMETHING%' or '%SOMETHING' type clauses.  Since indexes are useless
on those I was thinking I could use tsvectors but I can't figure out
how to accomplish this.

One option I have seen reccomended is to create a tsvector field and
concat the various fields into that field as a tsvector. That would
work for general text search but I am not sure how I could query
FIELD1 ILIKE '%SOMETHING%' vs FIELD2 ILIKE '%SOMETHING%' .    Would
using hstore help in this case?

I should point out that some of the fields are numbers. I am willing
to deal with those separately by building other indexes for them but
of course a unified approach would be preferable.

Any help would be much appreciated. Thanks.

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux