Re: pgstattuple: Have pgstattuple_approx accept TOAST tables

From: Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at>
To: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: pgstattuple: Have pgstattuple_approx accept TOAST tables
Date: 2020-06-17 11:39:30
Message-ID: e8850a0f4cb0609c210a4905141255e0622ef934.camel@cybertec.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, 2020-04-17 at 13:01 +0200, Peter Eisentraut wrote:
> I alluded to this in [0], but it's better discussed in its own thread.
>
> I think the check that makes pgstattuple_approx reject TOAST tables is a
> mistake. They have visibility and free space map, and it works just
> fine if the check is removed.
>
> Attached is a patch to fix this and add some tests related to how
> pgstattuple and pg_visibility accept TOAST tables for inspection.
>
>
> [0]:
> https://www.postgresql.org/message-id/dc35a398-37d0-75ce-07ea-1dd71d98f8ec@2ndquadrant.com

I gave the patch a spin, and it passes regression tests and didn't
cause any problems when I played with it.

No upgrade or dump considerations, of course.

This is a clear improvement.

I'll mark the patch as "ready for committer".

Yours,
Laurenz Albe

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Fujii Masao 2020-06-17 12:37:55 Re: min_safe_lsn column in pg_replication_slots view
Previous Message Amit Kapila 2020-06-17 11:14:07 Re: Resetting spilled txn statistics in pg_stat_replication