Using ojdbc7.jar with Oracle 11g database in DV errors with "TEIID30037 java.sql.SQLException: Protocol violation"
Issue
- Running query against Oracle 11g database table that has CLOB type column in DV using Oracle 12c driver "ojdbc7.jar" throws an error:
2016-08-25 11:20:34,680 ERROR \[org.teiid.PROCESSOR\] (Worker2_QueryProcessorQueue14) TEIID30019 Unexpected exception for request HJ46XelOyMQP.6: org.teiid.core.TeiidComponentException: TEIID30037 java.sql.SQLException: Protocol violation: [ 14, 84, ]
at org.teiid.common.buffer.LobManager.persistLob(LobManager.java:290) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.common.buffer.LobManager.updateReferences(LobManager.java:121) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.common.buffer.TupleBuffer.addTupleBatch(TupleBuffer.java:203) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.query.processor.BatchCollector.flushBatchDirect(BatchCollector.java:224) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.dqp.internal.process.RequestWorkItem$1.flushBatchDirect(RequestWorkItem.java:641) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.query.processor.BatchCollector.flushBatch(BatchCollector.java:218) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:189) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:141) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.dqp.internal.process.RequestWorkItem.processMore(RequestWorkItem.java:444) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:326) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:51) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:254) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:274) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:119) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:210) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [rt.jar:1.8.0_65]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [rt.jar:1.8.0_65]
at java.lang.Thread.run(Thread.java:745) [rt.jar:1.8.0_65]
Caused by: java.sql.SQLException: Protocol violation: [ 14, 84, ]
at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:669)
at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:249)
at oracle.jdbc.driver.T4C8TTIClob.read(T4C8TTIClob.java:245)
at oracle.jdbc.driver.T4CConnection.getChars(T4CConnection.java:3901)
at oracle.sql.CLOB.getChars(CLOB.java:517)
at oracle.sql.CLOB.getSubString(CLOB.java:354)
at org.teiid.core.types.ClobType.getSubString(ClobType.java:77) [teiid-common-core-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
at org.teiid.common.buffer.LobManager.persistLob(LobManager.java:231) [teiid-engine-8.7.5.6_2-redhat-2.jar:8.7.5.6_2-redhat-2]
... 17 more
Environment
- Red Hat JBoss Data Virtualization (DV) 6.2
- Oracle 11g Database
- Oracle 12c JDBC driver (ojdbc7.jar)
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.