RE: Purging few months old data and vacuuming in production

2023-01-06 Thread Ranjith Paliyath
Thank you very much again. > So, with this approach, is the advantage like, manual vacuuming worry may be set aside, because auto-vacuuming would deal with the dead rows? > Theoretically, manual vacuuming is never necessary.  I'd occasionally do manual vacuums (after p

Re: Purging few months old data and vacuuming in production

2023-01-06 Thread Ranjith Paliyath
Thank you very much for the response. > Can you do online purging? > For example, get a list of the main table's primary keys to be deleted, and > then nibble away at them all day: in one transaction delete all the records > for one logically related set of records.  Do that N m

Re: Purging few months old data and vacuuming in production

2023-01-06 Thread Ranjith Paliyath
Thank you for the details, experience shared and the suggestions. Apologies for the delay in collecting the response for the queries. (1)Are the tables tied together by FK? - Overall there are 9 tables (sorry not 6 as mentioned originally) that are being purged. Only 4 tables would be having FK

Purging few months old data and vacuuming in production

2022-12-29 Thread Ranjith Paliyath
Hi, We have a PostgreSQL (slightly old version, something like - PostgreSQL 11.2 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-36), 64-bit) production, where one particular table and its related 5 tables need to be purged of 3 months prior data. Each of these table