Re: partition tree inspection functions - Mailing list pgsql-hackers

From Michael Paquier
Subject Re: partition tree inspection functions
Date
Msg-id 20181030013318.GB1644@paquier.xyz
Whole thread Raw
In response to Re: partition tree inspection functions  (Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>)
Responses Re: partition tree inspection functions  (Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>)
List pgsql-hackers
On Mon, Oct 29, 2018 at 04:08:09PM +0900, Amit Langote wrote:
> Hmm, I think we mention the word "partitioned" in the error message only
> if partitioning is required to perform an operation but it's absent (for
> example, trying to attach partition to a non-partitioned table) or if its
> presence prevents certain operation from being performed (for example,
> calling pgrowlocks() on a partitioned table).  Neither seems true in this
> case.  One can pass a relation of any of the types mentioned in the above
> error message to pg_partition_tree and get some output from it.

Okay..  We could always reword the error message if there are any
complaints.

> I've fixed the documentation to mention regclass as the input type.  Also,
> I've also modified tests to not use ::regclass.

Thanks for the new version and using better index names.  I have
reviewed and committed the patch, with a couple of things tweaked:
- removal of the tests on the size, they don't seem useful as part of
showing partition information.
- no need to join on pg_class for the test of the normal table.
- added some comments and reformulated some other comments.
- added a test with a materialized view.
- added a test with a NULL input (as that's a strict function).
--
Michael

Attachment

pgsql-hackers by date:

Previous
From: Tomas Vondra
Date:
Subject: Re: FETCH FIRST clause WITH TIES option
Next
From: Tatsuo Ishii
Date:
Subject: pgbench doc fix