Received: from makus.postgresql.org (makus.postgresql.org [98.129.198.125]) by mail.postgresql.org (Postfix) with ESMTP id 224BCDDBC2A for ; Fri, 2 Dec 2011 13:28:25 -0400 (AST) Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1RWWuO-0008Ke-Nr for pgsql-bugs@postgresql.org; Fri, 02 Dec 2011 17:28:25 +0000 Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.2/8.14.2) with ESMTP id pB2HSClf019870; Fri, 2 Dec 2011 12:28:12 -0500 (EST) To: laurenz.albe@wien.gv.at cc: pgsql-bugs@postgresql.org Subject: Re: BUG #6318: pg_dump for non-template languages is broken In-reply-to: References: Comments: In-reply-to laurenz.albe@wien.gv.at message dated "Fri, 02 Dec 2011 11:06:41 +0000" Date: Fri, 02 Dec 2011 12:28:11 -0500 Message-ID: <19869.1322846891@sss.pgh.pa.us> From: Tom Lane X-Pg-Spam-Score: -3.1 (---) X-Archive-Number: 201112/27 X-Sequence-Number: 31838 laurenz.albe@wien.gv.at writes: > dumpme=# CREATE LANGUAGE mylang HANDLER plpgsql_call_handler INLINE > plpgsql_inline_handler VALIDATOR plpgsql_validator; I don't think this is a particularly interesting use-case. The reason it doesn't work for you is that it's depending on support functions that are in pg_catalog, and as the comment in pg_dump.c says: /* * Try to find the support function(s). It is not an error if we don't * find them --- if the functions are in the pg_catalog schema, as is * standard in 8.1 and up, then we won't have loaded them. (In this case * we will emit a parameterless CREATE LANGUAGE command, which will * require PL template knowledge in the backend to reload.) */ An actual add-on procedural language would not fall foul of this. regards, tom lane