Received: from malur.postgresql.org ([2a02:16a8:dc51::56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fyPJ8-0006K4-Uo for pgsql-hackers@arkaria.postgresql.org; Fri, 07 Sep 2018 22:32:55 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1fyPJ6-0001ml-VL for pgsql-hackers@arkaria.postgresql.org; Fri, 07 Sep 2018 22:32:52 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fyPJ6-0001me-OB for pgsql-hackers@lists.postgresql.org; Fri, 07 Sep 2018 22:32:52 +0000 Received: from momjian.us ([72.94.173.45]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1fyPJ3-0000JU-Ij for pgsql-hackers@lists.postgresql.org; Fri, 07 Sep 2018 22:32:52 +0000 Received: from bruce by momjian.us with local (Exim 4.84_2) (envelope-from ) id 1fyPJ1-0007Cz-6E; Fri, 07 Sep 2018 18:32:47 -0400 Date: Fri, 7 Sep 2018 18:32:47 -0400 From: Bruce Momjian To: Tom Lane Cc: Gunnlaugur Thor Briem , Adrian Klaver , pgsql-hackers@lists.postgresql.org Subject: Re: unaccent(text) fails depending on search_path (WAS: pg_upgrade fails saying function unaccent(text) doesn't exist) Message-ID: <20180907223247.GH28811@momjian.us> References: <20180829190635.GD25450@momjian.us> <6c73c320-95b7-c259-e309-c46300557852@aklaver.com> <6e023cde-943a-5cea-8626-f1e9b29695df@aklaver.com> <12109.1536174213@sss.pgh.pa.us> <22723.1536187020@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <22723.1536187020@sss.pgh.pa.us> User-Agent: Mutt/1.5.23 (2014-03-12) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Wed, Sep 5, 2018 at 06:37:00PM -0400, Tom Lane wrote: > [ redirecting to pgsql-hackers ] > > I wrote: > > Gunnlaugur Thor Briem 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. If we are going down this route, is there any thought of handling earchdistance the same way? https://www.postgresql.org/message-id/20180330205229.GS8476@momjian.us -- Bruce Momjian http://momjian.us EnterpriseDB http://enterprisedb.com + As you are, so once was I. As I am, so you will be. + + Ancient Roman grave inscription +