-->
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.  [ 6 posts ] 
Author Message
 Post subject: Exception while generating code
PostPosted: Wed Jan 31, 2007 4:28 am 
Newbie

Joined: Thu Jan 18, 2007 7:45 am
Posts: 3
Location: hyderabad
I'm using hibernateTools for the first time, I followed steps in hibernate Tools.pdf file to generate code. while running the tool the following error occured.I have placed mysql_jdbc.jar in the classpath using Add external file option in the tool.
Error occured:
org.hibernate.console.HibernateConsoleRuntimeException: Problems while loading database driverclass (com.mysql.jdbc.Driver)
java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
java.lang.ClassNotFoundException: com.mysql.jdbc.Driver


could any one please tell me what has to be done to resolve this problem.

Hibernate version:Hibernate3, HibernateTools 3.2.0.beta 9
eclipse3.1

Name and version of the database you are using:MySQL 5.0
Driver: com.mysql.jdbc.Driver

_________________
Deepika


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jan 31, 2007 5:26 am 
Newbie

Joined: Sat Mar 05, 2005 2:36 pm
Posts: 19
If it's in the classpath, it should work correctly. I am not quite sure where you have set the Add external file option.

You have an alternative: In the new version of the tools (3.2.0 beta 9 - the one you are using), you can set the option to include the project's default classpath.

In the Hibernate Configurations view change to the Classpath tab and click the checkbox at the bottom: Include default classpath from project. If you have configured the MySQL drivers correctly in Eclipse, it should work.

Hope this could help you,
Kariem


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jan 31, 2007 6:25 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
yup - just as kariem said it.

just wanted to say that in b9 it is the default behavior (for new created console configurations) to use the projects classpath...but you have to selct a project for it to actually pickup the classpath.

_________________
Max
Don't forget to rate


Top
 Profile  
 
 Post subject:
PostPosted: Mon Feb 05, 2007 12:19 am 
Newbie

Joined: Thu Jan 18, 2007 7:45 am
Posts: 3
Location: hyderabad
Thank you Kariem and Max . NO exception raised after installing Eclipse3.2 IDE.

_________________
Deepika


Top
 Profile  
 
 Post subject:
PostPosted: Mon Feb 05, 2007 12:44 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
you mean hibernate tools 3.2 or eclipse 3.2 :) ?

_________________
Max
Don't forget to rate


Top
 Profile  
 
 Post subject:
PostPosted: Mon Feb 19, 2007 3:36 am 
Newbie

Joined: Thu Jan 18, 2007 7:45 am
Posts: 3
Location: hyderabad
Its Eclipse3.2. Previously I was using Eclipse 3.1 ......
When I was using Eclipse 3.1 there were many exceptions fired
But now after installing Eclipse 3.2, no exception fired.

_________________
Deepika


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

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.