I am migrating from 2 to 4.00.22
We make use of OraclePreparedStatement to take advantage of setting parameters
by name.
This worked fine under Resin 2.
We get the datasource
try {
Context env = (Context) new
InitialContext().lookup(Constants.CONTEXT_ENV_ROOT);
ds = (DataSource) env.lookup(Constants.GENERAL_CONNECTION_POOL);
if (ds == null) {
System.out.println(Constants.GENERAL_CONNECTION_POOL + " is an
unknown DataSource");
}
} catch (NamingException e) {
e.printStackTrace();
}
and then in another class we use it:
Connection con = null;
list = new java.util.ArrayList();
try {
con = ds.getConnection();
OraclePreparedStatement ps = (OraclePreparedStatement)
con.prepareStatement(getSQLCommandText());
etc......
BUT under resin 4 we are getting errors that we cannot cast the
com.caucho.sql.UserPreparedStatement to OraclePreparedStatement.
Do we really have to abandon OraclePreparedStatement and named parameters?
I have tried casting the connection and such like but the caucho.sql.UserXXXX
seems to take over everything.
Any help or pointers would be welcome.
Thanks
Alan
--
Alan Wright
Athene Systems
tel 0845 230 9803
Athene Systems Limited
Registered Office:
Shieling House
Invincible Road
Farnborough
GU14 7QU
Registered in England and Wales No. 3156080
_______________________________________________
resin-interest mailing list
[email protected]
http://maillist.caucho.com/mailman/listinfo/resin-interest