Hi all

In the archive there are several mails describing problems with autocommit when using 
MySQL (3.23.32) and the org.gjt.mm.mysql.Driver (2.0.4)

The Cabin example from Monson-Haefel's book, which uses CMP, fails as autocommit is 
not turned off:

[snip from application.log]
19-03-01 15:56 Error in bean Cabin
java.sql.SQLException: Can't call commit when autocommit=true
        at org.gjt.mm.mysql.Connection.commit(Connection.java:520)
        at com.evermind.sql.an.commit(JAX)
        at com.evermind.sql.aj.commit(JAX)
        at com.evermind.server.ejb.DataSourceConnection.commit(JAX)
        at CabinHome_EntityHomeWrapper2.create(CabinHome_EntityHomeWrapper2.java:429)
        at java.lang.reflect.Method.invoke(Native Method)
        at com.evermind.server.rmi.bd.run(JAX)
        at com.evermind.server.rmi.bb.hy(JAX)
        at com.evermind.server.rmi.bb.run(JAX)
        at com.evermind.util.f.run(JAX)
[end snip]

I've tried to use the property:

jdbc.nontx.autocommit=false 

in the orion.properties file, but this does not turn off autocommit. I've also tried 
turning autocommit off in the MySQL DB (SET AUTOCOMMIT=0) itself, but with no effect.

Has any one found out how to turn off autocommit?

Regards
Henrik

-----Original Message-----
From: Tim Endres [mailto:[EMAIL PROTECTED]]
Sent: 30. januar 2001 22:16
To: Orion-Interest
Subject: Re: orion and mysql?


>          I found it very easy...I use:
> http://mmmysql.sourceforge.net/ - jdbc driver
> http://javaexchange.com/ - connection pooling....
> 
> One variable i had was w/javaexchange's DBBroker, set AutoReconnect=true...
> 
> so far so good...been using awhile

Which mysql are you using? Not all versions support transactions.
tim.


Reply via email to