15.00 - COLLECT STATISTICS (Optimizer Form) - Teradata Database

Teradata Database SQL Data Definition Language Detailed Topics

Product
Teradata Database
Release Number
15.00
Content Type
Programming Reference
Publication ID
B035-1184-015K
Language
English (United States)

COLLECT STATISTICS (Optimizer Form)

Why You Need To Collect Statistics

The purpose of collecting statistics is to compute statistical data that the Optimizer uses to optimize table access and join plans. The computed statistical data is retained in a synopsis data structure that is stored in the data dictionary for use during the optimizing phase of SQL request parsing.

Accurate demographics enable the Optimizer to determine the least costly access and join plans for a query. Accurate table demographic information is especially important when data to be accessed using a column or index might be skewed.