Dovetailed Technologies

Name

showtrtab — Co:Z utility to display a translation table

Synopsis

showtrtab [-L logging_options][-s source_codepage][-t target_codepage][-q technique_str]
    

Description

This z/OS Co:Z utility command will show the translate table associated with a source and target codeset. It first attempts to use unicode services, but will fall back to iconv() if needed.

If a table cannot be built, the command will display error information that may be useful in determining the problem.

This utility only supports SBCS -> SBCS and SBCS -> MBCS. MBCS -> SBCS tables are not supported.

To get detailed information, the logging option -LTranslator=T can be used.

Options

-L logging-options

A comma-separated list of options to control logging and tracing:

M | A | C | E | W | N | I | D | T

Logging threshhold: eMergency, Alert, Critical, Error, Warning, Notice, Info (default), Debug, Trace.

t

Prefix log messages with a system timestamp

e

Include consumed cpu time in log messages

s

Messages are logged to SYSLOG facility instead of stderr

logname=M|A|C|E|W|N|I|D|T

Set a specific log name to the given threshold

-s source-codepage

The source codepage name. If not specified, then the default z/OS process codepage is used. At least one of -s or -t is required.

-t target-codepage

The target codepage name. If not specified, then the default z/OS process codepage is used. At least one of -s or -t is required.

-q technique-str

The Unicode Services conversion technique(s) to accept. This is a string of one or more of the following technique characters:

C

Customized Subset

E

Enforced Subset

L

Language Environment Behavior

M

Modified Language Environment Behavior

R

Roundtrip

If more than one character is specified, the first available matching technique is used - therefore the order is significant.

When falling back to iconv() this list is ignored

Examples

  1. This example shows a Translate table from a source code page of ISO8859-1 to a target codepage which is the current z/OS process' default

    /dovetail/coz104/bin: > showtrtab -s ISO8859-1
                                                                               
    00:  00 01 02 03   37 2D 2E 2F   16 05 15 0B   0C 0D 0E 0F 
    10:  10 11 12 13   3C 3D 32 26   18 19 3F 27   1C 1D 1E 1F 
    20:  40 5A 7F 7B   5B 6C 50 7D   4D 5D 5C 4E   6B 60 4B 61 
    30:  F0 F1 F2 F3   F4 F5 F6 F7   F8 F9 7A 5E   4C 7E 6E 6F 
    40:  7C C1 C2 C3   C4 C5 C6 C7   C8 C9 D1 D2   D3 D4 D5 D6 
    50:  D7 D8 D9 E2   E3 E4 E5 E6   E7 E8 E9 AD   E0 BD 5F 6D 
    60:  79 81 82 83   84 85 86 87   88 89 91 92   93 94 95 96 
    70:  97 98 99 A2   A3 A4 A5 A6   A7 A8 A9 C0   4F D0 A1 07 
    80:  20 21 22 23   24 25 06 17   28 29 2A 2B   2C 09 0A 1B 
    90:  30 31 1A 33   34 35 36 08   38 39 3A 3B   04 14 3E FF 
    A0:  41 AA 4A B1   9F B2 6A B5   BB B4 9A 8A   B0 CA AF BC 
    B0:  90 8F EA FA   BE A0 B6 B3   9D DA 9B 8B   B7 B8 B9 AB 
    C0:  64 65 62 66   63 67 9E 68   74 71 72 73   78 75 76 77 
    D0:  AC 69 ED EE   EB EF EC BF   80 FD FE FB   FC BA AE 59 
    E0:  44 45 42 46   43 47 9C 48   54 51 52 53   58 55 56 57 
    F0:  8C 49 CD CE   CB CF CC E1   70 DD DE DB   DC 8D 8E DF 
          
  2. This example shows a Translate table from a source code page of ISO8859-2 to a target codepage of IBM-273. Logging is activated.

    /dovetail/coz104/bin: > showtrtab -LTranslator=T -s ISO8859-2 -t IBM-273                                                 
    showtrtab[T]: Translator: -> Translator(ISO8859-2, IBM-273, LMREC)
    showtrtab[T]: Translator: -> getCodePage(ISO8859-2)
    showtrtab[D]: Translator: Looking for codepage substitution environment 
       variable: COZ_TRSUB_ISO8859-2
    showtrtab[T]: Translator: <- getCodePage()
    showtrtab[T]: Translator: -> getCodePage(IBM-273)
    showtrtab[D]: Translator: Looking for codepage substitution environment 
       variable: COZ_TRSUB_IBM-273
    showtrtab[T]: Translator: <- getCodePage()
    showtrtab[T]: Translator: -> initialize( ISO8859-2->IBM-273, t=LMREC)
    showtrtab[T]: Translator: -> getCcsid(ISO8859-2)
    showtrtab[T]: Translator: <- getCcsid(912)
    showtrtab[T]: Translator: -> getCcsid(IBM-273)
    showtrtab[T]: Translator: <- getCcsid(273)
    showtrtab[T]: Translator: -> initCunbcprm()
    showtrtab[T]: Translator: <- initCunbcprm()
    showtrtab[T]: Translator: <- initialize()
    showtrtab[T]: Translator: <- Translator()
    00:  00 01 02 03   37 2D 2E 2F   16 05 25 0B   0C 0D 0E 0F 
    10:  10 11 12 13   3C 3D 32 26   18 19 3F 27   1C 1D 1E 1F 
    20:  40 4F 7F 7B   5B 6C 50 7D   4D 5D 5C 4E   6B 60 4B 61 
    30:  F0 F1 F2 F3   F4 F5 F6 F7   F8 F9 7A 5E   4C 7E 6E 6F 
    40:  B5 C1 C2 C3   C4 C5 C6 C7   C8 C9 D1 D2   D3 D4 D5 D6 
    50:  D7 D8 D9 E2   E3 E4 E5 E6   E7 E8 E9 63   EC FC 5F 6D 
    60:  79 81 82 83   84 85 86 87   88 89 91 92   93 94 95 96 
    70:  97 98 99 A2   A3 A4 A5 A6   A7 A8 A9 43   BB DC 59 07 
    80:  20 21 22 23   24 15 06 17   28 29 2A 2B   2C 09 0A 1B 
    90:  30 31 1A 33   34 35 36 08   38 39 3A 3B   04 14 3E FF 
    A0:  41 44 46 47   9F 49 52 7C   BD 54 57 58   64 CA 66 67 
    B0:  90 69 70 72   BE 74 77 78   9D 80 8A 8B   8C 8E 8F 9A 
    C0:  9B 65 62 9C   4A 9E A0 68   AA 71 AB 73   AE 75 76 AF 
    D0:  AC B0 B1 EE   EB B2 E0 BF   B3 B4 FE B6   5A AD B7 A1 
    E0:  B8 45 42 B9   C0 BA BC 48   CC 51 CD 53   CF 55 56 DA 
    F0:  DB DD DF CE   CB EA 6A E1   ED EF DE FA   D0 8D FB FD 
          
  3. Shows an attempt to build a MBCS->SBCS table, and the resulting error.

    /dovetail/coz104/bin: > showtrtab -s UTF-8 -t IBM-1047                                                                   
    showtrtab[E]: TranslateException: Exception occurred during translation, 
       RC=4, Reason=12      
          
Copyright© 2009-2017 Dovetailed Technologies, LLC. All rights reserved.
Co:Z® is a registered trademark of Dovetailed Technologies, LLC.