DB2 query results in Hex format — Need Character/String

后端 未结 2 1205
感情败类
感情败类 2021-01-27 08:30

I have a query that I can run on a DB2 table using my python SQL tester, and it returns the string values I\'m looking for.
However, when I run it directly on my database it

2条回答
  •  傲寒
    傲寒 (楼主)
    2021-01-27 09:07

    My guess is that it isn't returning hex...

    Rather it's returning EBCDIC.

    Your column is probably tagged with CCSID 65535, which tells the system not to translate it.

    The right way to fix this issue, is to make sure the column is tagged with the appropriate CCSID; for example, 37 for US English.

    The alternative, is to look for a "force translate" option in the settings of driver you're using.

提交回复
热议问题