hibernate
gwh_08
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
No row with the given identifier exists
产生此问题的原因: 有两张表,table1和table2.产生此问题的原因就是table1里做了关联<one-to-one>或者<many-to-one unique="true">(特殊的多对一映射,实际就是一对一)来关联table2.当hibernate查找的时候,table2里的数据没有与table1相匹配的,这样就会报No row ...原创 2010-09-20 17:00:32 · 152 阅读 · 0 评论 -
No row with the given identifier exists
常见的联合查询错误 ,转载一下 作者:blurxx 日期:2008-01-17 产生此问题的原因: 有两张表,table1和table2.产生此问题的原因就是table1里做了关联<one-to-one>或者<many-to- one unique="true">(特殊的多对一映射,实际就是一对一)来关联table2.当hibern...原创 2010-11-03 15:31:53 · 147 阅读 · 0 评论 -
IndexOutOfBoundsException: Index: 0, Size: 0
越界出错,往往出现在sql查询返回值为一个list,在取值的时候没有判断list.size()是否为0,或list是否为null,而直接进行list.get(i).getId()操作导致出错。原创 2010-11-03 15:36:43 · 289 阅读 · 0 评论 -
Batch update returned unexpected row count from update [0]
Batch update returned unexpected row count from update [0]; actual row count: 0; expected: 1; nested exception is org.hibernate.StaleStateException: 一般为save方法与saveUpdate方法合为一起实现造成的, 以user对象为例: 当要s...原创 2010-11-03 15:44:50 · 218 阅读 · 0 评论
分享