-->
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.  [ 3 posts ] 
Author Message
 Post subject: AbstractMethodError whith "ant eg" with mysql driv
PostPosted: Tue Jun 08, 2004 4:03 am 
Newbie

Joined: Tue Jun 08, 2004 3:51 am
Posts: 8
hi,



I am trying to run the eg example with mysql driver 2.0.14 (my production driver) on mysql 3.23 with hibernate 2.1

Here is my hibernate.properties
## MySQL
hibernate.dialect net.sf.hibernate.dialect.MySQLDialect
hibernate.connection.driver_class org.gjt.mm.mysql.Driver
#hibernate.connection.driver_class com.mysql.jdbc.Driver
hibernate.connection.url jdbc:mysql://localhost:3314/DBpostcards?autoReconnect=true
hibernate.connection.username atchik
hibernate.connection.password atchik

Here is the "ant eg" ouput.
SchemaExport:160 - schema export complete
[java] 09:50:53,354 INFO DriverManagerConnectionProvider:143 - cleaning up connection pool: jdbc:mysql://localhost:3314/DBpostcards?autoReconnect=true
[java] 09:50:53,366 INFO UpdateTimestampsCache:35 - starting update timestamps cache at region: net.sf.hibernate.cache.UpdateTimestampsCache
[java] 09:50:53,471 WARN Plugin:95 - Could not find configuration for net.sf.hibernate.cache.UpdateTimestampsCache. Configuring using the defaultCache settings.
[java] 09:50:53,479 INFO QueryCache:39 - starting query cache at region: net.sf.hibernate.cache.QueryCache
[java] 09:50:53,480 WARN Plugin:95 - Could not find configuration for net.sf.hibernate.cache.QueryCache. Configuring using the defaultCache settings.
[java] Setting up some test data
[java] Exception in thread "main" java.lang.AbstractMethodError: com.mysql.jdbc.jdbc2.Connection.prepareStatement(Ljava/lang/String;I)Ljava/sql/PreparedStatement;
[java] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[java] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[java] at java.lang.reflect.Method.invoke(Method.java:324)
[java] at net.sf.hibernate.util.GetGeneratedKeysHelper.prepareStatement(GetGeneratedKeysHelper.java:39)
[java] at net.sf.hibernate.impl.BatcherImpl.getPreparedStatement(BatcherImpl.java:246)
[java] at net.sf.hibernate.impl.BatcherImpl.prepareStatement(BatcherImpl.java:61)
[java] at net.sf.hibernate.persister.EntityPersister.insert(EntityPersister.java:525)
[java] at net.sf.hibernate.persister.EntityPersister.insert(EntityPersister.java:432)
[java] at net.sf.hibernate.impl.ScheduledIdentityInsertion.execute(ScheduledIdentityInsertion.java:29)
[java] at net.sf.hibernate.impl.SessionImpl.doSave(SessionImpl.java:932)
[java] at net.sf.hibernate.impl.SessionImpl.doSave(SessionImpl.java:857)
[java] at net.sf.hibernate.impl.SessionImpl.saveWithGeneratedIdentifier(SessionImpl.java:775)
[java] at net.sf.hibernate.impl.SessionImpl.save(SessionImpl.java:738)
[java] at org.hibernate.auction.Main.createTestAuctions(Main.java:291)
[java] at org.hibernate.auction.Main.main(Main.java:365)


I try to run the "ant eg" with with mysql driver 3.0.14 everything is ok.

Have someone managed to use hibernate with mysql driver 2.0.14 ?

Thanks

Yom


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jun 08, 2004 10:35 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 12:50 pm
Posts: 5130
Location: Melbourne, Australia
Disable use of getGeneratedKeys(), or MUCH better, upgrade to a recent driver.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jun 09, 2004 5:03 am 
Newbie

Joined: Tue Jun 08, 2004 3:51 am
Posts: 8
How can I do that ?


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 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.