pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Luigi Saggese <luigisag@gmail.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: Performance ts_vector fulltext search
Date: Thu, 11 Apr 2013 10:58:46 -0400
Message-ID: <2751.1365692326@sss.pgh.pa.us> (raw)
In-Reply-To: <CAGxgJgG6Uqjx5WjzOc-_uODq00MiRPJP=ja25FvMr1pU8s4XnQ@mail.gmail.com>
References: <CAGxgJgG6Uqjx5WjzOc-_uODq00MiRPJP=ja25FvMr1pU8s4XnQ@mail.gmail.com>
List-Unsubscribe:  <mailto:majordomo@postgresql.org?body=unsub%20pgsql-performance>

Luigi Saggese <luigisag@gmail.com> writes:
> I've configured 2 table like this
> ...
> CREATE INDEX "ix_fulltext_usp_what" ON "public"."User_Statement_Pivot"
> ("to_tsvector('italian'::regconfig, ""What""::text)",
> "to_tsvector('italian'::regconfig, ""What""::text)");

When I try that I get

ERROR:  column "to_tsvector('italian'::regconfig, "What"::text)" does not exist

as indeed I should, because you seem to be confused about SQL quoting
rules --- that whole expression is being taken as a name.  However, the
bigger problem here is that you're creating btree indexes, which are not
useful for full text search.  They need to be gin or gist indexes.  See
examples at

http://www.postgresql.org/docs/9.2/static/textsearch-tables.html#TEXTSEARCH-TABLES-INDEX

			regards, tom lane


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



view thread (2+ messages)

Message-ID: <2751.1365692326@sss.pgh.pa.us>
Permalink:  ../2751.1365692326@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/2751.1365692326@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: tgl@sss.pgh.pa.us, luigisag@gmail.com
  Subject: Re: Performance ts_vector fulltext search
  In-Reply-To: <2751.1365692326@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox