You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ignite.apache.org by "Pavel Pereslegin (Jira)" <ji...@apache.org> on 2025/07/10 09:13:00 UTC
[jira] [Updated] (IGNITE-25768) Sql. Invalid search boundaries are generated when accessing the index if the key is out of range
[ https://issues.apache.org/jira/browse/IGNITE-25768?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Pavel Pereslegin updated IGNITE-25768:
--------------------------------------
Component/s: (was: sql)
> Sql. Invalid search boundaries are generated when accessing the index if the key is out of range
> ------------------------------------------------------------------------------------------------
>
> Key: IGNITE-25768
> URL: https://issues.apache.org/jira/browse/IGNITE-25768
> Project: Ignite
> Issue Type: Bug
> Components: sql ai3
> Reporter: Pavel Pereslegin
> Priority: Major
> Labels: ignite-3
>
> Consider the following:
> {code:sql}
> CREATE TABLE t (id INT PRIMARY KEY, val TINYINT);
> CREATE INDEX t_val_idx ON t (val);
> {code}
> PLAN TableScan vs IndexScan
> {code:sql}
> sql("EXPLAIN SELECT /*+ NO_INDEX */ * FROM t WHERE val = ?", 100500)
> sql("EXPLAIN SELECT /*+ FORCE_INDEX(t_val_idx) */ * FROM t WHERE val = ?", 100500)
> {code}
> {noformat}
> TableScan
> table: PUBLIC.T
> predicate: =(CAST(VAL):INTEGER, ?0)
> IndexScan
> table: PUBLIC.T
> index: T_VAL_IDX
> predicate: =(CAST(VAL):INTEGER, ?0)
> searchBounds: [ExactBounds [bound=CAST(?0):TINYINT]]
> {noformat}
> As a result: TableScan returns no rows, but IndexScan fails with:
> {noformat}
> Caused by: org.apache.ignite.internal.sql.engine.exec.RemoteFragmentExecutionException: IGN-SQL-7 TINYINT out of range TraceId:e329e323
> at org.apache.ignite.internal.sql.engine.exec.ExecutionServiceImpl.onMessage(ExecutionServiceImpl.java:575)
> ... 7 more
> {noformat}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)