[ https://issues.apache.org/jira/browse/IGNITE-17250?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Vladimir Steshin updated IGNITE-17250: -------------------------------------- Ignite Flags: Release Notes Required (was: Docs Required,Release Notes Required) > Calcite. Make 'min()/max()' use first/last index value. > ------------------------------------------------------- > > Key: IGNITE-17250 > URL: https://issues.apache.org/jira/browse/IGNITE-17250 > Project: Ignite > Issue Type: Improvement > Reporter: Vladimir Steshin > Assignee: Vladimir Steshin > Priority: Major > Labels: ise > Time Spent: 1h 10m > Remaining Estimate: 0h > > Currently, Calcite's plan on min()/max() is the table scan and the > aggregation n the indexed field: > {code:sql} > "select min(salary) from Person" > {code} > Plan: > {code:java} > IgniteReduceHashAggregate(group=[{}], MAX(SALARY)=[MAX($0)]) > IgniteExchange(distribution=[single]) > IgniteMapHashAggregate(group=[{}], MAX(SALARY)=[MAX($0)]) > IgniteTableScan(table=[[PUBLIC, PERSON]], requiredColumns=[{3}]) > {code} > We could pick up first index record. No need to scan. -- This message was sent by Atlassian Jira (v8.20.10#820010)