mirror of
https://github.com/postgres/postgres.git
synced 2025-07-28 23:42:10 +03:00
Change psql's \dd command to do something more useful.
Instead of displaying comments on an arbitrary subset of the object types which support them, make \dd display comments on exactly those object types which don't have their own backlash commands. We now regard the display of comments as properly the job of the relevant backslash command (though many of them do so only in verbose mode) rather than something that \dd should be responsible for. However, a handful of object types have no backlash command, so make \dd give information about those. Josh Kupershmidt
This commit is contained in:
@ -990,24 +990,21 @@ testdb=>
|
||||
<term><literal>\dd[S] [ <link linkend="APP-PSQL-patterns"><replaceable class="parameter">pattern</replaceable></link> ]</literal></term>
|
||||
<listitem>
|
||||
<para>
|
||||
Shows the descriptions of objects matching the <replaceable
|
||||
class="parameter">pattern</replaceable>, or of all visible objects if
|
||||
no argument is given. But in either case, only objects that have
|
||||
a description are listed.
|
||||
Shows the descriptions of objects of type <literal>constraint</>,
|
||||
<literal>operator class</>, <literal>operator family</>,
|
||||
<literal>rule</>, and <literal>trigger</>. All
|
||||
other comments may be viewed by the respective backslash commands for
|
||||
those object types.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
<literal>\dd</literal> displays descriptions for objects matching the
|
||||
<replaceable class="parameter">pattern</replaceable>, or of visible
|
||||
objects of the appropriate type if no argument is given. But in either
|
||||
case, only objects that have a description are listed.
|
||||
By default, only user-created objects are shown; supply a
|
||||
pattern or the <literal>S</literal> modifier to include system
|
||||
objects.
|
||||
<quote>Object</quote> covers aggregates, functions, operators,
|
||||
types, relations (tables, views, indexes, sequences), large
|
||||
objects, rules, and triggers. For example:
|
||||
<programlisting>
|
||||
=> <userinput>\dd version</userinput>
|
||||
Object descriptions
|
||||
Schema | Name | Object | Description
|
||||
------------+---------+----------+---------------------------
|
||||
pg_catalog | version | function | PostgreSQL version string
|
||||
(1 row)
|
||||
</programlisting>
|
||||
</para>
|
||||
|
||||
<para>
|
||||
|
Reference in New Issue
Block a user