Re: Errors when restoring backup created by pg_dumpall - Mailing list pgsql-general

From David G. Johnston
Subject Re: Errors when restoring backup created by pg_dumpall
Date
Msg-id CAKFQuwZD80Na1sOmibDFzSBx=6OeySuoDZFbytcinxNP+2OtMw@mail.gmail.com
Whole thread Raw
In response to Re: Errors when restoring backup created by pg_dumpall  (Ron Johnson <ronljohnsonjr@gmail.com>)
List pgsql-general
On Thursday, December 5, 2024, Ron Johnson <ronljohnsonjr@gmail.com> wrote:
On Thu, Dec 5, 2024 at 6:24 PM David G. Johnston <david.g.johnston@gmail.com> wrote:
On Thu, Dec 5, 2024 at 4:04 PM Ron Johnson <ronljohnsonjr@gmail.com> wrote:
Another alternative is to open the .sql file in Notepad++, then add "public." before all the unqualified "earth" and "ll_to_earth" references.

And as discussed there are none in that file because those references are within an extension's objects and only create extension appears in the file.

Then why would changing search_path work? 


Because (I presume) function inlining during execution of create table keeps the search_path of the session executing create table which will then result in the parser resolving the unqualified “earth” function name to the one existing in the public schema when looking through the session’s search_path.

David J.

pgsql-general by date:

Previous
From: Adrian Klaver
Date:
Subject: Re: Errors when restoring backup created by pg_dumpall
Next
From: Arbol One
Date:
Subject: GRANT WITH INHERIT ??