Home Explore Blog CI



postgresql

30th chunk of `doc/src/sgml/ref/psql-ref.sgml`
9670d0305c7fd70e5bb9fbe56f1bdd3b71986bc6613c145a0000000100000fb1
 <replaceable class="parameter">arg_pattern</replaceable>s
        are specified, only binary operators whose argument type names match
        those patterns are listed.  (Alternatively, write <literal>-</literal>
        for the unused argument of a unary operator.)
        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.
        If <literal>+</literal> is appended to the command name,
        additional information about each operator is shown, including
        the name of the underlying function, and whether it is leakproof.
        </para>
        </listitem>
      </varlistentry>


      <varlistentry id="app-psql-meta-command-do-uc">
        <term><literal>\dO[Sx+] [ <link linkend="app-psql-patterns"><replaceable class="parameter">pattern</replaceable></link> ]</literal></term>
        <listitem>
        <para>
        Lists collations.
        If <replaceable class="parameter">pattern</replaceable> is
        specified, only collations whose names match the pattern are
        listed.  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.
        If <literal>+</literal> is appended
        to the command name, each collation is listed with its associated
        description, if any.
        Note that only collations usable with the current database's encoding
        are shown, so the results may vary in different databases of the
        same installation.
        </para>
        </listitem>
      </varlistentry>


      <varlistentry id="app-psql-meta-command-dp-lc">
        <term><literal>\dp[Sx] [ <link linkend="app-psql-patterns"><replaceable class="parameter">pattern</replaceable></link> ]</literal></term>
        <listitem>
        <para>
        Lists tables, views and sequences with their
        associated access privileges.
        If <replaceable class="parameter">pattern</replaceable> is
        specified, only tables, views and sequences whose names match the
        pattern are listed.  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>

        <para>
        The <link linkend="sql-grant"><command>GRANT</command></link> and
        <link linkend="sql-revoke"><command>REVOKE</command></link>
        commands are used to set access privileges.  The meaning of the
        privilege display is explained in
        <xref linkend="ddl-priv"/>.
        </para>
        </listitem>
      </varlistentry>


      <varlistentry id="app-psql-meta-command-dp-uc">
        <term><literal>\dP[itnx+] [ <link linkend="app-psql-patterns"><replaceable class="parameter">pattern</replaceable></link> ]</literal></term>
        <listitem>
        <para>
        Lists partitioned relations.
        If <replaceable class="parameter">pattern</replaceable>
        is specified, only entries whose name matches the pattern are listed.
        The modifiers <literal>t</literal> (tables) and <literal>i</literal>
        (indexes) can be appended to the command, filtering the kind of
        relations to list.  By default, partitioned tables and indexes are
        listed.
        </para>

        <para>
        If the modifier <literal>n</literal> (<quote>nested</quote>) is used,
        or a pattern is specified, then non-root partitioned relations are
        included, and a column is shown displaying the parent of each
        partitioned relation.
        </para>

        <para>
        If <literal>x</literal>

Title: psql Meta-Commands: \dO, \dp, \dP
Summary
This section details more psql meta-commands for listing database objects: * `\dO`: Lists collations, filtered by name. `S` includes system objects. `x` displays expanded mode, `+` lists associated description. Only collations usable with the current database encoding are shown. * `\dp`: Lists tables, views, and sequences with their access privileges, filtered by name. `S` includes system objects. `x` displays expanded mode. * `\dP`: Lists partitioned relations, filtered by name. Modifiers `t` (tables) and `i` (indexes) filter the kind of relations to list. `n` (nested) includes non-root partitioned relations, displaying the parent relation.