Database Statistics Tools
Statistics collection is a cluster-wide operation that accesses data using a historical query (at epoch latest) without any locks. After statistics are computed, they are stored in the catalog and replicated on all nodes. The storage operation requires a brief, exclusive lock on the catalog, similar to when a DDL operation occurs. In fact, these operations require a COMMIT
for the current transaction.
Vertica provides a number of tools for analyzing and updating database statistics:
Tool | Description |
---|---|
ANALYZE_STATISTICS
|
Collects a statistical data sampling. |
ANALYZE_ROW_COUNT
|
Invoked through the Vertica function DO_TM_TASK , collects projection row counts. |
ANALYZE_EXTERNAL_ROW_COUNT
|
Collects row count data for external tables. |
EXPORT_STATISTICS
|
Generates database statistics in XML format from data previously collected by ANALYZE_STATISTICS . |
PROJECTION_COLUMNS
|
Monitors information about projection columns, such as encoding type, sort order, type of statistics, and the time at which columns statistics were last updated. |
For more information about these analysis tools, see Analyzing Row Counts and Getting Statistics.
See also
For information about tools to monitor and analyze query performance, see Analyzing Workloads.
For information about managing statistics, see descriptions of the following Vertica functions in the SQL Reference Manual: