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

Oleg Zinoviev edited comment on IGNITE-21421 at 8/24/26 3:42 PM:
-----------------------------------------------------------------

[~alex_pl] 

Hi

Can I try to solve the issue with using search bounds for such predicates?
I have an almost working solution: I’m running into unclear problems where the 
query planner prefers a table scan over an index scan for 
{{{}CacheAtomicityMode.ATOMIC{}}}.


was (Author: le.louch):
[~alex_pl] 

Can I try to solve the issue with using search bounds for such predicates?
I have an almost working solution: I’m running into unclear problems where the 
query planner prefers a table scan over an index scan for 
{{{}CacheAtomicityMode.ATOMIC{}}}.

> Calcite engine. Tuple (row) comparison is not working
> -----------------------------------------------------
>
>                 Key: IGNITE-21421
>                 URL: https://issues.apache.org/jira/browse/IGNITE-21421
>             Project: Ignite
>          Issue Type: Bug
>            Reporter: Aleksey Plekhanov
>            Assignee: Aleksey Plekhanov
>            Priority: Major
>              Labels: ise
>
> Currentrly, row comparison fails with an error and don't use index.
> Reproducer:
> {code:java}
> sql("CREATE TABLE test (id INTEGER, val INTEGER)");
> sql("CREATE INDEX test_idx ON test (id, val)");
> sql("INSERT INTO test VALUES (0, 0), (0, 1), (1, 0), (1, 1)");
> assertQuery("SELECT * FROM test WHERE (id, val) >= (?, ?)")
>     .withParams(0, 1)
>     //.matches(QueryChecker.containsIndexScan("PUBLIC", "TEST", "TEST_IDX"))
>     .returns(0, 1)
>     .returns(1, 0)
>     .returns(1, 1)
>     .check(); {code}
> Exception:
> {noformat}
> Caused by: java.lang.RuntimeException: while resolving method 'ge[class 
> [Ljava.lang.Object;, class [Ljava.lang.Object;]' in class class 
> org.apache.calcite.runtime.SqlFunctions
>     at org.apache.calcite.linq4j.tree.Types.lookupMethod(Types.java:318)
>     at org.apache.calcite.linq4j.tree.Expressions.call(Expressions.java:449)
>     at 
> org.apache.ignite.internal.processors.query.calcite.exec.exp.RexImpTable$BinaryImplementor.implementSafe(RexImpTable.java:1233)
>     at 
> org.apache.ignite.internal.processors.query.calcite.exec.exp.RexImpTable$AbstractRexCallImplementor.genValueStatement(RexImpTable.java:1950)
>     at 
> org.apache.ignite.internal.processors.query.calcite.exec.exp.RexImpTable$AbstractRexCallImplementor.implement(RexImpTable.java:1911)
> {noformat}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to