hql查询 could not execute query
1个回答

严重:You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''aname' as column2_0_,admininfo0_.'apwd' as column3_0_,admininfo0_.'alevel' as' at line 1

第一:你确定你的实体名称Admininfo写对了,还有aname和apwd也写对了,aname和spwd也对应是实体Admininfo 的属性名称.

第二:如果以上确定没有错误的话,可以肯定的是你的实体映射有问题,映射文件里的实体属性名称要与你的表的列名要对应上,仔细研究上面的错误,问题很有可能出在表的列上.