| From: | Michael Paquier <michael(at)paquier(dot)xyz> |
|---|---|
| To: | Dominique Devienne <ddevienne(at)gmail(dot)com> |
| Cc: | Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at>, rob stone <floriparob(at)tpg(dot)com(dot)au>, pgsql-general(at)lists(dot)postgresql(dot)org |
| Subject: | Re: How to force "re-TOAST" after changing STORAGE or COMPRESSION? |
| Date: | 2023-10-03 07:15:12 |
| Message-ID: | ZRu_gO-lg_Ya1HPe@paquier.xyz |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
On Tue, Oct 03, 2023 at 09:08:49AM +0200, Dominique Devienne wrote:
> In my case, it's OK not to be transactional, for these experiments. Is
> there a way
> to lock the table and do the rewriting w/o generating any WAL? I don't have
> any experience
> with unlogged tables, but should I take an exclusive lock on the table,
> switch it to unlogged,
> rewrite, and switch it back to logged?
Switching a table back to be logged requires all its 8k blocks to be
WAL-logged, so that would be roughly the same as a plain UPDATE.
--
Michael
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Laurenz Albe | 2023-10-03 07:17:49 | Re: How to force "re-TOAST" after changing STORAGE or COMPRESSION? |
| Previous Message | Dominique Devienne | 2023-10-03 07:08:49 | Re: How to force "re-TOAST" after changing STORAGE or COMPRESSION? |