Re: [HACKERS] Create language syntax is not proper in pg_dumpall and not working using pg_upgrade

2017-07-25 Thread Robert Haas
On Tue, Jul 25, 2017 at 1:50 PM, Tom Lane wrote: > Andres Freund writes: >> I'm not sure what you're arguing for here. > > Robert wants perfection, of course ;-). As do we all. But there are > only so many hours in the day, and rejiggering pg_dump's

Re: [HACKERS] Create language syntax is not proper in pg_dumpall and not working using pg_upgrade

2017-07-25 Thread Tom Lane
"Joshua D. Drake" writes: > Isn't the simplest solution just to actually document this? Given that it's behaved this way since 8.1 (maybe earlier, I'm not sure), and nobody has complained before, I'm not sure it's worth documenting. There are lots of undocumented

Re: [HACKERS] Create language syntax is not proper in pg_dumpall and not working using pg_upgrade

2017-07-25 Thread Tom Lane
Andres Freund writes: > I'm not sure what you're arguing for here. Robert wants perfection, of course ;-). As do we all. But there are only so many hours in the day, and rejiggering pg_dump's rules about how to dump PLs is just way down the to-do list. I'm going to go do

Re: [HACKERS] Create language syntax is not proper in pg_dumpall and not working using pg_upgrade

2017-07-25 Thread Joshua D. Drake
On 07/25/2017 10:24 AM, Andres Freund wrote: On 2017-07-25 13:18:25 -0400, Robert Haas wrote: On Tue, Jul 25, 2017 at 1:13 PM, Andres Freund wrote: On 2017-07-25 13:10:11 -0400, Robert Haas wrote: On Tue, Jul 25, 2017 at 1:06 PM, Tom Lane wrote: Is

Re: [HACKERS] Create language syntax is not proper in pg_dumpall and not working using pg_upgrade

2017-07-25 Thread Andres Freund
On 2017-07-25 13:18:25 -0400, Robert Haas wrote: > On Tue, Jul 25, 2017 at 1:13 PM, Andres Freund wrote: > > On 2017-07-25 13:10:11 -0400, Robert Haas wrote: > >> On Tue, Jul 25, 2017 at 1:06 PM, Tom Lane wrote: > >> >> Is this assumption, like, documented

Re: [HACKERS] Create language syntax is not proper in pg_dumpall and not working using pg_upgrade

2017-07-25 Thread Robert Haas
On Tue, Jul 25, 2017 at 1:13 PM, Andres Freund wrote: > On 2017-07-25 13:10:11 -0400, Robert Haas wrote: >> On Tue, Jul 25, 2017 at 1:06 PM, Tom Lane wrote: >> >> Is this assumption, like, documented someplace? >> > >> > Uh, right there? >> >> I don't

Re: [HACKERS] Create language syntax is not proper in pg_dumpall and not working using pg_upgrade

2017-07-25 Thread Andres Freund
On 2017-07-25 13:10:11 -0400, Robert Haas wrote: > On Tue, Jul 25, 2017 at 1:06 PM, Tom Lane wrote: > >> Is this assumption, like, documented someplace? > > > > Uh, right there? > > I don't think we can expect end-users to read the code comments to > determine whether their

Re: [HACKERS] Create language syntax is not proper in pg_dumpall and not working using pg_upgrade

2017-07-25 Thread Robert Haas
On Tue, Jul 25, 2017 at 1:06 PM, Tom Lane wrote: >> Is this assumption, like, documented someplace? > > Uh, right there? I don't think we can expect end-users to read the code comments to determine whether their apparently-legal SQL is fully supported. -- Robert Haas

Re: [HACKERS] Create language syntax is not proper in pg_dumpall and not working using pg_upgrade

2017-07-25 Thread Tom Lane
Robert Haas writes: > On Tue, Jul 25, 2017 at 10:31 AM, Tom Lane wrote: >> pg_dump doesn't really support that scenario, and I don't feel any >> great need to make it do so. Per the comment in dumpProcLang: > Is this assumption, like, documented

Re: [HACKERS] Create language syntax is not proper in pg_dumpall and not working using pg_upgrade

2017-07-25 Thread Robert Haas
On Tue, Jul 25, 2017 at 10:31 AM, Tom Lane wrote: > tushar writes: >> postgres=# CREATE LANGUAGE alt_lang1 HANDLER plpgsql_call_handler; >> CREATE LANGUAGE > > pg_dump doesn't really support that scenario, and I don't feel any > great need to

Re: [HACKERS] Create language syntax is not proper in pg_dumpall and not working using pg_upgrade

2017-07-25 Thread Tom Lane
tushar writes: > postgres=# CREATE LANGUAGE alt_lang1 HANDLER plpgsql_call_handler; > CREATE LANGUAGE pg_dump doesn't really support that scenario, and I don't feel any great need to make it do so. Per the comment in dumpProcLang: * Try to find the

Re: [HACKERS] Create language syntax is not proper in pg_dumpall and not working using pg_upgrade

2017-07-25 Thread Thom Brown
On 25 July 2017 at 12:09, tushar wrote: > v9.6 > > postgres=# CREATE LANGUAGE alt_lang1 HANDLER plpgsql_call_handler; > CREATE LANGUAGE > postgres=# \q > > v10 , run pg_upgrade - failing with this error - > > pg_restore: creating pg_largeobject_metadata

[HACKERS] Create language syntax is not proper in pg_dumpall and not working using pg_upgrade

2017-07-25 Thread tushar
v9.6 postgres=# CREATE LANGUAGE alt_lang1 HANDLER plpgsql_call_handler; CREATE LANGUAGE postgres=# \q v10 , run pg_upgrade - failing with this error - pg_restore: creating pg_largeobject_metadata "pg_largeobject_metadata" pg_restore: creating COMMENT "postgres" pg_restore: creating SCHEMA