From: | Michail Nikolaev <michail(dot)nikolaev(at)gmail(dot)com> |
---|---|
To: | Shayon Mukherjee <shayonj(at)gmail(dot)com> |
Cc: | David Rowley <dgrowleyml(at)gmail(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, Peter Eisentraut <peter(at)eisentraut(dot)org>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Proposal to Enable/Disable Index using ALTER INDEX (with patch) |
Date: | 2024-12-30 16:08:18 |
Message-ID: | CANtu0oiBRqFoNSjCxeP+JcvXXGW-EQjw-Kkr8nibWace9hcZ4w@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hello.
A few comments on patch:
> + temporarily reducing the overhead of index maintenance
> + during bulk data loading operations
>
But tuples are still inserted, where the difference come from?
> or verifying an index is not being used
> + before dropping it
Hm, it does not provide the guarantee - index may also be used as an
arbiter for INSERT ON CONFLICT, for example. For that case, "update
pg_index set indisvalid = false" should be used before the DROP, probably.
Also index may also be used for constraint, part of partitioned table, etc.
Also, I think it is better to move check to indisvalid as if
(!index->indisvalid || !index->indisenabled).
Best regards,
Mikhail.
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2024-12-30 16:19:47 | Re: RFC: Allow EXPLAIN to Output Page Fault Information |
Previous Message | Greg Sabino Mullane | 2024-12-30 15:48:13 | Re: psql: Option to use expanded mode for various meta-commands |