Using concatenation with DBCS fields
When double-byte character set (DBCS) fields are included in a concatenation through the Open Query File (OPNQRYF) command, the resulting data type is the same as the data type of the concatenated field in a logical file, with some slight variations. The following rules apply when using concatenation with DBCS fields through the OPNQRYF command:
- If the concatenation contains one or more hexadecimal (H) fields, the resulting data type is hexadecimal (H).
- If the concatenation contains one or more UCS2-graphic fields, the resulting data type is UCS2-graphic.
- If all fields in the concatenation are DBCS-only (J), the resulting data type is variable length DBCS-only (J).
- If the concatenation contains one or more DBCS (O, E, J) fields, but no hexadecimal (H) or UCS2-graphic fields, the resulting data type is variable length DBCS open (O).
- If the concatenation contains one or more variable length fields of any data type, the resulting data type is variable length.
- If a DBCS-graphic (G) field is concatenated to another DBCS-graphic (G) field, the resulting data type is DBCS-graphic (G).
Parent topic:
Using DBCS fields in the Open Query File (OPNQRYF) command
Related concepts
DBCS field concatenation