diff options
Diffstat (limited to 'doc/src')
-rw-r--r-- | doc/src/sgml/ref/pg_dump.sgml | 130 | ||||
-rw-r--r-- | doc/src/sgml/ref/pg_dumpall.sgml | 138 | ||||
-rw-r--r-- | doc/src/sgml/ref/pg_restore.sgml | 102 |
3 files changed, 185 insertions, 185 deletions
diff --git a/doc/src/sgml/ref/pg_dump.sgml b/doc/src/sgml/ref/pg_dump.sgml index cca2ed4e4f6..c24cc394d66 100644 --- a/doc/src/sgml/ref/pg_dump.sgml +++ b/doc/src/sgml/ref/pg_dump.sgml @@ -559,25 +559,6 @@ PostgreSQL documentation </varlistentry> <varlistentry> - <term><option>--inserts</option></term> - <listitem> - <para> - Dump data as <command>INSERT</command> commands (rather - than <command>COPY</command>). This will make restoration very slow; - it is mainly useful for making dumps that can be loaded into - non-<productname>PostgreSQL</productname> databases. - However, since this option generates a separate command for each row, - an error in reloading a row causes only that row to be lost rather - than the entire table contents. - Note that - the restore might fail altogether if you have rearranged column order. - The <option>--column-inserts</option> option is safe against column - order changes, though even slower. - </para> - </listitem> - </varlistentry> - - <varlistentry> <term><option>--column-inserts</option></term> <term><option>--attribute-inserts</option></term> <listitem> @@ -634,6 +615,25 @@ PostgreSQL documentation </varlistentry> <varlistentry> + <term><option>--inserts</option></term> + <listitem> + <para> + Dump data as <command>INSERT</command> commands (rather + than <command>COPY</command>). This will make restoration very slow; + it is mainly useful for making dumps that can be loaded into + non-<productname>PostgreSQL</productname> databases. + However, since this option generates a separate command for each row, + an error in reloading a row causes only that row to be lost rather + than the entire table contents. + Note that + the restore might fail altogether if you have rearranged column order. + The <option>--column-inserts</option> option is safe against column + order changes, though even slower. + </para> + </listitem> + </varlistentry> + + <varlistentry> <term><option>--lock-wait-timeout=<replaceable class="parameter">timeout</replaceable></option></term> <listitem> <para> @@ -650,36 +650,10 @@ PostgreSQL documentation </varlistentry> <varlistentry> - <term><option>--serializable-deferrable</option></term> + <term><option>--no-security-labels</option></term> <listitem> <para> - Use a <literal>serializable</literal> transaction for the dump, to - ensure that the snapshot used is consistent with later database - states; but do this by waiting for a point in the transaction stream - at which no anomalies can be present, so that there isn't a risk of - the dump failing or causing other transactions to roll back with a - <literal>serialization_failure</literal>. See <xref linkend="mvcc"> - for more information about transaction isolation and concurrency - control. - </para> - - <para> - This option is not beneficial for a dump which is intended only for - disaster recovery. It could be useful for a dump used to load a - copy of the database for reporting or other read-only load sharing - while the original database continues to be updated. Without it the - dump may reflect a state which is not consistent with any serial - execution of the transactions eventually committed. For example, if - batch processing techniques are used, a batch may show as closed in - the dump without all of the items which are in the batch appearing. - </para> - - <para> - This option will make no difference if there are no read-write - transactions active when pg_dump is started. If read-write - transactions are active, the start of the dump may be delayed for an - indeterminate length of time. Once running, performance with or - without the switch is the same. + Do not dump security labels. </para> </listitem> </varlistentry> @@ -702,47 +676,73 @@ PostgreSQL documentation </varlistentry> <varlistentry> - <term><option>--no-security-labels</option></term> + <term><option>--no-unlogged-table-data</option></term> <listitem> <para> - Do not dump security labels. + Do not dump the contents of unlogged tables. This option has no + effect on whether or not the table definitions (schema) are dumped; + it only suppresses dumping the table data. </para> </listitem> </varlistentry> <varlistentry> - <term><option>--use-set-session-authorization</></term> + <term><option>--quote-all-identifiers</></term> <listitem> <para> - Output SQL-standard <command>SET SESSION AUTHORIZATION</> commands - instead of <command>ALTER OWNER</> commands to determine object - ownership. This makes the dump more standards-compatible, but - depending on the history of the objects in the dump, might not restore - properly. Also, a dump using <command>SET SESSION AUTHORIZATION</> - will certainly require superuser privileges to restore correctly, - whereas <command>ALTER OWNER</> requires lesser privileges. + Force quoting of all identifiers. This may be useful when dumping a + database for migration to a future version that may have introduced + additional keywords. </para> </listitem> </varlistentry> <varlistentry> - <term><option>--no-unlogged-table-data</option></term> + <term><option>--serializable-deferrable</option></term> <listitem> <para> - Do not dump the contents of unlogged tables. This option has no - effect on whether or not the table definitions (schema) are dumped; - it only suppresses dumping the table data. + Use a <literal>serializable</literal> transaction for the dump, to + ensure that the snapshot used is consistent with later database + states; but do this by waiting for a point in the transaction stream + at which no anomalies can be present, so that there isn't a risk of + the dump failing or causing other transactions to roll back with a + <literal>serialization_failure</literal>. See <xref linkend="mvcc"> + for more information about transaction isolation and concurrency + control. + </para> + + <para> + This option is not beneficial for a dump which is intended only for + disaster recovery. It could be useful for a dump used to load a + copy of the database for reporting or other read-only load sharing + while the original database continues to be updated. Without it the + dump may reflect a state which is not consistent with any serial + execution of the transactions eventually committed. For example, if + batch processing techniques are used, a batch may show as closed in + the dump without all of the items which are in the batch appearing. + </para> + + <para> + This option will make no difference if there are no read-write + transactions active when pg_dump is started. If read-write + transactions are active, the start of the dump may be delayed for an + indeterminate length of time. Once running, performance with or + without the switch is the same. </para> </listitem> </varlistentry> <varlistentry> - <term><option>--quote-all-identifiers</></term> + <term><option>--use-set-session-authorization</></term> <listitem> <para> - Force quoting of all identifiers. This may be useful when dumping a - database for migration to a future version that may have introduced - additional keywords. + Output SQL-standard <command>SET SESSION AUTHORIZATION</> commands + instead of <command>ALTER OWNER</> commands to determine object + ownership. This makes the dump more standards-compatible, but + depending on the history of the objects in the dump, might not restore + properly. Also, a dump using <command>SET SESSION AUTHORIZATION</> + will certainly require superuser privileges to restore correctly, + whereas <command>ALTER OWNER</> requires lesser privileges. </para> </listitem> </varlistentry> diff --git a/doc/src/sgml/ref/pg_dumpall.sgml b/doc/src/sgml/ref/pg_dumpall.sgml index 039e86ec90d..7c49c0364fb 100644 --- a/doc/src/sgml/ref/pg_dumpall.sgml +++ b/doc/src/sgml/ref/pg_dumpall.sgml @@ -165,54 +165,6 @@ PostgreSQL documentation </varlistentry> <varlistentry> - <term><option>--lock-wait-timeout=<replaceable class="parameter">timeout</replaceable></option></term> - <listitem> - <para> - Do not wait forever to acquire shared table locks at the beginning of - the dump. Instead, fail if unable to lock a table within the specified - <replaceable class="parameter">timeout</>. The timeout may be - specified in any of the formats accepted by <command>SET - statement_timeout</>. Allowed values vary depending on the server - version you are dumping from, but an integer number of milliseconds - is accepted by all versions since 7.3. This option is ignored when - dumping from a pre-7.3 server. - </para> - </listitem> - </varlistentry> - - <varlistentry> - <term><option>--no-tablespaces</option></term> - <listitem> - <para> - Do not output commands to create tablespaces nor select tablespaces - for objects. - With this option, all objects will be created in whichever - tablespace is the default during restore. - </para> - </listitem> - </varlistentry> - - <varlistentry> - <term><option>--no-security-labels</option></term> - <listitem> - <para> - Do not dump security labels. - </para> - </listitem> - </varlistentry> - - <varlistentry> - <term><option>--no-unlogged-table-data</option></term> - <listitem> - <para> - Do not dump the contents of unlogged tables. This option has no - effect on whether or not the table definitions (schema) are dumped; - it only suppresses dumping the table data. - </para> - </listitem> - </varlistentry> - - <varlistentry> <term><option>-r</option></term> <term><option>--roles-only</option></term> <listitem> @@ -302,21 +254,6 @@ PostgreSQL documentation </varlistentry> <varlistentry> - <term><option>--inserts</option></term> - <listitem> - <para> - Dump data as <command>INSERT</command> commands (rather - than <command>COPY</command>). This will make restoration very slow; - it is mainly useful for making dumps that can be loaded into - non-<productname>PostgreSQL</productname> databases. Note that - the restore might fail altogether if you have rearranged column order. - The <option>--column-inserts</option> option is safer, though even - slower. - </para> - </listitem> - </varlistentry> - - <varlistentry> <term><option>--column-inserts</option></term> <term><option>--attribute-inserts</option></term> <listitem> @@ -364,14 +301,64 @@ PostgreSQL documentation </varlistentry> <varlistentry> - <term><option>--use-set-session-authorization</></term> + <term><option>--inserts</option></term> <listitem> <para> - Output SQL-standard <command>SET SESSION AUTHORIZATION</> commands - instead of <command>ALTER OWNER</> commands to determine object - ownership. This makes the dump more standards compatible, but - depending on the history of the objects in the dump, might not restore - properly. + Dump data as <command>INSERT</command> commands (rather + than <command>COPY</command>). This will make restoration very slow; + it is mainly useful for making dumps that can be loaded into + non-<productname>PostgreSQL</productname> databases. Note that + the restore might fail altogether if you have rearranged column order. + The <option>--column-inserts</option> option is safer, though even + slower. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term><option>--lock-wait-timeout=<replaceable class="parameter">timeout</replaceable></option></term> + <listitem> + <para> + Do not wait forever to acquire shared table locks at the beginning of + the dump. Instead, fail if unable to lock a table within the specified + <replaceable class="parameter">timeout</>. The timeout may be + specified in any of the formats accepted by <command>SET + statement_timeout</>. Allowed values vary depending on the server + version you are dumping from, but an integer number of milliseconds + is accepted by all versions since 7.3. This option is ignored when + dumping from a pre-7.3 server. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term><option>--no-security-labels</option></term> + <listitem> + <para> + Do not dump security labels. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term><option>--no-tablespaces</option></term> + <listitem> + <para> + Do not output commands to create tablespaces nor select tablespaces + for objects. + With this option, all objects will be created in whichever + tablespace is the default during restore. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term><option>--no-unlogged-table-data</option></term> + <listitem> + <para> + Do not dump the contents of unlogged tables. This option has no + effect on whether or not the table definitions (schema) are dumped; + it only suppresses dumping the table data. </para> </listitem> </varlistentry> @@ -388,6 +375,19 @@ PostgreSQL documentation </varlistentry> <varlistentry> + <term><option>--use-set-session-authorization</></term> + <listitem> + <para> + Output SQL-standard <command>SET SESSION AUTHORIZATION</> commands + instead of <command>ALTER OWNER</> commands to determine object + ownership. This makes the dump more standards compatible, but + depending on the history of the objects in the dump, might not restore + properly. + </para> + </listitem> + </varlistentry> + + <varlistentry> <term><option>-?</></term> <term><option>--help</></term> <listitem> diff --git a/doc/src/sgml/ref/pg_restore.sgml b/doc/src/sgml/ref/pg_restore.sgml index a7202e24228..be4851b6570 100644 --- a/doc/src/sgml/ref/pg_restore.sgml +++ b/doc/src/sgml/ref/pg_restore.sgml @@ -168,32 +168,32 @@ <variablelist> <varlistentry> - <term><literal>d</></term> - <term><literal>directory</></term> + <term><literal>c</></term> + <term><literal>custom</></term> <listitem> <para> - The archive is a <command>directory</command> archive. + The archive is in the custom format of + <application>pg_dump</application>. </para> </listitem> </varlistentry> <varlistentry> - <term><literal>t</></term> - <term><literal>tar</></term> + <term><literal>d</></term> + <term><literal>directory</></term> <listitem> <para> - The archive is a <command>tar</command> archive. + The archive is a directory archive. </para> </listitem> </varlistentry> <varlistentry> - <term><literal>c</></term> - <term><literal>custom</></term> + <term><literal>t</></term> + <term><literal>tar</></term> <listitem> <para> - The archive is in the custom format of - <application>pg_dump</application>. + The archive is a <command>tar</command> archive. </para> </listitem> </varlistentry> @@ -329,27 +329,6 @@ </varlistentry> <varlistentry> - <term><option>--no-tablespaces</option></term> - <listitem> - <para> - Do not output commands to select tablespaces. - With this option, all objects will be created in whichever - tablespace is the default during restore. - </para> - </listitem> - </varlistentry> - - <varlistentry> - <term><option>--no-security-labels</option></term> - <listitem> - <para> - Do not output commands to restore security labels, - even if the archive contains them. - </para> - </listitem> - </varlistentry> - - <varlistentry> <term><option>-P <replaceable class="parameter">function-name(argtype [, ...])</replaceable></option></term> <term><option>--function=<replaceable class="parameter">function-name(argtype [, ...])</replaceable></option></term> <listitem> @@ -449,6 +428,20 @@ </varlistentry> <varlistentry> + <term><option>-1</option></term> + <term><option>--single-transaction</option></term> + <listitem> + <para> + Execute the restore as a single transaction (that is, wrap the + emitted commands in <command>BEGIN</>/<command>COMMIT</>). This + ensures that either all the commands complete successfully, or no + changes are applied. This option implies + <option>--exit-on-error</>. + </para> + </listitem> + </varlistentry> + + <varlistentry> <term><option>--disable-triggers</></term> <listitem> <para> @@ -471,19 +464,6 @@ </varlistentry> <varlistentry> - <term><option>--use-set-session-authorization</option></term> - <listitem> - <para> - Output SQL-standard <command>SET SESSION AUTHORIZATION</> commands - instead of <command>ALTER OWNER</> commands to determine object - ownership. This makes the dump more standards-compatible, but - depending on the history of the objects in the dump, might not restore - properly. - </para> - </listitem> - </varlistentry> - - <varlistentry> <term><option>--no-data-for-failed-tables</option></term> <listitem> <para> @@ -506,15 +486,35 @@ </varlistentry> <varlistentry> - <term><option>-1</option></term> - <term><option>--single-transaction</option></term> + <term><option>--no-security-labels</option></term> <listitem> <para> - Execute the restore as a single transaction (that is, wrap the - emitted commands in <command>BEGIN</>/<command>COMMIT</>). This - ensures that either all the commands complete successfully, or no - changes are applied. This option implies - <option>--exit-on-error</>. + Do not output commands to restore security labels, + even if the archive contains them. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term><option>--no-tablespaces</option></term> + <listitem> + <para> + Do not output commands to select tablespaces. + With this option, all objects will be created in whichever + tablespace is the default during restore. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term><option>--use-set-session-authorization</option></term> + <listitem> + <para> + Output SQL-standard <command>SET SESSION AUTHORIZATION</> commands + instead of <command>ALTER OWNER</> commands to determine object + ownership. This makes the dump more standards-compatible, but + depending on the history of the objects in the dump, might not restore + properly. </para> </listitem> </varlistentry> |