From 7af5ea736f680109de569b00f2c36ea8e0211aea Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Tue, 27 Aug 2002 18:57:26 +0000 Subject: Reimplement pg_dumpall in C. Currently no change in functionality, except that it's more robust, reconnects less often, and is NLS'ed. --- doc/src/sgml/ref/pg_dump.sgml | 26 ++--- doc/src/sgml/ref/pg_dumpall.sgml | 225 ++++++++++++++++++++++++++------------- 2 files changed, 166 insertions(+), 85 deletions(-) (limited to 'doc/src') diff --git a/doc/src/sgml/ref/pg_dump.sgml b/doc/src/sgml/ref/pg_dump.sgml index e96a443e0c3..fbfdcb3c2a4 100644 --- a/doc/src/sgml/ref/pg_dump.sgml +++ b/doc/src/sgml/ref/pg_dump.sgml @@ -1,5 +1,5 @@ @@ -112,13 +112,13 @@ PostgreSQL documentation does not block other users accessing the database (readers or writers). + - - Options + + Options - - pg_dump accepts the following command - line arguments. (Long option forms are only available on some platforms.) + + The following command-line options are used to control the output format. @@ -408,7 +408,9 @@ PostgreSQL documentation - Specifies verbose mode. + Specifies verbose mode. This will cause + pg_dump to print progress messages + to standard error. @@ -499,13 +501,11 @@ PostgreSQL documentation - - + - pg_dump also accepts - the following command line arguments for connection parameters: + The following command-line options control the database connection parameters. @@ -555,8 +555,10 @@ PostgreSQL documentation - + + Long option forms are only available on some platforms. + diff --git a/doc/src/sgml/ref/pg_dumpall.sgml b/doc/src/sgml/ref/pg_dumpall.sgml index 9f46b43a82c..869f480a341 100644 --- a/doc/src/sgml/ref/pg_dumpall.sgml +++ b/doc/src/sgml/ref/pg_dumpall.sgml @@ -1,5 +1,5 @@ @@ -12,18 +12,13 @@ PostgreSQL documentation pg_dumpall - extract all PostgreSQL databases into a script file + extract a PostgreSQL database cluster into a script file pg_dumpall - -c--clean - -g--globals-only - -h host - -p port - -U username - -W + options @@ -66,97 +61,161 @@ PostgreSQL documentation The SQL script will be written to the standard output. Shell operators should be used to redirect it into a file. - - - - pg_dumpall will need to connect several times to the - PostgreSQL server, asking for the password each - time. It will probably be very convenient to have a PGPASSWORDFILE in that case. - - Options - - pg_dumpall accepts the following - command line arguments: + + The following command-line options are used to control the output format. - - - -c, --clean - - + + + -c, --clean + + Include SQL commands to clean (drop) database objects before recreating them. (This option is fairly useless, since the output script expects to create the databases themselves; they would always be empty upon creation.) - - - - - - -g, --globals-only - - + + + + + + + + + + Dump data as INSERT commands (rather + than COPY). This will make restoration very + slow, but it makes the output more portable to other RDBMS + packages. + + + + + + + + + + + Dump data as INSERT commands with explicit + column names (INSERT INTO + table + (column, ...) VALUES + ...). This will make restoration very slow, + but it is necessary if you desire to rearrange column ordering. + + + + + + -g, --globals-only + + Only dump global objects (users and groups), no databases. - - - - - - -h host - - + + + + + + + + + + Ignore version mismatch between + pg_dumpall and the database server. + Since pg_dumpall knows a great deal + about system catalogs, any given version of + pg_dumpall is only intended to work + with the corresponding release of the database server. Use + this option if you need to override the version check (and if + pg_dumpall then fails, don't say + you weren't warned). + + + + + + + + + + Dump object identifiers (OIDs) for every + table. Use this option if your application references the OID + columns in some way (e.g., in a foreign key constraint). + Otherwise, this option should not be used. + + + + + + + + + + Specifies verbose mode. This will cause + pg_dumpall to print progress + messages to standard error. + + + + + + + + The following command-line options control the database connection parameters. + + + + -h host + + Specifies the host name of the machine on which the database server is running. If host begins with a slash, it is used as the directory for the Unix domain socket. The default is taken from the PGHOST environment variable, if set, else a Unix domain socket connection is attempted. - - - - - - -p port - - + + + + + + -p port + + The port number on which the server is listening. Defaults to the PGPORT environment variable, if set, or a compiled-in default. - - - - - - -U username - - + + + + + + -U username + + Connect as the given user. - - - - - - -W - - + + + + + + -W + + Force a password prompt. This should happen automatically if the server requires password authentication. - - - + + + - Any other command line parameters are passed to the underlying - - calls. This is useful to control some aspects of the output - format, but some options such as , - , , and dbname should be avoided. + Long options are only available on some platforms. @@ -180,6 +239,26 @@ PostgreSQL documentation + + Notes + + + Since pg_dumpall calls + pg_dump internally, some diagnostic + messages will refer to pg_dump. + + + + pg_dumpall will need to connect several + times to the PostgreSQL server. If password + authentication is configured, it will ask for a password each time. In + that case it would be convenient to set up a password file. + + + But where is that password file documented? + + + Examples -- cgit v1.2.3