Encode syntax requirements - Connect_ETL - 9.13

Connect ETL Data Transformation Language (DTL) Guide

Product type
Software
Portfolio
Integrate
Product family
Connect
Product
Connect > Connect (ETL, Sort, AppMod, Big Data)
Version
9.13
Language
English
Product name
Connect ETL
Title
Connect ETL Data Transformation Language (DTL) Guide
Copyright
2023
First publish date
2003
Last updated
2023-09-11
Published on
2023-09-11T19:01:45.019000

Consider the following encoding syntax requirements:

  • String constants can be single-/double-quoted, or single-quoted with a prefix of U.
  • Identifiers can be unquoted, or double-quoted with a prefix of I .
  • Pathnames can be unquoted, or double-quoted.
  • DTL files must be saved in one encoding: UTF-8 or locale. Mixed encoding is not allowed.

DTL Encoding in UTF-8

To specify that a DTL file is encoded in UTF-8, do either of the following:

  • Save the file in UTF-8 with the BOM
  • Specify UTF-8 encoding as an argument to the /DTL option:
    /DTL [ RUNTIMEVARIABLES ON|OFF ] [ ENCODING LOCALE|UTF-8]
    Note: LOCALE refers to the locale of the machine where the job/task will run.

When a DTL file is encoded in UTF-8:

  • Connect ETL translates all quoted text, that is single-/double-quoted string constants, identifiers double-quoted with a prefix of I, and double-quoted pathnames, from UTF-8 to locale before processing.
  • String constants that are Unicode literals, that is, those that should not be translated to locale, must be prefixed with U.

For example, /VALUE value1 U'çççç' means process 'çççç' as a UTF-8 string without translating to locale.

DTL Encoding in LOCALE

In DTL, locale indicates the locale of the machine where the job/task is run. In order for a job/task to run successfully, the locale of the machine where the job/task is run must be the same as the locale of the machine where the job/task was created. In scenarios where design-time and run-time machines have different locales, save the job/task in UTF-8 encoding.

Quoted text is processed without being translated. As mixed encoding is not supported, an error message is generated when a locale DTL file contains string constants prefixed with U.

DTL File Encodings

Consider the following table, which illustrates how Connect ETL treats DTL file encodings:

BOM /DTL ENCODING Connect ETL Treatment of DTL File Encoding
Unspecified Unspecified Locale
Unspecified Locale Locale
Unspecified UTF-8 UTF-8
UTF-8 Unspecified UTF-8
UTF-8 Locale Error
UTF-8 UTF-8 UTF-8
Non-UTF-8 (all cases) Error