BUG #6318: pg_dump for non-template languages is broken

From: laurenz(dot)albe(at)wien(dot)gv(dot)at
To: pgsql-bugs(at)postgresql(dot)org
Subject: BUG #6318: pg_dump for non-template languages is broken
Date: 2011-12-02 11:06:41
Message-ID: E1RWQwz-0005Ug-06@wrigleys.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

The following bug has been logged on the website:

Bug reference: 6318
Logged by: Laurenz Albe
Email address: laurenz(dot)albe(at)wien(dot)gv(dot)at
PostgreSQL version: 9.1.1
Operating system: Linux (RHEL 3)
Description:

How to reproduce:

postgres=# CREATE DATABASE dumpme;
postgres=# \c dumpme postgres
dumpme=# CREATE LANGUAGE mylang HANDLER plpgsql_call_handler INLINE
plpgsql_inline_handler VALIDATOR plpgsql_validator;
dumpme=# \q

$ pg_dump -C -F p -f dumpme.sql dumpme

$ psql -c 'DROP DATABASE dumpme'

$ psql -f dumpme.sql
[...]
psql:dumpme.sql:32: ERROR: unsupported language "mylang"
HINT: The supported languages are listed in the pg_pltemplate system
catalog.
psql:dumpme.sql:35: ERROR: language "mylang" does not exist
[...]

The reason is that the dump contains:

--
-- Name: mylang; Type: PROCEDURAL LANGUAGE; Schema: -; Owner: advpg
--

CREATE OR REPLACE PROCEDURAL LANGUAGE mylang;

ALTER PROCEDURAL LANGUAGE mylang OWNER TO advpg;

Yours,
Laurenz Albe

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Josh Kupershmidt 2011-12-02 14:31:55 Re: 9.1.1 hot standby startup gets sigbus
Previous Message Thomas Goerner 2011-12-02 10:56:36 Re: BUG #6308: Problem w. encoding in client