org.hibernate.hql.ast.QuerySyntaxException: XXX is not mapped [from XXX]
来源:互联网 发布:淘宝hd版下载 编辑:程序博客网 时间:2024/06/06 09:54
注意1:使用hql的时候,要使用实体类,以及实体类的属性
注意2:不要忘了加载映射文件,虽然已经有了映射文件,但是要让程序能够找到(加载)它。
使用hibernate.properties时
解决方法:Configuration config = new Configuration().addClass(实体类) 或 Configuration config = new Configuration().addResource(映射文件)
使用hibernate.cfg.xml时
解决方法:添加节点<mapping resource="路径\映射文件">
- org.hibernate.hql.ast.QuerySyntaxException: XXX is not mapped [from XXX]
- org.hibernate.hql.ast.QuerySyntaxException: xxx is not mapped [from xxx]
- org.hibernate.hql.ast.QuerySyntaxException: xxx is not mapped [from xxx]
- org.hibernate.hql.internal.ast.QuerySyntaxException: XXX is not mapped [from XXX]
- Hibernate查询报错:org.hibernate.hql.internal.ast.QuerySyntaxException: XXX is not mapped
- nested exception is org.hibernate.hql.ast.QuerySyntaxException: users is not mapped. [from users]
- nested exception is org.hibernate.hql.ast.QuerySyntaxException: Product is not mapped [from Product]
- org.hibernate.hql.ast.QuerySyntaxException is not mapped
- org.hibernate.hql.ast.QuerySyntaxException: myaddressbook is not mapped
- org.hibernate.hql.ast.QuerySyntaxException: Enroll is not mapped.
- org.hibernate.hql.ast.QuerySyntaxException: ? is not mapped
- org.hibernate.hql.ast.QuerySyntaxException:is not mapped
- org.hibernate.hql.ast.QuerySyntaxException: is not mapped 异常总结
- org.hibernate.hql.ast.QuerySyntaxException: is not mapped 异常总结 .
- org.hibernate.hql.ast.QuerySyntaxException is not mapped异常
- org.hibernate.hql.ast.QuerySyntaxException: Person is not mapped
- org.hibernate.hql.internal.ast.QuerySyntaxException: Exam is not mapped
- org.hibernate.hql.ast.QuerySyntaxException: UserType is not mapped
- tomcat添加用户
- [转]浮点数解惑
- 运行预构建 Linux 映像的 Windows Azure 虚拟机中的交换空间 – 第 1 部分
- 服务器场集群操控雏形
- 数据库性能优化二:数据库表优化
- org.hibernate.hql.ast.QuerySyntaxException: XXX is not mapped [from XXX]
- 解决android4.0以上程序请求需做的处理
- 高水位线对于全表扫描的影响
- EASYSIZE 文件解读
- *选择器(jQuery)
- 扩展方法(C# 编程指南)
- hdu 4313 Matrix(最大生成树)
- linux command-ps
- 反射的部分内容