X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 230C95E46CF for ; Sat, 14 Aug 2004 00:06:31 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 67069-07 for ; Sat, 14 Aug 2004 03:06:33 +0000 (GMT) Received: from candle.pha.pa.us (candle.pha.pa.us [207.106.42.251]) by svr1.postgresql.org (Postfix) with ESMTP id DA73E5E46C1 for ; Sat, 14 Aug 2004 00:06:24 -0300 (ADT) Received: (from pgman@localhost) by candle.pha.pa.us (8.11.6/8.11.6) id i7E36UB21275; Fri, 13 Aug 2004 23:06:30 -0400 (EDT) From: Bruce Momjian Message-Id: <200408140306.i7E36UB21275@candle.pha.pa.us> Subject: Re: Execute pg_dump using psql In-Reply-To: To: Richard Harris Date: Fri, 13 Aug 2004 23:06:30 -0400 (EDT) Cc: pgsql-admin@postgresql.org X-Mailer: ELM [version 2.4ME+ PL108 (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200408/117 X-Sequence-Number: 14512 We think we have found the cause and it will be fixed in 8.0 beta2. I assume you are testing 8.0beta1? --------------------------------------------------------------------------- Richard Harris wrote: > Hi, > > I found my problem. When I put the 'pg_dump' command in a file, I used a > 'Windows' editor instead of a 'Unix' editor. This appears to have caused > the problem. When I converted to file from 'DOS' to 'Unix' format, psql > executed the command in the file with no error. Sorry for the false > alarm. > > Thanks, > Rich > > -----Original Message----- > From: Richard Harris > Sent: Thursday, August 12, 2004 12:25 PM > To: 'pgsql-admin@postgresql.org' > Subject: Execute pg_dump using psql > > Hi, > > I'm trying to use the psql application to execute pg_dump to backup a > database named test_db. When I run psql interactively, as user dba > connected to database test_db, and enter the command > > \! pg_dump -U dba -f /backup/adp_test_db.bak -F c test_db > > The command executes with no error and the database gets backed up. > However, when I put the command in the file /backup/backup.cmd and pass > the file to psql as > > psql -f /backup/backup.cmd test_db dba > > The command fails with the message " does not exist database > "test_dbdatabase "test_db. > > Please tell me what I am doing wrong. > > Thanks, > Rich Harris > > ---------------------------(end of broadcast)--------------------------- > TIP 7: don't forget to increase your free space map settings > -- Bruce Momjian | http://candle.pha.pa.us pgman@candle.pha.pa.us | (610) 359-1001 + If your life is a hard drive, | 13 Roberts Road + Christ can be your backup. | Newtown Square, Pennsylvania 19073