diff options
Diffstat (limited to 'doc/src/sgml/ref/pg_restore.sgml')
-rw-r--r-- | doc/src/sgml/ref/pg_restore.sgml | 80 |
1 files changed, 80 insertions, 0 deletions
diff --git a/doc/src/sgml/ref/pg_restore.sgml b/doc/src/sgml/ref/pg_restore.sgml index 374d8d8715c..1a23874da68 100644 --- a/doc/src/sgml/ref/pg_restore.sgml +++ b/doc/src/sgml/ref/pg_restore.sgml @@ -191,6 +191,86 @@ PostgreSQL documentation </varlistentry> <varlistentry> + <term><option>--filter=<replaceable class="parameter">filename</replaceable></option></term> + <listitem> + <para> + Specify a filename from which to read patterns for objects excluded + or included from restore. The patterns are interpreted according to the + same rules as + <option>-n</option>/<option>--schema</option> for including objects in schemas, + <option>-N</option>/<option>--exclude-schema</option>for excluding objects in schemas, + <option>-P</option>/<option>--function</option> for restoring named functions, + <option>-I</option>/<option>--index</option> for restoring named indexes, + <option>-t</option>/<option>--table</option> for restoring named tables + or <option>-T</option>/<option>--trigger</option> for restoring triggers. + 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 + objects, and can also be specified more than once for multiple filter + files. + </para> + + <para> + The file lists one database pattern per row, with the following format: +<synopsis> +{ include | exclude } { function | index | schema | table | trigger } <replaceable class="parameter">PATTERN</replaceable> +</synopsis> + </para> + + <para> + The first keyword specifies whether the objects matched by the pattern + are to be included or excluded. The second keyword specifies the type + of object to be filtered using the pattern: + <itemizedlist> + <listitem> + <para> + <literal>function</literal>: functions, works like the + <option>-P</option>/<option>--function</option> option. This keyword + can only be used with the <literal>include</literal> keyword. + </para> + </listitem> + <listitem> + <para> + <literal>index</literal>: indexes, works like the + <option>-I</option>/<option>--indexes</option> option. This keyword + can only be used with the <literal>include</literal> keyword. + </para> + </listitem> + <listitem> + <para> + <literal>schema</literal>: schemas, works like the + <option>-n</option>/<option>--schema</option> and + <option>-N</option>/<option>--exclude-schema</option> options. + </para> + </listitem> + <listitem> + <para> + <literal>table</literal>: tables, works like the + <option>-t</option>/<option>--table</option> option. This keyword + can only be used with the <literal>include</literal> keyword. + </para> + </listitem> + <listitem> + <para> + <literal>trigger</literal>: triggers, works like the + <option>-T</option>/<option>--trigger</option> option. This keyword + can only be used with the <literal>include</literal> keyword. + </para> + </listitem> + </itemizedlist> + </para> + + <para> + Lines starting with <literal>#</literal> are considered comments and + ignored. Comments can be placed after an object pattern row as well. + Blank lines are also ignored. See <xref linkend="app-psql-patterns"/> + for how to perform quoting in patterns. + </para> + + </listitem> + </varlistentry> + + <varlistentry> <term><option>-F <replaceable class="parameter">format</replaceable></option></term> <term><option>--format=<replaceable class="parameter">format</replaceable></option></term> <listitem> |