Session Modes in Teradata

Teradata session modes description

The Teradata database has different modes for running queries: ANSI Mode (rules based on the ANSI SQL: 2011 specifications) and TERA mode (rules defined by Teradata). Please review the following Teradata documentation for more information.

Teradata mode for strings informative table

For strings, the Teradata Mode works differently. As it is explained in the following table based on the Teradata documentation:

Feature
ANSI mode
Teradata mode

Default attribute for character comparisons

CASESPECIFIC

NOT CASESPECIFIC

Default TRIM behavior

TRIM(BOTH FROM)

TRIM(BOTH FROM)

Translation specification summary

Mode
Column constraint values
Teradata behavior
SC expected behavior

ANSI Mode

CASESPECIFIC

CASESPECIFIC

No constraint added.

NOT CASESPECIFIC

CASESPECIFIC

Add COLLATE 'en-cs' in column definition.

Teradata Mode

CASESPECIFIC

CASESPECIFIC

In most cases, do not add COLLATE, and convert its usages of string comparison to RTRIM( expression )

NOT CASESPECIFIC

NOT CASESPECIFIC

In most cases, do not add COLLATE, and convert its usages of string comparison to RTRIM(UPPER( expression ))

Available translation specification options

Last updated