Re: pg_dump

From: Bob Pawley <rjpawley(at)shaw(dot)ca>
To: Erik Jones <erik(at)myemma(dot)com>
Cc: PostgreSQL <pgsql-general(at)postgresql(dot)org>
Subject: Re: pg_dump
Date: 2007-12-07 18:14:46
Message-ID: 003901c838fd$0ceb2ec0$6401a8c0@owner
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Thanks Erik. In between those attempts I did try what you suggest.

It failed, apparently due to not making a connection with the server.

Bob
----- Original Message -----
From: "Erik Jones" <erik(at)myemma(dot)com>
To: "Bob Pawley" <rjpawley(at)shaw(dot)ca>
Cc: "PostgreSQL" <pgsql-general(at)postgresql(dot)org>
Sent: Friday, December 07, 2007 9:58 AM
Subject: Re: [GENERAL] pg_dump

On Dec 7, 2007, at 11:38 AM, Bob Pawley wrote:

> Hi
>
> I am having a little more success with the pg_dump command. However, I
> still seem to have something wrong.
>
> I use the following command after navigating to the bin file -
>
> pg_dump -h localhost -d Aurel -U postgres
>
> After six attempts -
>
> Each attempt processed the database and the command prompt announced a
> successful completion.
>
> after 3 attempts - no dump file was found
> after 2 attempts - a dump file of 0kb was found.
> after the sixth attempt a good dump file of 4 meg made it to the bin
> folder. I was able to install this file successfully.
>
> Is it usual to require multiple attempts for each successful dump???
>
> If not, does anyone have thoughts on where the problem could be??

If that's all you're doing then I'm surprised you ever saw a file at
all. pg_dump writes to standard output unless you give it a file
name to write to with the -f flag. So, from your bin directory (I
normally just put it in my environment PATH variable).

./pg_dump -h localhost -d Aurel -U postgres -f dumpfile.sql

or

.pg_dump -h localhost -d Aurel -U postgres > dumpfile.sql

Erik Jones

Software Developer | Emma®
erik(at)myemma(dot)com
800.595.4401 or 615.292.5888
615.292.0777 (fax)

Emma helps organizations everywhere communicate & market in style.
Visit us online at http://www.myemma.com

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Marc Munro 2007-12-07 18:54:07 Identifying casts
Previous Message Shelby Cain 2007-12-07 18:06:42 Column pgl.transaction does not exist in 8.3 beta 4