Here is patch that adds Java type support back to Derby.
It is against my local CVS archive so it might not patch directly to any SVN
revision. It is against revision 55876.
Good luck!
--
Jacob S. Barrett
[EMAIL PROTECTED]
www.amduat.net
"I don't suffer from insanity, I enjoy every minute of it."
Index: trunk/java/engine/org/apache/derby/impl/jdbc/EmbedPreparedStatement.java
diff -u trunk/java/engine/org/apache/derby/impl/jdbc/EmbedPreparedStatement.java:1.1.1.1 trunk/java/engine/org/apache/derby/impl/jdbc/EmbedPreparedStatement.java:1.2
--- trunk/java/engine/org/apache/derby/impl/jdbc/EmbedPreparedStatement.java:1.1.1.1 Fri Sep 10 15:32:35 2004
+++ trunk/java/engine/org/apache/derby/impl/jdbc/EmbedPreparedStatement.java Tue Sep 14 09:09:55 2004
@@ -269,9 +269,10 @@
int jdbcTypeId = getParameterJDBCType(parameterIndex);
- if (!DataTypeDescriptor.isJDBCTypeEquivalent(jdbcTypeId, sqlType)) {
-
- throw dataTypeConversion(parameterIndex, Util.typeName(sqlType));
+ if (jdbcTypeId != java.sql.Types.JAVA_OBJECT) {
+ if (!DataTypeDescriptor.isJDBCTypeEquivalent(jdbcTypeId, sqlType)) {
+ throw dataTypeConversion(parameterIndex, Util.typeName(sqlType));
+ }
}
try {
Index: trunk/java/engine/org/apache/derby/impl/sql/compile/sqlgrammar.jj
diff -u trunk/java/engine/org/apache/derby/impl/sql/compile/sqlgrammar.jj:1.1.1.2 trunk/java/engine/org/apache/derby/impl/sql/compile/sqlgrammar.jj:1.4
--- trunk/java/engine/org/apache/derby/impl/sql/compile/sqlgrammar.jj:1.1.1.2 Thu Oct 28 10:19:03 2004
+++ trunk/java/engine/org/apache/derby/impl/sql/compile/sqlgrammar.jj Thu Oct 28 10:44:57 2004
@@ -3292,8 +3292,13 @@
DataTypeDescriptor typeDescriptor;
}
{
+(
LOOKAHEAD( { commonDatatypeName(false) } )
- typeDescriptor = dataTypeCommon()
+ typeDescriptor = dataTypeCommon()
+|
+ LOOKAHEAD( {true} )
+ typeDescriptor = javaType()
+)
{
return typeDescriptor;
}