Chen Luo created ASTERIXDB-2765:
-----------------------------------
Summary: Indentify Secondary Index-Only Plans without WHERE
conditions
Key: ASTERIXDB-2765
URL: https://issues.apache.org/jira/browse/ASTERIXDB-2765
Project: Apache AsterixDB
Issue Type: Wish
Reporter: Chen Luo
Assignee: Dmitry Lychagin
Currently, a secondary index is only picked if its secondary key is used in the
WHERE clause. This limits the applicability of secondary index plans.
For example, consider the following dataset User(+id+, name, salary) with a
secondary index on salary. The following query
{code:java}
select max(salary)
from User
{code}
will not pick the secondary index, even though a secondary index-only plan is
appcalible.
This query is equivalent to the following query (assuming all salaries are
non-negative), where the secondary index will be picked.
{code:java}
select max(salary)
from User
where salary >= 0
{code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)