Re: pg_dump/PgAdmin problem? - Mailing list pgsql-general

From Stephan Szabo
Subject Re: pg_dump/PgAdmin problem?
Date
Msg-id 20020129134935.C95254-100000@megazone23.bigpanda.com
Whole thread Raw
In response to Re: pg_dump/PgAdmin problem?  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: pg_dump/PgAdmin problem?  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
On Tue, 29 Jan 2002, Tom Lane wrote:

> "Gregory Wood" <gregw@com-stock.com> writes:
> > I've tracked down the problem and it seems it doesn't like two view
> > definitions (pgadmin_sequences and pgadmin_tables), and therefore the
> > subsequent GRANTs. The views are at the end of the email.
>
> The views are difficult to do much with when we can't run them through
> the software ... which we can't do without the context of the underlying
> table definitions.  Could you provide the complete schema dump
> (pg_dump -s)?

My guess is the problem is that the views use column(func(params))
which get output by pg_dump as func(params).column.  I can replicate in
7.2beta4 with a simpler case, but haven't looked any further.

create table eee1( a int, b int);
create function foo1(int) returns eee1 as 'select * from eee1
limit 1;' language 'sql';
create view vv1 as select b(foo1(3));

sszabo@bills:~ $ pg_dump -s -t vv1 sszabo
--
-- Selected TOC Entries:
--
\connect - sszabo

--
-- TOC Entry ID 2 (OID 4938784)
--
-- Name: vv1 Type: VIEW Owner: sszabo
--

CREATE VIEW "vv1" as SELECT foo1(3).b AS b;

sszabo@bills:~ $ pg_dump -s -t vv1 sszabo | psql
You are now connected as new user sszabo.
ERROR:  parser: parse error at or near "."


pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: outer joins complexity
Next
From: "Gregory Wood"
Date:
Subject: Re: pg_dump/PgAdmin problem?