Home Explore Blog CI



postgresql

20th chunk of `doc/src/sgml/ref/psql-ref.sgml`
0fcc5bcc900eeee355e9ba37e3201b4397ca7ced9b0adcf90000000100000fa0
 </para>

        <note>
        <para>
        If <command>\d</command> is used without a
        <replaceable class="parameter">pattern</replaceable> argument, it is
        equivalent to <command>\dtvmsE</command> which will show a list of
        all visible tables, views, materialized views, sequences and
        foreign tables.
        This is purely a convenience measure.
        </para>
        <para>
        As with many other commands, if <literal>x</literal> is appended to
        the command name, the results are displayed in expanded mode, but note
        that this only applies when <command>\d</command> is used without a
        <replaceable class="parameter">pattern</replaceable> argument, and
        the <literal>x</literal> modifier cannot appear immediately after the
        <command>\d</command> (because <command>\dx</command> is a different
        command); the <literal>x</literal> modifier may only appear after an
        <literal>S</literal> or <literal>+</literal> modifier. For example,
        <command>\d+x</command> is equivalent to <command>\dtvmsE+x</command>
        and will show a list of all relations in expanded mode.
        </para>
        </note>
        </listitem>
      </varlistentry>

      <varlistentry id="app-psql-meta-command-da-lc">
        <term><literal>\da[Sx] [ <link linkend="app-psql-patterns"><replaceable class="parameter">pattern</replaceable></link> ]</literal></term>

        <listitem>
        <para>
        Lists aggregate functions, together with their
        return type and the data types they operate on. If <replaceable
        class="parameter">pattern</replaceable>
        is specified, only aggregates whose names match the pattern are shown.
        By default, only user-created objects are shown;  supply a
        pattern or the <literal>S</literal> modifier to include system
        objects.
        If <literal>x</literal> is appended to the command name, the results
        are displayed in expanded mode.
        </para>
        </listitem>
      </varlistentry>

      <varlistentry id="app-psql-meta-command-da-uc">
        <term><literal>\dA[x+] [ <link linkend="app-psql-patterns"><replaceable class="parameter">pattern</replaceable></link> ]</literal></term>

        <listitem>
        <para>
        Lists access methods. If <replaceable
        class="parameter">pattern</replaceable> is specified, only access
        methods whose names match the pattern are shown.
        If <literal>x</literal> is appended to the command name, the results
        are displayed in expanded mode.
        If <literal>+</literal> is appended to the command name, each access
        method is listed with its associated handler function and description.
        </para>
        </listitem>
      </varlistentry>

      <varlistentry id="app-psql-meta-command-dac">
        <term>
          <literal>\dAc[x+]
            [<link linkend="app-psql-patterns"><replaceable class="parameter">access-method-pattern</replaceable></link>
              [<link linkend="app-psql-patterns"><replaceable class="parameter">input-type-pattern</replaceable></link>]]
          </literal>
        </term>
        <listitem>
        <para>
        Lists operator classes
        (see <xref linkend="xindex-opclass"/>).
        If <replaceable class="parameter">access-method-pattern</replaceable>
        is specified, only operator classes associated with access methods whose
        names match that pattern are listed.
        If <replaceable class="parameter">input-type-pattern</replaceable>
        is specified, only operator classes associated with input types whose
        names match that pattern are listed.
        If <literal>x</literal> is appended to the command name, the results
        are displayed in expanded mode.
        If <literal>+</literal> is appended to the command name, each operator
        class is listed with its associated operator family and owner.
        </para>
        </listitem>

Title: psql Meta-Commands: \d (Continued), \da, \dA, \dAc
Summary
This section continues the \d meta-command explanation, giving more details about how the command functions without a pattern argument and when used with modifiers like 'x', 'S' or '+'. It then defines other meta-commands: * `\da`: Lists aggregate functions, filtered by a pattern. The `S` modifier includes system objects and the `x` modifier displays results in expanded mode. * `\dA`: Lists access methods, filtered by a pattern. The `x` modifier displays results in expanded mode, and the `+` modifier includes the handler function and description. * `\dAc`: Lists operator classes, filtered by access method and input type patterns. The `x` modifier displays results in expanded mode, and the `+` modifier includes the associated operator family and owner.