Example: HELP STATISTICS for a Geospatial Column - Advanced SQL Engine - Teradata Database

SQL Data Definition Language Syntax and Examples

Product
Advanced SQL Engine
Teradata Database
Release Number
17.00
Published
September 2020
Language
English (United States)
Last Update
2021-01-23
dita:mapPath
wgr1555383704548.ditamap
dita:ditavalPath
lze1555437562152.ditaval
dita:id
B035-1144
lifecycle
previous
Product Category
Teradata Vantage™

Consider the following COLLECT STATISTICS request, where o_spatial_location is a geospatial column.

     COLLECT STATISTICS 
       COLUMN o_orderdatetime,
       COLUMN o_orderkey,
       COLUMN o_spatial_location
     ON orders;

The following HELP STATISTICS request returns summary statistical information for orders that reports information for the geospatial column. This information includes the table cardinality known to the Optimizer indicated by the row with column value *.

Because the concept Unique Values is meaningless for Geospatial data types, a HELP STATISTICS request always returns the total number of base table rows in the position taken by a geospatial column, which in this case is o_spatial_location.

     HELP STATISTICS orders;
     *** Help information returned. 3 rows.
     *** Total elapsed time was 1 second.
Date      Time       Unique Values        Column Names
-------- -------- -------------------- ----------------------------
10/08/16 18:14:36               100        *
10/08/16 18:10:48               100        o_orderdatetime
10/08/16 18:05:44               100        o_orderkey
10/08/16 18:19:08               100        o_spatial_location