Re: [HACKERS] pg_restore -d doesn't display output

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, PostgreSQL-patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: [HACKERS] pg_restore -d doesn't display output
Date: 2003-10-08 17:48:43
Message-ID: 200310081748.h98Hmht14044@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

Peter Eisentraut wrote:
> Bruce Momjian writes:
>
> > I have patched pg_restore to output the script contents if you restore
> > with -v:
>
> I don't think it's a good idea to overload the -v switch with it. A
> separate switch seems OK, but I don't quite get the point of this
> functionality, actually.

Oh, OK. When I was testing, I didn't realize that pg_restore doesn't do
anything unless you specify the database via -d, but I see it in the
docs now:

pg_restore can operate in two modes: If a database name is
specified, the archive is restored directly into the
database. Otherwise, a script containing the SQL commands
necessary to rebuild the database is created (and written
to a file or standard output), similar to the ones created
by the pg_dump plain text format. Some of the options con-
trolling the script output are therefore analogous to
pg_dump options.

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Josh Berkus 2003-10-08 17:49:55 Re: PostgreSQL vs. MySQL
Previous Message Peter Eisentraut 2003-10-08 17:44:17 Re: [HACKERS] pg_restore -d doesn't display output

Browse pgsql-patches by date

  From Date Subject
Next Message Robert Treat 2003-10-08 18:07:20 akward wording in autovacuum README
Previous Message Peter Eisentraut 2003-10-08 17:44:17 Re: [HACKERS] pg_restore -d doesn't display output