java吧 关注:1,261,806贴子:12,761,292
  • 11回复贴,共1

大神帮忙看看...代码如下...

只看楼主收藏回复

private SessionFactory se;
public SessionFactory getSe() {
return se;
}
@Autowired
public void setSe(SessionFactory se) {
this.se = se;
}
se.getCurrentSession()
为什么这个getCurrentSession()报错 提示The method getCurrentSession() is undefined for the type SessionFactory


IP属地:河北1楼2017-08-08 09:36回复
    hibernate 获取session? 你应该是少了一个配置 不然的话 用不了get的 只能open


    IP属地:广东2楼2017-08-08 09:40
    收起回复