[ 
https://issues.apache.org/jira/browse/ASTERIXDB-2921?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Glenn Justo Galvizo resolved ASTERIXDB-2921.
--------------------------------------------
    Resolution: Fixed

> INLJ w/ Quantification
> ----------------------
>
>                 Key: ASTERIXDB-2921
>                 URL: https://issues.apache.org/jira/browse/ASTERIXDB-2921
>             Project: Apache AsterixDB
>          Issue Type: New Feature
>          Components: IDX - Indexes
>            Reporter: Glenn Justo Galvizo
>            Assignee: Glenn Justo Galvizo
>            Priority: Major
>
> The following query should be optimized, but currently isn't:
> {code:java}
> SET `compiler.arrayindex` "true";
> DROP DATAVERSE TestYelp IF EXISTS;
> CREATE DATAVERSE TestYelp;
> USE TestYelp;
> CREATE TYPE CheckinType AS {
>     checkin_id: uuid,
>     business_id: string,
>     dates: [string]
>     };
> CREATE TYPE CheckinDatesToMarkersType AS {
>     marker: string,
>     datetime: string,
>     date: string,
>     time: string
>     };
> CREATE DATASET YelpCheckin(CheckinType) PRIMARY KEY checkin_id AUTOGENERATED;
> CREATE DATASET YelpCheckinDateMarkers (CheckinDatesToMarkersType) PRIMARY KEY 
> marker;
> CREATE INDEX IdxYelpCheckinDates ON YelpCheckin (UNNEST dates);
> FROM    YelpCheckinDateMarkers M, YelpCheckin C
> WHERE   M.datetime /*+ indexnl */ IN C.dates AND 
>         C.business_id = "--Ni3oJ4VOqfOEu7Sj2Vzg"
> SELECT  COUNT(*);
> {code}
> Grammar support needs to be added to recognize the INLJ hint in quantified 
> expressions, and the same "throwaway branch" optimization from the SELECT-AM 
> rule needs to be performed for the JOIN-AM rule. 



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

Reply via email to