wood burning stoves 2.0*
The moose likes JDBC and the fly likes does the Oracle JDBC driver auto-commit? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "does the Oracle JDBC driver auto-commit?" Watch "does the Oracle JDBC driver auto-commit?" New topic
Author

does the Oracle JDBC driver auto-commit?

Stephen Huey
Ranch Hand

Joined: Jul 15, 2003
Posts: 618
We've just moved to Oracle, and I've noticed that if I log into the same db user with the command-line SQL*Plus to execute updates on the database, one user won't see what another user has done until you explicitly type commit. However, when our web application interacts with the database, the users on the console can see the changes immediately. Do you think the Oracle JDBC thin client auto-commits whatever our web app does?
David Harkness
Ranch Hand

Joined: Aug 07, 2003
Posts: 1646
Yes, I've found that Oracle's thin driver does auto-commit by default. You can change this by usingSome connection pools like Apache's DBCP allow you to set this at the pool level.
Al Tam
Greenhorn

Joined: Nov 27, 2004
Posts: 5
If you are accessing the DB through a EJB container, such as JBoss or Weblogic, the container will automatically turn-off the auto-commit functionality of the driver.
Stephen Huey
Ranch Hand

Joined: Jul 15, 2003
Posts: 618
Ok...no EJB container here...
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: does the Oracle JDBC driver auto-commit?
 
Similar Threads
Oracle Connection in WSAD 5.0
commit - asynchronous or synchronous? (DB2)
storing date in mysql
commit problem - always happens even if set to false!!
A servlet code written to add details in database but not happening?