JSON Data Type | Compressing JSON Type Data | Teradata Vantage - Compressing JSON Type Data - 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™
You can use the following compression functions to perform algorithmic compression (ALC) on JSON type columns:
  • JSON_COMPRESS
  • JSON_DECOMPRESS
  • TD_LZ_COMPRESS
  • TD_LZ_DECOMPRESS

You can use TD_LZ_COMPRESS to compress JSON data; however, Teradata recommends that you use JSON_COMPRESS instead because the JSON_COMPRESS function is optimized for compressing JSON data.

JSON_COMPRESS and JSON_DECOMPRESS can be used to compress JSON type columns only. These functions cannot be used to compress columns of other data types.

You cannot create your own compression and decompression user-defined functions to perform algorithmic compression on JSON type columns. You must use the functions previously listed.

You can use ALC to compress columns that store JSON data using one of the binary storage formats (BSON or UBJSON).

Using ALC together with block-level compression (BLC) may degrade performance, so this practice is not recommended. For more information on compression use cases and examples, see Teradata Orange Book Block-Level Compression in Teradata:
  1. Go to https://support.teradata.com.
  2. Log in.

For more information about compression functions, see Teradata Vantage™ - SQL Operators and User-Defined Functions, B035-1210.

For information about the COMPRESS and DECOMPRESS phrases, see Teradata Vantage™ - Data Types and Literals, B035-1143.