JSON Default Values for INLINE LENGTH - Advanced SQL Engine - Teradata Database

JSON Data Type

Product
Advanced SQL Engine
Teradata Database
Release Number
17.05
17.00
Published
September 2020
Language
English (United States)
Last Update
2021-01-23
dita:mapPath
gzn1554761068186.ditamap
dita:ditavalPath
lze1555437562152.ditaval
dita:id
B035-1150
lifecycle
previous
Product Category
Teradata Vantage™

If you do not specify an inline length and the maximum length of the data type is 64000 bytes (32000 UNICODE characters) or smaller, the default inline length is the same as the maximum length, and the data type is a non-LOB type.

If you do not specify an inline length and the maximum length of the data type is larger than 64000 bytes (32000 UNICODE characters), the data type is a LOB type with a default inline length as shown in the following table.

This table summarizes possible values for the inline length and the maximum length and whether the data type will be a LOB or non-LOB.

Data Type Inline Storage Maximum Length LOB Type
JSON 4096 bytes (default) 16776192 bytes (default) LOB
JSON(n) CHARACTER SET LATIN, where n ≤ 64000 ncharacters (default) n characters non-LOB
JSON(n) CHARACTER SET LATIN, where n > 64000 4096 bytes (default) n characters LOB
JSON(n) CHARACTER SET LATIN INLINE LENGTH m m characters n characters
  • If n = m, then non-LOB
  • If n > m, then LOB
  • If n < m, then error
JSON(n) CHARACTER SET UNICODE, where n ≤ 32000 n characters (default) n characters non-LOB
JSON(n) CHARACTER SET UNICODE, where n > 32000 4096 bytes (default) n characters LOB
JSON(n) CHARACTER SET UNICODE INLINE LENGTH m m characters n characters
  • If n = m, then non-LOB
  • If n > m, then LOB
  • If n < m, then error
JSON(n) STORAGE FORMAT BSON, where n ≤ 64000 n bytes (default) n bytes non-LOB
JSON(n) STORAGE FORMAT BSON, where n > 64000 4096 bytes (default) n bytes LOB
JSON(n) STORAGE FORMAT BSON INLINE LENGTH m m bytes n bytes
  • If n = m, then non-LOB
  • If n > m, then LOB
  • If n < m, then error
JSON(n) STORAGE FORMAT UBJSON, where n ≤ 64000 n bytes (default) n bytes non-LOB
JSON(n) STORAGE FORMAT UBJSON, where n > 64000 4096 bytes (default) n bytes LOB
JSON(n) STORAGE FORMAT UBJSON INLINE LENGTH m m bytes n bytes
  • If n = m, then non-LOB
  • If n > m, then LOB
  • If n < m, then error