JasperServer 6.2.1 issue connecting Oracle 12c using ojdbc7 driver

Problem Description:

We are developing a reporting solution using Jasper Server 6.2.1 and Oracle 12c (12.1.0). The database. 12c has been upgraded from 10g. In fact we did a progressive migration from to 11g to 12c.

The issue we are encountering is that the reports that are running fine in 11g, when migrated its data source to 12c is not working properly.  

In fact the stack trace is very obvious with "Error executing SQL statement for”. We are puzzled for the a fact that the SQL statement works with 11g.

We would like to determine the cause of this. Kindly share with us your experiences 

Jasper Development environment:
- Jasper Studio version: 6.2.0

-  JDK & JRE version:  jdk-8u60

- JDBC driver:  ojdbc7.jar

Database: Amazon RDS Oracle 12c Instance

Application Server for Jasper : Tomacat

Error Stack from Jasper:

 

Error Message

Error filling report

Error Trace

com.jaspersoft.jasperserver.api.JSException: Error filling report Arguments: at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.EngineServiceImpl$FillResultListener.reportFillError(EngineServiceImpl.java:1294) at net.sf.jasperreports.engine.fill.BaseFillHandle.notifyError(BaseFillHandle.java:210) at net.sf.jasperreports.engine.fill.BaseFillHandle$ReportFill.run(BaseFillHandle.java:134) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.EngineServiceImpl$SynchronousExecutor.execute(EngineServiceImpl.java:922) at net.sf.jasperreports.engine.fill.BaseFillHandle.startFill(BaseFillHandle.java:164) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.EngineServiceImpl$AsynchronousReportFiller.fillReport(EngineServiceImpl.java:878) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.EngineServiceImpl.fillReport(EngineServiceImpl.java:1774) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.EngineServiceImpl$ReportFill.runWithDataSource(EngineServiceImpl.java:1118) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.EngineServiceImpl$ReportFill.runReport(EngineServiceImpl.java:1047) at com.jaspersoft.jasperserver.api.engine.jasperreports.service.impl.EngineServiceImpl$ReportRunnable.run(EngineServiceImpl.java:944) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: net.sf.jasperreports.engine.JRException: Error executing SQL statement for: RPTAMTCTRL. at net.sf.jasperreports.engine.query.JRJdbcQueryExecuter.createDatasource(JRJdbcQueryExecuter.java:342) at com.jaspersoft.jasperserver.api.engine.jasperreports.util.JRTimezoneJdbcQueryExecuter.createDatasource(JRTimezoneJdbcQueryExecuter.java:168) at net.sf.jasperreports.engine.fill.JRFillDataset.createQueryDatasource(JRFillDataset.java:1129) at net.sf.jasperreports.engine.fill.JRFillDataset.initDatasource(JRFillDataset.java:696) at net.sf.jasperreports.engine.fill.BaseReportFiller.setParameters(BaseReportFiller.java:437) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:526) at net.sf.jasperreports.engine.fill.BaseFillHandle$ReportFill.run(BaseFillHandle.java:119) ... 10 more Caused by: java.sql.SQLRecoverableException: No more data to read from socket at oracle.jdbc.driver.T4CMAREngineStream.unmarshalUB1(T4CMAREngineStream.java:456) at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:397) at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:257) at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:587) at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:225) at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:53) at oracle.jdbc.driver.T4CPreparedStatement.executeForDescribe(T4CPreparedStatement.java:774) at oracle.jdbc.driver.OracleStatement.executeMaybeDescribe(OracleStatement.java:925) at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1111) at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:4798) at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(OraclePreparedStatement.java:4845) at oracle.jdbc.driver.OraclePreparedStatementWrapper.executeQuery(OraclePreparedStatementWrapper.java:1501) at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:96) at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:96) at net.sf.jasperreports.engine.query.JRJdbcQueryExecuter.createDatasource(JRJdbcQueryExecuter.java:332) ... 16 more 

sreenath.akkattu_1's picture
Joined: Apr 19 2016 - 3:03am
Last seen: 5 years 10 months ago

Sreenath,

I am also facing the same problem after Oracle 12c.can you post the solution for this issue here.

krishnagmit3224 - 5 years 11 months ago

1 Answer:

After checking with Oracle support, it looks like it's an Oracle BUG, in fact Bug 17633803

According to Oracle, BUG is fixed in Oracle 12.1.0.2.

For us we have upgraded to 12.1.0.2 resolved the issue.

Another workaround is to use

alter session set "_optimizer_unnest_scalar_sq"= FALSE;

 

OR use /*+ no_unnest */ hints in the SQL having the problem.

 

sreenath.akkattu_1's picture
Joined: Apr 19 2016 - 3:03am
Last seen: 5 years 10 months ago
Feedback