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]Enabling negative test for scroll sensitive updatable resultset in Network Server mode
Date Wed, 23 Mar 2005 19:41:05 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>
Satheesh<br>
<br>
Sending&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
java\testing\org\apache\derbyTesting\functionTests\master\DerbyNet\updatableResultSet.out<br>
Sending&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
java\testing\org\apache\derbyTesting\functionTests\master\DerbyNetClient\updatableResultSet.out<br>
Sending&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
java\testing\org\apache\derbyTesting\functionTests\master\jdk14\updatableResultSet.out<br>
Sending&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
java\testing\org\apache\derbyTesting\functionTests\master\updatableResultSet.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 158821.<br>
<br>
Mamta Satoor wrote:<br>
<blockquote cite="midd9619e4a050323080749ba2383@mail.gmail.com"
 type="cite">
  <pre wrap="">Hi,

Derby does not support scroll sensitive updatable resultsets. There is
already a test for this in embedded mode. Enabling the same test for
Network Server. The new Derby Net Client driver will correctly
downgrade the resultset type to scroll insensitive read only
resultset. JCC driver does not do that and there is already a JIRA
entry 154 for it.

svn stat
M      java\testing\org\apache\derbyTesting\functionTests\tests\lang\updatableRe
sultSet.java
M      java\testing\org\apache\derbyTesting\functionTests\master\DerbyNet\updata
bleResultSet.out
M      java\testing\org\apache\derbyTesting\functionTests\master\DerbyNetClient\
updatableResultSet.out
M      java\testing\org\apache\derbyTesting\functionTests\master\updatableResult
Set.out
M      java\testing\org\apache\derbyTesting\functionTests\master\jdk14\updatable
ResultSet.out

thanks,
Mamta
  </pre>
  <pre wrap="">
<hr size="4" width="90%">
Index: java/testing/org/apache/derbyTesting/functionTests/tests/lang/updatableResultSet.java
===================================================================
--- java/testing/org/apache/derbyTesting/functionTests/tests/lang/updatableResultSet.java
(revision 158774)
+++ java/testing/org/apache/derbyTesting/functionTests/tests/lang/updatableResultSet.java
(working copy)
@@ -247,7 +247,6 @@
 			//have to close the resultset because by default, resultsets are held open over commit
 			rs.close();
 
-			if (TestUtil.isEmbeddedFramework()) {
 			System.out.println("Negative Test2 - request for scroll sensitive updatable resultset
will give a read only scroll insensitive resultset");
 			stmt = conn.createStatement(ResultSet.TYPE_SCROLL_SENSITIVE, ResultSet.CONCUR_UPDATABLE);
 			while (warnings != null)
@@ -257,6 +256,7 @@
 			}
 			conn.clearWarnings();
       System.out.println("requested TYPE_SCROLL_SENSITIVE, CONCUR_UPDATABLE but that is not
supported");
+			System.out.println("Jira issue Derby-154 : When client connects to Network Server using
JCC, it incorrectly shows support for scroll sensitive updatable resultsets"); 
       System.out.println("Make sure that we got TYPE_SCROLL_INSENSITIVE? " +  (stmt.getResultSetType()
== ResultSet.TYPE_SCROLL_INSENSITIVE));
       System.out.println("Make sure that we got CONCUR_READ_ONLY? " +  (stmt.getResultSetConcurrency()
== ResultSet.CONCUR_READ_ONLY));
 			System.out.println("JDBC 2.0 updatable resultset api will fail on this resultset because
this is not an updatable resultset");
@@ -281,7 +281,6 @@
 			rs.next();
 			//have to close the resultset because by default, resultsets are held open over commit
 			rs.close();
-			}
 
 			System.out.println("Negative Test3 - request a read only resultset and attempt deleteRow
and updateRow on it");
 			stmt = conn.createStatement();//the default is a read only forward only resultset
Index: java/testing/org/apache/derbyTesting/functionTests/master/DerbyNet/updatableResultSet.out
===================================================================
--- java/testing/org/apache/derbyTesting/functionTests/master/DerbyNet/updatableResultSet.out
(revision 158774)
+++ java/testing/org/apache/derbyTesting/functionTests/master/DerbyNet/updatableResultSet.out
(working copy)
@@ -12,6 +12,16 @@
 Got expected exception This method cannot be invoked while the cursor is on the insert row
or if the concurrency of this ResultSet object is CONCUR_READ_ONLY.
 SQL State : null
 Got expected exception This method cannot be invoked while the cursor is on the insert row
or if the concurrency of this ResultSet object is CONCUR_READ_ONLY.
+Negative Test2 - request for scroll sensitive updatable resultset will give a read only scroll
insensitive resultset
+requested TYPE_SCROLL_SENSITIVE, CONCUR_UPDATABLE but that is not supported
+Jira issue Derby-154 : When client connects to Network Server using JCC, it incorrectly shows
support for scroll sensitive updatable resultsets
+Make sure that we got TYPE_SCROLL_INSENSITIVE? false
+Make sure that we got CONCUR_READ_ONLY? false
+JDBC 2.0 updatable resultset api will fail on this resultset because this is not an updatable
resultset
+SQL State : null
+Got expected exception This method cannot be invoked while the cursor is on the insert row
or if the concurrency of this ResultSet object is CONCUR_READ_ONLY.
+SQL State : null
+Got expected exception This method cannot be invoked while the cursor is on the insert row
or if the concurrency of this ResultSet object is CONCUR_READ_ONLY.
 Negative Test3 - request a read only resultset and attempt deleteRow and updateRow on it
 Make sure that we got CONCUR_READ_ONLY? true
 Now attempting to send a deleteRow on a read only resultset.
Index: java/testing/org/apache/derbyTesting/functionTests/master/DerbyNetClient/updatableResultSet.out
===================================================================
--- java/testing/org/apache/derbyTesting/functionTests/master/DerbyNetClient/updatableResultSet.out
(revision 158774)
+++ java/testing/org/apache/derbyTesting/functionTests/master/DerbyNetClient/updatableResultSet.out
(working copy)
@@ -12,6 +12,16 @@
 Got expected exception This method cannot be invoked while the cursor is on the insert row
or if the concurrency of this ResultSet object is CONCUR_READ_ONLY.
 SQL State : null
 Got expected exception This method cannot be invoked while the cursor is on the insert row
or if the concurrency of this ResultSet object is CONCUR_READ_ONLY.
+Negative Test2 - request for scroll sensitive updatable resultset will give a read only scroll
insensitive resultset
+requested TYPE_SCROLL_SENSITIVE, CONCUR_UPDATABLE but that is not supported
+Jira issue Derby-154 : When client connects to Network Server using JCC, it incorrectly shows
support for scroll sensitive updatable resultsets
+Make sure that we got TYPE_SCROLL_INSENSITIVE? true
+Make sure that we got CONCUR_READ_ONLY? true
+JDBC 2.0 updatable resultset api will fail on this resultset because this is not an updatable
resultset
+SQL State : null
+Got expected exception This method cannot be invoked while the cursor is on the insert row
or if the concurrency of this ResultSet object is CONCUR_READ_ONLY.
+SQL State : null
+Got expected exception This method cannot be invoked while the cursor is on the insert row
or if the concurrency of this ResultSet object is CONCUR_READ_ONLY.
 Negative Test3 - request a read only resultset and attempt deleteRow and updateRow on it
 Make sure that we got CONCUR_READ_ONLY? true
 Now attempting to send a deleteRow on a read only resultset.
Index: java/testing/org/apache/derbyTesting/functionTests/master/updatableResultSet.out
===================================================================
--- java/testing/org/apache/derbyTesting/functionTests/master/updatableResultSet.out	(revision
158774)
+++ java/testing/org/apache/derbyTesting/functionTests/master/updatableResultSet.out	(working
copy)
@@ -14,6 +14,7 @@
 Got expected exception 'updateRow' not allowed because the ResultSet is not an updatable
ResultSet. 
 Negative Test2 - request for scroll sensitive updatable resultset will give a read only scroll
insensitive resultset
 requested TYPE_SCROLL_SENSITIVE, CONCUR_UPDATABLE but that is not supported
+Jira issue Derby-154 : When client connects to Network Server using JCC, it incorrectly shows
support for scroll sensitive updatable resultsets
 Make sure that we got TYPE_SCROLL_INSENSITIVE? true
 Make sure that we got CONCUR_READ_ONLY? true
 JDBC 2.0 updatable resultset api will fail on this resultset because this is not an updatable
resultset
Index: java/testing/org/apache/derbyTesting/functionTests/master/jdk14/updatableResultSet.out
===================================================================
--- java/testing/org/apache/derbyTesting/functionTests/master/jdk14/updatableResultSet.out
(revision 158774)
+++ java/testing/org/apache/derbyTesting/functionTests/master/jdk14/updatableResultSet.out
(working copy)
@@ -14,6 +14,7 @@
 Got expected exception 'updateRow' not allowed because the ResultSet is not an updatable
ResultSet. 
 Negative Test2 - request for scroll sensitive updatable resultset will give a read only scroll
insensitive resultset
 requested TYPE_SCROLL_SENSITIVE, CONCUR_UPDATABLE but that is not supported
+Jira issue Derby-154 : When client connects to Network Server using JCC, it incorrectly shows
support for scroll sensitive updatable resultsets
 Make sure that we got TYPE_SCROLL_INSENSITIVE? true
 Make sure that we got CONCUR_READ_ONLY? true
 JDBC 2.0 updatable resultset api will fail on this resultset because this is not an updatable
resultset
  </pre>
</blockquote>
</body>
</html>


Mime
View raw message