You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xalan.apache.org by sb...@locus.apache.org on 2000/11/15 18:13:11 UTC
cvs commit: xml-xalan/java/src/org/apache/xalan/lib/sql XConnection.java
sboag 00/11/15 09:13:10
Modified: java/src/org/apache/xalan/lib/sql XConnection.java
Log:
Wrap setAutoCommit with try, and catch SQLException if thrown.
Revision Changes Path
1.4 +8 -1 xml-xalan/java/src/org/apache/xalan/lib/sql/XConnection.java
Index: XConnection.java
===================================================================
RCS file: /home/cvs/xml-xalan/java/src/org/apache/xalan/lib/sql/XConnection.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- XConnection.java 2000/10/30 18:56:33 1.3
+++ XConnection.java 2000/11/15 17:13:10 1.4
@@ -242,7 +242,14 @@
We could also turn autocommit off by putting
;autocommit=false on the URL.
*/
- m_connection.setAutoCommit(false);
+ try
+ {
+ m_connection.setAutoCommit(false);
+ }
+ catch(java.sql.SQLException se)
+ {
+ // Some drivers do not support transactions
+ }
DatabaseMetaData dma = m_connection.getMetaData();