diff options
author | Dean Rasheed <dean.a.rasheed@gmail.com> | 2024-03-20 08:05:44 +0000 |
---|---|---|
committer | Dean Rasheed <dean.a.rasheed@gmail.com> | 2024-03-20 08:05:44 +0000 |
commit | 522ed12f7c600243870b13d9ff59f8fd5af10978 (patch) | |
tree | 27dd4d18d02ee32efc4c515715561a78efb837ee /doc/src | |
parent | d63d486d6c393817810d0477569fc657c388bfb2 (diff) | |
download | postgresql-522ed12f7c600243870b13d9ff59f8fd5af10978.tar.gz postgresql-522ed12f7c600243870b13d9ff59f8fd5af10978.zip |
Add "--exclude-extension" to pg_dump's options.
This option (or equivalently specifying "exclude extension pattern" in
a filter file) allows extensions matching the specified pattern to be
excluded from the dump.
Ayush Vatsa, reviewed by Junwang Zhao, Dean Rasheed, and Daniel
Gustafsson.
Discussion: https://postgr.es/m/CACX+KaP=VgVy9h-EUh598DTu+-fNr1jyEmpghC8rRp9s=w33Kg@mail.gmail.com
Diffstat (limited to 'doc/src')
-rw-r--r-- | doc/src/sgml/ref/pg_dump.sgml | 34 |
1 files changed, 28 insertions, 6 deletions
diff --git a/doc/src/sgml/ref/pg_dump.sgml b/doc/src/sgml/ref/pg_dump.sgml index 0caf56e0e04..8edf03a03df 100644 --- a/doc/src/sgml/ref/pg_dump.sgml +++ b/doc/src/sgml/ref/pg_dump.sgml @@ -257,6 +257,27 @@ PostgreSQL documentation </varlistentry> <varlistentry> + <term><option>--exclude-extension=<replaceable class="parameter">pattern</replaceable></option></term> + <listitem> + <para> + Do not dump any extensions matching <replaceable + class="parameter">pattern</replaceable>. The pattern is + interpreted according to the same rules as for <option>-e</option>. + <option>--exclude-extension</option> can be given more than once to exclude extensions + matching any of several patterns. + </para> + + <para> + When both <option>-e</option> and <option>--exclude-extension</option> are given, the behavior + is to dump just the extensions that match at least one <option>-e</option> + switch but no <option>--exclude-extension</option> switches. If <option>--exclude-extension</option> + appears without <option>-e</option>, then extensions matching <option>--exclude-extension</option> are + excluded from what is otherwise a normal dump. + </para> + </listitem> + </varlistentry> + + <varlistentry> <term><option>-E <replaceable class="parameter">encoding</replaceable></option></term> <term><option>--encoding=<replaceable class="parameter">encoding</replaceable></option></term> <listitem> @@ -848,10 +869,11 @@ PostgreSQL documentation <option>--exclude-table-and-children</option> or <option>-T</option> for tables, <option>-n</option>/<option>--schema</option> for schemas, - <option>--include-foreign-data</option> for data on foreign servers and + <option>--include-foreign-data</option> for data on foreign servers, <option>--exclude-table-data</option>, - <option>--exclude-table-data-and-children</option> for table data, - <option>-e</option>/<option>--extension</option> for extensions. + <option>--exclude-table-data-and-children</option> for table data, and + <option>-e</option>/<option>--extension</option> or + <option>--exclude-extension</option> for extensions. To read from <literal>STDIN</literal>, use <filename>-</filename> as the filename. The <option>--filter</option> option can be specified in conjunction with the above listed options for including or excluding @@ -874,8 +896,7 @@ PostgreSQL documentation <listitem> <para> <literal>extension</literal>: extensions, works like the - <option>--extension</option> option. This keyword can only be - used with the <literal>include</literal> keyword. + <option>-e</option>/<option>--extension</option> option. </para> </listitem> <listitem> @@ -1278,7 +1299,8 @@ PostgreSQL documentation </para> <para> This option has no effect - on <option>-N</option>/<option>--exclude-schema</option>, + on <option>--exclude-extension</option>, + <option>-N</option>/<option>--exclude-schema</option>, <option>-T</option>/<option>--exclude-table</option>, or <option>--exclude-table-data</option>. An exclude pattern failing to match any objects is not considered an error. |