Re: How does the tsearch configuration get selected?

From: Teodor Sigaev <teodor(at)sigaev(dot)ru>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Michael Paesold <mpaesold(at)gmx(dot)at>, "Joshua D(dot) Drake" <jd(at)commandprompt(dot)com>, Gregory Stark <stark(at)enterprisedb(dot)com>, Oleg Bartunov <oleg(at)sai(dot)msu(dot)su>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: How does the tsearch configuration get selected?
Date: 2007-06-15 14:46:46
Message-ID: 4672A656.50600@sigaev.ru
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-advocacy pgsql-hackers

> 1) Require the configuration to be always specified. The problem with
> this is that casting (::tsquery) and operators (@@) have no way to
> specify a configuration.
it's not comfortable for most often cases

>
> 2) Use a GUC that you can set for the configuration, and perhaps
> default it if possible to match the locale. Is the default affected by
> search_path (ouch)?
Right now it works so

>
> How do we make sure that any index that is accessed is using the same
> configuration that is being used by the query, e.g. ::tsquery? Do we
> have to store the configuration name in the index and somehow throw an
> error if it doesn't match? What about changes to the configuration
> after the index has been created, e.g. new stop words or dictionaries?
That's possible intentional case, so we should not throw ERROR!

>
> The two big open issues are whether we allow a default configuration,
> and whether we require the configuration name to be always specified.
>
> My guess right now is that we use a GUC that will default if a
> pg_catalog configuration name matches the lc_ctype locale name, and we
> have to throw an error if an accessed index creation GUC doesn't match
> the current GUC.

Where will index store index creation GUC?
>
> So we create a pg_catalog full text configuration named UTF8.en-US, and
> some others like ru_RU.UTF-8.
>

--
Teodor Sigaev E-mail: teodor(at)sigaev(dot)ru
WWW: http://www.sigaev.ru/

In response to

Responses

Browse pgsql-advocacy by date

  From Date Subject
Next Message Teodor Sigaev 2007-06-15 14:50:04 Re: How does the tsearch configuration get selected?
Previous Message Tom Lane 2007-06-15 14:43:56 Re: How does the tsearch configuration get selected?

Browse pgsql-hackers by date

  From Date Subject
Next Message Teodor Sigaev 2007-06-15 14:50:04 Re: How does the tsearch configuration get selected?
Previous Message Tom Lane 2007-06-15 14:43:56 Re: How does the tsearch configuration get selected?