-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: Problem with beginTransaction and DAO generator
PostPosted: Wed Jun 13, 2007 3:21 am 
Newbie

Joined: Tue Jun 12, 2007 11:07 am
Posts: 9
Hi,
I have this problem:

I have generated my DAO class (from a "ArcUtente" table) with Hibernate Tool 3.2 beta 9 and Eclipse 3.2

I have created: a simple test.jsp:

ArcUtente vo=new ArcUtente();
vo.setUser("test");
vo.setPassword("test");
List list=(new ArcUtenteHome()).findByExample(vo);

ArcUtente.java is my bean (generated from Hibernate Tools)
ArcUtenteHome.java is my DAO (generated from Hibernate Tools)

When I try my jsp, I take thid exception:
"org.hibernate.HibernateException: createCriteria is not valid without active transaction"

I believed that the DAO was independent
Can you help me?

Thanks,
Carlo


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.