pg.ddx.io pgsql-jdbc@postgresql.org mailing list archive
help / color / mirror / Atom feedpg_dump syntax
2+ messages / 2 participants
[nested] [flat]
* pg_dump syntax
@ 2006-04-02 22:06 Michael Schmidt <michaelmschmidt@msn.com>
2006-04-02 22:19 ` Re: pg_dump syntax Oliver Jowett <oliver@opencloud.com>
0 siblings, 1 reply; 2+ messages in thread
From: Michael Schmidt @ 2006-04-02 22:06 UTC (permalink / raw)
To: pgsql-jdbc
Folks,
Sorry to be a bother, but I can't figure out how to do pg_dump of a database with jdbc. I've tried a variety of syntaxes to no avail and searched through the archives and the web with no help. Here is my last attempt
SELECT pg_dump -Fc -f E:\backup\test.pgb npbase
What am I doing wrong?
Thanks
Michael Schmidt
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: pg_dump syntax
2006-04-02 22:06 pg_dump syntax Michael Schmidt <michaelmschmidt@msn.com>
@ 2006-04-02 22:19 ` Oliver Jowett <oliver@opencloud.com>
0 siblings, 0 replies; 2+ messages in thread
From: Oliver Jowett @ 2006-04-02 22:19 UTC (permalink / raw)
To: Michael Schmidt <michaelmschmidt@msn.com>; +Cc: pgsql-jdbc
Michael Schmidt wrote:
> Folks,
> Sorry to be a bother, but I can't figure out how to do pg_dump of a
> database with jdbc. I've tried a variety of syntaxes to no avail and
> searched through the archives and the web with no help. Here is my last
> attempt
>
> SELECT pg_dump -Fc -f E:\backup\test.pgb npbase
>
> What am I doing wrong?
pg_dump is not a SQL command implemented by the DB backend. It is an
executable client program that connects to the DB backend itself and
runs various SQL queries to extract the database structure and data.
If you want to run pg_dump from Java, you need to be using
Runtime.exec() or similar.
You could also reimplement pg_dump's logic using JDBC, but I strongly
recommend you don't do that!
-O
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2006-04-02 22:19 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2006-04-02 22:06 pg_dump syntax Michael Schmidt <michaelmschmidt@msn.com>
2006-04-02 22:19 ` Oliver Jowett <oliver@opencloud.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox