论坛首页 Java企业应用论坛

Webwork2.2.2中文搜索乱码新问题

浏览 1729 次
精华帖 (0) :: 良好帖 (0) :: 新手帖 (0) :: 隐藏帖 (0)
作者 正文
   发表时间:2006-08-31  
webwork2.2.2中文搜索时,我打开了hibernate的showSql,发现,HQL语句都是正常的,但真正的sql语句中的关键字变成了????,语句如下:
HQL:
from TCompanyGroup as t where 1 = 1  and t.name like '%测试%' order by t.top desc,t.backTime desc,t.inTime desc,t.id desc
SQL:
select top 16 tcompanygr0_.id as id, tcompanygr0_.title as title45_, tcompanygr0_.inTime as inTime45_, tcompanygr0_.backTime as backTime45_, tcompanygr0_.hits as hits45_, tcompanygr0_.backNum as backNum45_, tcompanygr0_.isGood as isGood45_, tcompanygr0_.isTop as isTop45_, tcompanygr0_.isLock as isLock45_, tcompanygr0_.html as html45_, tcompanygr0_.rss as rss45_, tcompanygr0_.userId as userId45_, tcompanygr0_.backerId as backerId45_, tcompanygr0_.content as content45_ from com_netwant_company_TCompanyGroup tcompanygr0_ where 1=1 and (tcompanygr0_.title like '%????%') order by tcompanygr0_.isTop desc,
唉,想不明白哪里出了问题,当然2.1.7下正常,好人帮我一下吧
论坛首页 Java企业应用版

跳转论坛:
Global site tag (gtag.js) - Google Analytics