My Oracle Support Banner

java.lang.ClassCastException: weblogic.jdbc.wrapper.CallableStatement (Doc ID 1134010.1)

Last updated on AUGUST 26, 2020

Applies to:

Oracle WebLogic Server - Version 10.3 to 10.3.3
Information in this document applies to any platform.
This document is applicable for Using Weblogic JDBC API


Symptoms

Migrating from OC4J to WLS 11g(11.1.2) and  using Oracle extensions to the JDBC API from within WebLogic.
After obtaining the underlying vendor connection, they are getting a ClassCastException when trying to cast it to an OracleConnection.

java.lang.ClassCastException: oracle.jdbc.driver.LogicalConnection cannot be cast to oracle.jdbc.OracleConnection
at dep.dep.fra.base.JdbcDAOImpl.getOracleConnection(JdbcDAOImpl.java:50)
at dep.dep.fra.base.BaseDAO.getOracleConnection(BaseDAO.java:21)
at dep.dep.fra.dao.UtilDAO.getFuelData(UtilDAO.java:802)
at dep.dep.fra.fuels.servlet.FraPortStatusActionDisplay.execute(FraPortStatusActionDisplay.java:287)
at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)
at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)

Changes

 

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Changes
Cause
Solution

My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.