Re: BUG #9616: Materialized view with indexes unable to load from pg_dump - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #9616: Materialized view with indexes unable to load from pg_dump
Date
Msg-id 9030.1395154727@sss.pgh.pa.us
Whole thread Raw
In response to BUG #9616: Materialized view with indexes unable to load from pg_dump  (jesse.denardo@myfarms.com)
Responses Re: BUG #9616: Materialized view with indexes unable to load from pg_dump  (Jesse Denardo <jesse.denardo@myfarms.com>)
List pgsql-bugs
jesse.denardo@myfarms.com writes:
> I have created several materialized views on one database. To copy data to a
> new database, I dump the schema(s) of choice using pg_dump and pipe the
> result to psql. The exact command looks like:

> $ pg_dump -b -n <schema> -O -x -h localhost -U <user> <db> | psql -h <other
> host> -d <other db> -U <other user>

> The materialized views get copied and restored just fine with one exception:
> The one mat view that has indexes. Here is the result of \d on this mat
> view:

I can't reproduce this here; it seems clear that there's some triggering
condition other than the mere presence of indexes.  Could you submit a
*self contained* example (preferably, a SQL script that makes a database
that pg_dump misbehaves on)?

The output looks a little bit like pg_dump might be trying to break some
circular dependency involving the matview.  But it's not obvious how
you'd have gotten into such a situation, and we certainly haven't been
shown all the moving parts.

            regards, tom lane

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #9620: pg_dumpall -i --globals-only = wrong behaviour
Next
From: Sandro Santilli
Date:
Subject: Leaking regexp_replace in 9.3.1 ? (was: [HACKERSUninterruptable regexp_replace in 9.3.1 ?)