From: Tom Lane <tgl@sss.pgh.pa.us>
To: Grant Hutchins and Peter Jaros <grant@pivotallabs.com>
Cc: pgsql-bugs@postgresql.org
Subject: Re: BUG #5781: unaccent() function should be marked IMMUTABLE
Date: Thu, 02 Dec 2010 23:50:06 -0500
Message-ID: <16472.1291351806@sss.pgh.pa.us> (raw)
In-Reply-To: <201012021544.oB2FiTn1041521@wwwmaster.postgresql.org>
References: <201012021544.oB2FiTn1041521@wwwmaster.postgresql.org>
"Grant Hutchins and Peter Jaros" <grant@pivotallabs.com> writes:
> The unaccent(text) function supplied by contrib/unaccent is marked VOLATILE.
> This prevents it from being used in indexes. We believe that the function
> meets the requirements to be marked IMMUTABLE.
No, it most certainly doesn't. It depends on the behavior of a
dictionary that it has no hard-wired connection to, so the specific
behavior of the dictionary is uncertain. Even if you're willing to
assume that the dictionary being used is the one defined by this
module, that dictionary depends on external configuration files
which are easily changeable.
Arguably it'd be reasonable to change the function's marking from
volatile to stable, but that's not going to be enough to allow use in
indexes.
regards, tom lane
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: tgl@sss.pgh.pa.us, grant@pivotallabs.com
Subject: Re: BUG #5781: unaccent() function should be marked IMMUTABLE
In-Reply-To: <16472.1291351806@sss.pgh.pa.us>
References: <201012021544.oB2FiTn1041521@wwwmaster.postgresql.org> <16472.1291351806@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