Re: unaccent(text) fails depending on search_path (WAS: pg_upgrade fails saying function unaccent(text) doesn't exist)
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Gunnlaugur Thor Briem <gunnlaugur@gmail.com>
Cc: Adrian Klaver <adrian.klaver@aklaver.com>,
Bruce Momjian <bruce@momjian.us>, pgsql-hackers@lists.postgresql.org
Date: 2018-09-05T22:37:00Z
Lists: pgsql-hackers, pgsql-general
Attachments
- avoid-depending-on-search-path-in-unaccent-2.patch (text/x-diff) patch
[ redirecting to pgsql-hackers ]
I wrote:
> Gunnlaugur Thor Briem <gunnlaugur@gmail.com> writes:
>> SET search_path = "$user"; SELECT public.unaccent('foo');
>> SET
>> ERROR: text search dictionary "unaccent" does not exist
> Meh. I think we need the attached, or something just about like it.
>
> It's barely possible that there's somebody out there who's relying on
> setting the search path to allow choosing among multiple "unaccent"
> dictionaries. But there are way more people whose functions are
> broken due to the recent search-path-tightening changes.
Here's a slightly more efficient version.
regards, tom lane
Commits
-
Make contrib/unaccent's unaccent() function work when not in search path.
- d4ab3962613f 9.4.20 landed
- c79b39fb1c5b 9.5.15 landed
- a54f5b187a4a 10.6 landed
- a5322ca10fa1 12.0 landed
- 594ee1ada5bc 9.6.11 landed
- 25ff97ba77cb 9.3.25 landed
- 23aad181f447 11.0 landed
-
Avoid unnecessary use of pg_strcasecmp for already-downcased identifiers.
- fb8697b31aae 11.0 cited