dbTalk Databases Forums  

[BUGS] pg_dump dependency loop with extension containing its own schema

mailing.database.pgsql-bugs mailing.database.pgsql-bugs


Discuss [BUGS] pg_dump dependency loop with extension containing its own schema in the mailing.database.pgsql-bugs forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Thom Brown
 
Posts: n/a

Default [BUGS] pg_dump dependency loop with extension containing its own schema - 08-11-2012 , 05:55 PM






Hi,

I'm getting a dependency loop issue with pg_dump when adding a schema
to an extension where the schema being added is the same as the one
containing the extension.

CREATE EXTENSION file_fdw;
ALTER EXTENSION file_fdw ADD SCHEMA public;

$ pg_dump -f /dev/null test
pg_dump: [sorter] WARNING: could not resolve dependency loop among these items:
pg_dump: [sorter] SCHEMA public (ID 5 OID 2200)
pg_dump: [sorter] EXTENSION file_fdw (ID 170 OID 28912)

or

CREATE SCHEMA meow;
CREATE EXTENSION file_fdw WITH SCHEMA meow;
ALTER EXTENSION file_fdw ADD SCHEMA meow;

$ pg_dump -f /dev/null test
pg_dump: [sorter] WARNING: could not resolve dependency loop among these items:
pg_dump: [sorter] SCHEMA meow (ID 7 OID 28917)
pg_dump: [sorter] EXTENSION file_fdw (ID 171 OID 28918)

but not

CREATE SCHEMA meow;
CREATE EXTENSION file_fdw WITH SCHEMA meow;
ALTER EXTENSION file_fdw ADD SCHEMA public;

$ pg_dump -f /dev/null test3
$
(no errors shown)

I can produce this issue in 9.1.4 and head (as of commit
83af58f6b5657840f5924332fccecca1e3556abe).

Since this is a bug report, I'll include the necessary supporting info:
OS: Linux Mint x64
Kernel: 3.2.0-27-generic
CC version: Linaro 4.6.3-1ubuntu5
RAM: 16GB DDR3

--
Thom

-
Sent via pgsql-bugs mailing list (pgsql-bugs (AT) postgresql (DOT) org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs

Reply With Quote
  #2  
Old   
Tom Lane
 
Posts: n/a

Default Re: [BUGS] pg_dump dependency loop with extension containing its own schema - 08-11-2012 , 07:06 PM






Thom Brown <thom (AT) linux (DOT) com> writes:
Quote:
I'm getting a dependency loop issue with pg_dump when adding a schema
to an extension where the schema being added is the same as the one
containing the extension.

CREATE EXTENSION file_fdw;
ALTER EXTENSION file_fdw ADD SCHEMA public;
ISTM we ought to disallow that ... either the schema is inside the
extension, or vice versa, it's not sensible to say both.

regards, tom lane

-
Sent via pgsql-bugs mailing list (pgsql-bugs (AT) postgresql (DOT) org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs

Reply With Quote
  #3  
Old   
Thom Brown
 
Posts: n/a

Default Re: [BUGS] pg_dump dependency loop with extension containing its own schema - 08-12-2012 , 02:17 AM



On 12 August 2012 01:06, Tom Lane <tgl (AT) sss (DOT) pgh.pa.us> wrote:
Quote:
Thom Brown <thom (AT) linux (DOT) com> writes:
I'm getting a dependency loop issue with pg_dump when adding a schema
to an extension where the schema being added is the same as the one
containing the extension.

CREATE EXTENSION file_fdw;
ALTER EXTENSION file_fdw ADD SCHEMA public;

ISTM we ought to disallow that ... either the schema is inside the
extension, or vice versa, it's not sensible to say both.
Precisely.

--
Thom

-
Sent via pgsql-bugs mailing list (pgsql-bugs (AT) postgresql (DOT) org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs

Reply With Quote
  #4  
Old   
Thom Brown
 
Posts: n/a

Default Re: [BUGS] pg_dump dependency loop with extension containing its own schema - 08-15-2012 , 08:00 AM



On 12 August 2012 08:17, Thom Brown <thom (AT) linux (DOT) com> wrote:
Quote:
On 12 August 2012 01:06, Tom Lane <tgl (AT) sss (DOT) pgh.pa.us> wrote:
Thom Brown <thom (AT) linux (DOT) com> writes:
I'm getting a dependency loop issue with pg_dump when adding a schema
to an extension where the schema being added is the same as the one
containing the extension.

CREATE EXTENSION file_fdw;
ALTER EXTENSION file_fdw ADD SCHEMA public;

ISTM we ought to disallow that ... either the schema is inside the
extension, or vice versa, it's not sensible to say both.

Precisely.
Suggested changes attached. (not really confident about it though)

--
Thom


--
Sent via pgsql-bugs mailing list (pgsql-bugs (AT) postgresql (DOT) org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs

Reply With Quote
  #5  
Old   
Tom Lane
 
Posts: n/a

Default Re: [BUGS] pg_dump dependency loop with extension containing its own schema - 08-15-2012 , 10:30 AM



Thom Brown <thom (AT) linux (DOT) com> writes:
Quote:
On 12 August 2012 08:17, Thom Brown <thom (AT) linux (DOT) com> wrote:
On 12 August 2012 01:06, Tom Lane <tgl (AT) sss (DOT) pgh.pa.us> wrote:
ISTM we ought to disallow that ... either the schema is inside the
extension, or vice versa, it's not sensible to say both.

Precisely.

Suggested changes attached. (not really confident about it though)
Applied with minor editorialization. Thanks!

regards, tom lane


--
Sent via pgsql-bugs mailing list (pgsql-bugs (AT) postgresql (DOT) org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs

Reply With Quote
  #6  
Old   
Thom Brown
 
Posts: n/a

Default Re: [BUGS] pg_dump dependency loop with extension containing its own schema - 08-15-2012 , 10:51 AM



On 15 August 2012 16:30, Tom Lane <tgl (AT) sss (DOT) pgh.pa.us> wrote:
Quote:
Thom Brown <thom (AT) linux (DOT) com> writes:
On 12 August 2012 08:17, Thom Brown <thom (AT) linux (DOT) com> wrote:
On 12 August 2012 01:06, Tom Lane <tgl (AT) sss (DOT) pgh.pa.us> wrote:
ISTM we ought to disallow that ... either the schema is inside the
extension, or vice versa, it's not sensible to say both.

Precisely.

Suggested changes attached. (not really confident about it though)

Applied with minor editorialization. Thanks!
Cheers Tom.

--
Thom


--
Sent via pgsql-bugs mailing list (pgsql-bugs (AT) postgresql (DOT) org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.