From: Nathan Bossart <nathandbossart@gmail.com>
To: Ayush Vatsa <ayushvatsa1810@gmail.com>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: PostgreSQL Hackers <pgsql-hackers@postgresql.org>
Cc: michael@paquier.xyz
Subject: Re: Pgstattuple on Sequences: Seeking Community Feedback on Potential Patch
Date: Thu, 29 Aug 2024 12:36:35 -0500
Message-ID: <ZtCxo95K_bqGbmNQ@nathan> (raw)
In-Reply-To: <CACX+KaNhg-ZwkqCSjsq7j_gRYDmHip2b4kwa6ohac0MspSeW9w@mail.gmail.com>
References: <CACX+KaP3i+i9tdPLjF5JCHVv93xobEdcd_eB+638VDvZ3i=cQA@mail.gmail.com>
<Zsy6w_yW2QKYSo_m@nathan>
<CA+TgmoYm0X=KuHry1A6prNzf3pUmAcXYgQEr25kCY8jSMJaVjg@mail.gmail.com>
<ZszGBMK1D4hCsRnD@nathan>
<CACX+KaNhg-ZwkqCSjsq7j_gRYDmHip2b4kwa6ohac0MspSeW9w@mail.gmail.com>
On Thu, Aug 29, 2024 at 10:17:57PM +0530, Ayush Vatsa wrote:
> Please find attached the patch that re-enables
> support for sequences within the pgstattuple extension.
> I have also included the necessary test cases for
> sequences, implemented in the form of regress tests.
Thanks. Robert, do you have any concerns with this?
+select * from pgstattuple('serial');
+ table_len | tuple_count | tuple_len | tuple_percent | dead_tuple_count | dead_tuple_len | dead_tuple_percent | free_space | free_percent
+-----------+-------------+-----------+---------------+------------------+----------------+--------------------+------------+--------------
+ 8192 | 1 | 41 | 0.5 | 0 | 0 | 0 | 8104 | 98.93
+(1 row)
I'm concerned that some of this might be platform-dependent and make the
test unstable. Perhaps we should just select count(*) here.
+ /**
+ * Sequences don't fall under heap AM but are still
+ * allowed for obtaining tuple-level statistics.
+ */
I think we should be a bit more descriptive here, like the comment in
verify_heapam.c:
/*
* Sequences always use heap AM, but they don't show that in the catalogs.
* Other relkinds might be using a different AM, so check.
*/
--
nathan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: nathandbossart@gmail.com, ayushvatsa1810@gmail.com, robertmhaas@gmail.com, michael@paquier.xyz
Subject: Re: Pgstattuple on Sequences: Seeking Community Feedback on Potential Patch
In-Reply-To: <ZtCxo95K_bqGbmNQ@nathan>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox