TRANSLATE Function Syntax | VantageCloud Lake - TRANSLATE Function Syntax - Teradata Vantage

Teradata® VantageCloud Lake

Deployment
VantageCloud
Edition
Lake
Product
Teradata Vantage
Published
January 2023
Language
English (United States)
Last Update
2024-04-03
dita:mapPath
phg1621910019905.ditamap
dita:ditavalPath
pny1626732985837.ditaval
dita:id
phg1621910019905
TRANSLATE (
  character_string_expression
  USING source_repertoire_name
  [ _encoding ]
  TO target_repertoire_name
  [ _suffix ]
  [ WITH ERROR ]
)

Syntax Elements

character_string_expression
A character string or character string expression for which the hexadecimal representation is to be returned.
If character_string_expression is not a character type, an error is returned.
source_repertoire_name
The source character set of the string to translate.
A value of LOCALE can be specified for source_repertoire_name to translate a character string from LATIN or KANJI1 to UNICODE using a source repertoire determined by the language support mode of the system and the client character set of the session.
_encoding
A literal for translating from KANJI1 to UNICODE that indicates a specific encoding of KANJI1.
The _encoding option is not allowed if LOCALE is specified for source_repertoire_name or target_repertoire_name.
If the translation is from these character sets:
  • KatakanaEBCDIC
  • KanjiEBCDIC5026_0I
  • KanjiEBCDIC5038_0I
Use the following value for _encoding: _KanjiEBCDIC
KanjiEUC_0U, use the following value for _encoding: _KanjiEUC
KanjiShiftJIS_0S, use the following value for _encoding: _KANJISJIS
ASCII or EBCDIC, use the following value for _encoding: _SBC
target_repertoire_name
The target character set of the string to translate.
A value of LOCALE can be specified for target_repertoire_name to translate a character string from UNICODE to LATIN or KANJI1 using a target repertoire determined by the language support mode of the system and the client character set of the session.
_suffix
Specifies that there are source characters that the translation maps to semantically different characters.
For example, a translation that specifies the _Halfwidth suffix maps any character with a halfwidth variant to that variant, and all fullwidth variants to their non-fullwidth counterparts.
The _suffix option also indicates the form of character data translated from UNICODE to the KANJI1 server character set, for example, _KanjiEUC.
Valid values are:
  • _KanjiEBCDIC
  • _KanjiEUC
  • _KANJISJIS
  • _SBC
  • _PadSpace
  • _PadGraphic
  • _Fullwidth
  • _Halfwidth
  • _FoldSpace
  • _VarGraphic
The _suffix option is not allowed if LOCALE is specified for source_repertoire_name or target_repertoire_name.
WITH ERROR
Specifies that the translation replaces offending characters in the string with a designated error character, instead of reporting an error.