异常org.hibernate.PropertyAccessException: IllegalArgumentException occurred calling getter of com.mi.domain.Department.id

【异常提示】 org.hibernate.PropertyAccessException: IllegalArgumentException occurred calling getter of com.mi.domain.Department.id

       java.lang.IllegalArgumentException: object is not an instance of declaring class

解决办法:Hql 中的级联关系不能传入外键,而是要传入级联对象,学习还是要认真仔细啊

原文地址:https://www.cnblogs.com/Sly-Mi/p/11179311.html

时间: 2024-10-20 07:52:50

异常org.hibernate.PropertyAccessException: IllegalArgumentException occurred calling getter of com.mi.domain.Department.id的相关文章

org.hibernate.PropertyAccessException: IllegalArgumentException occurred while

导致异常结果: org.hibernate.PropertyAccessException: IllegalArgumentException occurred while calling setter of com.zxr.shoucang.domain.MySite.isShare .... Caused by: java.lang.IllegalArgumentException: argument(论点) type mismatch(翻译:类型不匹配(错配)) 这个异常java.lang

org.hibernate.PropertyAccessException:Null value was assigned to a property of primitive type setter

在项目开发中遇到下面的异常:org.hibernate.PropertyAccessException:Null value was assigned to a property of primitive type setter ofcom.atguigu.surveypark.model.Page.orderno 这个异常的解释是:      Null值被分配给了设置为基本类型的Page类里的orderno属性.也就是说Null是不能分配给基本数据类型的.解决办法:手动给数据库中是Null值的

[hibernate]org.hibernate.PropertyAccessException: Null value was assigned to a property of primitive type setter

org.hibernate.PropertyAccessException: Null value was assigned to a property of primitive type setter of com.wa.dataprocess.query.model.AcrossDeptApply 包装类和基本数据类型的区别, 包装类默认为null,基本类型为0. public class AcrossDeptApply implements Serializable private Str

hibernate.PropertyAccessException: Null value was assigned to a property of primitive type

日志: [WARN-2016/07/26/18/:45/:52]ProcessEngineServiceImpl.(257) - 审批流程log日志--submitProcess方法:提交人userId:3333333349,TaskId:245959,ProcInstId:null,WfInstaceId:16583386853,当前时间:Tue Jul 26 18:45:52 CST 2016 [ERROR-2016/07/26/18/:45/:52]ProjectRepayControll

org.hibernate.PropertyAccessException: Null value was assigned to a property of primitive type sette

org.hibernate.PropertyAccessException: Null value was assigned to a property <property column="sex"  name="sex"  type="java.lang.Boolean"/> JavaBean修改:private Boolean sex; 原因:数据库字段值为NULL,int 类型不能赋值为NULL,只能为0,但有些实际应用中,如学

【异常】java.lang.IllegalArgumentException: Cannot locate declared field class org.apache.http.impl.client.HttpClientBuilder.dnsResolver 的解决方案

起因:使用htmlunit爬取外部网页的时候遇到这个异常:java.lang.IllegalArgumentException: Cannot locate declared field class org.apache.http.impl.client.HttpClientBuilder.dnsResolver <dependency> <groupId>net.sourceforge.htmlunit</groupId> <artifactId>html

启动Tomcat出现异常解决方案 java.lang.IllegalArgumentException: Document

启动Tomcat出现异常解决方案 java.lang.IllegalArgumentException: Document base D:\Software_Install\Program Files (x86)\apache-tomcat-6.0.39\webapps\host-manager does not exist or is not a readable directory 启动服务器,出现一下情况,是因为删除了tomcat中的项目,但是残留配置文件没有删除,解决方法:到服务器中(我

org.hibernate.PropertyAccessException: Null value was assigned to a property of primitive type setter of 异常

在开发项目的过程中,发现如下异常: 原因是updateType字段为int类型,不能接收null,而在数据库中对应的字段为null,解决方法:将updateType字段类型改为Integer.

懒加载异常org.hibernate.LazyInitializationException: could not initialize proxy - no Session

错误页面提示 could not initialize proxy - no Session 控制台 org.hibernate.LazyInitializationException: could not initialize proxy - no Session 病症:这是一个lazy使用后的Exception,使用迟时加载,在session(hibernate里的session),关闭后使用该对象的未加载变量,也就是说session已经关闭,没有保存到内存中,然后你使用了,导致该异常. Q