You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@asterixdb.apache.org by "Glenn Justo Galvizo (Jira)" <ji...@apache.org> on 2021/07/31 23:06:00 UTC

[jira] [Created] (ASTERIXDB-2937) Use atomic prefix from array indexes in queries w/o array element.

Glenn Justo Galvizo created ASTERIXDB-2937:
----------------------------------------------

             Summary: Use atomic prefix from array indexes in queries w/o array element.
                 Key: ASTERIXDB-2937
                 URL: https://issues.apache.org/jira/browse/ASTERIXDB-2937
             Project: Apache AsterixDB
          Issue Type: Improvement
          Components: IDX - Indexes
            Reporter: Glenn Justo Galvizo


Given the multi-valued index:

 
{code:java}
CREATE INDEX someIdx ON SomeDataset (
    field1, 
    field2,
    UNNEST arrayField 
    SELECT field3, field4
);{code}
The following query could take advantage of the index above:
{code:java}
FROM   SomeDataset D
WHERE  D.field1 = 1 AND D.field2 = 2
SELECT *;{code}
but is currently not. This is because we delay recognition of array index applicability until we see the array component of an array index. Work to realize this involves improving how we make the decision to use a prefix search for array indexes.

 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)