db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From krist...@apache.org
Subject svn commit: r760820 - in /db/derby/code/branches/10.5/java: engine/org/apache/derby/iapi/types/SQLClob.java testing/org/apache/derbyTesting/functionTests/tests/jdbcapi/BlobClob4BlobTest.java
Date Wed, 01 Apr 2009 09:04:33 GMT
Author: kristwaa
Date: Wed Apr  1 09:04:32 2009
New Revision: 760820

URL: http://svn.apache.org/viewvc?rev=760820&view=rev
Log:
DERBY-4122 (partial): ClassCastException in SQLClob when running in soft upgrade mode (10.4.2.0
-> 10.5.1.0).
Merged revisions 759153 and 759155 (patches 1a and 2a) from trunk.

Modified:
    db/derby/code/branches/10.5/java/engine/org/apache/derby/iapi/types/SQLClob.java
    db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/jdbcapi/BlobClob4BlobTest.java

Modified: db/derby/code/branches/10.5/java/engine/org/apache/derby/iapi/types/SQLClob.java
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/engine/org/apache/derby/iapi/types/SQLClob.java?rev=760820&r1=760819&r2=760820&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/engine/org/apache/derby/iapi/types/SQLClob.java (original)
+++ db/derby/code/branches/10.5/java/engine/org/apache/derby/iapi/types/SQLClob.java Wed Apr
 1 09:04:32 2009
@@ -334,8 +334,8 @@
                 HeaderInfo hdrInfo = investigateHeader(header, read);
                 if (read > hdrInfo.headerLength()) {
                     // We have read too much. Reset the stream.
-                    ((Resetable)stream).resetStream();
-                    read = 0;
+                    read = hdrInfo.headerLength();
+                    rewindStream(read);
                 }
                 csd = new CharacterStreamDescriptor.Builder().stream(stream).
                     bufferable(false).positionAware(false).

Modified: db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/jdbcapi/BlobClob4BlobTest.java
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/jdbcapi/BlobClob4BlobTest.java?rev=760820&r1=760819&r2=760820&view=diff
==============================================================================
--- db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/jdbcapi/BlobClob4BlobTest.java
(original)
+++ db/derby/code/branches/10.5/java/testing/org/apache/derbyTesting/functionTests/tests/jdbcapi/BlobClob4BlobTest.java
Wed Apr  1 09:04:32 2009
@@ -408,7 +408,7 @@
         ResultSet trigARS = trigASt.executeQuery(
                 "select a, length(a), b from testClobTriggerA order by b");
         ResultSet trigBRS = trigBSt.executeQuery(
-                "select a, length(a), b from testClobTriggerA order by b");
+                "select a, length(a), b from testClobTriggerB order by b");
 
         int count = 0;
         while (origRS.next()) {



Mime
View raw message