openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mprud...@apache.org
Subject svn commit: r497683 - /incubator/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/OracleDictionary.java
Date Fri, 19 Jan 2007 02:09:54 GMT
Author: mprudhom
Date: Thu Jan 18 18:09:53 2007
New Revision: 497683

URL: http://svn.apache.org/viewvc?view=rev&rev=497683
Log:
Work around Oracle's inability to call PreparedStatement.setNull(index, Types.OTHER). We will
instead used PreparedStatement.setNull(index, Types.NULL).

Modified:
    incubator/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/OracleDictionary.java

Modified: incubator/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/OracleDictionary.java
URL: http://svn.apache.org/viewvc/incubator/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/OracleDictionary.java?view=diff&rev=497683&r1=497682&r2=497683
==============================================================================
--- incubator/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/OracleDictionary.java
(original)
+++ incubator/openjpa/trunk/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/sql/OracleDictionary.java
Thu Jan 18 18:09:53 2007
@@ -504,6 +504,9 @@
             // setNull with DATE; see bug #1171
         else if (colType == Types.DATE)
             super.setNull(stmnt, idx, Types.TIMESTAMP, col);
+        // the Oracle driver does not support Types.OTHER with setNull
+        else if (colType == Types.OTHER)
+            super.setNull(stmnt, idx, Types.NULL, col);
         else
             super.setNull(stmnt, idx, colType, col);
     }



Mime
View raw message