From: | jeffreylyon at mac(dot)com (Jeffrey Lyon) |
---|---|
To: | |
Subject: | [Pljava-dev] Missing JDBC Features - part II |
Date: | 2006-10-11 03:17:08 |
Message-ID: | C2B37048-01A3-4C2B-B30C-9FEAEE86B0EB@mac.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pljava-dev |
Sorry guys,
I took a look at SPI_prepare to see that prepareStatement does not
return the data types for the parameters, rather, it expects them.
So I guess that a call to getParameterType(index) before the
parameter is set would return the default (java.sql.Types.VARCHAR).
Sorry for jumping the gun.
However, I have a new question. When I do a
Integer x = null;
_prepared.setObject(1, x, java.sql.Types.INTEGER);
A
java.sql.SQLException: Can't assign null unless the SQL type is known
at org.postgresql.pljava.jdbc.SPIPreparedStatement.setObject
(SPIPreparedStatement.java:230)
is thrown. The problem that I'm having is that the exception is
thrown at SPIPreparedStatement.setObject(int columnIndex, Object
value) and not at SPIPreparedStatement.setObject(int columnIndex,
Object value, int sqlType), which is what I think I'm calling.
setObject(int, Object, int) doesn't call setObject(int, Object).
Thoughts?
OS X 10.4.9, Pgsql 8.1.3, PL/Java 1.3
Jeff
From | Date | Subject | |
---|---|---|---|
Next Message | Markus Schaber | 2006-10-15 08:38:08 | [Pljava-dev] Deployment Descriptor Problem |
Previous Message | Jeffrey Lyon | 2006-10-11 02:46:23 | [Pljava-dev] Missing JDBC Features? |