Tom Lane wrote:
I speculate that you did a VACUUM FULL on it recently.
You speculate right, we do a vacuum full every sunday night as a safety net. So the vacuum full was a week old.
The condition of the indexes suggests strongly that you've not been vacuuming pg_attribute often enough (and perhaps not any of the other system catalogs, either?). Heavy use of temp tables will cause pg_attribute and pg_class to bloat if you don't keep after them.
That's interesting. We stopped using temporary tables because they were causing us lots of trouble, including table bloat. We vacuum pg_attribute (and every other table with an entry in pg_tables) every ten minutes. What other that temp tables could bloat pg_attribute? We use refcursors to return data from our stored procedures. We also have a few stored procedures that return SETOF.
Thanks for helping us out on this. -- David Mitchell Software Engineer Telogis ---------------------------(end of broadcast)--------------------------- TIP 5: don't forget to increase your free space map settings