Hibernate4中使用getCurrentSession報Could not obtain transaction-synchronized Session for current thread
架個spring4+hibernate4的demo,dao層直接注入的sessionFactory,然后用getCurrentSession方法獲取session,然后問題來了,直接報錯: ...
架個spring4+hibernate4的demo,dao層直接注入的sessionFactory,然后用getCurrentSession方法獲取session,然后問題來了,直接報錯: ...