[teiid-issues] [JBoss JIRA] (TEIID-5060) Infinispan Hotrod Translator UPDATE on primary key column

Ramesh Reddy (JIRA) issues at jboss.org
Wed Sep 13 12:52:00 EDT 2017


    [ https://issues.jboss.org/browse/TEIID-5060?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13463631#comment-13463631 ] 

Ramesh Reddy commented on TEIID-5060:
-------------------------------------

You are comparing the StringKey with an integer value. The latest master code fails with a resolution error which is correct. I would think any implicit conversions will be done before it reaches the translator layer. May be this check is not there in 6.4. [~shawkins] should know.

{code}
11:48:18,677 WARN  [org.teiid.PROCESSOR] (Worker8_QueryProcessorQueue66) TmA7S72KI8PR TEIID30020 Processing exception for request TmA7S72KI8PR.11 'TEIID31172 Could not resolve expressions being compared to a common type excluding character conversions: CRUD.SmallA.StringNum > 30'. Originally QueryResolverException ResolverVisitor.java:1041.: org.teiid.api.exception.query.QueryResolverException: TEIID31172 Could not resolve expressions being compared to a common type excluding character conversions: CRUD.SmallA.StringNum > 30
	at org.teiid.query.resolver.util.ResolverVisitor.resolveCompareCriteria(ResolverVisitor.java:1041)
	at org.teiid.query.resolver.util.ResolverVisitor.visit(ResolverVisitor.java:245)
	at org.teiid.query.sql.lang.CompareCriteria.acceptVisitor(CompareCriteria.java:126)
	at org.teiid.query.sql.navigator.AbstractNavigator.visitVisitor(AbstractNavigator.java:50)
	at org.teiid.query.sql.navigator.PreOrPostOrderNavigator.postVisitVisitor(PreOrPostOrderNavigator.java:57)
	at org.teiid.query.resolver.command.SimpleQueryResolver$QueryResolverVisitor.postVisitVisitor(SimpleQueryResolver.java:219)
	at org.teiid.query.sql.navigator.PreOrPostOrderNavigator.visit(PreOrPostOrderNavigator.java:131)
	at org.teiid.query.sql.lang.CompareCriteria.acceptVisitor(CompareCriteria.java:126)
	at org.teiid.query.sql.navigator.AbstractNavigator.visitNode(AbstractNavigator.java:59)
	at org.teiid.query.resolver.command.SimpleQueryResolver$QueryResolverVisitor.visit(SimpleQueryResolver.java:234)
	at org.teiid.query.resolver.command.SimpleQueryResolver.resolveCommand(SimpleQueryResolver.java:66)
	at org.teiid.query.resolver.QueryResolver.resolveCommand(QueryResolver.java:282)
	at org.teiid.query.resolver.QueryResolver.resolveCommand(QueryResolver.java:128)
	at org.teiid.dqp.internal.process.Request.resolveCommand(Request.java:278)
	at org.teiid.dqp.internal.process.Request.generatePlan(Request.java:414)
	at org.teiid.dqp.internal.process.Request.processRequest(Request.java:482)
	at org.teiid.dqp.internal.process.RequestWorkItem.processNew(RequestWorkItem.java:655)
	at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:334)
	at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:47)
	at org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:271)
	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}

> Infinispan Hotrod Translator UPDATE on primary key column
> ---------------------------------------------------------
>
>                 Key: TEIID-5060
>                 URL: https://issues.jboss.org/browse/TEIID-5060
>             Project: Teiid
>          Issue Type: Bug
>          Components: JDG Connector, Misc. Connectors
>            Reporter: Jan Stastny
>            Assignee: Ramesh Reddy
>            Priority: Blocker
>             Fix For: 10.0
>
>
> UPDATE query where the PRIMARY KEY of the table is being changed succeeds, returns update count of corresponding rows, but the changes don't get promoted to actual cache.
> Consider
> {code:sql|title=UPDATE query}
> UPDATE SmallA SET StringKey = 100 WHERE IntKey > 25
> {code}
> where StringKey is set as PRIMARY KEY and 6 rows fulfill the filter on IntKey>25.
> When this UPDATE is performed, returned number of rows update is 6, but the contents of the cache don't change.
> There are several applicable resolutions:
> # There should be error thrown by Teiid, that this is not allowed operation
> # There should be update count 0 returned
> # There should be change in JDG cache, effectively squashing the 6 rows into single one
> # There should be error thrown by Teiid, that there is duplicate PK value (this is not something Teiid usually enforces)



--
This message was sent by Atlassian JIRA
(v7.2.3#72005)


More information about the teiid-issues mailing list