HELP STATISTICS Examples | Teradata Vantage - Example: Summary Statistics on a Database - Analytics Database - Teradata Vantage

SQL Data Definition Language Syntax and Examples

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Analytics Database
Teradata Vantage
Release Number
17.20
Published
June 2022
Language
English (United States)
Last Update
2024-10-04
dita:mapPath
jco1628111346878.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
mdr1472255012272
lifecycle
latest
Product Category
Teradata Vantage™

If statistics have been collected for the employee table in the personnel database, you can use the following request to obtain a list of the columns of the employee table that currently have statistics.

     HELP STATISTICS personnel.employee;

The result shows that statistics were last collected for YrsExp on 02/06/03, when there were 17 unique values for the column.

     Date      Time     Unique Values        Column Names 
     --------  -------- -------------------- ---------------- 
     02/06/03  13:12:45                   17 YrsExp


Suppose you have collected statistics on the following single and multicolumn sets from the orders table.

     COLLECT STATISTICS COLUMN (o_orderdate), 
                        COLUMN (o_orderkey), 
                        COLUMN (o_orderdate, o_orderkey), 
                        COLUMN (o_orderkey, o_orderdate) 
     ON orders;

The following request displays a summary of statistical information for the orders table.

     HELP STATISTICS orders;