[JBoss JIRA] (TEIID-3802) HANA translator modifies boolean to tinyint in type conversion
by RH Bugzilla Integration (JIRA)
[ https://issues.jboss.org/browse/TEIID-3802?page=com.atlassian.jira.plugin... ]
RH Bugzilla Integration commented on TEIID-3802:
------------------------------------------------
Jan Stastny <jstastny(a)redhat.com> changed the Status of [bug 1278409|https://bugzilla.redhat.com/show_bug.cgi?id=1278409] from ON_QA to VERIFIED
> HANA translator modifies boolean to tinyint in type conversion
> --------------------------------------------------------------
>
> Key: TEIID-3802
> URL: https://issues.jboss.org/browse/TEIID-3802
> Project: Teiid
> Issue Type: Bug
> Components: Misc. Connectors
> Affects Versions: 8.7.1.6_2
> Reporter: Jan Stastny
> Assignee: Steven Hawkins
> Fix For: 8.12.2, 8.13
>
>
> Teiid modifies boolean data type to tinyint before pushing the query down to the HANA instance.
> This brings following issue while having a query similar to this one:
> {code:sql}
> SELECT BQT1.SMallA.BooleanValue,cast(BQT2.SmallB.CharValue as boolean) FROM BQT1.SmallA,BQT2.SmallB WHERE BQT1.SmallA.BooleanValue = cast(BQT2.SmallB.CharValue as boolean)
> {code}
> which Teiid modifies to:
> {code:sql}
> SELECT g_0."BOOLEANVALUE", cast(g_1."CHARVALUE" AS tinyint) FROM "BQT1"."SMALLA" AS g_0, "BQT2"."SMALLB" AS g_1 WHERE g_0."BOOLEANVALUE" = cast(g_1."CHARVALUE" AS tinyint)
> {code}
> But the problem is not present for:
> {code:sql}
> SELECT BQT1.SMallA.BooleanValue FROM BQT1.SmallA WHERE BQT1.SmallA.BooleanValue = cast(BQT1.SmallA.CharValue as boolean)
> {code}
> It seems that the Cartesian product and comparing values from different sources are the cause of the issue. But HANA has internal type BOOLEAN, so there might be no point at modifying the type to TINYINT after all. I also checked, that the pushed query (which causes the issue) with the casting altered to BOOLEAN runs well on HANA. The following query returns expected results when pushed directly to HANA instance:
> {code:sql}
> SELECT g_0."BOOLEANVALUE", cast(g_1."CHARVALUE" AS boolean) FROM "BQT1"."SMALLA" AS g_0, "BQT2"."SMALLB" AS g_1 WHERE g_0."BOOLEANVALUE" = cast(g_1."CHARVALUE" AS boolean)
> {code}
> NOTE: The CharValue columns are modelled as VARCHAR/string in fact. Thus the cast is a valid operation.
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
9 years, 10 months
[JBoss JIRA] (TEIID-3964) Cassandra does not account for null values
by RH Bugzilla Integration (JIRA)
[ https://issues.jboss.org/browse/TEIID-3964?page=com.atlassian.jira.plugin... ]
RH Bugzilla Integration commented on TEIID-3964:
------------------------------------------------
Jan Stastny <jstastny(a)redhat.com> changed the Status of [bug 1306234|https://bugzilla.redhat.com/show_bug.cgi?id=1306234] from ON_QA to VERIFIED
> Cassandra does not account for null values
> ------------------------------------------
>
> Key: TEIID-3964
> URL: https://issues.jboss.org/browse/TEIID-3964
> Project: Teiid
> Issue Type: Bug
> Components: Misc. Connectors
> Affects Versions: 8.6
> Reporter: Filip Elias
> Assignee: Steven Hawkins
> Priority: Blocker
> Fix For: 9.0, 8.12.5, 8.13.1
>
> Attachments: cassandra-vdb.xml
>
>
> primitive wrapper types (integer, long, float, double, etc.) do not account for null values from Cassandra, but instead return their default 0 value. Teiid also throws NPE when Blob column contains null.
> Query (should return [14,null]):
> {code}select intkey, objectvalue from smalla where intkey = 14 {code}
> Stack Trace:
> {code}
> 12:14:58,599 ERROR [org.teiid.CONNECTOR] (Worker0_QueryProcessorQueue7) Connector worker process failed for atomic-request=afOb+DA5w6pF.5.0.5: java.lang.NullPointerException
> at org.teiid.translator.cassandra.CassandraQueryExecution.getRow(CassandraQueryExecution.java:160) [translator-cassandra-8.12.3.redhat-1.jar:8.12.3.redhat-1]
> at org.teiid.translator.cassandra.CassandraQueryExecution.next(CassandraQueryExecution.java:86) [translator-cassandra-8.12.3.redhat-1.jar:8.12.3.redhat-1]
> at org.teiid.dqp.internal.datamgr.ConnectorWorkItem.handleBatch(ConnectorWorkItem.java:419)
> at org.teiid.dqp.internal.datamgr.ConnectorWorkItem.more(ConnectorWorkItem.java:220)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.8.0_45]
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) [rt.jar:1.8.0_45]
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.8.0_45]
> at java.lang.reflect.Method.invoke(Method.java:497) [rt.jar:1.8.0_45]
> at org.teiid.dqp.internal.datamgr.ConnectorManager$1.invoke(ConnectorManager.java:211)
> at com.sun.proxy.$Proxy94.more(Unknown Source)
> at org.teiid.dqp.internal.process.DataTierTupleSource.getResults(DataTierTupleSource.java:309)
> at org.teiid.dqp.internal.process.DataTierTupleSource.nextTuple(DataTierTupleSource.java:142)
> at org.teiid.query.processor.relational.AccessNode.nextBatchDirect(AccessNode.java:374)
> at org.teiid.query.processor.relational.RelationalNode.nextBatch(RelationalNode.java:282)
> at org.teiid.query.processor.relational.RelationalPlan.nextBatch(RelationalPlan.java:145)
> at org.teiid.query.processor.QueryProcessor.nextBatchDirect(QueryProcessor.java:151)
> at org.teiid.query.processor.QueryProcessor.nextBatch(QueryProcessor.java:114)
> at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:164)
> at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:146)
> at org.teiid.dqp.internal.process.RequestWorkItem.processMore(RequestWorkItem.java:470)
> at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:348)
> at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:51)
> at org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:274)
> at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:276)
> 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:1142) [rt.jar:1.8.0_45]
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [rt.jar:1.8.0_45]
> at java.lang.Thread.run(Thread.java:745) [rt.jar:1.8.0_45]
> {code}
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
9 years, 10 months
[JBoss JIRA] (TEIID-4166) JDG cache translator - In predicate does not support more than 1024 values
by RH Bugzilla Integration (JIRA)
[ https://issues.jboss.org/browse/TEIID-4166?page=com.atlassian.jira.plugin... ]
RH Bugzilla Integration commented on TEIID-4166:
------------------------------------------------
Van Halbert <vhalbert(a)redhat.com> changed the Status of [bug 1330048|https://bugzilla.redhat.com/show_bug.cgi?id=1330048] from NEW to ASSIGNED
> JDG cache translator - In predicate does not support more than 1024 values
> --------------------------------------------------------------------------
>
> Key: TEIID-4166
> URL: https://issues.jboss.org/browse/TEIID-4166
> Project: Teiid
> Issue Type: Bug
> Affects Versions: 8.12.x
> Reporter: Juraj Duráni
> Assignee: Van Halbert
>
> JDG cache translator (local JDG) does not support more than 1024 values in IN predicate.
> The exception is thrown because 'maxClauseCount' is set to 1024.
> *Exception:*
> {code:plain}
> 12:27:43,579 ERROR [org.teiid.PROCESSOR] (Worker1_QueryProcessorQueue73) TEIID30019 Unexpected exception for request Q4A3h+Gv1LIh.13: org.apache.lucene.search.BooleanQuery$TooManyClauses: maxClauseCount is set to 1024
> at org.apache.lucene.search.BooleanQuery.add(BooleanQuery.java:136)
> at org.hibernate.search.query.dsl.impl.BooleanQueryBuilder.createQuery(BooleanQueryBuilder.java:115)
> at org.hibernate.hql.lucene.internal.builder.predicate.LuceneDisjunctionPredicate.getQuery(LuceneDisjunctionPredicate.java:51)
> at org.hibernate.hql.lucene.internal.builder.predicate.LuceneInPredicate.getQuery(LuceneInPredicate.java:60)
> at org.hibernate.hql.lucene.internal.builder.predicate.LuceneInPredicate.getQuery(LuceneInPredicate.java:35)
> at org.hibernate.hql.lucene.internal.builder.predicate.LuceneRootPredicate.getQuery(LuceneRootPredicate.java:42)
> at org.hibernate.hql.lucene.internal.builder.predicate.LuceneRootPredicate.getQuery(LuceneRootPredicate.java:32)
> at org.hibernate.hql.ast.spi.SingleEntityQueryBuilder.build(SingleEntityQueryBuilder.java:174)
> at org.hibernate.hql.lucene.internal.LuceneQueryRendererDelegate.getResult(LuceneQueryRendererDelegate.java:98)
> at org.hibernate.hql.lucene.LuceneProcessingChain.getResult(LuceneProcessingChain.java:157)
> at org.hibernate.hql.lucene.LuceneProcessingChain.getResult(LuceneProcessingChain.java:49)
> at org.hibernate.hql.QueryParser.parseQuery(QueryParser.java:89)
> at org.infinispan.query.dsl.embedded.impl.QueryEngine.transformJpaToLucene(QueryEngine.java:708)
> at org.infinispan.query.dsl.embedded.impl.QueryEngine.buildLuceneQuery(QueryEngine.java:676)
> at org.infinispan.query.dsl.embedded.impl.EmbeddedLuceneQuery.createCacheQuery(EmbeddedLuceneQuery.java:59)
> at org.infinispan.query.dsl.embedded.impl.EmbeddedLuceneQuery.listInternal(EmbeddedLuceneQuery.java:74)
> at org.infinispan.query.dsl.embedded.impl.EmbeddedLuceneQuery.list(EmbeddedLuceneQuery.java:68)
> at org.infinispan.query.dsl.embedded.impl.DelegatingQuery.list(DelegatingQuery.java:45)
> at org.teiid.resource.adapter.infinispan.DSLSearch.performSearch(DSLSearch.java:169)
> at org.teiid.resource.adapter.infinispan.DSLSearch.performSearch(DSLSearch.java:130)
> at org.teiid.translator.object.ObjectExecution.execute(ObjectExecution.java:259)
> at org.teiid.dqp.internal.datamgr.ConnectorWorkItem.execute(ConnectorWorkItem.java:359) [teiid-engine-8.12.5.redhat-3.jar:8.12.5.redhat-3]
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.8.0-internal]
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) [rt.jar:1.8.0-internal]
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.8.0-internal]
> at java.lang.reflect.Method.invoke(Method.java:483) [rt.jar:1.8.0-internal]
> at org.teiid.dqp.internal.datamgr.ConnectorManager$1.invoke(ConnectorManager.java:211) [teiid-engine-8.12.5.redhat-3.jar:8.12.5.redhat-3]
> at com.sun.proxy.$Proxy81.execute(Unknown Source)
> at org.teiid.dqp.internal.process.DataTierTupleSource.getResults(DataTierTupleSource.java:306) [teiid-engine-8.12.5.redhat-3.jar:8.12.5.redhat-3]
> at org.teiid.dqp.internal.process.DataTierTupleSource$1.call(DataTierTupleSource.java:112) [teiid-engine-8.12.5.redhat-3.jar:8.12.5.redhat-3]
> at org.teiid.dqp.internal.process.DataTierTupleSource$1.call(DataTierTupleSource.java:108) [teiid-engine-8.12.5.redhat-3.jar:8.12.5.redhat-3]
> at java.util.concurrent.FutureTask.run(FutureTask.java:266) [rt.jar:1.8.0-internal]
> at org.teiid.dqp.internal.process.FutureWork.run(FutureWork.java:65) [teiid-engine-8.12.5.redhat-3.jar:8.12.5.redhat-3]
> at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:276) [teiid-engine-8.12.5.redhat-3.jar:8.12.5.redhat-3]
> at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:119) [teiid-engine-8.12.5.redhat-3.jar:8.12.5.redhat-3]
> at org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:210) [teiid-engine-8.12.5.redhat-3.jar:8.12.5.redhat-3]
> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [rt.jar:1.8.0-internal]
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [rt.jar:1.8.0-internal]
> at java.lang.Thread.run(Thread.java:744) [rt.jar:1.8.0-internal]
> {code}
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
9 years, 10 months
[JBoss JIRA] (TEIID-3600) DB2 - error getting substring if "from position" is out of range
by Van Halbert (JIRA)
[ https://issues.jboss.org/browse/TEIID-3600?page=com.atlassian.jira.plugin... ]
Van Halbert reopened TEIID-3600:
--------------------------------
The issue is still present. Source-specific command has changed, but exception is thrown anyway.
Source-specific command: SELECT substr(varchar(g_0.TIMESTAMPVALUE), CASE WHEN 40 > 0 THEN 0 ELSE 40 END, CASE WHEN 0 > (length(varchar(g_0.TIMESTAMPVALUE)) - (CASE WHEN 40 > 0 THEN 0 ELSE 40 END - 1)) THEN (length(varchar(g_0.TIMESTAMPVALUE)) - (CASE WHEN 40 > 0 THEN 0 ELSE 40 END - 1)) ELSE 0 END) FROM SMALLA AS g_0 WHERE g_0.INTKEY = 1
Result: Caused by: com.ibm.db2.jcc.am.SqlDataException: DB2 SQL Error: SQLCODE=-138, SQLSTATE=22011, SQLERRMC=null, DRIVER=4.12.55
> DB2 - error getting substring if "from position" is out of range
> ----------------------------------------------------------------
>
> Key: TEIID-3600
> URL: https://issues.jboss.org/browse/TEIID-3600
> Project: Teiid
> Issue Type: Quality Risk
> Components: Misc. Connectors
> Reporter: Juraj Duráni
> Assignee: Steven Hawkins
> Fix For: 8.12
>
>
> If second argument of a SUBSTRING(x,y,z) function is out of range of first argument an exception is thrown [1]. Source-specific command [2].
> [1]
> Caused by: com.ibm.db2.jcc.am.SqlDataException: DB2 SQL Error: SQLCODE=-138, SQLSTATE=22011, SQLERRMC=null, DRIVER=4.12.55
> at com.ibm.db2.jcc.am.hd.a(hd.java:668)
> at com.ibm.db2.jcc.am.hd.a(hd.java:60)
> ...
> [2]
> SELECT substr(varchar(g_0.TimestampValue), 40, CASE WHEN 0 > (length(varchar(g_0.TimestampValue)) - (40 - 1)) THEN (length(varchar(g_0.TimestampValue)) - (40 - 1)) ELSE 0 END) FROM SmallA AS g_0 WHERE g_0.IntKey = 1
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
9 years, 10 months