Error converting characters into server's characte

 

hibernate使用sybase 15.0数据库,在未设置好DB参数时可能会造成乱码,出错显示如下:
Error 500: Hibernate flushing: Could not execute JDBC batch update; SQL [insert into CCS_LOG_ACTION (OP_ID, OP_TIME, MAINTYPE_CODE, SUBTYPE_CODE, SECONDTYPE_CODE, DESCRIPTION, DATALINE, BP_TYPE, BIZ_CODE, BIZ_ID, WORKSHEET_ID, WORKSHEET_NO, ID) values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)]; JZ0BE: BatchUpdateException:鎵ц鎵瑰鐞嗚鍙ユ椂鍑洪敊:Error converting characters into server's character set. Some character(s) could not be converted. ; nested exception is com.sybase.jdbc3.jdbc.SybBatchUpdateException: JZ0BE: BatchUpdateException:鎵ц鎵瑰鐞嗚鍙ユ椂鍑洪敊:Error converting characters into server's character set. Some character(s) could not be converted.

解决办法:
sp_configure "disable character set conversions" ,1
"disable character set conversions"为静态数据,需要重启server。那先shutdown数据库,然后再./startserver -f servername

 

昨日帮同事安装LoadRunner9.1,把依赖(或可能需要)的组件都装上后,仍出现command line option syntax error.type command /? for help  错误,google一下,竟然跟很多SQLServer数据库安装出错的提示一样,可见http://www.918x.cn/post/679.html

寻寻觅觅,终于还是在微软站点找到答案。是这样说的:
This problem may occur if all the following conditions are true: 
• You run the SQL Server 2000 SP3 Setup.bat file from a folder that contains double-byte character set (DBCS) characters in the folder name. 
• An ODBC client program that uses the Sqlsrv32.dll file is running on your computer.
我英文很烂,不过还是勉强看明白了。其中第一点是说,如果你把安装文件放在一个拥有双字节的名字的文件夹里就活该倒大霉。我的SQL SERVER2000安装盘的所在文件夹起了个中文名字,而汉字正是所谓的双字节。将文件夹名字改回英文再装,问题解决了。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值