Re: ToDo: show size of partitioned table
От
Amit Langote
Тема
Re: ToDo: show size of partitioned table
Дата
Msg-id
ad3bd857-43cf-ab23-9645-681d59e7d9ef@lab.ntt.co.jp
Ответ на
Re: ToDo: show size of partitioned table (Pavel Stehule)
Список
Дерево обсуждения
ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Ashutosh Bapat <ashutosh.bapat@enterprisedb.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Michael Paquier <michael@paquier.xyz>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Michael Paquier <michael@paquier.xyz>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Michael Paquier <michael@paquier.xyz>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Mathias Brossard <postgresql@zoinx.org>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Mathias Brossard <mathias@brossard.org>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Michael Paquier <michael@paquier.xyz>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Michael Paquier <michael@paquier.xyz>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Michael Paquier <michael@paquier.xyz>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Michael Paquier <michael@paquier.xyz>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Michael Paquier <michael@paquier.xyz>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Michael Paquier <michael@paquier.xyz>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Michael Paquier <michael@paquier.xyz>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Justin Pryzby <pryzby@telsasoft.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Kyotaro HORIGUCHI <horiguchi.kyotaro@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Kyotaro HORIGUCHI <horiguchi.kyotaro@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Justin Pryzby <pryzby@telsasoft.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Justin Pryzby <pryzby@telsasoft.com>
Re: ToDo: show size of partitioned table Justin Pryzby <pryzby@telsasoft.com>
Re: ToDo: show size of partitioned table Justin Pryzby <pryzby@telsasoft.com>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Alvaro Herrera <alvherre@2ndquadrant.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: Re: ToDo: show size of partitioned table David Steele <david@pgmasters.net>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>
Re: ToDo: show size of partitioned table Amit Langote <amitlangote09@gmail.com>
Re: ToDo: show size of partitioned table Michael Paquier <michael@paquier.xyz>
Re: ToDo: show size of partitioned table Pavel Stehule <pavel.stehule@gmail.com>
Re: ToDo: show size of partitioned table Jeevan Ladhe <jeevan.ladhe@enterprisedb.com>
Hi,
Thank you for updating the patch.
On 2018/12/17 17:48, Pavel Stehule wrote:
> new update of this patch
Documentation portion of this patch still contains some typos that I
mentioned before here:
https://www.postgresql.org/message-id/1c83bb5c-47cd-d796-226c-e95795b05551%40lab.ntt.co.jp
+ .. If the form \dP+
+ is used, the sum of size of related partitions (including the
+ table and indexes, if any) and a description
+ are also displayed.
+ ... If the form \dPi+
+ is used, the sum of size of related indexes and a description
+ are also displayed.
+ ... If the form \dPt+
+ is used, the sum of size of related tables and a description
+ are also displayed.
In all of the three hunks:
the sum of size of -> the sum of "sizes" of
and a description -> and associated description
> changes:
>
> 1. only root partitioned tables are displayed - you can see quickly total
> allocated space. It is not duplicated due nested partitions.
+1
If one wants to see a non-root partitioned table's details, they can use
\dP+ .
> I can imagine new additional flag - line "n" nested - and then we can
> display nested partitioned tables with parent table info. Some like
>
> \dPt - show only root partition tables
> \dPnt or \dPtn - show root and nested partitioned tables
Too much complication maybe?
> 2. \dP without pattern shows root partitioned tables + total relation size.
> When pattern is defined, then shows tables and indexes + table size
>
> postgres=# \dP+
> List of partitioned relations
> ┌────────┬────────────┬───────┬────────┬─────────────┐
> │ Schema │ Name │ Owner │ Size │ Description │
> ╞════════╪════════════╪═══════╪════════╪═════════════╡
> │ public │ parent_tab │ pavel │ 120 kB │ │
> └────────┴────────────┴───────┴────────┴─────────────┘
> (1 row)
>
> postgres=# \dP+ *
> List of partitioned relations or indexes
> ┌────────┬──────────────┬───────┬───────────────────┬────────────┬───────┬─────────────┐
> │ Schema │ Name │ Owner │ Type │ Table │ Size │
> Description │
> ╞════════╪══════════════╪═══════╪═══════════════════╪════════════╪═══════╪═════════════╡
> │ public │ parent_index │ pavel │ partitioned index │ parent_tab │ 80 kB
> │ │
> │ public │ parent_tab │ pavel │ partitioned table │ │ 40 kB
> │ │
> └────────┴──────────────┴───────┴───────────────────┴────────────┴───────┴─────────────┘
> (2 rows)
>
> postgres=# \dP+ *index
> List of partitioned relations or indexes
> ┌────────┬──────────────┬───────┬───────────────────┬────────────┬───────┬─────────────┐
> │ Schema │ Name │ Owner │ Type │ Table │ Size │
> Description │
> ╞════════╪══════════════╪═══════╪═══════════════════╪════════════╪═══════╪═════════════╡
> │ public │ parent_index │ pavel │ partitioned index │ parent_tab │ 80 kB
> │ │
> └────────┴──────────────┴───────┴───────────────────┴────────────┴───────┴─────────────┘
> (1 row)
Looking at the patch:
+ if (pattern)
+ /* translator: objects_name is "indexes", "tables" or "relations" */
+ psql_error("Did not find any partitioned %s named \"%s\".\n",
+ objects_name,
+ pattern);
+ else
+ /* translator: object_name is "index", "table" or "relation" */
+ psql_error("Did not find any partitioned %s.\n",
+ object_name);
It seems that objects_name and object_name need to be swapped between the
if and else blocks, and so do /* translator: ... */ comments.
if (pattern)
/* translator: object_name is "index", "table" or "relation" */
psql_error(..., object_name);
else
/* translator: objects_name is "indexes", "tables" or "relations" */
psql_error(..., objects_name);
That is, it should say, "Did not find any partitioned index/table/relation
named "foo" and "Did not find any partitioned indexes/tables/relations".
Thanks,
Amit
В списке pgsql-hackers по дате отправления
От: Michael Paquier
Дата: