Restrictions on the Data Types Involved in Predicates - Analytics Database - Teradata Vantage

SQL Functions, Expressions, and Predicates

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-01-12
dita:mapPath
obm1628111499646.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
kby1472250656485
lifecycle
latest
Product Category
Teradata Vantage™

The restrictions in the following table apply to operations involving predicates and CLOB, BLOB, and UDT types.

Data Type Restrictions
BLOB Predicates do not support BLOB or CLOB data types.

You can explicitly cast BLOBs to BYTE and VARBYTE types and CLOBs to CHARACTER and VARCHAR types, and use the results in a predicate.

CLOB
UDT The LIKE and OVERLAPS logical predicates do not support UDTs.

For EXISTS and NOT EXISTS: Multiple UDTs involved as predicate operands must be identical types because Vantage does not perform implicit type conversion on UDTs involved as predicate operands.

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 operation involving predicates.

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

For BETWEEN/ NOT BETWEEN and IN/NOT:
  • Multiple UDTs involved as predicate operands must be identical types because Vantage does not perform implicit type conversion on UDTs involved as predicate operands.

    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 operation involving predicates.

  • UDTs involved as predicate operands must have ordering definitions.

    Vantage 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.