Results 1 to 2 of 2

Thread: Hibernate Exception

  1. #1
    Join Date
    Mar 2009
    Location
    Canberra
    Posts
    6

    Default Hibernate Exception

    Hi
    I am new to Spring and Hibernate, I am trying to learn this technologies.
    I got <tx:annotation-driven/>
    in my hibernate context xml file. When I try to add a new record using this line of code
    sessionFactory.getCurrentSession().merge(user);
    I am getting this exception
    org.hibernate.HibernateException: No Hibernate Session bound to thread, and configuration does not allow creation of non-transactional one here
    org.springframework.orm.hibernate3.SpringSessionCo ntext.currentSession(SpringSessionContext.java:63) .

    I have copied these configuration and code from Petclinic example.
    Please help
    Philip
    Last edited by philipj; Apr 13th, 2009 at 04:30 PM.

  2. #2
    Join Date
    Mar 2009
    Location
    Canberra
    Posts
    6

    Default

    No worries guys, I found the answer too.
    Philip

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •