JDBC 连接informix 中文字符集转换失败

0
Java 数据库 JDBC C/C++ Informix 12776 次浏览
JDBC 连接informix ,informix 数据库字符集设置为big5. 客户端语言环境为UTF-8,数据库字段存在“墙”,“銹”字符时,
获取数据失败
url详细:
url=jdbc:informix-sqli://192.168.0.1:8015/dsx:INFORMIXSERVER=on_tcp8;NEWLOACLE=en_us,zh_cn,zh_tw;
NEWCODESET=utf8,big5,57352;DB_LOCALE=zh_TW.57352;CLIENT_LOCALE=zh_TW.57352
错误信息:
Caused by: java.sql.SQLException: 不支援編碼或內碼集.
at com.informix.util.IfxErrMsg.getSQLException(IfxErrMsg.java:413)
at com.informix.jdbc.IfxChar.fromIfx(IfxChar.java:235)
at com.informix.jdbc.IfxRowColumn.a(IfxRowColumn.java:380)
at com.informix.jdbc.IfxRowColumn.a(IfxRowColumn.java:282)
at com.informix.jdbc.IfxSqli.a(IfxSqli.java:4775)
at com.informix.jdbc.IfxResultSet.a(IfxResultSet.java:669)
at com.informix.jdbc.IfxResultSet.b(IfxResultSet.java:641)
at com.informix.jdbc.IfxResultSet.getObject(IfxResultSet.java:1511)
at com.informix.jdbc.IfxResultSet.getObject(IfxResultSet.java:809)
请尽量让自己的答案能够对别人有帮助

1个答案

默认排序 按投票排序
0
你好!我也遇到了同种问题(不支援編碼或內碼集.),请问你是怎么解决的?纠结了我好久了

informix数据库URL:jdbc:informix-sqli://11.1.60.133:4568/iqc:informixserver=ol_cc;newlocale=en_us,zh_cn;newcodeset=gbk,8859-1,819