Re: text search vs schemas

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org, Oleg Bartunov <oleg(at)sai(dot)msu(dot)su>, Teodor Sigaev <teodor(at)sigaev(dot)ru>
Subject: Re: text search vs schemas
Date: 2007-08-17 15:34:05
Message-ID: 5903.1187364845@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> Am Freitag, 17. August 2007 05:15 schrieb Tom Lane:
>> Actually ... I'm suddenly not happy about the choice to put text search
>> configurations etc. into schemas at all.

> But that isn't different from any other part of the system. A proper fix
> would be a mechanism to alleviate the confusion in all places, not simply to
> remove features that cause such confusion in some places (but not all,
> thereby causing inconsistencies).

Well, we are already inconsistent about this. PL languages and index
access methods, for example, don't have schema-ified names.

>> It does not seem likely that a typical installation will have so many
>> text search configs that subdividing them into schemas will really be
>> useful.

> But schemas are not only used to organize objects because there are so many.
> Altering the search path to get at a different implementation without having
> to alter the names in every single place is also a useful application.

This is isomorphic to the argument about whether default_text_search_config
is a good idea; indeed, I think that default_text_search_config pretty
much solves this problem already, for the places where it's sane to have
the configuration-in-use depend upon context. The problem with using
schemas for TS configs is that we can't prevent the search result from
changing in contexts where it mustn't change. At least, not short of
requiring fully-qualified config names in those places, which doesn't
sound like an advance in usability.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Luke Lonergan 2007-08-17 15:46:25 Re: tsearch2 in PostgreSQL 8.3?
Previous Message Tom Lane 2007-08-17 15:24:13 Re: tsearch2 in PostgreSQL 8.3?