By default, if you do
not specify the CONVERT Get Message Option, then SAS converts the
data conversion to the default encoding for the SAS session. To disable
the automatic SAS data conversion, specify the MQSASCNV SAS macro
variable and set it to a value of DISABLE or OFF:
You can use the KCVT
function to convert your data manually. Converting data manually is
especially useful for programs that put reply messages on a queue.
For example, your SAS
program might use messaging to interact with a Java Web application
that uses UTF-8 encoding. When receiving messages, SAS automatically
converts the message data to the session encoding. However, you must
convert the data back to UTF-8 before sending it to the reply queue.
The following code converts the variable TEXT from WLatin1 to UTF-8:
text= kcvt(text, wlatin1, utf8));
For more information,
see
KCVT Function in SAS National Language Support (NLS): Reference Guide.