1
1
<!--
2
- $Header: /cvsroot/pgsql/doc/src/sgml/ref/pg_dump.sgml,v 1.64 2003/09/11 21:42:20 momjian Exp $
2
+ $Header: /cvsroot/pgsql/doc/src/sgml/ref/pg_dump.sgml,v 1.65 2003/09/23 22:48:53 tgl Exp $
3
3
PostgreSQL documentation
4
4
-->
5
5
@@ -318,16 +318,16 @@ PostgreSQL documentation
318
318
<term><option>--no-owner</option></term>
319
319
<listitem>
320
320
<para>
321
- Do not output commands to set the
322
- object ownership to match the original database. Typically,
323
- <application>pg_dump</application> issues
324
- (<application>psql</application>-specific) < command>\connect </command>
325
- statements to set ownership of schema elements. See also
326
- under <option>-R</option> and <option>-X
327
- use-set-session-authorization</option>. Note that
328
- <option>-O</option> does not prevent all reconnections to the
329
- database, only the ones that are exclusively used for
330
- ownership adjustments .
321
+ Do not output commands to set
322
+ ownership of objects to match the original database.
323
+ By default, <application>pg_dump</application> issues
324
+ < command>SET SESSION AUTHORIZATION </command>
325
+ statements to set ownership of created schema elements.
326
+ These statements
327
+ will fail when the script is run unless it is started by a superuser
328
+ (or the same user that owns all of the objects in the script).
329
+ To make a script that can be restored by any user, but will give
330
+ that user ownership of all the objects, specify <option>-O</> .
331
331
</para>
332
332
333
333
<para>
@@ -343,27 +343,8 @@ PostgreSQL documentation
343
343
<term><option>--no-reconnect</option></term>
344
344
<listitem>
345
345
<para>
346
- Prohibit <application>pg_dump</application>
347
- from outputting a script that would require reconnections to
348
- the database while being restored. An average restoration
349
- script usually has to reconnect several times as different
350
- users to set the original ownerships of the objects. This
351
- option is a rather blunt instrument because it makes
352
- <application>pg_dump</application> lose this ownership information,
353
- <emphasis>unless</emphasis> you use the <option>-X
354
- use-set-session-authorization</option> option.
355
- </para>
356
-
357
- <para>
358
- One possible reason why reconnections during restore might not
359
- be desired is if the access to the database requires manual
360
- interaction (e.g., passwords).
361
- </para>
362
-
363
- <para>
364
- This option is only meaningful for the plain-text format. For
365
- the other formats, you may specify the option when you
366
- call <command>pg_restore</command>.
346
+ This option is obsolete but still accepted for backwards
347
+ compatibility.
367
348
</para>
368
349
</listitem>
369
350
</varlistentry>
@@ -385,8 +366,7 @@ PostgreSQL documentation
385
366
<para>
386
367
Specify the superuser user name to use when disabling triggers.
387
368
This is only relevant if <option>--disable-triggers</> is used.
388
- (Usually, it's better to specify
389
- <option>--use-set-session-authorization</>, and then start the
369
+ (Usually, it's better to leave this out, and instead start the
390
370
resulting script as superuser.)
391
371
</para>
392
372
</listitem>
@@ -444,32 +424,10 @@ PostgreSQL documentation
444
424
<term><option>--use-set-session-authorization</></term>
445
425
<listitem>
446
426
<para>
447
- Normally, if a (plain-text mode) script generated by
448
- <application>pg_dump</application> must alter the current database
449
- user (e.g., to set correct object ownerships), it uses the
450
- <application>psql</application> <command>\connect</command> command.
451
- This command actually opens a new connection, which might
452
- require manual interaction (e.g., passwords). If you use the
453
- <option>-X use-set-session-authorization</option> option, then
454
- <application>pg_dump</application> will instead output <xref
455
- linkend="sql-set-session-authorization" endterm="sql-set-session-authorization-title"> commands. This has
456
- the same effect, but it requires that the user restoring the
457
- database from the generated script be a database superuser.
458
- This option effectively overrides the <option>-R</option>
459
- option.
460
- </para>
461
-
462
- <para>
463
- Since <xref linkend="sql-set-session-authorization" endterm="sql-set-session-authorization-title"> is a
464
- standard SQL command, whereas <command>\connect</command> only
465
- works in <application>psql</application>, this option also enhances
466
- the theoretical portability of the output script.
467
- </para>
468
-
469
- <para>
470
- This option is only meaningful for the plain-text format. For
471
- the other formats, you may specify the option when you
472
- call <command>pg_restore</command>.
427
+ This option is obsolete but still accepted for backwards
428
+ compatibility.
429
+ <application>pg_dump</application> now always behaves in the
430
+ way formerly selected by this option.
473
431
</para>
474
432
</listitem>
475
433
</varlistentry>
@@ -490,10 +448,8 @@ PostgreSQL documentation
490
448
<para>
491
449
Presently, the commands emitted for <option>--disable-triggers</>
492
450
must be done as superuser. So, you should also specify
493
- a superuser name with <option>-S</>, or preferably specify
494
- <option>--use-set-session-authorization</> and then be careful to
495
- start the resulting script as a superuser. If you give neither
496
- option, the entire script must be run as superuser.
451
+ a superuser name with <option>-S</>, or preferably be careful to
452
+ start the resulting script as a superuser.
497
453
</para>
498
454
499
455
<para>
0 commit comments