Home » Developer & Programmer » JDeveloper, Java & XML » jdbc and oracle fails
jdbc and oracle fails [message #350831] Fri, 26 September 2008 10:58
ziggy25
Messages: 206
Registered: July 2005
Senior Member
I am trying to send an array to a pl/sql module but for some reason i am unable to get the connection object.

Here is the line of code that fails

Connection conn = null;
ArrayDescriptor rectabDescriptor = ArrayDescriptor.createDescriptor("CCS21_CONSIGNMENTLIST_TYPE",conn);   <<FAILS HERE<<
ARRAY awbNoHwbs = new ARRAY(rectabDescriptor,conn,childLessAwbs);
ARRAY hwbs = new ARRAY(rectabDescriptor,conn,hwbList);
			
OracleCallableStatement cst = (OracleCallableStatement)conn.prepareCall(stp.SUBMIT_CONSIGNMENT_STORED_PROC);
			


Here is the stack trace

java.lang.ClassCastException: org.apache.tomcat.dbcp.dbcp.DelegatingCallableStatement
	at com.acbt.ccstt.data.accessors.ConsignmentDAO.submitDeclaration(ConsignmentDAO.java:301)
	at com.acbt.ccstt.presentation.events.consignments.select.SubmitDeclaration.midAction(SubmitDeclaration.java:68)
	at com.acbt.ccstt.presentation.events.CCS21EventAction.execute(CCS21EventAction.java:36)
	at org.apache.struts.chain.commands.servlet.ExecuteAction.execute(ExecuteAction.java:58)
	at org.apache.struts.chain.commands.AbstractExecuteAction.execute(AbstractExecuteAction.java:67)
	at org.apache.struts.chain.commands.ActionCommandBase.execute(ActionCommandBase.java:51)
	at org.apache.commons.chain.impl.ChainBase.execute(ChainBase.java:190)
	at org.apache.commons.chain.generic.LookupCommand.execute(LookupCommand.java:304)
	at org.apache.commons.chain.impl.ChainBase.execute(ChainBase.java:190)
	at org.apache.struts.chain.ComposableRequestProcessor.process(ComposableRequestProcessor.java:283)
	at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1913)
	at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:462)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:647)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:172)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:174)
	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:875)
	at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
	at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
	at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
	at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689)
	at java.lang.Thread.run(Thread.java:595)


And here is my connection config

Struts Web.xml file

<resource-ref>
	 <description>Oracle Datasource</description>
	 <res-ref-name>jdbc/ccs21db</res-ref-name>
	 <res-type>javax.sql.DataSource</res-type>
	 <res-auth>Container</res-auth>
	</resource-ref>


Metainf/context.xml
    <Resource name="jdbc/thedb" auth="Container"
              type="javax.sql.DataSource" driverClassName="oracle.jdbc.OracleDriver"
              url="jdbc:oracle:thin:@xxx.xxx.xxx.xxx:1521:dbsid"
              username="xxx" password="xxx" maxActive="20" maxIdle="10"
              maxWait="-1"/> 

[Updated on: Fri, 26 September 2008 11:03]

Report message to a moderator

Previous Topic: Problem in OA framework while using jdeveloper in oracle apps 11.5.10
Next Topic: XXL-FO help to print text when firstpage=lastpage
Goto Forum:
  


Current Time: Wed Jul 30 00:22:29 CDT 2014

Total time taken to generate the page: 0.20093 seconds