CLOB Data Type Usage Notes - Teradata VantageCloud Lake

Lake - Working with SQL

Deployment
VantageCloud
Edition
Lake
Product
Teradata VantageCloud Lake
Release Number
Published
February 2025
ft:locale
en-US
ft:lastEdition
2025-11-21
dita:mapPath
jbe1714339405530.ditamap
dita:ditavalPath
pny1626732985837.ditaval
dita:id
jbe1714339405530

External Representation

A client application talks to Vantage indicates its character set (form-of-use for character data). Vantage returns all character data to the application in that form.

Whenever multibyte characters are involved, their representation has the length (n-2)/2 multibyte characters exclusive of the preceding Shift-Out and following Shift-In characters.

The following table lists the client representations for the CLOB data type. Determining the application definitions and client data types is the responsibility of the application programmer.

Define the length of the CLOB string as k, where 0 ≤ k ≤ n.

Client CPU Architecture Client Internal Data Format
IBM mainframe Eight byte (most significant byte first) length count k followed by k bytes of EBCDIC character data for a total of k+8 bytes.
  • UTS
  • RISC
  • Motorola 68000
  • WE 32000
Eight byte (most significant byte first) length count k followed by k bytes of ASCII character data for a total of k+8 bytes.
Intel Eight byte (least significant byte first) length count k followed by k bytes of ASCII character data for a total of k+8 bytes.

Restrictions

A table can have a maximum of 32 LOB columns.

Queue tables cannot have CLOB columns.

A LOB column cannot be a component of an index. Therefore, a table must define at least one non-LOB column.

The CHARACTER SET clause can specify the following server character sets for a CLOB column:
  • LATIN
  • UNICODE

Functions That Operate on CLOBs

The following functions and operators support CLOB types:
  • CHARACTERS/CHARS/CHAR
  • MCHARACTERS
  • CHARACTER_LENGTH
  • TRANSLATE and TRANSLATE_CHK
  • SUBSTRING/SUBSTR
  • Concatenation operator (||)
  • TYPE
  • Explicit data type conversion (CAST and Teradata conversion syntax)
  • User-defined functions (UDFs)
  • Stored procedures
  • External stored procedures