Converting data with message flows

Data conversion is the process by which data is transformed from the format recognized by one operating system into that recognized by a second operating system with different characteristics such as numeric order.

If you are using a network of systems that use different methods for storing numeric values, or you need to communicate between users who view data in different code pages, you must consider how to implement data conversion.

Numeric order
For numeric and encoding aspects, consider:
  • Big Endian versus Little Endian
  • Encoding values in WebSphere MQ (the Encoding field in the MQMD)

    Encoding values are system specific. For example, Windows usually has an encoding of 546, hexadecimal value X'00000222'. The three final hexadecimal digits identify:

    1. The float number format

      Start of changeThis value can be 1 (IEEE format byte order normal), 2 (IEEE format byte order reversed), or 3 (zSeries format byte order normal). Note that operations on floating point numbers, whether IEEE or z/Series (S/390) format, are subject to rounding error.End of change

    2. The packed decimal number format

      This value can be 1 (byte order normal) or 2 (byte order reversed).

    3. The hexadecimal number format

      This value can be 1 (byte order normal) or 2 (byte order reversed).

    The bit order within a byte is never reversed. Byte order normal means that the least significant digit occupies the highest address.

    Systems that process numbers in normal byte order are Big Endian (z/Series, iSeries, Linux, and UNIX). Systems that process numbers in reversed byte order are Little Endian (mainly PCs).

    For further details about numeric order, see Appendix D, Machine Encodings, in the WebSphere MQ Application Programming Reference.

Code page conversions
Code page conversion might be required for any of the following reasons:
  • ASCII versus EBCDIC
  • National languages
  • Operating system specific code pages

For more information about code page support in WebSphere MQ, see the WebSphere MQ Application Programming Reference book.

When you use WebSphere Event Broker, you can use the data conversion facilities of WebSphere MQ.

WebSphere MQ facilities

Headers and message body are converted according to the MQMD values, and other header format names. You might have to set up data conversion exits to convert the body of your messages.

When you use WebSphere MQ facilities, the whole message is converted to the specified encoding and CCSID, according to the setting of the format in the WebSphere MQ header.

For more detail about data conversion using WebSphere MQ facilities, see Appendix F, Data Conversion, in the WebSphere MQ Application Programming Reference.

Related concepts
Message flows overview
Related tasks
Configuring message flows for data conversion
Related reference
Built-in nodes
Supported code pages