17.10 - COUNT_mode - Advanced SQL Engine - Teradata Database

Teradata Vantage™ - Database Utilities

Product
Advanced SQL Engine
Teradata Database
Release Number
17.10
Release Date
July 2021
Content Type
Configuration
Publication ID
B035-1102-171K
Language
English (United States)

Determines the data type returned by COUNT operations.

Field Group

General

Valid Settings

Setting Description
0 Data type depends on session mode:
  • For ANSI session mode, the data type is DECIMAL.
  • For Teradata session mode, the data type is INTEGER.
1 Data type is NUMBER.
2 Data type is BIGINT.

Default

0

Changes Take Effect

After the DBS Control Record has been written.

Usage Notes

If you experience numeric overflow errors with COUNT operations, try changing this field value to 1 or 2. This can happen for tables with billions of rows, specifically in Teradata session mode if the base table of the COUNT aggregate function exceeds about two billion rows.

Related Information

For more information about aggregate functions including COUNT, see Teradata Vantage™ - SQL Functions, Expressions, and Predicates, B035-1145.