Skip to Main Content

Java Database Connectivity (JDBC)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

JDBC Drivers compatability between Oracle and IBM WSAD 5.1.1

843854May 24 2005 — edited May 24 2005
I am using a DataAccessObject pattern. I discovered you can speed up your procesing with SELECT statments us using an OraclePreparedStatment and setting defineColumnType; thereby reducing the number of trips the SQL is sent to the database.

Here is the code:
 ((OraclePreparedStatement)ps).defineColumnType(1, Types.BIGINT);
'ps' is a PreparedStatement.

However, at runtime, I am getting a class cast exception for the below reason. I am using WASD version 5.1.1. I was not aware IBM was using any specific classes in the JDBC drivers.

[
2005-05-23 15:36:59,855][Servlet.Engine.Transports : 2][ERROR][{TDAO}{getTWebInfos}{APP0000}{Unknown Contained Application Exception}{External Message:com/ibm/ws/rsadapter/jdbc/WSJdbcPreparedStatement incompatible with oracle/jdbc/OraclePreparedStatement}]
{TDAO}{getTWebInfos}{APP0000}{Unknown Contained Application Exception}{External Message:com/ibm/ws/rsadapter/jdbc/WSJdbcPreparedStatement incompatible with oracle/jdbc/OraclePreparedStatement}
	at java.lang.Throwable.(Throwable.java)
Could someone please explain this to me? Any help would be greatly appreciated.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 21 2005
Added on May 24 2005
1 comment
258 views