Mario Weilguni <[EMAIL PROTECTED]> writes:
> Here are the problems I've encountered:
> * pg_restore tries to create a table with ltree and ltree[] datatypes before the 
>type itself is created, so it fails.

Odd; what are the OIDs of the table and the datatypes?

> * several functions are already defined in template1, so "create database " will 
>restore these functions. pg_restore will try to restore those functions as well
>   and fails. Maybe "create or replace function" can be used here?

No.  Use pg_restore per the documentation: make an empty database for it
to restore into (by cloning template0 instead of template1).

>   pg_restore: [archiver (db)] could not execute query: ERROR:  data type ltree[] has 
>no default operator class for access method "gist"
>           You must specify an operator class for the index or define a
>           default operator class for the data type

Are you using recent sources?  As of two weeks or so ago, pg_dump should
know how to dump operator classes.

                        regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

Reply via email to