On Tue, Jul 01, 2008 at 01:14:12AM -0700, Damjan Rems wrote:
> Id would like to get aproximatly this.
> WHERE name LIKE 'somes%'
> But how do I construct FTS query for this?
for this - you dont need ftps. you just need proper index.
there will be prefix searches in full text indexes in postgresql
Damjan Rems wrote:
Um - you're using the full-text indexing. It's
supposed to search words.
You can use any of the pattern-matching functions /
operators (LIKE etc)
here if you want to explicitly match characters.
http://www.postgresql.org/docs/current/static/functions-matching.html
If that's
> Um - you're using the full-text indexing. It's
> supposed to search words.
>
> You can use any of the pattern-matching functions /
> operators (LIKE etc)
> here if you want to explicitly match characters.
> http://www.postgresql.org/docs/current/static/functions-matching.html
>
> If that's no
Damjan Rems wrote:
SELECT * FROM clients
WHERE to_tsvector('english',name) @@ to_tsquery( 'english','somestring');
But if I want to query just part of the string return set is empty:
SELECT * FROM clients
WHERE to_tsvector('english',name) @@ to_tsquery( 'english','somes');
returns no results.
On Mon, 30 Jun 2008, Damjan Rems wrote:
I created a FTS index:
CREATE INDEX clients_fts ON clients USING gist( to_tsvector( 'english', name) )
I can do FTS queries like:
SELECT * FROM clients
WHERE to_tsvector('english',name) @@ to_tsquery( 'english','somestring');
But if I want to query just
I created a FTS index:
CREATE INDEX clients_fts ON clients USING gist( to_tsvector( 'english', name) )
I can do FTS queries like:
SELECT * FROM clients
WHERE to_tsvector('english',name) @@ to_tsquery( 'english','somestring');
But if I want to query just part of the string return set is empty:
SEL