org.hibernate.QueryException: Unable to resolve path [SecWilldosetdate.name],xxxxxxxx...异常处理
今天在写hql语句的时候出现了这个错误,然后一直运行到执行hql这儿就出错了。页面报500.
原hql如下:
String hql = "from SecWilldosetdate where name = 'secEduplan'";
问题如下:
org.hibernate.QueryException: Unable to resolve path [SecWilldosetdate.name], unexpected token [SecWilldosetdate] [from com.sms.security.supervisionAssess.bean.SecWilldosetdate where SecWilldosetdate.name = 'secEduplan']
org.hibernate.hql.ast.tree.IdentNode.resolveAsNakedComponentPropertyRefLHS(IdentNode.java:)
折腾了好一会,最后加了个别名好了,不知道是什么原因。还是对hql不熟悉啊。
String hql = "from SecWilldosetdate s where s.name = 'secEduplan'";
org.hibernate.QueryException: Unable to resolve path [SecWilldosetdate.name],xxxxxxxx...异常处理的更多相关文章
- nested exception is org.hibernate.QueryException: could not resolve property
SSH框架出现了下面的错误: nested exception is org.hibernate.QueryException: could not resolve property 检查了hbm.x ...
- org.hibernate.QueryException: could not resolve property
org.hibernate.QueryException: could not resolve property HibernateSQLXML org.hibernate.QueryExcepti ...
- org.hibernate.QueryException: could not resolve property: address of:
Hibernate: select count(*) as y0_ from test.course this_ org.hibernate.QueryException: could not res ...
- 常见Hibernate报错处理:出现“org.hibernate.QueryException: could not resolve property”和 is not mapped和could not locate named parameter错误的解决
正确写法: @Override @SuppressWarnings("unchecked") public List<Device> queryOSDevice(Str ...
- Hibernate-org.hibernate.QueryException: could not resolve property: code of:
查询的时候有个属性跟表里的字段不符合,没有完全匹配上.
- Caused by: org.hibernate.boot.registry.selector.spi.StrategySelectionException: Unable to resolve name [org.hibernate.cache.ehcache.EhCacheRegionFactory] as strategy [org.hibernate.cache.spi.RegionFac
警告: Exception encountered during context initialization - cancelling refresh attempt: org.springfram ...
- Error creating bean with name 'sessionFactory' defined in class path resource [applicationContext.xml]: Invocation of init method failed; nested exception is org.hibernate.HibernateException: Unable t
spring与hibernate整合然后出现如下错误: org.springframework.beans.factory.BeanCreationException: Error creating ...
- 本地缺Android SDK版本20,Unable to resolve target 'android-20'
解决方案一 本地缺Android SDK版本20,Unable to resolve target 'android-20' 通过SDK Manager安装一个Android 20. 解决方案二: L ...
- Android 开发 --Unable to resolve target 'android-19'
Android 开发 --Unable to resolve target 'android-19' http://blog.csdn.net/love_javc_you/article/detail ...
随机推荐
- 使用Apache IO库操作IO与文件
--------------siwuxie095 首先到 Apache官网 下载相关的库文件 Apache官网:http://www.apach ...
- sql语句查询中exists中为什么要用select 1?
select * from call_cdr_xz_200609 a where and a.ori_charge<>0 and exists(select 1 from special ...
- 37.ROUND() 函数
ROUND() 函数 ROUND 函数用于把数值字段舍入为指定的小数位数. SQL ROUND() 语法 SELECT ROUND(column_name,decimals) FROM table_n ...
- 认识Filter
1). Filter 是什么 ? ①. JavaWEB 的一个重要组件, 可以对发送到 Servlet 的请求进行拦截, 并对响应也进行拦截. ②. Filter 是实现了 Filter 接口的 Ja ...
- 编写高质量代码改善C#程序的157个建议——建议48:Dispose方法应允许被多次调用
建议48:Dispose方法应允许被多次调用 一个类型的Dispose方法应该允许被多次调用而不抛出异常.鉴于此,类型内部维护了一个私有的bool变量disposed,如下: private bool ...
- 应用Bundle捆绑压缩技术
从MVC4开始,我们就发现,项目中对Global.asax进行了优化,将原来在MVC3中使用的代码移到了[App_Start]文件夹下,而Global.asax只负责初始化.其中的BundleConf ...
- 牌型总数——第六届蓝桥杯C语言B组(省赛)第七题
原创 牌型种数 小明被劫持到X赌城,被迫与其他3人玩牌.一副扑克牌(去掉大小王牌,共52张),均匀发给4个人,每个人13张.这时,小明脑子里突然冒出一个问题:如果不考虑花色,只考虑点数,也不考虑自己得 ...
- Android sutdio单元测试 简单使用步骤
1.简介 单元测试(unit testing),是指对软件中的最小可测试单元进行检查和验证.比如一个函数,一个方法等 2.添加依赖 dependencies { testCompile 'junit: ...
- c# 解析MP3文件
不说那么多,网上有很多关于MP3文件说明的. 该C#代码是将C\C++转化过来的,可能存在问题. 如有需要的朋友可以参考. 项目中的文件路径大家自己修改. 下载地址
- C#中return的两个作用
using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Threa ...