On 2022-Jul-06, Florents Tselai wrote:
> Actually, I monitored my disk usage and it was **definitely** working as
> It had already eaten up an additional 30% of my disk capacity.
Adding a column like this requires creating a second copy of the table,
copying all the contents from the old table (plus the new column) into
the new one, then recreating all indexes from scratch on the new copy of
the table. If you have a lot of indexes, this can be significant.
Also, AFAIU all data has to be uncompressed on read, then compressed
back on write.
Note: the 80 GB from pg_relation_size() does *not* include the size of
TOAST data. You're copying a lot of additional data. See
pg_table_size().
--
Álvaro Herrera Breisgau, Deutschland — https://www.EnterpriseDB.com/
"Hay quien adquiere la mala costumbre de ser infeliz" (M. A. Evans)