Skip site navigation (1) Skip section navigation (2)

Re: Extensions support for pg_dump, patch v27

From: Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr>, Itagaki Takahiro <itagaki(dot)takahiro(at)gmail(dot)com>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, David Fetter <david(at)fetter(dot)org>, PostgreSQL-Hackers <pgsql-hackers(at)postgresql(dot)org>, Dave Page <dpage(at)postgresql(dot)org>, Guillaume Lelarge <guillaume(at)lelarge(dot)info>
Subject: Re: Extensions support for pg_dump, patch v27
Date: 2011-01-27 11:01:46
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> writes:
> Oh: then you're doing it wrong.  If you want to remember that WITH
> SCHEMA was specified, you need to explicitly store that as another
> column in pg_extension.

Ok, done.  Of course, it solves the whole problem Itagaki had with
adminpack because we stop relying on dependencies to get it right now.

I've also added another parameter in the control file, named "schema".
It's only valid to use that when relocatable is false, and it allows to
force the schema where to install the extension.  When this schema does
not already exists, it will be created for the user.

Of course the adminpack extension's control file now has relocatable =
false and schema = 'pg_catalog'.

~=# create extension lo;
~=# create extension adminpack;
~=# \dx
                             List of extensions
   Schema   |   Name    | Version  |               Description               
 pg_catalog | adminpack | 9.1devel | Administrative functions for PostgreSQL
 utils      | lo        | 9.1devel | managing Large Objects
(2 rows)

~=# drop extension adminpack;
~=# create extension adminpack with schema utils;
ERROR:  this extension has to be installed in schema "pg_catalog"
~=# create extension adminpack with schema pg_catalog;
~=# alter extension adminpack set schema utils;
ERROR:  this extension does not support SET SCHEMA

The documentation is updated both in the patch and here:

Dimitri Fontaine     PostgreSQL : Expertise, Formation et Support

Attachment: extension.v28.patch.gz
Description: application/octet-stream (59.8 KB)

In response to


pgsql-hackers by date

Next:From: Itagaki TakahiroDate: 2011-01-27 12:02:15
Subject: Re: Extensions support for pg_dump, patch v27
Previous:From: Alexey KlyukinDate: 2011-01-27 10:38:53
Subject: Re: arrays as pl/perl input arguments [PATCH]

Privacy Policy | About PostgreSQL
Copyright © 1996-2018 The PostgreSQL Global Development Group