db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Satheesh Bandaram <sathe...@Sourcery.Org>
Subject Re: [PATCH] (DERBY-66) Derby does not support open cursor across commits for XA transactions and hence DatabaseMetaData.supportsOpenCursorsAcrossCommit should return false.
Date Tue, 08 Feb 2005 17:16:15 GMT
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
  <title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
Submitted this patch.<br>
<br>
Thanks,<br>
Satheesh<br>
<br>
Sending&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
java\engine\org\apache\derby\impl\jdbc\EmbedDatabaseMetaData.java<br>
Sending&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
java\testing\org\apache\derbyTesting\functionTests\master\DerbyNet\metadata.out<br>
Sending&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
java\testing\org\apache\derbyTesting\functionTests\master\metadata.out<br>
Sending&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
java\testing\org\apache\derbyTesting\functionTests\tests\lang\updatableResultSet.java<br>
Transmitting file data ....<br>
Committed revision 152678.<br>
<br>
Mamta Satoor wrote:
<blockquote cite="mid4207E38E.8D93C835@Remulak.Net" type="cite">
  <pre wrap="">Hi,

Can a commiter please commit the attached patch for Derby-66? The patch will have
DatabaseMetaData.supportsOpenCursorsAcrossCommit return false because Derby
does not support open cursors across commit for XA transactions. I have put a
comment in the code so we know why this method should return false.

thanks,
Mamta
  </pre>
  <pre wrap="">
<hr size="4" width="90%">
Index: java/engine/org/apache/derby/impl/jdbc/EmbedDatabaseMetaData.java
===================================================================
--- java/engine/org/apache/derby/impl/jdbc/EmbedDatabaseMetaData.java	(revision 151760)
+++ java/engine/org/apache/derby/impl/jdbc/EmbedDatabaseMetaData.java	(working copy)
@@ -1045,9 +1045,9 @@
      *
      * @return true if cursors always remain open; false if they might not remain open
      */
-	//returns true because Derby can have cursors that are open across commits.
+	//returns false because Derby does not support cursors that are open across commits for
XA transactions.
 	public boolean supportsOpenCursorsAcrossCommit() {
-		return true;
+		return false;
 	}
 
     /**
Index: java/testing/org/apache/derbyTesting/functionTests/tests/lang/updatableResultSet.java
===================================================================
--- java/testing/org/apache/derbyTesting/functionTests/tests/lang/updatableResultSet.java
(revision 151760)
+++ java/testing/org/apache/derbyTesting/functionTests/tests/lang/updatableResultSet.java
(working copy)
@@ -451,7 +451,6 @@
       System.out.println("got TYPE_FORWARD_ONLY? " +  (callStmt.getResultSetType() == ResultSet.TYPE_FORWARD_ONLY));
       System.out.println("got CONCUR_UPDATABLE? " +  (callStmt.getResultSetConcurrency()
== ResultSet.CONCUR_UPDATABLE));
 			rs.next();
-      System.out.println("row not deleted yet. Confirm with rs.rowDeleted()? " + rs.rowDeleted());
       System.out.println("column 1 on this row is " + rs.getInt(1));
 			rs.deleteRow();
       System.out.println("Since after deleteRow(), ResultSet is positioned before the next
row, getXXX will fail");
Index: java/testing/org/apache/derbyTesting/functionTests/master/DerbyNet/metadata.out
===================================================================
--- java/testing/org/apache/derbyTesting/functionTests/master/DerbyNet/metadata.out	(revision
151760)
+++ java/testing/org/apache/derbyTesting/functionTests/master/DerbyNet/metadata.out	(working
copy)
@@ -119,7 +119,7 @@
 supportsCorrelatedSubqueries(): true
 supportsUnion(): true
 supportsUnionAll(): true
-supportsOpenCursorsAcrossCommit(): true
+supportsOpenCursorsAcrossCommit(): false
 supportsOpenCursorsAcrossRollback(): false
 supportsOpenStatementsAcrossCommit(): true
 supportsOpenStatementsAcrossRollback(): false
Index: java/testing/org/apache/derbyTesting/functionTests/master/metadata.out
===================================================================
--- java/testing/org/apache/derbyTesting/functionTests/master/metadata.out	(revision 151760)
+++ java/testing/org/apache/derbyTesting/functionTests/master/metadata.out	(working copy)
@@ -119,7 +119,7 @@
 supportsCorrelatedSubqueries(): true
 supportsUnion(): true
 supportsUnionAll(): true
-supportsOpenCursorsAcrossCommit(): true
+supportsOpenCursorsAcrossCommit(): false
 supportsOpenCursorsAcrossRollback(): false
 supportsOpenStatementsAcrossCommit(): true
 supportsOpenStatementsAcrossRollback(): false
  </pre>
</blockquote>
</body>
</html>

Mime
View raw message