Forum Stats

  • 3,817,362 Users
  • 2,259,322 Discussions
  • 7,893,760 Comments

Discussions

set autocommit= off in JDBC driver

Kim Gabrielsen
Kim Gabrielsen Member Posts: 29
edited Jun 29, 2013 3:36PM in JDeveloper and ADF

Hi,

i'm running jdev v. 11.1.2.4 and deploying a simple ADF application on glassfish against a mySQL database v 5.1.....

when i commit my changes to the database i receive an exception:

at com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513)

    at java.lang.Thread.run(Thread.java:722)

Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: Can't call rollback when autocommit=true

    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)

    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)

    at java.lang.reflect.Constructor.newInstance(Constructor.java:525)

    at com.mysql.jdbc.Util.handleNewInstance(Util.java:411)

    a|#]

it's pretty obvious what is causing it but how do i set autocommit off in JDev?

I've looked into bc4j.cfg but don't see any indications here. is it related to the JDBC pool on glassfish? and as such not a JDev/ADF problem?

/

Kim

Tagged:

Answers

This discussion has been closed.