org.hibernate.hql.ast.QuerySyntaxException: GoodsInfo is not mapped [select coun

org.hibernate.hql.ast.QuerySyntaxException:

GoodsInfo is not mapped [select count(*) from GoodsInfo where gname like '%%']

有可能是以下的原因导致Exception:

1. HQL语句有错:HQL语言要面向对象 GoodsInfo.java实体类进行操作,不是数据库表名,或者实体类写错;

2.忘了配置GoodsInfo.hbm.xml文件,或者配置有错;

猜你喜欢

转载自xienan123.iteye.com/blog/1133127