Vacuum reclaims storage occupied by deleted tuples. In normal PostgreSQL operation, tuples that are deleted or obsoleted by an update are not physically removed from their table; they remain present until a Vacuum is done. Therefore it's necessary to do Vacuum periodically, especially on frequently-updated tables.
Vacuum Database
Just simply right-click the database and select Maintain Database -> Vacuum Database... -> desired option.Vacuum Table
Just simply right-click the table and select Maintain Tables -> Vacuum Tables... -> desired option.
Parameters
|
|
Full | Selects "full" vacuum, which may reclaim more space, but takes much longer and exclusively locks the table. |
Freeze | Selects aggressive "freezing" of tuples. |
Analyze | Updates statistics used by the planner to determine the most efficient way to execute a query. |
Verbose | Prints a detailed vacuum activity report for each table. (Default enabled in Navicat) |
Outputs
|
When Verbose is specified, Vacuum emits progress messages to indicate which table is currently being processed. Various statistics about the tables are printed as well. |
Related topics:
Analyze
Reindex