wood burning stoves 2.0*
The moose likes Object Relational Mapping and the fly likes Hibernate with annotations problems Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "Hibernate with annotations problems" Watch "Hibernate with annotations problems" New topic
Author

Hibernate with annotations problems

Gunnar Maluf
Ranch Hand

Joined: Dec 29, 2007
Posts: 39
Hello all,

I am trying to configure a hibernate java project using annotations and I am getting the following error:
org.postgresql.jdbc2.Jdbc2DatabaseMetaData.supportsGetGeneratedKeys()Z

I have the following jars in my project:
C:\Program Files\Java\jre1.6.0_07\lib\resources.jar
C:\Program Files\Java\jre1.6.0_07\lib\rt.jar
C:\Program Files\Java\jre1.6.0_07\lib\jsse.jar
C:\Program Files\Java\jre1.6.0_07\lib\jce.jar
C:\Program Files\Java\jre1.6.0_07\lib\charsets.jar
C:\Program Files\Java\jre1.6.0_07\lib\ext\dnsns.jar
C:\Program Files\Java\jre1.6.0_07\lib\ext\localedata.jar
C:\Program Files\Java\jre1.6.0_07\lib\ext\postgresql-8.3-603.jdbc2.jar
C:\Program Files\Java\jre1.6.0_07\lib\ext\sunjce_provider.jar
C:\Program Files\Java\jre1.6.0_07\lib\ext\sunmscapi.jar
C:\Program Files\Java\jre1.6.0_07\lib\ext\sunpkcs11.jar
C:\Users\Gunnar\Documents\Text\Java\Hibernate\hibernate-distribution-3.3.2.GA\lib\required\antlr-2.7.6.jar
C:\Users\Gunnar\Documents\Text\Java\Hibernate\hibernate-distribution-3.3.2.GA\lib\required\commons-collections-3.1.jar
C:\Users\Gunnar\Documents\Text\Java\Hibernate\hibernate-distribution-3.3.2.GA\lib\required\dom4j-1.6.1.jar
C:\Users\Gunnar\Documents\Text\Java\Hibernate\hibernate-distribution-3.3.2.GA\lib\required\javassist-3.9.0.GA.jar
C:\Users\Gunnar\Documents\Text\Java\Hibernate\hibernate-distribution-3.3.2.GA\lib\required\jta-1.1.jar
C:\Users\Gunnar\Documents\Text\Java\Hibernate\hibernate-distribution-3.3.2.GA\lib\required\slf4j-api-1.5.8.jar
C:\Users\Gunnar\Documents\Text\Java\Hibernate\hibernate-distribution-3.3.2.GA\hibernate3.jar
C:\Users\Gunnar\Documents\Text\Java\Hibernate\hibernate-annotations-3.4.0.GA\hibernate-annotations.jar
C:\Users\Gunnar\Documents\Text\Java\Hibernate\hibernate-annotations-3.4.0.GA\lib\ejb3-persistence.jar
C:\Users\Gunnar\Documents\Text\Java\Hibernate\hibernate-annotations-3.4.0.GA\lib\hibernate-commons-annotations.jar
C:\Users\Gunnar\Documents\Text\Java\Hibernate\slf4j-1.5.8\slf4j-nop-1.5.8.jar

and the following classes:










Any help is appreciatted.

best regards
Gunnar


Sun Certified Associate for Java Platform
Sun Certified Java Programmer 5.0
Sun Certified Web Component Developer 5.0
Mark Spritzler
ranger
Sheriff

Joined: Feb 05, 2001
Posts: 17249
    
    6

Where are you getting this error, and what exactly is the error?

org.postgresql.jdbc2.Jdbc2DatabaseMetaData.supportsGetGeneratedKeys()Z

That isn't an exception. Is there a stack trace? In the table in the database how is the primary key getting set. With just @Id, it is your apps responsibility to set the id. Are you using a Sequence table?

Thanks

Mark


Perfect World Programming, LLC - Two Laptop Bag - Tube Organizer
How to Ask Questions the Smart Way FAQ
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Hibernate with annotations problems
 
Similar Threads
Hibernate 3.3.1 setup help!
jdk5 and ejb3 options unavailable in HibernateTools-3.2.4.GA
Problem configuring Hibernate and JPA in Eclipse
ClassNotFoundException after setting env variable
Hibernate annotations gives me a NoSuchMethodError exception