Re: Execute pg_dump using psql

Поиск
Список
Период
Сортировка
От Richard Harris
Тема Re: Execute pg_dump using psql
Дата
Msg-id D6EE939FB590D84CB70371C2CB8CA34C1AE7BA@nexus.plaza.ds.adp.com
обсуждение исходный текст
Ответ на Execute pg_dump using psql  ("Richard Harris" <Richard_Harris@adp.com>)
Ответы Re: Execute pg_dump using psql
Список pgsql-admin
 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

В списке pgsql-admin по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: PG 7.2 varchar change
Следующее
От: Tom Lane
Дата:
Сообщение: Re: can't authenticate pg admin