[
https://issues.jboss.org/browse/TEIID-5136?page=com.atlassian.jira.plugin...
]
Ramesh Reddy commented on TEIID-5136:
-------------------------------------
[~asmigala] LATERAL JOIN applies to "CROSS APPLY" in PI and it does with
restrictions as to where this applies. So, the above query may not be correct. Please see
the documentation and see if above applies. Also for LATERAL, there are additional
metadata requirements. If you already did those, I need the VDB, I remember the JOIN to be
with the procedure, not a table. Can you check to make sure you are done those steps?
Osisoft translator - NPE when running query with LATERAL JOIN
-------------------------------------------------------------
Key: TEIID-5136
URL:
https://issues.jboss.org/browse/TEIID-5136
Project: Teiid
Issue Type: Bug
Components: JDBC Connector
Reporter: Andrej Šmigala
Assignee: Ramesh Reddy
Fix For: 10.1
Running the following query:
{code:sql}
SELECT bqt2.smalla.intkey, g2.intkey, bqt2.smalla.bytenum FROM bqt2.smalla LEFT JOIN
LATERAL (SELECT intkey FROM bqt2.mediuma WHERE bqt2.smalla.bytenum = bqt2.mediuma.bytenum)
AS g2 ON true
{code}
results in a NPE in teiid (before sending source src command).
Stacktrace:
{noformat}
Connector worker process failed for atomic-request=vEbs99yd+srV.1.0.1:
java.lang.NullPointerException
at
org.teiid.translator.jdbc.pi.PIExecutionFactory.translate(PIExecutionFactory.java:273)
[translator-jdbc-8.12.11.6_4.jar:8.12.11.6_4]
at
org.teiid.translator.jdbc.SQLConversionVisitor.append(SQLConversionVisitor.java:111)
[translator-jdbc-8.12.11.6_4.jar:8.12.11.6_4]
at org.teiid.language.visitor.SQLStringVisitor.append(SQLStringVisitor.java:106)
[teiid-api-8.12.11.6_4-redhat-64-7.jar:8.12.11.6_4-redhat-64-7]
at org.teiid.language.visitor.SQLStringVisitor.visit(SQLStringVisitor.java:767)
[teiid-api-8.12.11.6_4-redhat-64-7.jar:8.12.11.6_4-redhat-64-7]
at org.teiid.language.Select.acceptVisitor(Select.java:110)
[teiid-api-8.12.11.6_4-redhat-64-7.jar:8.12.11.6_4-redhat-64-7]
at
org.teiid.language.visitor.AbstractLanguageVisitor.visitNode(AbstractLanguageVisitor.java:51)
[teiid-api-8.12.11.6_4-redhat-64-7.jar:8.12.11.6_4-redhat-64-7]
at org.teiid.language.visitor.SQLStringVisitor.append(SQLStringVisitor.java:91)
[teiid-api-8.12.11.6_4-redhat-64-7.jar:8.12.11.6_4-redhat-64-7]
at
org.teiid.translator.jdbc.SQLConversionVisitor.append(SQLConversionVisitor.java:130)
[translator-jdbc-8.12.11.6_4.jar:8.12.11.6_4]
at
org.teiid.translator.jdbc.TranslatedCommand.translateCommand(TranslatedCommand.java:76)
[translator-jdbc-8.12.11.6_4.jar:8.12.11.6_4]
at
org.teiid.translator.jdbc.JDBCBaseExecution.translateCommand(JDBCBaseExecution.java:120)
[translator-jdbc-8.12.11.6_4.jar:8.12.11.6_4]
at
org.teiid.translator.jdbc.JDBCQueryExecution.execute(JDBCQueryExecution.java:114)
[translator-jdbc-8.12.11.6_4.jar:8.12.11.6_4]
at
org.teiid.dqp.internal.datamgr.ConnectorWorkItem.execute(ConnectorWorkItem.java:363)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[rt.jar:1.8.0_141]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[rt.jar:1.8.0_141]
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[rt.jar:1.8.0_141]
at java.lang.reflect.Method.invoke(Method.java:498) [rt.jar:1.8.0_141]
at
org.teiid.dqp.internal.datamgr.ConnectorManager$1.invoke(ConnectorManager.java:211)
at com.sun.proxy.$Proxy79.execute(Unknown Source)
at
org.teiid.dqp.internal.process.DataTierTupleSource.getResults(DataTierTupleSource.java:306)
at
org.teiid.dqp.internal.process.DataTierTupleSource$1.call(DataTierTupleSource.java:112)
at
org.teiid.dqp.internal.process.DataTierTupleSource$1.call(DataTierTupleSource.java:108)
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [rt.jar:1.8.0_141]
at org.teiid.dqp.internal.process.FutureWork.run(FutureWork.java:65)
at
org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:284)
at
org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:119)
at
org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:210)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[rt.jar:1.8.0_141]
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[rt.jar:1.8.0_141]
at java.lang.Thread.run(Thread.java:748) [rt.jar:1.8.0_141]
{noformat}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)