Re: Howdoes; pg; index; page; optimize; dead; tuples?;

From: "Jonah H(dot) Harris" <jonah(dot)harris(at)gmail(dot)com>
To: "jacktby(at)gmail(dot)com" <jacktby(at)gmail(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Howdoes; pg; index; page; optimize; dead; tuples?;
Date: 2023-04-20 01:48:43
Message-ID: CADUqk8UWt08dx6QEOHioiCnNqEwsuz-+tG4EYKQLHURo6-A0Ew@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Apr 19, 2023 at 9:40 PM jacktby(at)gmail(dot)com <jacktby(at)gmail(dot)com> wrote:

> As far as I know, when a index page is full, if you insert a new tuple
> here, you will split it into two pages.
> But pg won't delete the half tuples in the old page in real. So if there
> is another tuple inserted into this old
> page, will pg split it again? I think that's not true, so how it solve
> this one? please give me a code example,thanks
>

This is not how the hackers list works; you need to do your own research.
The Postgres code is pretty straightforward and giving you examples in
isolation makes no sense. If you want to understand how things actually
work, you need to read the code in context and understand how the system
works, minimally, at a component level.

--
Jonah H. Harris

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Zhijie Hou (Fujitsu) 2023-04-20 01:49:23 RE: Support logical replication of DDLs
Previous Message Melanie Plageman 2023-04-20 01:45:32 Re: Remove io prefix from pg_stat_io columns