Summary of Bug

2 篇文章 0 订阅
2 篇文章 0 订阅
  • 描述:
org.hibernate.LazyInitializationException: failed to lazily initialize a collection of role: ocr.entity.User.messageRecord, could not initialize proxy - no Session
    at ...
  • 分析:
    在双向一对多映射中,从一方获得多方的信息时,如果未建立级联关系,需要 session 的存在。
  • 解决方法
    建立级联关系/在查询全部完成后再关闭 session。

  • 描述:
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'GROUP (
       ID integer not null,
  • 分析
    使用了数据库中的关键字 GROUP
  • 解决方法
    换个名字。。

另:其他的关键字
http://www.cnblogs.com/lawdong/archive/2010/08/08/2357903.html


  • 描述:
Batch update returned unexpected row count from update [0]; actual row count: 0; expected: 1
  • 分析
    主键值设置为自增长,但在程序执行时为其赋值。
  • 解决方法
    改变主键生成策略,或者不给主键赋值。
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值