Restrictions on the Data Types Involved in Set Operations - Teradata Database - Teradata Vantage NewSQL Engine

SQL Data Manipulation Language

Product
Teradata Database
Teradata Vantage NewSQL Engine
Release Number
16.20
Published
March 2019
Language
English (United States)
Last Update
2019-05-03
dita:mapPath
fbo1512081269404.ditamap
dita:ditavalPath
TD_DBS_16_20_Update1.ditaval
dita:id
B035-1146
lifecycle
previous
Product Category
Teradata Vantage™

The following restrictions apply to CLOB, BLOB, and UDT types involved in set operations.

Data Type Restrictions
BLOB

You cannot use set operators with CLOB or BLOB types, except in the case of the UNION ALL set operator.

CLOB
UDT
  • Multiple UDTs involved in set operations must be identical types because Teradata Database does not perform implicit type conversion on UDTs involved in set operations.

    A workaround for this restriction is to use CREATE CAST to define casts that cast between the UDTs and then explicitly invoke the CAST function within the set operation.

  • UDTs involved in set operations must have ordering definitions.

    Teradata Database generates ordering functionality for distinct UDTs where the source types are not LOBs. To create an ordering definition for structured UDTs or distinct UDTs where the source types are LOBs, or to replace system-generated ordering functionality, use CREATE ORDERING.

For more information on CREATE CAST and CREATE ORDERING, see Teradata Vantage™ SQL Data Definition Language Syntax and Examples, B035-1144.