6.6.2 Data Translation Rules

The TMA TCP Gateway adheres to the following data translation rules:

  • CARRAY fields are passed untranslated as sequences of bytes.
  • STRING and CHAR fields undergo ASCII to EBCDIC translation (if needed).
  • SHORT and LONG fields are translated to S9(4) COMP and S9(9) COMP, respectively.
  • FLOAT and DOUBLE fields are translated to COMP‑1 and COMP‑2, respectively.

    Note:

    The Oracle Tuxedo product provides a field type named dec_t that supports decimal values within VIEWs. The TMA TCP for IMS gateway translates these fields into machine independent representations of packed decimals. For example, dec_t(m,n) becomes S9(2*m-(n+1))V9(n) COMP-3. Therefore, a decimal field with a size of 8,5 corresponds to S9(10)V9(5) COMP-3

The following table summarizes the rules for translating between C and IBM 370 data types.

Remote Data Type Description View Field Type/Length
PIC X(n) Alphanumeric characters string / n
PIC X Single alphanumeric character char
PIC X(n) Raw bytes carray / n
PIC 9 Single numeric byte carray / 1
PIC S9(4) COMP 32-bit integer short
PIC S9(4) COMP 64-bit integer long
COMP-1 Single-precision floating point float
COMP-2 Double-precision floating point double
PIC S9((m+(n+1))/2)V9(n) COMP-3 Packed decimal dec_t / m,n