About DATASET Type Transform - Teradata Vantage NewSQL Engine - 16.20

Teradata Vantageā„¢ DATASET Data Type

prodname
Teradata Database
Teradata Vantage NewSQL Engine
vrm_release
16.20
category
Programming Reference
featnum
B035-1198-162K

The DATASET type transform groups are used to import and export DATASET data from a client system to the Teradata Database, and from Teradata Database to a client system.

You can specify which predefined transform group is used by default for a certain data type. The DATASET transform groups are based on the DATASET type instance storage format.

STORAGE FORMAT Avro transforms must meet the following requirements:

  • Transform to/from BLOB using TD_DATASET_AVRO_BLOB (default).

    The BLOB is composed of the UTF-8 encoded schema, null-terminated, followed by the binary-encoded Avro value.

  • Transform to/from VARBYTE using TD_DATASET_AVRO_VARBYTE

    The VARBYTE is composed of the UTF-8 encoded schema, null-terminated, followed by the binary-encoded Avro value.

STORAGE FORMAT CSV transforms must meet the following requirements:
  • Transform to/from CLOB in the CSV value character set using TD_Dataset_CSV_CLOB.

    The CLOB is composed of a CSV value. Specified optional schemas are not included.

  • Transforms to/from VARCHAR in the character set of the CSV value using TD_Dataset_CSV_VARCHAR.

    The VARCHAR is composed of a CSV value. Specified optional schemas are not included.

The required formats of these transforms are equivalent to those defined for the system-defined casts.

You can use the TRANSFORM option in the CREATE PROFILE/MODIFY PROFILE or CREATE USER/MODIFY USER statements to specify for a user the particular transform group that will be used for a given data type.

Use the SET TRANSFORM GROUP FOR TYPE statement to change the active transform group in the current session. You can use this statement multiple times for a data type to switch from one transform group to another within the session. If the logon user already has transform settings, the statement modifies the transform settings for the current session.

You cannot use CREATE TRANSFORM or REPLACE TRANSFORM to create new transforms for complex data types (CDTs). You can only create new transforms for structured and distinct user-defined types (UDTs).

Transform Group Macros

You can use the following macros to find the transform group for a UDT (or CDT), or the transform group settings for a user, profile, or current session.

Macro Description
SYSUDTLIB.HelpCurrentUserTransforms Lists the transform group settings of the current logon user.
SYSUDTLIB.HelpCurrentSessionTransforms Lists the transform group settings of the current session.
SYSUDTLIB.HelpUserTransforms(User) Lists the transform group settings for a specific user.
SYSUDTLIB.HelpCurrentUDTTransform(UDT)

Lists the transform group settings of the current session for the specified UDT.

SYSUDTLIB.HelpUDTTransform(User,UDT) Lists the transform group for a UDT for a user.
SYSUDTLIB.HelpProfileTransforms(Profile) Lists the transform group settings for a specific profile.

SYSUDTLIB.HelpProfileTransform(Profile,UDT)

Lists the transform group for a UDT for a profile.

For more information about these macros, see Teradata Vantageā„¢ SQL Data Definition Language Syntax and Examples, B035-1144.