6.6.2 Data Translation Rules
The TMA TCP Gateway adheres to the following data translation rules:
CARRAYfields are passed untranslated as sequences of bytes.STRINGandCHARfields undergo ASCII to EBCDIC translation (if needed).SHORTandLONGfields are translated toS9(4) COMPandS9(9) COMP, respectively.FLOATandDOUBLEfields are translated to COMP‑1 and COMP‑2, respectively.Note:
The Oracle Tuxedo product provides a field type nameddec_tthat supports decimal values withinVIEWs. The TMA TCP for IMS gateway translates these fields into machine independent representations of packed decimals. For example,dec_t(m,n)becomesS9(2*m-(n+1))V9(n) COMP-3. Therefore, a decimal field with a size of 8,5 corresponds toS9(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 |