Re: pg_dump and search_path

2019-07-10 Thread Adrian Klaver
On 7/10/19 4:31 PM, Ryan Lambert wrote: My exact situation was a deployment via sqitch,  It appears that uses psql under the hood based on the error message I get. Yes it does: https://sqitch.org/docs/manual/sqitch/ "Native scripting Changes are implemented as scripts native to your selected d

Re: pg_dump and search_path

2019-07-10 Thread Ryan Lambert
My exact situation was a deployment via sqitch, It appears that uses psql under the hood based on the error message I get. Running just "sqitch deploy" I get an error due to a non-fully qualified name and a missing search path (my mistakes). The error I get: + 004 .. psql:deploy/004.sql:72: E

Re: pg_dump and search_path

2019-07-10 Thread Adrian Klaver
On 7/10/19 1:19 PM, Ryan Lambert wrote: I had a similar problem and was able to being the command with the search_path to work around it.  I did this on Linux and it looks like you are on Windows but I maybe you can do something similar that will work? PGOPTIONS='-c search_path=staging, transi

Re: pg_dump and search_path

2019-07-10 Thread Ryan Lambert
I had a similar problem and was able to being the command with the search_path to work around it. I did this on Linux and it looks like you are on Windows but I maybe you can do something similar that will work? PGOPTIONS='-c search_path=staging, transient, pg_catalog' *Ryan Lambert* RustProof

Re: pg_dump and search_path

2019-07-09 Thread Adrian Klaver
On 7/9/19 4:24 PM, Igal @ Lucee.org wrote: On 7/9/2019 10:45 AM, Adrian Klaver wrote: On 7/9/19 7:41 AM, Igal @ Lucee.org wrote: On 7/9/2019 7:02 AM, Adrian Klaver wrote: On 7/8/19 11:48 PM, Igal @ Lucee.org wrote: I have a custom search_path: # show search_path;     search_path

Re: pg_dump and search_path

2019-07-09 Thread Igal @ Lucee.org
On 7/9/2019 10:45 AM, Adrian Klaver wrote: On 7/9/19 7:41 AM, Igal @ Lucee.org wrote: On 7/9/2019 7:02 AM, Adrian Klaver wrote: On 7/8/19 11:48 PM, Igal @ Lucee.org wrote: I have a custom search_path: # show search_path;     search_path --   "staging, t

Re: pg_dump and search_path

2019-07-09 Thread Adrian Klaver
On 7/9/19 7:41 AM, Igal @ Lucee.org wrote: On 7/9/2019 7:02 AM, Adrian Klaver wrote: On 7/8/19 11:48 PM, Igal @ Lucee.org wrote: I have a custom search_path: # show search_path;     search_path --   "staging, transient, pg_catalog" (1 row) I ran `pg_dum

Re: pg_dump and search_path

2019-07-09 Thread David G. Johnston
On Tue, Jul 9, 2019 at 8:48 AM Igal @ Lucee.org wrote: > David, > > On 7/9/2019 7:49 AM, David G. Johnston wrote: > > On Tue, Jul 9, 2019 at 7:41 AM Igal @ Lucee.org wrote: > >> search_path is not set int he config, but rather with ALTER DATABASE SET >> search_path TO ... but I have executed tha

Re: pg_dump and search_path

2019-07-09 Thread Igal @ Lucee.org
David, On 7/9/2019 7:49 AM, David G. Johnston wrote: On Tue, Jul 9, 2019 at 7:41 AM Igal @ Lucee.org > wrote: search_path is not set int he config, but rather with ALTER DATABASE SET search_path TO ... but I have executed that prior to the RESTORE on the

Re: pg_dump and search_path

2019-07-09 Thread David G. Johnston
On Tue, Jul 9, 2019 at 7:41 AM Igal @ Lucee.org wrote: > search_path is not set int he config, but rather with ALTER DATABASE SET > search_path TO ... but I have executed that prior to the RESTORE on the > target database. Would it make a difference if I set it in the config? > What is your res

Re: pg_dump and search_path

2019-07-09 Thread Igal @ Lucee.org
On 7/9/2019 7:02 AM, Adrian Klaver wrote: On 7/8/19 11:48 PM, Igal @ Lucee.org wrote: I have a custom search_path: # show search_path;     search_path --   "staging, transient, pg_catalog" (1 row) I ran `pg_dump --schema-only` and the only reference in t

Re: pg_dump and search_path

2019-07-09 Thread Adrian Klaver
On 7/9/19 6:28 AM, Ron wrote: Then should search_path be set at the end of pg_restore? 1) That would be to late for anything happening in the restore. 2) The: SELECT pg_catalog.set_config('search_path', '', false); only applies to the restore session. After the restore the search_path wi

Re: pg_dump and search_path

2019-07-09 Thread Adrian Klaver
On 7/8/19 11:48 PM, Igal @ Lucee.org wrote: I have a custom search_path: # show search_path;    search_path --  "staging, transient, pg_catalog" (1 row) I ran `pg_dump --schema-only` and the only reference in the output to search_path is:   SELECT p

Re: pg_dump and search_path

2019-07-09 Thread Ron
On 7/9/19 2:22 AM, Laurenz Albe wrote: On Mon, 2019-07-08 at 23:54 -0700, Igal @ Lucee.org wrote: I have a custom search_path: # show search_path; search_path -- "staging, transient, pg_catalog" (1 row) I ran `pg_dump --schema-only` and the only re

Re: pg_dump and search_path

2019-07-09 Thread Laurenz Albe
On Mon, 2019-07-08 at 23:54 -0700, Igal @ Lucee.org wrote: > > I have a custom search_path: > > > > # show search_path; > >search_path > > -- > > "staging, transient, pg_catalog" > > (1 row) > > > > I ran `pg_dump --schema-only` and the only reference

Re: pg_dump and search_path

2019-07-08 Thread Igal @ Lucee.org
On 7/8/2019 11:48 PM, Igal @ Lucee.org wrote: I have a custom search_path: # show search_path;    search_path --  "staging, transient, pg_catalog" (1 row) I ran `pg_dump --schema-only` and the only reference in the output to search_path is:   SELECT p

pg_dump and search_path

2019-07-08 Thread Igal @ Lucee.org
I have a custom search_path: # show search_path;    search_path --  "staging, transient, pg_catalog" (1 row) I ran `pg_dump --schema-only` and the only reference in the output to search_path is:   SELECT pg_catalog.set_config('search_path', '', false);