</varlistentry>
<varlistentry>
- <term><option>-n <replaceable class="parameter">namespace</replaceable></option></term>
+ <term><option>-n <replaceable class="parameter">schema</replaceable></option></term>
<term><option>--schema=<replaceable class="parameter">schema</replaceable></option></term>
<listitem>
<para>
</listitem>
</varlistentry>
+ <varlistentry>
+ <term><option>-N <replaceable class="parameter">schema</replaceable></option></term>
+ <term><option>--exclude-schema=<replaceable class="parameter">schema</replaceable></option></term>
+ <listitem>
+ <para>
+ Do not restore objects that are in the named schema. Multiple schemas
+ to be excluded may be specified with multiple <option>-N</> switches.
+ </para>
+
+ <para>
+ When both <option>-n</> and <option>-N</> are given for the same
+ schema name, the <option>-N</> switch wins and the schema is excluded.
+ </para>
+ </listitem>
+ </varlistentry>
+
<varlistentry>
<term><option>-O</option></term>
<term><option>--no-owner</option></term>
{"data-only", 0, NULL, 'a'},
{"dbname", 1, NULL, 'd'},
{"exit-on-error", 0, NULL, 'e'},
+ {"exclude-schema", 1, NULL, 'N'},
{"file", 1, NULL, 'f'},
{"format", 1, NULL, 'F'},
{"function", 1, NULL, 'P'},
}
}
- while ((c = getopt_long(argc, argv, "acCd:ef:F:h:I:j:lL:n:Op:P:RsS:t:T:U:vwWx1",
+ while ((c = getopt_long(argc, argv, "acCd:ef:F:h:I:j:lL:n:N:Op:P:RsS:t:T:U:vwWx1",
cmdopts, NULL)) != -1)
{
switch (c)
simple_string_list_append(&opts->schemaNames, optarg);
break;
+ case 'N': /* Do not dump data for this schema */
+ simple_string_list_append(&opts->schemaExcludeNames, optarg);
+ break;
+
case 'O':
opts->noOwner = 1;
break;
printf(_(" -L, --use-list=FILENAME use table of contents from this file for\n"
" selecting/ordering output\n"));
printf(_(" -n, --schema=NAME restore only objects in this schema\n"));
+ printf(_(" -N, --exclude-schema=NAME do not restore objects in this schema\n"));
printf(_(" -O, --no-owner skip restoration of object ownership\n"));
printf(_(" -P, --function=NAME(args) restore named function\n"));
printf(_(" -s, --schema-only restore only the schema, no data\n"));