• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Error:java.lang.NoClassDefFoundError: javax/persistence/EntityList

 
Vikram Kohli
Ranch Hand
Posts: 174
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I have just started learning Hibernate. And following tutorial @ http://www.vaannila.com/hibernate/hibernate-example/hibernate-tools-1.html. And have included following jars as user libraries in project:-
antlr-2.7.6.jar,commons-collections-3.1.jar,dom4j-1.6.1.jar,hibernate3.jar,javassist-3.12.0.GA.jar,jta-1.1.jar,log4j-1.2.8.jar,mysql-connector-java-5.1.13-bin.jar,slf4j-api-1.6.1.jar,slf4j-simple-1.6.1.jar.

But when I am running the Main program I am getting following error in console:-



Request you all to please help in solving the above error.
 
Cameron Wallace McKenzie
author and cow tipper
Saloon Keeper
Posts: 4968
1
Hibernate Spring Tomcat Server
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do you have the JPA jar file in there? Which version of Hibernate are you using? Here are my jar files for 3.5:



Getting Started with Hibernate: Jar Files and Such

 
Vikram Kohli
Ranch Hand
Posts: 174
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Cameron . It worked

Thanks Alot again
Vikram
 
Alan Hampson
Ranch Hand
Posts: 31
  • Likes 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This seems to be caused by Hibernate 3.6. It is now dependent on JPA, so it must have a JPA jar in the class path as well. You can find one in the Hibernate 3.6 distro: hibernate-distribution-3.6.0.Final/lib/jpa/hibernate-jpa-2.0-api-1.0.0.Final.jar

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic