mirror of
https://github.com/postgres/postgres.git
synced 2025-07-31 22:04:40 +03:00
psql \dX: list extended statistics objects
The new command lists extended statistics objects. All past releases
with extended statistics are supported.
This is a simplified version of commit 891a1d0bca
, which had to be
reverted due to not considering pg_statistic_ext_data is not accessible
by regular users. Fields requiring access to this catalog were removed.
It's possible to add them, but it'll require changes to core.
Author: Tatsuro Yamada
Reviewed-by: Julien Rouhaud, Alvaro Herrera, Tomas Vondra, Noriyoshi Shinoda
Discussion: https://postgr.es/m/c027a541-5856-75a5-0868-341301e1624b%40nttcom.co.jp_1
This commit is contained in:
@ -1919,6 +1919,27 @@ testdb=>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><literal>\dX [ <link linkend="app-psql-patterns"><replaceable class="parameter">pattern</replaceable></link> ]</literal></term>
|
||||
<listitem>
|
||||
<para>
|
||||
Lists extended statistics.
|
||||
If <replaceable class="parameter">pattern</replaceable>
|
||||
is specified, only those extended statistics whose names match the
|
||||
pattern are listed.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
The column of the kind of extended stats (e.g. Ndistinct) shows its status.
|
||||
NULL means that it doesn't exists. "defined" means that it was requested
|
||||
when creating the statistics.
|
||||
You can use pg_stats_ext if you'd like to know whether <link linkend="sql-analyze">
|
||||
<command>ANALYZE</command></link> was run and statistics are available to the
|
||||
planner.
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><literal>\dy[+] [ <link linkend="app-psql-patterns"><replaceable class="parameter">pattern</replaceable></link> ]</literal></term>
|
||||
<listitem>
|
||||
|
Reference in New Issue
Block a user