ignite-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (IGNITE-7113) "Key is missing from query" when creating table with key_type=java.lang.String
Date Thu, 07 Dec 2017 17:15:00 GMT

    [ https://issues.apache.org/jira/browse/IGNITE-7113?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16282182#comment-16282182
] 

ASF GitHub Bot commented on IGNITE-7113:
----------------------------------------

GitHub user alexpaschenko opened a pull request:

    https://github.com/apache/ignite/pull/3176

    IGNITE-7113 Processing of redundant type names

    

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/gridgain/apache-ignite ignite-7113

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/ignite/pull/3176.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #3176
    
----
commit 071d55881db33cadcda40b568978bca3a151d8b3
Author: Alexander Paschenko <alexander.a.paschenko@gmail.com>
Date:   2017-12-07T17:11:11Z

    IGNITE-7113 Processing of redundant type names

----


> "Key is missing from query" when creating table with key_type=java.lang.String
> ------------------------------------------------------------------------------
>
>                 Key: IGNITE-7113
>                 URL: https://issues.apache.org/jira/browse/IGNITE-7113
>             Project: Ignite
>          Issue Type: Bug
>          Components: sql
>    Affects Versions: 2.3
>            Reporter: Ilya Kasnacheev
>            Assignee: Alexander Paschenko
>         Attachments: IgniteStringKeyTest.java
>
>
> When creating a table of
> {code}
> CREATE TABLE IF NOT EXISTS TableWithStringKey (
>       ID VARCHAR PRIMARY KEY,
>       DataNodeId VARCHAR
> ) WITH "backups=1, cache_name=TableWithStringKey, atomicity=transactional, key_type=java.lang.String,
value_type=TableWithStringKey"
> {code}
> and attempting an insert later
> {code}
> INSERT INTO TableWithStringKey (ID, DataNodeId) VALUES ('ref2', 'src2')
> {code}
> There's suddently an exception
> {code}
> javax.cache.CacheException: class org.apache.ignite.internal.processors.query.IgniteSQLException:
Failed to execute DML statement [stmt=INSERT INTO TableWithStringKey (ID, DataNodeId) VALUES
('ref2', 'src2'), params=null]
> 	at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:597)
> 	at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:560)
> 	at org.apache.ignite.internal.processors.cache.GatewayProtectedCacheProxy.query(GatewayProtectedCacheProxy.java:382)
> 	at com.gridgain.reproducer.IgniteStringKeyTest.insertTest(IgniteStringKeyTest.java:34)
> 	... 24 more
> Caused by: class org.apache.ignite.internal.processors.query.IgniteSQLException: Failed
to execute DML statement [stmt=INSERT INTO TableWithStringKey (ID, DataNodeId) VALUES ('ref2',
'src2'), params=null]
> 	at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.queryDistributedSqlFields(IgniteH2Indexing.java:1459)
> 	at org.apache.ignite.internal.processors.query.GridQueryProcessor$5.applyx(GridQueryProcessor.java:1909)
> 	at org.apache.ignite.internal.processors.query.GridQueryProcessor$5.applyx(GridQueryProcessor.java:1907)
> 	at org.apache.ignite.internal.util.lang.IgniteOutClosureX.apply(IgniteOutClosureX.java:36)
> 	at org.apache.ignite.internal.processors.query.GridQueryProcessor.executeQuery(GridQueryProcessor.java:2445)
> 	at org.apache.ignite.internal.processors.query.GridQueryProcessor.querySqlFields(GridQueryProcessor.java:1914)
> 	at org.apache.ignite.internal.processors.cache.IgniteCacheProxyImpl.query(IgniteCacheProxyImpl.java:585)
> 	... 27 more
> Caused by: class org.apache.ignite.IgniteCheckedException: Key is missing from query
> 	at org.apache.ignite.internal.processors.query.h2.dml.UpdatePlanBuilder.createSupplier(UpdatePlanBuilder.java:369)
> 	at org.apache.ignite.internal.processors.query.h2.dml.UpdatePlanBuilder.planForInsert(UpdatePlanBuilder.java:211)
> 	at org.apache.ignite.internal.processors.query.h2.dml.UpdatePlanBuilder.planForStatement(UpdatePlanBuilder.java:98)
> 	at org.apache.ignite.internal.processors.query.h2.DmlStatementsProcessor.getPlanForStatement(DmlStatementsProcessor.java:473)
> 	at org.apache.ignite.internal.processors.query.h2.DmlStatementsProcessor.updateSqlFields(DmlStatementsProcessor.java:170)
> 	at org.apache.ignite.internal.processors.query.h2.DmlStatementsProcessor.updateSqlFieldsDistributed(DmlStatementsProcessor.java:229)
> 	at org.apache.ignite.internal.processors.query.h2.IgniteH2Indexing.queryDistributedSqlFields(IgniteH2Indexing.java:1453)
> 	... 33 more
> {code}
> that goes away if you remove "key_type=java.lang.String"
> I'm attaching a reproducer class.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message