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

Re: pg_dump: SQL command failed

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Thangalin <thangalin(at)gmail(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: pg_dump: SQL command failed
Date: 2012-05-14 03:26:27
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-bugs
Thangalin <thangalin(at)gmail(dot)com> writes:
> 4. Dump the schema using pg_dump:
> pg_dump -n *superschema* --inserts *superdatabase* > superduper.sql

This does not dump the extension, because the extension is not within
the schema "superschema".  (It definitely isn't given your creation
command, but pg_dump doesn't consider that extensions are inside schemas
anyway, for the purposes of options such as "-n".)  So on reload, the
user function fails; it's referencing a function that doesn't exist
in the new database.  That's not a bug.

BTW, the reason the unaccent function isn't marked immutable is that its
behavior can be changed with ALTER TEXT DICTIONARY.  This wrapper
function doesn't eliminate that risk (in fact it adds some new ones),
so it doesn't look very safe to me.

			regards, tom lane

In response to


pgsql-bugs by date

Next:From: SuhadDate: 2012-05-14 08:38:34
Subject: Fatal error in my PostgreSQL
Previous:From: ThangalinDate: 2012-05-14 02:52:24
Subject: Re: pg_dump: SQL command failed

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