From: | "Grant Hutchins and Peter Jaros" <grant(at)pivotallabs(dot)com> |
---|---|
To: | pgsql-bugs(at)postgresql(dot)org |
Subject: | BUG #5781: unaccent() function should be marked IMMUTABLE |
Date: | 2010-12-02 15:44:29 |
Message-ID: | 201012021544.oB2FiTn1041521@wwwmaster.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
The following bug has been logged online:
Bug reference: 5781
Logged by: Grant Hutchins and Peter Jaros
Email address: grant(at)pivotallabs(dot)com
PostgreSQL version: 9.0.1
Operating system: Mac OS X 10.6.4
Description: unaccent() function should be marked IMMUTABLE
Details:
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.
=# CREATE TABLE foo ();
CREATE TABLE
=# CREATE INDEX bar ON foo ( unaccent('baz') );
ERROR: functions in index expression must be marked IMMUTABLE
=# ALTER FUNCTION unaccent(text) IMMUTABLE;
ALTER FUNCTION
=# CREATE INDEX bar ON foo ( unaccent('baz') );
CREATE INDEX
From | Date | Subject | |
---|---|---|---|
Next Message | Konstantin Nikiforov | 2010-12-02 20:23:43 | Bug: table inheritance. Trigger before DELETE for each statement is ignored |
Previous Message | Thomas Bakketun | 2010-12-01 17:27:42 | BUG #5780: Case insensitive regular expressions |