[JBoss JIRA] (TEIID-5301) With MongoDB, a query with subquery in HAVING clause doesn't return any results
by Johnathon Lee (JIRA)
[ https://issues.jboss.org/browse/TEIID-5301?page=com.atlassian.jira.plugin... ]
Johnathon Lee updated TEIID-5301:
---------------------------------
Fix Version/s: 8.12.13.6_4
> With MongoDB, a query with subquery in HAVING clause doesn't return any results
> -------------------------------------------------------------------------------
>
> Key: TEIID-5301
> URL: https://issues.jboss.org/browse/TEIID-5301
> Project: Teiid
> Issue Type: Bug
> Components: Misc. Connectors
> Affects Versions: 8.12.12.6_4
> Reporter: Jan Martiska
> Assignee: Steven Hawkins
> Fix For: 10.2, 10.3, 10.1.3, 10.0.5, 8.12.13.6_4
>
>
> Example:
> {noformat}
> SELECT INTKEY FROM BQT1.SMALLA GROUP BY INTKEY HAVING INTKEY = (SELECT INTKEY FROM BQT1.SMALLA WHERE INTKEY = 20)
> {noformat}
> This will not return any results even if there are rows with INTKEY=20.
> If I use a value instead of subquery, it works as expected, this will return a result:
> {noformat}
> SELECT INTKEY FROM BQT1.SMALLA GROUP BY INTKEY HAVING INTKEY = 20;
> {noformat}
> Furthermore, if the subquery returns null, the whole query fails with a NPE:
> {noformat}
> SELECT INTKEY FROM BQT1.SMALLA GROUP BY INTKEY HAVING INTKEY = (SELECT null);
> 13:43:50,250 ERROR [org.teiid.CONNECTOR] (Worker1_QueryProcessorQueue1) Connector worker process failed for atomic-request=mo0zm9PiOEre.0.3.0: java.lang.NullPointerException
> at java.util.concurrent.ConcurrentHashMap.get(ConcurrentHashMap.java:936) [rt.jar:1.8.0_151]
> at org.teiid.translator.mongodb.MongoDBSelectVisitor.getExpressionAlias(MongoDBSelectVisitor.java:808) [translator-mongodb-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.translator.mongodb.MongoDBSelectVisitor.visit(MongoDBSelectVisitor.java:641) [translator-mongodb-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.language.Comparison.acceptVisitor(Comparison.java:110) [teiid-api-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.language.visitor.AbstractLanguageVisitor.visitNode(AbstractLanguageVisitor.java:51) [teiid-api-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.translator.mongodb.MongoDBSelectVisitor.append(MongoDBSelectVisitor.java:81) [translator-mongodb-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.translator.mongodb.MongoDBSelectVisitor.visit(MongoDBSelectVisitor.java:574) [translator-mongodb-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.language.Select.acceptVisitor(Select.java:110) [teiid-api-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.language.visitor.AbstractLanguageVisitor.visitNode(AbstractLanguageVisitor.java:51) [teiid-api-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.translator.mongodb.MongoDBQueryExecution.execute(MongoDBQueryExecution.java:60) [translator-mongodb-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.dqp.internal.datamgr.ConnectorWorkItem.execute(ConnectorWorkItem.java:361)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.8.0_151]
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) [rt.jar:1.8.0_151]
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.8.0_151]
> at java.lang.reflect.Method.invoke(Method.java:498) [rt.jar:1.8.0_151]
> 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_151]
> 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_151]
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [rt.jar:1.8.0_151]
> at java.lang.Thread.run(Thread.java:748) [rt.jar:1.8.0_151]
> 13:43:50,257 WARN [org.teiid.PROCESSOR] (Worker0_QueryProcessorQueue2) TEIID30020 Processing exception for request mo0zm9PiOEre.0 'TEIID30504 local: null'. Originally TeiidProcessingException ConcurrentHashMap.java:936. Enable more detailed logging to see the entire stacktrace.
> {noformat}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 8 months
[JBoss JIRA] (TEIID-5305) NPE when executing a query
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-5305?page=com.atlassian.jira.plugin... ]
Steven Hawkins commented on TEIID-5305:
---------------------------------------
This looks to be an issue that was addressed with TEIID-5271 - what version is the above stacktrace from? I wasn't able to reproduce this on master.
> NPE when executing a query
> --------------------------
>
> Key: TEIID-5305
> URL: https://issues.jboss.org/browse/TEIID-5305
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Reporter: Ramesh Reddy
> Assignee: Steven Hawkins
>
> while executing a query like
> {code}
> SELECT MyOrclTbl.wellname, MyOrclTbl.surveyname, MyOrclTbl.npts, depthTable.depth, azimuthTable.azimuth,inclinationTable.inclination
> FROM
> (select 'Well-01' as wellname,
> 'survey_01' as surveyname,
> 6 as npts,
> '10,20,30,40,50,60' depth,
> '0,8.05,8.05,10.73,5.80,10.46' azimuth,
> '0.00,0.96,1.10,1.20,1.47,1.56' as inclination
> ) as MyOrclTbl,
> TEXTTABLE (MyOrclTbl.depth COLUMNS depth integer, id for ordinality ROW DELIMITER ',' DELIMITER '-') as depthTable
> LEFT JOIN TEXTTABLE (MyOrclTbl.azimuth COLUMNS azimuth double, id for ordinality ROW DELIMITER ',' DELIMITER '-') as azimuthTable ON depthTable.id = azimuthTable.id
> LEFT JOIN TEXTTABLE (MyOrclTbl.inclination COLUMNS inclination double, id for ordinality ROW DELIMITER ',' DELIMITER '-') as inclinationTable ON depthTable.id = inclinationTable.id
> {code}
> I see an error in log
> {code}
> 00 ERROR [org.teiid.PROCESSOR] (Worker14_QueryProcessorQueue121) qdLiyou1hVfE TEIID30019 Unexpected exception for request qdLiyou1hVfE.40: java.lang.NullPointerException
> at org.teiid.query.optimizer.relational.rules.RulePlanOuterJoins.checkLeftOrdering(RulePlanOuterJoins.java:338)
> at org.teiid.query.optimizer.relational.rules.RulePlanOuterJoins.planLeftOuterJoinAssociativityBeforePlanning(RulePlanOuterJoins.java:251)
> at org.teiid.query.optimizer.relational.rules.RulePlanOuterJoins.execute(RulePlanOuterJoins.java:62)
> at org.teiid.query.optimizer.relational.RelationalPlanner.executeRules(RelationalPlanner.java:995)
> at org.teiid.query.optimizer.relational.RelationalPlanner.optimize(RelationalPlanner.java:228)
> at org.teiid.query.optimizer.QueryOptimizer.optimizePlan(QueryOptimizer.java:179)
> at org.teiid.dqp.internal.process.Request.generatePlan(Request.java:458)
> at org.teiid.dqp.internal.process.Request.processRequest(Request.java:486)
> at org.teiid.dqp.internal.process.RequestWorkItem.processNew(RequestWorkItem.java:660)
> at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:339)
> at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:47)
> at org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:276)
> at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:280)
> at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:115)
> at org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:206)
> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
> at java.lang.Thread.run(Thread.java:748)
> {code}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 8 months
[JBoss JIRA] (TEIID-5193) Osisoft translator - correlated subquery on HAVING clause fails
by Johnathon Lee (JIRA)
[ https://issues.jboss.org/browse/TEIID-5193?page=com.atlassian.jira.plugin... ]
Johnathon Lee updated TEIID-5193:
---------------------------------
Fix Version/s: 8.12.13.6_4
> Osisoft translator - correlated subquery on HAVING clause fails
> ---------------------------------------------------------------
>
> Key: TEIID-5193
> URL: https://issues.jboss.org/browse/TEIID-5193
> Project: Teiid
> Issue Type: Bug
> Components: JDBC Connector
> Affects Versions: 8.12.11.6_4
> Reporter: Andrej Šmigala
> Assignee: Steven Hawkins
> Fix For: 10.1, 8.12.13.6_4
>
>
> Running a query with a correlated subquery in a HAVING clause, such as
> {code:sql}
> SELECT INTKEY, STRINGKEY
> FROM BQT1.SMALLA AS A
> WHERE NOT (INTKEY IN (10))
> GROUP BY INTKEY, STRINGKEY
> HAVING INTKEY = (SELECT MIN(STRINGKEY) FROM BQT1.SMALLA AS B WHERE A.INTKEY = B.INTKEY)
> {code}
> fails on the datasource with
> bq. com.osisoft.rdsa.RdsaException: [PIOLEDBENT] HAVING condition cannot be nonaggregate.
> This seems to be an issue on the Osisoft PI datasource side, as running the query directly against the datasource produces the same failure.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 8 months
[JBoss JIRA] (TEIID-5091) EdmPrimitiveTypeException in OData4 parse results
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-5091?page=com.atlassian.jira.plugin... ]
Steven Hawkins commented on TEIID-5091:
---------------------------------------
[~berenger] This was addressed in the community with an upgrade of olingo. It is definitely in the 10.0 release, but it may also be in the last 9.2 and 9.3 releases if the fix made it into olingo 4.3.
> EdmPrimitiveTypeException in OData4 parse results
> -------------------------------------------------
>
> Key: TEIID-5091
> URL: https://issues.jboss.org/browse/TEIID-5091
> Project: Teiid
> Issue Type: Quality Risk
> Components: OData
> Affects Versions: 8.12.5
> Environment: * JDV 6.3
> Reporter: Kylin Soong
> Assignee: Steven Hawkins
>
> Decimal type has risk if use odata4 to query data, I would use below example to show how to reproduce the errot:
> h3. set up sample data in mysql
> {code}
> create table test(U_ID Decimal Primary Key);
> insert into test values(11);
> desc test;
> +-------+---------------+------+-----+---------+-------+
> | Field | Type | Null | Key | Default | Extra |
> +-------+---------------+------+-----+---------+-------+
> | U_ID | decimal(10,0) | NO | PRI | NULL | |
> +-------+---------------+------+-----+---------+-------+
> {code}
> h3. Deploy VDB
> The VDB only contain one source model
> {code}
> <model name="TEST">
> <property name="importer.useFullSchemaName" value="false"/>
> <source name="mysql-connector" translator-name="translator-mysql5" connection-jndi-name="java:/TEST_DS"/>
> </model>
> {code}
> h3. Reproduce
> Once the vdb deployed finished, the http://localhost:8080/odata4/TEST_VDB/TEST/test will return below error in web browswer
> {code}
> <error xmlns="http://docs.oasis-open.org/odata/ns/metadata">
> <code>null</code>
> <message>
> org.apache.olingo.commons.api.edm.EdmPrimitiveTypeException: The value '11' does not match the facets' constraints.
> </message>
> </error>
> {code}
> The server log have a error like
> {code}
> 15:47:05,306 ERROR [org.teiid.ODATA] (http-0.0.0.0:8180-3) TEIID16050 Unable to process odata request due to: org.apache.olingo.commons.api.edm.EdmPrimitiveTypeException: The value '11' does not match the facets' constraints. with cause The value '11' does not match the facets' constraints.: org.apache.olingo.server.api.ODataApplicationException: org.apache.olingo.commons.api.edm.EdmPrimitiveTypeException: The value '11' does not match the facets' constraints.
> at org.teiid.olingo.service.TeiidServiceHandler.read(TeiidServiceHandler.java:174) [teiid-olingo-8.12.5.redhat-8.jar:8.12.5.redhat-8]
> at org.apache.olingo.server.core.requests.DataRequest$EntityRequest.execute(DataRequest.java:332)
> at org.apache.olingo.server.core.requests.DataRequest.execute(DataRequest.java:255)
> at org.apache.olingo.server.core.ServiceDispatcher.internalExecute(ServiceDispatcher.java:160)
> at org.apache.olingo.server.core.ServiceDispatcher.execute(ServiceDispatcher.java:98)
> at org.apache.olingo.server.core.OData4HttpHandler.process(OData4HttpHandler.java:66)
> at org.teiid.olingo.web.ODataServlet.service(ODataServlet.java:43) [teiid-olingo-8.12.5.redhat-8.jar:8.12.5.redhat-8]
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:847) [jboss-servlet-api_3.0_spec-1.0.2.Final-redhat-2.jar:1.0.2.Final-redhat-2]
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:295) [jbossweb-7.5.17.Final-redhat-1.jar:7.5.17.Final-redhat-1]
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.17.Final-redhat-1.jar:7.5.17.Final-redhat-1]
> at org.teiid.olingo.web.ODataFilter.internalDoFilter(ODataFilter.java:231) [teiid-olingo-8.12.5.redhat-8.jar:8.12.5.redhat-8]
> at org.teiid.olingo.web.ODataFilter.doFilter(ODataFilter.java:100) [teiid-olingo-8.12.5.redhat-8.jar:8.12.5.redhat-8]
> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.5.17.Final-redhat-1.jar:7.5.17.Final-redhat-1]
> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.5.17.Final-redhat-1.jar:7.5.17.Final-redhat-1]
> at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:231) [jbossweb-7.5.17.Final-redhat-1.jar:7.5.17.Final-redhat-1]
> at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149) [jbossweb-7.5.17.Final-redhat-1.jar:7.5.17.Final-redhat-1]
> at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:512) [jbossweb-7.5.17.Final-redhat-1.jar:7.5.17.Final-redhat-1]
> at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169) [jboss-as-web-7.5.9.Final-redhat-2.jar:7.5.9.Final-redhat-2]
> at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:150) [jbossweb-7.5.17.Final-redhat-1.jar:7.5.17.Final-redhat-1]
> at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97) [jbossweb-7.5.17.Final-redhat-1.jar:7.5.17.Final-redhat-1]
> at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102) [jbossweb-7.5.17.Final-redhat-1.jar:7.5.17.Final-redhat-1]
> at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:344) [jbossweb-7.5.17.Final-redhat-1.jar:7.5.17.Final-redhat-1]
> at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:854) [jbossweb-7.5.17.Final-redhat-1.jar:7.5.17.Final-redhat-1]
> at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:654) [jbossweb-7.5.17.Final-redhat-1.jar:7.5.17.Final-redhat-1]
> at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:926) [jbossweb-7.5.17.Final-redhat-1.jar:7.5.17.Final-redhat-1]
> at java.lang.Thread.run(Thread.java:748) [rt.jar:1.8.0_131]
> Caused by: java.sql.SQLException: org.apache.olingo.commons.api.edm.EdmPrimitiveTypeException: The value '11' does not match the facets' constraints.
> at org.teiid.olingo.service.EntityCollectionResponse.createEntity(EntityCollectionResponse.java:275) [teiid-olingo-8.12.5.redhat-8.jar:8.12.5.redhat-8]
> at org.teiid.olingo.service.EntityCollectionResponse.isSameEntity(EntityCollectionResponse.java:151) [teiid-olingo-8.12.5.redhat-8.jar:8.12.5.redhat-8]
> at org.teiid.olingo.service.LocalClient.executeSQL(LocalClient.java:280) [teiid-olingo-8.12.5.redhat-8.jar:8.12.5.redhat-8]
> at org.teiid.olingo.service.TeiidServiceHandler.executeQuery(TeiidServiceHandler.java:349) [teiid-olingo-8.12.5.redhat-8.jar:8.12.5.redhat-8]
> at org.teiid.olingo.service.TeiidServiceHandler.read(TeiidServiceHandler.java:172) [teiid-olingo-8.12.5.redhat-8.jar:8.12.5.redhat-8]
> ... 25 more
> Caused by: org.apache.olingo.commons.api.edm.EdmPrimitiveTypeException: The value '11' does not match the facets' constraints.
> at org.apache.olingo.commons.core.edm.primitivetype.EdmDecimal.internalValueToString(EdmDecimal.java:185)
> at org.apache.olingo.commons.core.edm.primitivetype.AbstractPrimitiveType.valueToString(AbstractPrimitiveType.java:86)
> at org.apache.olingo.server.core.responses.EntityResponse.buildLocation(EntityResponse.java:200)
> at org.teiid.olingo.service.EntityCollectionResponse.createEntity(EntityCollectionResponse.java:247) [teiid-olingo-8.12.5.redhat-8.jar:8.12.5.redhat-8]
> ... 29 more
> {code}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 8 months
[JBoss JIRA] (TEIID-5297) With MongoDB, null is returned from timestamp functions if the same function is part of WHERE clause
by Johnathon Lee (JIRA)
[ https://issues.jboss.org/browse/TEIID-5297?page=com.atlassian.jira.plugin... ]
Johnathon Lee updated TEIID-5297:
---------------------------------
Fix Version/s: 8.12.13.6_4
> With MongoDB, null is returned from timestamp functions if the same function is part of WHERE clause
> ----------------------------------------------------------------------------------------------------
>
> Key: TEIID-5297
> URL: https://issues.jboss.org/browse/TEIID-5297
> Project: Teiid
> Issue Type: Bug
> Components: Misc. Connectors
> Affects Versions: 8.12.11.6_4
> Reporter: Jan Martiska
> Assignee: Steven Hawkins
> Fix For: 10.3, 10.1.3, 10.0.5, 10.2.1, 8.12.13.6_4
>
>
> For example:
> {noformat}
> SELECT timestampvalue, second(timestampvalue) as sec FROM bqt1.hugeA WHERE second(timestampvalue) >= 0
> {noformat}
> This will correctly select rows where {{second(timestampvalue) >= 0}}, but the {{sec}} column in the result will contain only nulls.
> If I remove the WHERE clause:
> {noformat}
> SELECT timestampvalue, second(timestampvalue) as sec FROM bqt1.hugeA;
> {noformat}
> Then the {{sec}} column will be computed correctly.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 8 months
[JBoss JIRA] (TEIID-5305) NPE when executing a query
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-5305?page=com.atlassian.jira.plugin... ]
Work on TEIID-5305 started by Steven Hawkins.
---------------------------------------------
> NPE when executing a query
> --------------------------
>
> Key: TEIID-5305
> URL: https://issues.jboss.org/browse/TEIID-5305
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Reporter: Ramesh Reddy
> Assignee: Steven Hawkins
>
> while executing a query like
> {code}
> SELECT MyOrclTbl.wellname, MyOrclTbl.surveyname, MyOrclTbl.npts, depthTable.depth, azimuthTable.azimuth,inclinationTable.inclination
> FROM
> (select 'Well-01' as wellname,
> 'survey_01' as surveyname,
> 6 as npts,
> '10,20,30,40,50,60' depth,
> '0,8.05,8.05,10.73,5.80,10.46' azimuth,
> '0.00,0.96,1.10,1.20,1.47,1.56' as inclination
> ) as MyOrclTbl,
> TEXTTABLE (MyOrclTbl.depth COLUMNS depth integer, id for ordinality ROW DELIMITER ',' DELIMITER '-') as depthTable
> LEFT JOIN TEXTTABLE (MyOrclTbl.azimuth COLUMNS azimuth double, id for ordinality ROW DELIMITER ',' DELIMITER '-') as azimuthTable ON depthTable.id = azimuthTable.id
> LEFT JOIN TEXTTABLE (MyOrclTbl.inclination COLUMNS inclination double, id for ordinality ROW DELIMITER ',' DELIMITER '-') as inclinationTable ON depthTable.id = inclinationTable.id
> {code}
> I see an error in log
> {code}
> 00 ERROR [org.teiid.PROCESSOR] (Worker14_QueryProcessorQueue121) qdLiyou1hVfE TEIID30019 Unexpected exception for request qdLiyou1hVfE.40: java.lang.NullPointerException
> at org.teiid.query.optimizer.relational.rules.RulePlanOuterJoins.checkLeftOrdering(RulePlanOuterJoins.java:338)
> at org.teiid.query.optimizer.relational.rules.RulePlanOuterJoins.planLeftOuterJoinAssociativityBeforePlanning(RulePlanOuterJoins.java:251)
> at org.teiid.query.optimizer.relational.rules.RulePlanOuterJoins.execute(RulePlanOuterJoins.java:62)
> at org.teiid.query.optimizer.relational.RelationalPlanner.executeRules(RelationalPlanner.java:995)
> at org.teiid.query.optimizer.relational.RelationalPlanner.optimize(RelationalPlanner.java:228)
> at org.teiid.query.optimizer.QueryOptimizer.optimizePlan(QueryOptimizer.java:179)
> at org.teiid.dqp.internal.process.Request.generatePlan(Request.java:458)
> at org.teiid.dqp.internal.process.Request.processRequest(Request.java:486)
> at org.teiid.dqp.internal.process.RequestWorkItem.processNew(RequestWorkItem.java:660)
> at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:339)
> at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:47)
> at org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:276)
> at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:280)
> at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:115)
> at org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:206)
> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
> at java.lang.Thread.run(Thread.java:748)
> {code}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 8 months
[JBoss JIRA] (TEIID-5305) NPE when executing a query
by Ramesh Reddy (JIRA)
Ramesh Reddy created TEIID-5305:
-----------------------------------
Summary: NPE when executing a query
Key: TEIID-5305
URL: https://issues.jboss.org/browse/TEIID-5305
Project: Teiid
Issue Type: Bug
Components: Query Engine
Reporter: Ramesh Reddy
Assignee: Steven Hawkins
while executing a query like
{code}
SELECT MyOrclTbl.wellname, MyOrclTbl.surveyname, MyOrclTbl.npts, depthTable.depth, azimuthTable.azimuth,inclinationTable.inclination
FROM
(select 'Well-01' as wellname,
'survey_01' as surveyname,
6 as npts,
'10,20,30,40,50,60' depth,
'0,8.05,8.05,10.73,5.80,10.46' azimuth,
'0.00,0.96,1.10,1.20,1.47,1.56' as inclination
) as MyOrclTbl,
TEXTTABLE (MyOrclTbl.depth COLUMNS depth integer, id for ordinality ROW DELIMITER ',' DELIMITER '-') as depthTable
LEFT JOIN TEXTTABLE (MyOrclTbl.azimuth COLUMNS azimuth double, id for ordinality ROW DELIMITER ',' DELIMITER '-') as azimuthTable ON depthTable.id = azimuthTable.id
LEFT JOIN TEXTTABLE (MyOrclTbl.inclination COLUMNS inclination double, id for ordinality ROW DELIMITER ',' DELIMITER '-') as inclinationTable ON depthTable.id = inclinationTable.id
{code}
I see an error in log
{code}
00 ERROR [org.teiid.PROCESSOR] (Worker14_QueryProcessorQueue121) qdLiyou1hVfE TEIID30019 Unexpected exception for request qdLiyou1hVfE.40: java.lang.NullPointerException
at org.teiid.query.optimizer.relational.rules.RulePlanOuterJoins.checkLeftOrdering(RulePlanOuterJoins.java:338)
at org.teiid.query.optimizer.relational.rules.RulePlanOuterJoins.planLeftOuterJoinAssociativityBeforePlanning(RulePlanOuterJoins.java:251)
at org.teiid.query.optimizer.relational.rules.RulePlanOuterJoins.execute(RulePlanOuterJoins.java:62)
at org.teiid.query.optimizer.relational.RelationalPlanner.executeRules(RelationalPlanner.java:995)
at org.teiid.query.optimizer.relational.RelationalPlanner.optimize(RelationalPlanner.java:228)
at org.teiid.query.optimizer.QueryOptimizer.optimizePlan(QueryOptimizer.java:179)
at org.teiid.dqp.internal.process.Request.generatePlan(Request.java:458)
at org.teiid.dqp.internal.process.Request.processRequest(Request.java:486)
at org.teiid.dqp.internal.process.RequestWorkItem.processNew(RequestWorkItem.java:660)
at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:339)
at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:47)
at org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:276)
at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:280)
at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:115)
at org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:206)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
{code}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 8 months
[JBoss JIRA] (TEIID-5283) Recursive WITH query results in "java.lang.ClassCastException: org.teiid.query.sql.lang.Query cannot be cast to org.teiid.query.sql.lang.SetQuery"
by Johnathon Lee (JIRA)
[ https://issues.jboss.org/browse/TEIID-5283?page=com.atlassian.jira.plugin... ]
Johnathon Lee updated TEIID-5283:
---------------------------------
Fix Version/s: 8.12.13.6_4
> Recursive WITH query results in "java.lang.ClassCastException: org.teiid.query.sql.lang.Query cannot be cast to org.teiid.query.sql.lang.SetQuery"
> --------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: TEIID-5283
> URL: https://issues.jboss.org/browse/TEIID-5283
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Affects Versions: 8.12.11.6_4
> Reporter: Marc Shirley
> Assignee: Steven Hawkins
> Fix For: 10.0.4, 10.2, 10.1.2, 8.12.13.6_4
>
>
> Executing a query using a recursive WITH clause results in the error:
> ERROR [org.teiid.PROCESSOR] (Worker1_QueryProcessorQueue29) TEIID30019 Unexpected exception for request juY1MrNVs8vD.7: java.lang.ClassCastException: org.teiid.query.sql.lang.Query cannot be cast to org.teiid.query.sql.lang.SetQuery
> at org.teiid.query.optimizer.relational.RelationalPlanner.planWith(RelationalPlanner.java:327) [teiid-engine-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.query.optimizer.relational.RelationalPlanner.optimize(RelationalPlanner.java:208) [teiid-engine-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.query.optimizer.QueryOptimizer.optimizePlan(QueryOptimizer.java:159) [teiid-engine-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.dqp.internal.process.Request.generatePlan(Request.java:448) [teiid-engine-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.dqp.internal.process.Request.processRequest(Request.java:476) [teiid-engine-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.dqp.internal.process.RequestWorkItem.processNew(RequestWorkItem.java:642) [teiid-engine-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:337) [teiid-engine-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:51) [teiid-engine-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:274) [teiid-engine-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:284) [teiid-engine-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:119) [teiid-engine-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:210) [teiid-engine-8.12.11.6_4-redhat-64-12.jar:8.12.11.6_4-redhat-64-12]
> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [rt.jar:1.8.0_151]
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [rt.jar:1.8.0_151]
> at java.lang.Thread.run(Thread.java:748) [rt.jar:1.8.0_151]
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 8 months
[JBoss JIRA] (TEIID-5258) TEIID30151 Error building Source for context item
by dalex dalex (JIRA)
[ https://issues.jboss.org/browse/TEIID-5258?page=com.atlassian.jira.plugin... ]
dalex dalex edited comment on TEIID-5258 at 4/3/18 10:25 AM:
-------------------------------------------------------------
Hi [~shawkins]
> can you test with master?
I'm very sorry, didn't have enough time for checking the bug on master branch. But I'll check the TEIID-5242 changes asap. Thx.
was (Author: dalex005):
Hi [~shawkins]
> can you test with master?
I'm very sorry, didn't have enough time for checking the bug on master branch. But I'll check the TEIID-5242 changes asap, that's great that you have already fixed it in scope of the DVCORE-5242 issue. Thx.
> TEIID30151 Error building Source for context item
> -------------------------------------------------
>
> Key: TEIID-5258
> URL: https://issues.jboss.org/browse/TEIID-5258
> Project: Teiid
> Issue Type: Bug
> Components: XML Connector
> Affects Versions: 10.1
> Environment: teiid-10.1.0 on WildFly Full 11.0.0.Final (WildFly Core 3.0.8.Final)
> Reporter: dalex dalex
> Assignee: Steven Hawkins
> Attachments: failed.json
>
>
> When running the following script:
> {code:sql}
> Begin
> with t As (
> Select campaign_id, email_address, activity
> From (
> call files.getFiles(pathAndPattern => 'failed.json')
> ) f
> Cross Join
> XmlTable (
> '/root/emails'
> Passing JsonToXml('root', f.file)
> Columns
> campaign_id string,
> list_id string,
> list_is_active boolean,
> email_id string,
> email_address string,
> activity xml
> ) x
> Where activity Is Not Null
> )
> Select *
> From t Cross Join XmlTable (
> '/root/activity'
> Passing XmlElement(root, t.activity)
> Columns
> action string,
> "timestamp" timestamp,
> url string,
> ip string
> ) a;
> End;
> {code}
> teiid throws out the following error:
> {code:noformat}
> 2018-02-13 17:55:47,054 WARN [org.teiid.PROCESSOR] (Worker2_QueryProcessorQueue7) /okCCfP2/yjh TEIID30020 Processing exception for request /okCCfP2/yjh.0 'TEIID30151 Error building
> Source for context item.'. Originally TeiidProcessingException StaxToEventBridge.java:325.: org.teiid.core.TeiidProcessingException: TEIID30151 Error building Source for context item
> .
> at org.teiid.query.xquery.saxon.XQueryEvaluator.evaluateXQuery(XQueryEvaluator.java:163)
> at org.teiid.query.processor.relational.XMLTableNode$1.run(XMLTableNode.java:265)
> at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:280)
> at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:115)
> at org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:206)
> 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: nu.xom.ParsingException
> at nu.xom.Builder.build(Unknown Source)
> at nu.xom.Builder.build(Unknown Source)
> at org.teiid.query.xquery.saxon.XQueryEvaluator.evaluateXQuery(XQueryEvaluator.java:157)
> ... 7 more
> Caused by: java.lang.NullPointerException
> at net.sf.saxon.evpull.StaxToEventBridge.getSystemId(StaxToEventBridge.java:325)
> at net.sf.saxon.evpull.StaxToEventBridge.getSystemId(StaxToEventBridge.java:385)
> at net.sf.saxon.event.ContentHandlerProxyLocator.getSystemId(ContentHandlerProxyLocator.java:72)
> at nu.xom.XOMHandler.startElement(Unknown Source)
> at net.sf.saxon.event.ContentHandlerProxy.startContent(ContentHandlerProxy.java:373)
> at org.teiid.query.xquery.saxon.ContentHandlerProxyReceiver.startContent(StreamingUtils.java:291)
> at net.sf.saxon.event.ProxyReceiver.startContent(ProxyReceiver.java:177)
> at org.teiid.query.xquery.saxon.PathMapFilter.startContent(PathMapFilter.java:226)
> at net.sf.saxon.event.TreeReceiver.startContent(TreeReceiver.java:220)
> at net.sf.saxon.evpull.EventIteratorToReceiver.copy(EventIteratorToReceiver.java:78)
> at net.sf.saxon.event.Sender.sendPullEventSource(Sender.java:559)
> at net.sf.saxon.event.Sender.send(Sender.java:132)
> at net.sf.saxon.Configuration.buildDocument(Configuration.java:3361)
> at net.sf.saxon.Configuration.buildDocument(Configuration.java:3303)
> at org.teiid.query.xquery.saxon.SaxonReader.parse(StreamingUtils.java:175)
> ... 10 more
> {code}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
6 years, 8 months