powa-team / powa-archivist

powa-archivist: the powa PostgreSQL extension
http://powa.readthedocs.io/
PostgreSQL License
53 stars 20 forks source link

make the min/max fields stay in the main table #60

Closed marco44 closed 3 weeks ago

marco44 commented 6 months ago

on some environments, i got the mins_in_range/maxs_in_range columns toasted on powa_statement_history the main purpose of having those 2 columns is to get direct access to them

i worked around this on my production server by doing


alter table powa_statements_history alter mins_in_range set storage main;
alter table powa_statements_history alter maxs_in_range set storage main;
``` (and rebuilding the table)
Maybe it's worth doing systematically ?
rjuju commented 6 months ago

Indeed, I wouldn't have thought that they would go to the TOAST and that clearly defeats the wanted optimization.

marco44 commented 6 months ago

You want me to do a PR for v5 ? (I don't see a point in backporting it…)

rjuju commented 6 months ago

That would be helpful :)

I agree that there isn't much point in back-porting, it's unlikely that we will do another release for 4.x at this point.