Home Explore Blog CI



postgresql

9th chunk of `doc/src/sgml/ref/pg_dumpall.sgml`
b739ad95f61aa2cb81d48e3dac3ab93dc8e4406cc10e9d8f0000000100000fad
      <term><option>--rows-per-insert=<replaceable class="parameter">nrows</replaceable></option></term>
      <listitem>
       <para>
        Dump data as <command>INSERT</command> commands (rather than
        <command>COPY</command>).  Controls the maximum number of rows per
        <command>INSERT</command> command. The value specified must be a
        number greater than zero.  Any error during restoring will cause only
        rows that are part of the problematic <command>INSERT</command> to be
        lost, rather than the entire table contents.
       </para>
      </listitem>
     </varlistentry>

     <varlistentry>
      <term><option>--statistics-only</option></term>
      <listitem>
       <para>
        Dump only the statistics, not the schema (data definitions) or data.
        Statistics for tables, materialized views, and indexes are dumped.
       </para>
      </listitem>
     </varlistentry>

     <varlistentry>
      <term><option>--sequence-data</option></term>
      <listitem>
       <para>
        Include sequence data in the dump.  This is the default behavior except
        when <option>--no-data</option>, <option>--schema-only</option>, or
        <option>--statistics-only</option> is specified.
       </para>
      </listitem>
     </varlistentry>

     <varlistentry>
      <term><option>--use-set-session-authorization</option></term>
      <listitem>
       <para>
        Output SQL-standard <command>SET SESSION AUTHORIZATION</command> commands
        instead of <command>ALTER OWNER</command> 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>--with-data</option></term>
      <listitem>
       <para>
        Dump data. This is the default.
       </para>
      </listitem>
     </varlistentry>

     <varlistentry>
      <term><option>--with-schema</option></term>
      <listitem>
       <para>
        Dump schema (data definitions). This is the default.
       </para>
      </listitem>
     </varlistentry>

     <varlistentry>
      <term><option>--with-statistics</option></term>
      <listitem>
       <para>
        Dump statistics.
       </para>
      </listitem>
     </varlistentry>

     <varlistentry>
       <term><option>-?</option></term>
       <term><option>--help</option></term>
       <listitem>
       <para>
       Show help about <application>pg_dumpall</application> command line
       arguments, and exit.
       </para>
       </listitem>
     </varlistentry>

    </variablelist>
   </para>

  <para>
   The following command-line options control the database connection parameters.

   <variablelist>
     <varlistentry>
      <term><option>-d <replaceable class="parameter">connstr</replaceable></option></term>
      <term><option>--dbname=<replaceable class="parameter">connstr</replaceable></option></term>
      <listitem>
       <para>
        Specifies parameters used to connect to the server, as a <link
        linkend="libpq-connstring">connection string</link>;  these
        will override any conflicting command line options.
       </para>
       <para>
        The option is called <literal>--dbname</literal> for consistency with other
        client applications, but because <application>pg_dumpall</application>
        needs to connect to many databases, the database name in the
        connection string will be ignored.  Use the <literal>-l</literal>
        option to specify the name of the database used for the initial
        connection, which will dump global objects and discover what other
        databases should be dumped.
       </para>
      </listitem>
     </varlistentry>

     <varlistentry>
      <term><option>-h <replaceable>host</replaceable></option></term>
      <term><option>--host=<replaceable>host</replaceable></option></term>

Title: pg_dumpall Options: Data Handling, Ownership, and Connection Parameters
Summary
This section describes pg_dumpall options related to data handling (rows per insert, statistics, sequence data, schema and data inclusion), object ownership (using SET SESSION AUTHORIZATION), and provides help information. It also details the command-line options for specifying database connection parameters, including the connection string, host, and port.